1 2 3 Previous Next 34 Replies Latest reply: Apr 10, 2012 9:56 AM by FrenchToast
Serenna Level 1 Level 1 (0 points)

Hi, first I know that what I did was stupid but I didnt know what I was doing.. and I still don’t know what are the consequences.

In order to save space on my MBP 2011 Snow Leopard, I deleted private/var/db folder, yes the whole folder to the trashbin and then I emptied it. Files that were in use weren´t deleted.

So I rebooted and the screen is stuck on apple logo with the turning wheel and safe boot start normally but end up with the turning wheel too.

 

How can I put fix this issue?

Can I recover the files deleted ? Or at least put back the files that are still in the trash bin ?

 

Thank you for any help.


MacBook Pro, Mac OS X (10.6.8)
  • 1. Re: Deleted private/var/db folder.... Can't boot
    Kappy Level 10 Level 10 (226,775 points)

    You will have to reinstall Snow Leopard.

     

    Reinstall OS X without erasing the drive

     

    Do the following:

     

    1. Repair the Hard Drive and Permissions

     

    Boot from your Snow Leopard Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Utilities menu. After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list.  In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive.  If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the installer.

     

    If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.

     

    2. Reinstall Snow Leopard

     

    If the drive is OK then quit DU and return to the installer.  Proceed with reinstalling OS X.  Note that the Snow Leopard installer will not erase your drive or disturb your files.  After installing a fresh copy of OS X the installer will move your Home folder, third-party applications, support items, and network preferences into the newly installed system.

     

    Download and install the Combo Updater for 10.6.8 from support.apple.com/downloads/.

  • 2. Re: Deleted private/var/db folder.... Can't boot
    Limnos Level 8 Level 8 (38,455 points)

    If the files are still in trash you should be able to boot to Single User Mode and replace them with a move (mv) command, but it would take me a long time to work out the details.  Maybe somebody else who is more regularly familiar with using Terminal and is actually running a copy of Snow Leopard (I use Tiger) could help.

  • 3. Re: Deleted private/var/db folder.... Can't boot
    Kappy Level 10 Level 10 (226,775 points)

    He's already deleted them, so no way to restore them from the Trash.

  • 4. Re: Deleted private/var/db folder.... Can't boot
    Limnos Level 8 Level 8 (38,455 points)

    the whole folder to the trashbin and then I emptied it. Files that were in use weren´t deleted.

    Or at least put back the files that are still in the trash bin

    Sorry just registered the second part. Yes, reinstall SL.

  • 5. Re: Deleted private/var/db folder.... Can't boot
    Serenna Level 1 Level 1 (0 points)

    Thank you for your answers, well the files that the OSX were using weren't deleted and are still in the trashbin, so I think they are the critical one and can be restored no?

    I would like to use the installation DVD but Im far far from my home and I didn't take the dvd so I ll try one of a friend when I can.

  • 6. Re: Deleted private/var/db folder.... Can't boot
    Limnos Level 8 Level 8 (38,455 points)

    If you borrow a DVD it will have to be either a retail version or she/he has to have a computer identical to the one you have.  Discs that came with a Mac will only work in that model.

  • 7. Re: Deleted private/var/db folder.... Can't boot
    Kappy Level 10 Level 10 (226,775 points)

    No, you need to have everything replaced that was deleted, not just those in use.

  • 8. Re: Deleted private/var/db folder.... Can't boot
    Kappy Level 10 Level 10 (226,775 points)

    If they borrow a disc it's possible to replace just the deleted directory using Pacifist:

     

    How Restore Deleted or Missing OS X Components

     

    A few of the basic OS X installed applications can be restored from the Optional Installs installer located in the Optional installs folder on your Installer DVD.  However, if what you need is not there then follow the instructions below.

     

    How to Use Pacifist to Restore Deleted or Missing OS X Components

     

    Insert the OS X Installer DVD into the optical drive.  Use a simple utility like TinkerTool to toggle invisibility so you can see invisible items.  Alternatively, open the Terminal application in your Utilities folder and at the prompt enter the following:

     

    defaults write com.apple.finder AppleShowAllFiles Yes

     

    Press RETURN.

     

    To turn off the display of invisible files repeat the above command substituting No for Yes.

     

    The install packages are located in the /System/Installation/ folder on the DVD.

     

    Download the shareware utility Pacifist. Use it to extract a fresh copy of the missing item(s) from the file archives on your OS X installation DVD. The file archives are in the /System/Installations/ folder (use Go to Folder option in the Go menu of the Finder.)

     

    Here are Four Basic ways to use Pacifist (courtesy of George Orville.)

     

    1. Drag a .pkg icon onto the Pacifist window .....proceed to step 7.
    2. Click on “Open Package ....” and navigate to package desired and click “Open” in the open/save window.....proceed to step 7.
    3. Insert Mac OS X installer CD and when it mounts, navigate to .... Menu->Go->Go to Folder. In the path field enter or paste ....

     

    /Volumes/disc name/System/Installation/Packages (where disc name is the name of the CD/DVD that you inserted.)

     

    Click on the  "Go" button ..... • Drag a .pkg to Pacifist..... proceed to step 7.

     

    The package you'll need will have to be discovered by trial and error, but for most applications you should start with the Essentials.pkg and/or Additional Essentials.pkg.

     

    D. Insert your Mac OS X install disk 1 .... and open Pacifist.

     

    1.          In Pacifist, select "Open Mac OS X Install Packages" ... dialog may appear asking for disk 2, then disk 3 and finally disk 1 again.... {if DVD is not used)...If “Stop Loading” is selected...the procedure will stop!!!

     

    2a. When loading is complete, a new window appears, click the triangle to display contents of each package...Select item and proceed to step 7.

     

    2b.          or click the “Find” icon in the Pacifist window and type the name of the software you need.

     

    3.          In the list that comes back, click the top most entry for the item that you want. ..... that is the one for the English language.

     

    4.          On the top of the Pacifist window, click “verify” .... you will probably be prompted for your password.

     

    5.          Enter checks for.... “verify permissions” and “verify file contents.” and click “verify” ....enter password when prompted.... you will get back output which may look like this:

     

              20 files were scanned. 20 of 20 files were present on the hard disk. 0 of 20 files had file permissions that did not match those specified in the package. 0 of 20 files had checksums that did not match those specified in the package.

     

    6.          Click “close”. Go to step 7.

     

    Extract or Install........

     

    7.          In the Toolbar (upper left), you now have the option to extract or install. Click a file in the lower list and those two icons will be enabled.

     

    8.          If “Extract to...” is selected.... navigate to the location where the file will be placed, select “choose”, select “extract” in new dialog that appears,authenicate , if prompted, click “OK”.

     

    9.          In the next dialog, click “Extract”.

     

    10.          If “Install” is selected... dialog will appear with the location/path of the installed software. Click “Install”

     

    11.          Type in your password, click “OK”

     

    Pacifist will begin to extract files.

     

    12.          In steps 8/10ß.... you also have the choice to “cancel”

     

    Notes:          Pacifist may find that a file it is installing already exists on the hard disk. Pacifist will present you with an alert panel....

     

    • Stop
    • Leave original alone
    • Update .....
    • Default selection
    • Replace .... (Replace option should only be used on full install packages)
  • 9. Re: Deleted private/var/db folder.... Can't boot
    Serenna Level 1 Level 1 (0 points)

    This is the kind of solutions I was hoping for. Thank you very much, I'll try it as soon as possible and let you know the results.

  • 10. Re: Deleted private/var/db folder.... Can't boot
    Serenna Level 1 Level 1 (0 points)

    When I boot with the installation dvd of a friend it says to reboot the mac and then the turning wheel with apple logo appear again, so it's not working. Yet I have isolated the db file from the cd, can I insert it in some way using the single user mode ? Or boot from another drive and acess my snow leopard partition and remplace it ?

  • 11. Re: Deleted private/var/db folder.... Can't boot
    Kappy Level 10 Level 10 (226,775 points)

    The procedure requires you use Pacifist to reinstall the entire folder whose contents you deleted. This is done by carefully following the directions I sent you.

     

    From your description I don't know what you did. If you booted from an installation disc, then all you can do is reinstall OS X from it.

  • 12. Re: Deleted private/var/db folder.... Can't boot
    Limnos Level 8 Level 8 (38,455 points)

    When I boot with the installation dvd of a friend it says to reboot the mac and then the turning wheel with apple logo appear again, so it's not working.

    Note what I said earlier about borrowed DVDs.

  • 13. Re: Deleted private/var/db folder.... Can't boot
    Serenna Level 1 Level 1 (0 points)

    I thought I had to insert the installation dvd in my mac for the first step of using pacifist, I misunderstood. But anyways I only have a windows xp  laptop to help me, so I cannot use pacifist.

  • 14. Re: Deleted private/var/db folder.... Can't boot
    Kappy Level 10 Level 10 (226,775 points)

    Then I would find a suitable installer disc for your computer and reinstall OS X. You will need the same version as you now have installed or later. Otherwise, you will need to erase the drive to install a different point version (like 10.6 versus 10.7.)

     

    For Snow Leopard do this:

     

    Reinstall OS X without erasing the drive

     

    Do the following:

     

    1. Repair the Hard Drive and Permissions

     

    Boot from your Snow Leopard Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Utilities menu. After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list.  In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive.  If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the installer.

     

    If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.

     

    2. Reinstall Snow Leopard

     

    If the drive is OK then quit DU and return to the installer.  Proceed with reinstalling OS X.  Note that the Snow Leopard installer will not erase your drive or disturb your files.  After installing a fresh copy of OS X the installer will move your Home folder, third-party applications, support items, and network preferences into the newly installed system.

     

    Download and install the Combo Updater 10.6.8 from support.apple.com/downloads/.


1 2 3 Previous Next