Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
Hi. Is there anything special about a home directory before users' home directories are stored there, or is just as typical as any other "empty" folder?
Let me just cut to the chase, but please no ear ringing about the folly of messing around as root, particularly with directories at root level. I know it's considered stupidity, but I deleted my home directory.
Is there an easy way to restore a working home directory? I tried copying /etc/skel under root, but I'm not sure what a home directory should look like once it has been restored. Besides . & .., there were .screenrc & .xsession in my home directory when I copied /etc/skel. Are these files suppose to be in "/home" or "/home/~" or both?
First, /home contains all of the user's directories... as in there is a folder for each user corresponding with their username in /home. So my /home is really "/home/keithieopia" You shouldn't really need to copy anything from "/etc/skel" most Linux applications will create whatever file they need automatically in your home directory... but better safe that sorry.
So if your deleted your /home/USERNAME type the following commands as root to fix it (replace USERNAME with your actual username):
Erm... if you deleted "/home" then everything under "/home" such as "/home/keithieopia" is also deleted. Did you do one of these: "rm -r"? If so, that's the case. You'll need to just "mkdir /home" before the rest of my instructions:
Or to directly answer your question, "/home" is just a folder with 755 permissions. However .xsession and .screenrc should not have been in the /home folder but a /home/USERNAME folder. Not sure why they were there.
Last edited by keithieopia; 06-19-2010 at 08:58 PM.
Reason: screenrc in /home confusion
It should be doable by messing around with you /etc/fstab file. Theoretically, in Linux, you can mount any drive partition to any empty folder. It all depends on exactly what you want to do with this, and the permissions you assign to both the folder you created and the partition to be mounted. Look up the 'mount' command (man -k mount or info mount) Hope you get your system back up and running!