Skip to contentSkip to conversation

wierd file perms

DISCUSSION vignesh babu 5 participants 10 messages Oct 13, 2007 – Oct 15, 2007

lore
Share & tools
lore
#0 lore raw

Hi all,

Was having trouble with the latest source-in compiling it and did an mrproper which fixed things...well-temporarily.

I was hitting another issue with permissions-as root :(

I was surprised and did an ls -l on the files and guess what I found:

total 0

?--------- ? ? ? ?                ? fcntl.c
?--------- ? ? ? ?                ? fifo.c
?--------- ? ? ? ?                ? filesystems.c
?--------- ? ? ? ?                ? file_table.c
?--------- ? ? ? ?                ? freevxfs

So end result is that, Im not able to delete the files or change perms or ownership even as root.

Can some one help please?

How did this even happen?

I could compile without any issues till yesterday and todays update seems to have caused this...

Not really sure if it is just a local phenomenon....

Signature · 2 lines
----------------------------------------------
"Why is it that every time I'm with you, makes me believe in magic?"
#1 lore raw
Quoted 4 lines · vignesh babu

I was surprised and did an ls -l on the files and guess what I found:

total 0

Quoted 8 lines
?--------- ? ? ? ?                ? fcntl.c
?--------- ? ? ? ?                ? fifo.c
?--------- ? ? ? ?                ? filesystems.c
?--------- ? ? ? ?                ? file_table.c
?--------- ? ? ? ?                ? freevxfs

So end result is that, Im not able to delete the files or change perms or ownership even as root.

Most probably, your filesystem is broken and needs a fsck.

MfG, JBG

Signature · 3 lines
      Jan-Benedict Glaw      [email protected]              +49-172-7608481
  Signature of:                          Zensur im Internet? Nein danke!
  the second  :
#2 lore raw

Jan-Benedict Glaw wrote on 13-10-07 19:28:

Quoted 10 lines · vignesh babu
Quoted 9 lines

I was surprised and did an ls -l on the files and guess what I found:

total 0

?--------- ? ? ? ?                ? fcntl.c
?--------- ? ? ? ?                ? fifo.c
?--------- ? ? ? ?                ? filesystems.c
?--------- ? ? ? ?                ? file_table.c
?--------- ? ? ? ?                ? freevxfs
Quoted 7 lines
Quoted 2 lines

So end result is that, Im not able to delete the files or change perms or ownership even as root.

Most probably, your filesystem is broken and needs a fsck.

MfG, JBG

I don't think this is a bug, but a feature of 'ls', see for instance the coreutils mailing list:

http://lists.gnu.org/archive/html/bug-coreutils/2007-05/msg00226.html

bjd

#3 lore raw
Quoted 14 lines · Bauke Jan Douma
Quoted 14 lines
Quoted 11 lines · vignesh babu

I was surprised and did an ls -l on the files and guess what I found:

total 0

?--------- ? ? ? ?                ? fcntl.c
?--------- ? ? ? ?                ? fifo.c
?--------- ? ? ? ?                ? filesystems.c
?--------- ? ? ? ?                ? file_table.c
?--------- ? ? ? ?                ? freevxfs

So end result is that, Im not able to delete the files or change perms or ownership even as root.

Quoted 6 lines
Quoted 1 line

Most probably, your filesystem is broken and needs a fsck.

I don't think this is a bug, but a feature of 'ls', see for instance the coreutils mailing list:

http://lists.gnu.org/archive/html/bug-coreutils/2007-05/msg00226.html

- broken on-disk fs
- you are not allowed to stat() -- which can only reasonably happen with FUSE or remote filesystems
- ls also outputs ?--------- if the file mode does not make sense, though as we can see, UID/GID nlink, etc. are also missing, so I suspect item 2.

#4 lore raw
In reply to Jan-Benedict Glaw
Quoted 10 lines · Jan-Benedict Glaw
Quoted 9 lines · vignesh babu

I was surprised and did an ls -l on the files and guess what I found:

total 0

?--------- ? ? ? ?                ? fcntl.c
?--------- ? ? ? ?                ? fifo.c
?--------- ? ? ? ?                ? filesystems.c
?--------- ? ? ? ?                ? file_table.c
?--------- ? ? ? ?                ? freevxfs
Quoted 4 lines
Quoted 2 lines

So end result is that, Im not able to delete the files or change perms or ownership even as root.

Most probably, your filesystem is broken and needs a fsck.

No, this is perfectly normal behaviour, for when a directory has READ permissions but not EXECUTE permissions.

Eg.

	mkdir a
	touch a/b
	chmod 644 a
	ls -l a

Try it!

Cheers

#5 lore raw
Quoted 12 lines · Mark Lord
Quoted 11 lines · Jan-Benedict Glaw
Quoted 9 lines · vignesh babu

I was surprised and did an ls -l on the files and guess what I found:

total 0

?--------- ? ? ? ?                ? fcntl.c
?--------- ? ? ? ?                ? fifo.c
?--------- ? ? ? ?                ? filesystems.c
?--------- ? ? ? ?                ? file_table.c
?--------- ? ? ? ?                ? freevxfs
Quoted 7 lines
Quoted 4 lines
Quoted 2 lines

So end result is that, Im not able to delete the files or change perms or ownership even as root.

Most probably, your filesystem is broken and needs a fsck.

No, this is perfectly normal behaviour, for when a directory has READ permissions but not EXECUTE permissions.

Er, close.

	16:02 ichi:/dev/shm > md a
	16:02 ichi:/dev/shm > touch a/b
	16:02 ichi:/dev/shm > chmod 644 a
	16:02 ichi:/dev/shm > ls -l a
	/bin/ls: cannot access a/b: Permission denied
	total 0
	-????????? ? ? ? ?            ? b
	16:02 ichi:/dev/shm > ls --version
	ls (GNU coreutils) 6.9

There is a difference .. "-?????????" vs "?---------".

The first looks to me like "filetype known (S_IFREG)", while the latter is "filetype and mode unknown".

#6 lore raw
Quoted 32 lines · Jan Engelhardt
Quoted 12 lines · Mark Lord
Quoted 11 lines · Jan-Benedict Glaw
Quoted 9 lines · vignesh babu

I was surprised and did an ls -l on the files and guess what I found:

total 0

?--------- ? ? ? ?                ? fcntl.c
?--------- ? ? ? ?                ? fifo.c
?--------- ? ? ? ?                ? filesystems.c
?--------- ? ? ? ?                ? file_table.c
?--------- ? ? ? ?                ? freevxfs
Quoted 5 lines
Quoted 3 lines
Quoted 2 lines

So end result is that, Im not able to delete the files or change perms or ownership even as root.

Most probably, your filesystem is broken and needs a fsck.

No, this is perfectly normal behaviour, for when a directory has READ permissions but not EXECUTE permissions.

Er, close.

	16:02 ichi:/dev/shm > md a
	16:02 ichi:/dev/shm > touch a/b
	16:02 ichi:/dev/shm > chmod 644 a
	16:02 ichi:/dev/shm > ls -l a
	/bin/ls: cannot access a/b: Permission denied
	total 0
	-????????? ? ? ? ?            ? b
	16:02 ichi:/dev/shm > ls --version
	ls (GNU coreutils) 6.9
Quoted 1 line

There is a difference .. "-?????????" vs "?---------".

That's just a version difference for GNU ls.
Here, with ls (GNU coreutils) 5.97 it gives this:

?--------- ? ? ? ? ? a/b

#7 lore raw

ls --version
ls (GNU coreutils) 5.97

An fsck did it :) and had the source restored by checkout -f

