All of lore.kernel.org
 help / color / mirror / Atom feed
* wierd file perms
@ 2007-10-13 17:10 vignesh babu
  2007-10-13 17:28 ` Jan-Benedict Glaw
  2007-10-14 13:29 ` Mark Lord
  0 siblings, 2 replies; 10+ messages in thread
From: vignesh babu @ 2007-10-13 17:10 UTC (permalink / raw)
  To: linux-kernel

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....
-- 

----------------------------------------------
"Why is it that every time I'm with you, makes me believe in magic?"

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: wierd file perms
  2007-10-13 17:10 wierd file perms vignesh babu
@ 2007-10-13 17:28 ` Jan-Benedict Glaw
  2007-10-14 12:30   ` Bauke Jan Douma
  2007-10-14 13:27   ` Mark Lord
  2007-10-14 13:29 ` Mark Lord
  1 sibling, 2 replies; 10+ messages in thread
From: Jan-Benedict Glaw @ 2007-10-13 17:28 UTC (permalink / raw)
  To: vignesh babu; +Cc: linux-kernel

[-- Attachment #1: Type: text/plain, Size: 775 bytes --]

On Sat, 2007-10-13 22:40:23 +0530, vignesh babu <vigneshbabu@gmail.com> wrote:
> 
> 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.

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

MfG, JBG

-- 
      Jan-Benedict Glaw      jbglaw@lug-owl.de              +49-172-7608481
  Signature of:                          Zensur im Internet? Nein danke!
  the second  :

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: wierd file perms
  2007-10-13 17:28 ` Jan-Benedict Glaw
@ 2007-10-14 12:30   ` Bauke Jan Douma
  2007-10-14 12:42     ` Jan Engelhardt
  2007-10-14 13:27   ` Mark Lord
  1 sibling, 1 reply; 10+ messages in thread
From: Bauke Jan Douma @ 2007-10-14 12:30 UTC (permalink / raw)
  To: vignesh babu, linux-kernel

Jan-Benedict Glaw wrote on 13-10-07 19:28:
> On Sat, 2007-10-13 22:40:23 +0530, vignesh babu <vigneshbabu@gmail.com> wrote:
>> 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.
> 
> 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


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: wierd file perms
  2007-10-14 12:30   ` Bauke Jan Douma
@ 2007-10-14 12:42     ` Jan Engelhardt
  0 siblings, 0 replies; 10+ messages in thread
From: Jan Engelhardt @ 2007-10-14 12:42 UTC (permalink / raw)
  To: Bauke Jan Douma; +Cc: vignesh babu, linux-kernel


On Oct 14 2007 14:30, Bauke Jan Douma wrote:
>> On Sat, 2007-10-13 22:40:23 +0530, vignesh babu <vigneshbabu@gmail.com>
>> wrote:
>> > 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.
>> 
>> 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.


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: wierd file perms
  2007-10-13 17:28 ` Jan-Benedict Glaw
  2007-10-14 12:30   ` Bauke Jan Douma
@ 2007-10-14 13:27   ` Mark Lord
  2007-10-14 14:05     ` Jan Engelhardt
  1 sibling, 1 reply; 10+ messages in thread
From: Mark Lord @ 2007-10-14 13:27 UTC (permalink / raw)
  To: vignesh babu, linux-kernel

Jan-Benedict Glaw wrote:
> On Sat, 2007-10-13 22:40:23 +0530, vignesh babu <vigneshbabu@gmail.com> wrote:
>> 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.
> 
> 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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: wierd file perms
  2007-10-13 17:10 wierd file perms vignesh babu
  2007-10-13 17:28 ` Jan-Benedict Glaw
@ 2007-10-14 13:29 ` Mark Lord
  2007-10-14 13:31   ` Jan-Benedict Glaw
  1 sibling, 1 reply; 10+ messages in thread
From: Mark Lord @ 2007-10-14 13:29 UTC (permalink / raw)
  To: vignesh babu; +Cc: linux-kernel

vignesh babu wrote:
..
> ?--------- ? ? ? ?                ? 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.


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: wierd file perms
  2007-10-14 13:29 ` Mark Lord
@ 2007-10-14 13:31   ` Jan-Benedict Glaw
  0 siblings, 0 replies; 10+ messages in thread
From: Jan-Benedict Glaw @ 2007-10-14 13:31 UTC (permalink / raw)
  To: Mark Lord; +Cc: vignesh babu, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 1016 bytes --]

On Sun, 2007-10-14 09:29:01 -0400, Mark Lord <lkml@rtr.ca> wrote:
> vignesh babu wrote:
> ..
> >?--------- ? ? ? ?                ? 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.

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

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

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

MfG, JBG

-- 
      Jan-Benedict Glaw      jbglaw@lug-owl.de              +49-172-7608481
  Signature of:                           Wenn ich wach bin, träume ich.
  the second  :

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: wierd file perms
  2007-10-14 13:27   ` Mark Lord
@ 2007-10-14 14:05     ` Jan Engelhardt
  2007-10-14 20:01       ` Mark Lord
  0 siblings, 1 reply; 10+ messages in thread
From: Jan Engelhardt @ 2007-10-14 14:05 UTC (permalink / raw)
  To: Mark Lord; +Cc: vignesh babu, linux-kernel


On Oct 14 2007 09:27, Mark Lord wrote:
> Jan-Benedict Glaw wrote:
>> On Sat, 2007-10-13 22:40:23 +0530, vignesh babu <vigneshbabu@gmail.com>
>> wrote:
>> > 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.
>> 
>> 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".



^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: wierd file perms
  2007-10-14 14:05     ` Jan Engelhardt
@ 2007-10-14 20:01       ` Mark Lord
  2007-10-15  1:29         ` vignesh babu
  0 siblings, 1 reply; 10+ messages in thread
From: Mark Lord @ 2007-10-14 20:01 UTC (permalink / raw)
  To: Jan Engelhardt; +Cc: vignesh babu, linux-kernel

Jan Engelhardt wrote:
> On Oct 14 2007 09:27, Mark Lord wrote:
>> Jan-Benedict Glaw wrote:
>>> On Sat, 2007-10-13 22:40:23 +0530, vignesh babu <vigneshbabu@gmail.com>
>>> wrote:
>>>> 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.
>>> 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 "?---------".

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

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



^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: wierd file perms
  2007-10-14 20:01       ` Mark Lord
@ 2007-10-15  1:29         ` vignesh babu
  0 siblings, 0 replies; 10+ messages in thread
From: vignesh babu @ 2007-10-15  1:29 UTC (permalink / raw)
  To: Mark Lord; +Cc: Jan Engelhardt, linux-kernel

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...

On 10/15/07, Mark Lord <lkml@rtr.ca> wrote:
> Jan Engelhardt wrote:
> > On Oct 14 2007 09:27, Mark Lord wrote:
> >> Jan-Benedict Glaw wrote:
> >>> On Sat, 2007-10-13 22:40:23 +0530, vignesh babu <vigneshbabu@gmail.com>
> >>> wrote:
> >>>> 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.
> >>> 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 "?---------".
>
> That's just a version difference for GNU ls.
> Here, with ls (GNU coreutils) 5.97 it gives this:
>
> ?--------- ? ? ? ?                ? a/b
>
>
>


-- 

----------------------------------------------
"Why is it that every time I'm with you, makes me believe in magic?"

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2007-10-15  1:29 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-10-13 17:10 wierd file perms vignesh babu
2007-10-13 17:28 ` Jan-Benedict Glaw
2007-10-14 12:30   ` Bauke Jan Douma
2007-10-14 12:42     ` Jan Engelhardt
2007-10-14 13:27   ` Mark Lord
2007-10-14 14:05     ` Jan Engelhardt
2007-10-14 20:01       ` Mark Lord
2007-10-15  1:29         ` vignesh babu
2007-10-14 13:29 ` Mark Lord
2007-10-14 13:31   ` Jan-Benedict Glaw

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.