How to get to user files in single user mode

Hello,

For making a long story short - I accidentally deleted /usr/lib/*. Now, I have a tar of directory that I had created, and it is extracted in /home/user/libfolder. However, I can't log in because libpam is missing. So I am in single user mode, however /home is empty.

How do I see all my user files while I am in single user mode so I can move the libraries into /usr/lib?
 
Keep in mind when booting to single user mode that only the root (/) filesystem is mounted, read-only. Nothing else is loaded and no other filesystems are mounted.

Basic single user mode stanza:
Code:
fsck -y         # Check filesystems for errors
mount -u /      # re-mount root as read/write
mount -a -u ufs # mount all UFS filesystems
swapon -a       # Enable swap
 
II had read that about the root file system being read only. I have tried to mount -a with no luck.
I gave up on trying to get this system back up, and just created a new VM. This one had minimal amounts of necessary files on it so at this point it was faster to just re-create those files than trying to get this system back in working order.
 
If it's a ZFS system you may need to run zfs mount -a. The mount -a command only works for filesystems that are in /etc/fstab (ZFS filesystems usually aren't).
 
Ah. You are probably correct that's what the problem was. It was in fact a ZFS system. Thanks for the help! I'll remember for next time.
 
Back
Top