Think Jan is right, there is a diff between the two...

Quoted 42 lines · Mark Lord
Quoted 32 lines · Jan Engelhardt
Quoted 12 lines · Mark Lord
Quoted 11 lines · Jan-Benedict Glaw
Quoted 9 lines · vignesh babu

I was surprised and did an ls -l on the files and guess what I found:

total 0

?--------- ? ? ? ?                ? fcntl.c
?--------- ? ? ? ?                ? fifo.c
?--------- ? ? ? ?                ? filesystems.c
?--------- ? ? ? ?                ? file_table.c
?--------- ? ? ? ?                ? freevxfs
Quoted 5 lines
Quoted 3 lines
Quoted 2 lines

So end result is that, Im not able to delete the files or change perms or ownership even as root.

Most probably, your filesystem is broken and needs a fsck.

No, this is perfectly normal behaviour, for when a directory has READ permissions but not EXECUTE permissions.

Er, close.

      16:02 ichi:/dev/shm > md a
      16:02 ichi:/dev/shm > touch a/b
      16:02 ichi:/dev/shm > chmod 644 a
      16:02 ichi:/dev/shm > ls -l a
      /bin/ls: cannot access a/b: Permission denied
      total 0
      -????????? ? ? ? ?            ? b
      16:02 ichi:/dev/shm > ls --version
      ls (GNU coreutils) 6.9
Quoted 1 line

There is a difference .. "-?????????" vs "?---------".

That's just a version difference for GNU ls.
Here, with ls (GNU coreutils) 5.97 it gives this:

?--------- ? ? ? ? ? a/b

Signature · 2 lines
----------------------------------------------
"Why is it that every time I'm with you, makes me believe in magic?"
#8 lore raw
In reply to vignesh babu

vignesh babu wrote:
..

Quoted 10 lines
?--------- ? ? ? ?                ? fcntl.c
?--------- ? ? ? ?                ? fifo.c
?--------- ? ? ? ?                ? filesystems.c
?--------- ? ? ? ?                ? file_table.c
?--------- ? ? ? ?                ? freevxfs

So end result is that, Im not able to delete the files or change perms or ownership even as root.

Can some one help please?

chmod a+x name_of_directory

Now you can do "ls -l" and "rm" or whatever.

#9 lore raw
Quoted 8 lines · Mark Lord

vignesh babu wrote:
..

Quoted 6 lines
?--------- ? ? ? ?                ? fcntl.c
?--------- ? ? ? ?                ? fifo.c
?--------- ? ? ? ?                ? filesystems.c
?--------- ? ? ? ?                ? file_table.c
?--------- ? ? ? ?                ? freevxfs
Quoted 8 lines
Quoted 4 lines

So end result is that, Im not able to delete the files or change perms or ownership even as root.

Can some one help please?

chmod a+x name_of_directory

Now you can do "ls -l" and "rm" or whatever.

*cough* The original mail you're replying to had this inside:

Quoted 1 line
Quoted 1 line

I was hitting another issue with permissions-as root :(

I really think he better starts a fsck... Soon.

MfG, JBG

Signature · 3 lines
      Jan-Benedict Glaw      [email protected]              +49-172-7608481
  Signature of:                           Wenn ich wach bin, träume ich.
  the second  :