The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
running sshd server from home directory without root access sayeo SUN Solaris 0 03-13-2008 01:53 PM
Can't login root account due to can't find root shell neikel AIX 2 01-30-2008 08:07 PM
Root cannot change /home permission moe2266 UNIX for Dummies Questions & Answers 6 10-31-2007 07:19 AM
how to access root priveliges if root password is lost wojtyla Linux 1 02-18-2005 03:24 AM
Run non-root script as root with non-root environment bubba112557 UNIX for Dummies Questions & Answers 2 12-02-2004 09:39 PM

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1  
Old 02-06-2007
Registered User
 

Join Date: Feb 2007
Location: here
Posts: 7
root dir ? home dir ?

I am little bit confused when the words "root directory" and "home directory" and "parent directory" are used. Can anybody explains the difference.

I am trying to list the names and protections levels and size of visible files in the root directory

would it be correct if I just typed:

ls -o ./ ?

I guess "./" pretends that it would be a parent directory ? or using a ~ maybe this is for a home dir...? Confused !
Reply With Quote
Forum Sponsor
  #2  
Old 02-06-2007
Perderabo's Avatar
Unix Daemon
 

Join Date: Aug 2001
Location: Washington DC Area
Posts: 8,618
The root directory is /
Home directory is assigned to you when your account is added. It might be something like /home/hinman /export/home/hinman or something like that. Each user gets a home directory.

/export/home/hinman has a parent called /export/home
/export/home has a parent called /export
/export has a parent called /
/ does not really have a parent, but it acts as it's own parent.

With many shells you can use ~ as a shortcut for /export/home/hinman but if I use ~ it would be /export/home/perderabo (or whatever our home directories really are). We both can use ~joe to refer to joe's home directory.

Every directory must have two special entries called . and ..
. is the current directory
.. is the parent directory

So if you are in /usr/local/bin, . is /usr/local/bin and .. is /usr/local. Unlike ~ these really are in the directory and will work with any shell.
Reply With Quote
  #3  
Old 02-07-2007
Registered User
 

Join Date: Jul 2005
Location: Amsterdam
Posts: 97
Quote:
Originally Posted by hinman
I am little bit confused when the words "root directory" and "home directory" and "parent directory" are used. Can anybody explains the difference.

I am trying to list the names and protections levels and size of visible files in the root directory

would it be correct if I just typed:

ls -o ./ ?

I guess "./" pretends that it would be a parent directory ? or using a ~ maybe this is for a home dir...? Confused !

You might want to check some things about the UNIX file system: http://www.liquidweb.com/manual/chap...ilesystem.html

Regards,
Johan Louwers
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 12:06 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0