Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This 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!


  Search this Thread
Old 06-18-2004, 02:04 PM   #1
Registered: Jan 2004
Location: Scituate, MA
Distribution: Mandrake 10
Posts: 94

Rep: Reputation: 15
File Permission Question

Help me understand this would you?

[coop@x1-6-00-a0-cc-5f-d9-d3 Documents]$ ls -l
total 8 -rwxrwxrwx 1 coop coop 5943 Jun 15 21:08 Linux stuff.sxc*
(What does total 8, what does 1 and what does 5943 stand for. I know the rest.)

[coop@x1-6-00-a0-cc-5f-d9-d3 Documents]$ ls -l Linux stuff.sxc
ls: Linux: No such file or directory
ls: stuff.sxc: No such file or directory
I thought $ls -l Linux stuff.sxc would give me the permissions..etc.

I thought when I did ls -l Linux stuff.sxc it would give me -rwxrwxrwx ....line

So when I do this:
[coop@x1-6-00-a0-cc-5f-d9-d3 Documents]$ ls -l
This lists what is in the Documents directory with the permission, etc.

Old 06-18-2004, 02:27 PM   #2
Registered: Mar 2004
Location: Minnesota
Distribution: Fedora Core 1, Mandrake 10
Posts: 405

Rep: Reputation: 30
Not sure what the portions of it you asked about mean, but I can tell you why it didn't work when you did

ls -l Linux stuff.sxc

It's because you have a space in the name, and you need to enter a backslash prior to the space or it thinks you're looking at two different calle Linux and one called stuff.sxc. It would need to look like this:

ls -l Linux\ stuff.sxc

That's all I've got...

Good luck!
Old 06-18-2004, 02:44 PM   #3
Senior Member
Registered: Jan 2003
Posts: 2,786

Rep: Reputation: 373Reputation: 373Reputation: 373Reputation: 373
From the info pages of ls (info ls):
In addition to the name of each file, print the file type,
permissions, number of hard links, owner name, group name, size in
bytes, and timestamp (*note Formatting file timestamps::), normally
the modification time.

For each directory that is listed, preface the files with a line
`total BLOCKS', where BLOCKS is the total disk allocation for all
files in that directory. The block size currently defaults to 1024
bytes, but this can be overridden (*note Block size::). The
BLOCKS computed counts each hard link separately; this is arguably
a deficiency.

The permissions listed are similar to symbolic mode specifications
(*note Symbolic Modes::). But `ls' combines multiple bits into the
third character of each set of permissions as follows:

If the setuid or setgid bit and the corresponding executable
bit are both set.

If the setuid or setgid bit is set but the corresponding
executable bit is not set.

If the sticky bit and the other-executable bit are both set.

If the sticky bit is set but the other-executable bit is not

If the executable bit is set and none of the above apply.


Following the permission bits is a single character that specifies
whether an alternate access method applies to the file. When that
character is a space, there is no alternate access method. When it
is a printing character (e.g., `+'), then there is such a method.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
file permission jh31480 Linux - Newbie 2 01-25-2005 07:42 PM
a question about file permission tony yu Mandriva 5 04-13-2004 11:18 AM
file/directory access permission question correro Linux - General 4 05-22-2003 08:48 PM
what's file permission for this? doublefailure Linux - Newbie 2 03-16-2002 12:21 PM
File Permission glock19 Linux - General 4 01-02-2002 08:40 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:07 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration