Please help urgently

alipo

Registered
I wanted to reset password on a mac and used the following commands:

mount -ow /
rm /var/ db .AppleSetyupDone
shutdown -h now

when I rebooted, the machine just hangs there with the apple logo on the grey screen.

What can i do to reverse this - please help!!
 
If you typed those lines as that, first problem was with mount -ow.

Second, if there was a space in
rm /var/ db .AppleSetyupDone
before db, basically the way the system read that command was rm /var/

Back to the initial problem, reseting the password - that's done differently.
Get the install discs that came with that Mac, OR if it has a later OS than it was shipped with (if it shipped with 10.5 and you have now 10.6 or similar) then the discs of that later OS, restart the Mac from the disc (alt, or C at boot).
Select from the install menu the option to reset the password.

To get back /var/ that you removed with the command line acrobatics above, get the install discs and do an archive&install. Manually creating a /var/ would not do the trick to get everything back there in a working order.
 
I initially thought that /var would have been removed as well (in fact, I typed a lengthy reply assuming so and had to delete it!), but a simple "rm" command without an "-r" switch will not remove a directory. I think the /var directory is safe.

Still, it does sound like some system-level file was removed due to bad formatting of that second line of code he/she posted.
 
Yes, but only the system data that was deleted.

If you put anything custom (documents, etc.) or modified any files in /var or any place that was deleted, an Archive & Install will not "bring back" those changes.

Short answer is that an Archive & Install should get you up and running again, but it's not going to "unerase" anything that's not included with the system (music files you downloaded, documents you created, etc.).
 
... but it's not going to "unerase" anything that's not included with the system (music files you downloaded, documents you created, etc.).
I think that you mean that it will not "erase" anything that in not in the System. All user files will be left untouched. The previous System is replaced, but not erased. Anything needed on the new System can be dragged over from the previous System--unless it is corrupt.
 
True and false: I truly did mean that performing an Archive & Install will not "unerase" any user-created files that may have been deleted.

An Archive & Install will not "erase" any user-created files, but it will also not "unerase" any user-created file either. The user asked "will i get the data back that i had on the machine?", and the answer to that is: if the "data" is system-related and was deleted, then yes. If it's user-created and was deleted, then no.
 
Back
Top