Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

al256

macrumors 6502a
Original poster
Jun 7, 2001
946
782
Sorry to bring this up again after it was recently covered, https://forums.macrumors.com/threads/354078/

but, I deleted my var alias while cleaning up my harddrive before a complete backup. I was about to run OnyX but was unable to because my password no longer worked. I restarted and was forced to create a new account. Help!

Because I do backup I have a month old copy of everything, including that var. I want to know which is the best route to take to try and restore my old user account. Do I follow the previous thread? Does someone else have a different idea? Is it better to somehow move all my files over to this newly created account?

On a side note: When I tried to bootup using my external USB drive it went into a darwin like mode then froze, then I restarted only to find I can't use it to bootup. This has worked perviously in times of need.
 

Makosuke

macrumors 604
Aug 15, 2001
6,665
1,250
The Cool Part of CA, USA
To confirm, we're talking about the alias at /var, or the whole folder at /private/var?

If it's the alias, you should theoretically be able to just recreate it. If it's the actual var directory, you can theoretically copy it over from your backup and it SHOULD work... but that's not what I'd do.

I believe the safest thing to do (or at least the one that would cause the least weirdness down the road) would be to do a full Archive and Install of the OS; assuming you didn't delete anything in your home directory, that should give you a clean copy of the OS with your user data intact.

Alternately, if you also wiped something from your user account or want the REALLY long one, you could: backup your files, do a clean install of the OS, then use the Migration Assistant to bring your users over from your month-old backup, and finally manually copy over any files modified within the last month from the backup of the screwed-up one.

That's pretty foolproof, albeit time consuming.
 

al256

macrumors 6502a
Original poster
Jun 7, 2001
946
782
To confirm, we're talking about the alias at /var, or the whole folder at /private/var?

If it's the alias, you should theoretically be able to just recreate it. If it's the actual var directory, you can theoretically copy it over from your backup and it SHOULD work... but that's not what I'd do.

I believe the safest thing to do (or at least the one that would cause the least weirdness down the road) would be to do a full Archive and Install of the OS; assuming you didn't delete anything in your home directory, that should give you a clean copy of the OS with your user data intact.

Alternately, if you also wiped something from your user account or want the REALLY long one, you could: backup your files, do a clean install of the OS, then use the Migration Assistant to bring your users over from your month-old backup, and finally manually copy over any files modified within the last month from the backup of the screwed-up one.

That's pretty foolproof, albeit time consuming.

Well, the folder had that alias little arrow. That's why I felt comfortable removing it. Is there oddly someway that the OS needs the alias to be there to function as my user account? Could everything be safe and sound somewhere on my harddrive? If so, where could I find it? How would I put it back there in a functional way?
 

SC68Cal

macrumors 68000
Feb 23, 2006
1,642
0
You might have just deleted the alias. You can recreate it. If you deleted the actual directory that the alias points to, then you're screwed.

What did you use to delete it? Finder? rm? what parameters did you use if you used rm?

The rm utility removes symbolic links, not the files referenced by the
links.

Here's what the alias should be set to.

Code:
lrwxr-xr-x     1 root      admin       11 Aug  4 18:31 var -> private/var

Be a little more careful with what you do while running as root?
 

al256

macrumors 6502a
Original poster
Jun 7, 2001
946
782
You might have just deleted the alias. You can recreate it. If you deleted the actual directory that the alias points to, then you're screwed.

What did you use to delete it? Finder? rm? what parameters did you use if you used rm?



Here's what the alias should be set to.

Code:
lrwxr-xr-x     1 root      admin       11 Aug  4 18:31 var -> private/var

Be a little more careful with what you do while running as root?

I just used the Finder and typed the password. Root isn't activated on my machine. Thank you for your response.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.