Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Entering directories structured above user. Post 60952 by Neo on Tuesday 25th of January 2005 11:29:02 PM
Old 01-26-2005
Dear Frank,

You can go to the root directory of your entire filesystem with this command:

cd /

Then, simply type a command such as

ls -l

and you will see the first level of directories under the root of your filesystem.

Then, simply "cd" into one of the directories you see, for example:

cd /etc

Neo

PS, for example:

Code:
www# cd /
www# ls -l
total 117
drwxr-xr-x    2 root     root         4096 Sep  6  2003 archives/
drwxr-xr-x    2 root     bin          4096 Jan 18  2004 bin/
drwxr-xr-x    5 root     root         1024 Aug 24  2003 boot/
drwxr-xr-x   11 root     root         4096 Aug 25  2003 database/
drwxr-xr-x   14 root     root        45056 Nov 24 21:26 dev/
drwxr-xr-x   37 root     root         4096 Jan 23 22:57 etc/
drwxr-xr-x   14 root     users        4096 Jan 23 22:57 home/
drwxr-xr-x    4 root     root         4096 Jan  1  2003 lib/
drwx------    2 root     root        16384 Jan  1  2003 lost+found/
drwxr-xr-x    5 root     root         4096 Mar 16  2002 mnt/
drwxr-xr-x    4 root     root         4096 May 19  2002 opt/
dr-xr-xr-x   69 root     root            0 Nov 24 16:26 proc/
drwx--x---    9 root     root         4096 Jan 24 18:32 root/
drwxr-xr-x    2 root     bin          4096 Jun  1  2002 sbin/
drwxrwxrwt    4 mysql    users        4096 Jan 25 23:30 tmp/
drwxr-xr-x   21 root     root         4096 Dec  4 18:04 usr/
drwxr-xr-x    4 root     root         4096 Dec 20 00:04 usr2/
drwxr-xr-x   18 root     root         4096 Nov 24 22:56 var/
www# cd etc
www# pwd
/etc
www#

 

9 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

How to use SFTP from command line without entering user and password

I would like to use SFTP from command line without entering userid and password. Here is what I have gathered and did. 1) Create a public and private key pair for the protocol you want to use. To create a key pair for use by SSH2, enter: ssh-keygen -t dsa I did that and got... (7 Replies)
Discussion started by: Hangman2
7 Replies

2. Shell Programming and Scripting

structured file update

Hi I have a very structured file consisting of multiple lines as follows: 3752 AVAILABLE 06/24/2009 FFFF 000000 0000 0000 3753 TRADITION (ASIA) LTD TACB 008329 0000 0000 3754 WACHOVIA CONVS/PRFDS WBCP 001099 0000 0000 3755 AVAILABLE 05/12/2009 FFFF 000000 0000 0000 3756... (3 Replies)
Discussion started by: aoussenko
3 Replies

3. UNIX for Dummies Questions & Answers

find directories owned by a given user

Hi, I want to know if the is a way I can list the directories owned by a given user. Say i am logged in as that user. I found out the find command lists the files owned by a certain user/group but i want to know only the directories and if possible the permissions associated with these... (6 Replies)
Discussion started by: poojabhat
6 Replies

4. Shell Programming and Scripting

Parsing structured files in Perl

Hi, looking for a piece of code to get the values from a structured text file like this: ############################################################################### ############################################################################### # # PERSONAL DATA DEFINITIONS #... (8 Replies)
Discussion started by: sarabande
8 Replies

5. Solaris

Login delay after entering id (40 secs) same after entering pw

Hi all, I have just installed Solaris 10 on an old Fujitsu Primepower 650 which has been wiped clean. I haven't installed anything apart from the OS yet, so the machine is 99% idle. I get long delays when logging in, first after entering the id then another long delay after entering a valid... (8 Replies)
Discussion started by: longjon
8 Replies

6. Solaris

Particular user account shouldn't be locked after entering wrong passwd specfic no. times

Hi all In my system we have implemented user lockout feature after 3 failure attempt if he tries to login directly or if he run the any command through sudo and enter wrong password thrice. Now I have requirement in which particular user account shouldn't be locked when he run the command... (1 Reply)
Discussion started by: sb200
1 Replies

7. Shell Programming and Scripting

Using awk to create a summary of a structured file

I am trying to use awk to create a summary of a structured file. Here is what it looks like: (random text) H1 H2 H3 H4 44 78 99 30 31 -- 32 21 12 33 55 21 I'd like to be able to specify a column, say H2, and then have information about that column printed. ... (4 Replies)
Discussion started by: afulldevnull
4 Replies

8. Programming

Reading structured arguments

I am passing an argument to a C++ program which is going to look like I need to get the integers into arrays a, b, c, d with a= 12,12,34,2,12 b= 34,4,2,1,23 c= 5,5,4,4,13 d= 6,6,6,6,5 (5 Replies)
Discussion started by: kristinu
5 Replies

9. Solaris

Giving read write permission to user for specific directories and sub directories.

I have searched this quite a long time but couldn't find the right method for me to use. I need to assign read write permission to the user for specific directories and it's sub directories and files. I do not want to use ACL. This is for Solaris. Please help. (1 Reply)
Discussion started by: blinkingdan
1 Replies
XDG-USER-DIRS-UPD(1)						   User Commands					      XDG-USER-DIRS-UPD(1)

NAME
xdg-user-dirs-update - Update XDG user dir configuration SYNOPSIS
xdg-user-dirs-update [OPTION...] [--set NAME PATH...] DESCRIPTION
xdg-user-dirs-update updates the current state of the users user-dirs.dir. If none existed before then one is created based on the system default values, or falling back to the old non-translated filenames if such directories exists. The list of old directories used are: ~/Desktop, ~/Templates and ~/Public. If an old configuration exists it is updated with any new default directories. Additionally, any configured directories that point to non-existing locations are reset by pointing then to the users home directory. This typically happens when the users removed the directory, so they likely don't want to use it anymore. On the first run a user-dirs.locale file is created containing the locale that was used for the translation. This is used later by gui tools like xdg-user-dirs-gtk-update to detect if the locale was changed, letting you to migrate from the old names. xdg-user-dirs-update is normally run automatically at the start of a user session to update the XDG user dirs according to the users locale. OPTIONS
The following options are understood: --help Print help output and exit. --force Update existing user-dirs.dir, but force a full reset. This means: Don't reset nonexisting directories to HOME, rather recreate the directory. Never use backwards compatible non-translated names. Always recreate user-dirs.locale. --dummy-output PATH Write the configuration to PATH instead of the default configuration file. Also, no directories are created. --set NAME PATH Sets the XDG user dir with the given name. NAME should be one of the following: DESKTOP DOWNLOAD TEMPLATES PUBLICSHARE DOCUMENTS MUSIC PICTURES VIDEOS PATH must be an absolute path, e.g. $HOME/Some/Directory. FILES
The XDG user dirs configuration is stored in the user-dirs.dir file in the location pointed to by the XDG_CONFIG_HOME environment variable. ENVIRONMENT
The XDG_CONFIG_HOME environment variable determines where the user-dirs.dirs file is located. SEE ALSO
xdg-user-dir(1), user-dirs.dirs(5), user-dirs.defaults(5), user-dirs.conf(5). XDG
XDG-USER-DIRS-UPD(1)
All times are GMT -4. The time now is 10:15 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy