File attributes ????

Tags
attributes, file

 
Thread Tools Search this Thread
# 1  
Old 12-20-2017
File attributes ????

I'm trying to sort out the charing of a problem folder, in the 'ls -l' list is shows as:
Code:
 d???????????? ? ?    ?          ?          ? Pi-Share

PiShare is the name of the directory, all the ??s make no sense to me at all, and no user (there are only two, pi and root) can make any changes to it.

It's the only directory out of many that has the problem.

I've tried chmod to change the atts, sudo su can't change anything or remove it, so I'm a bit confused.

Does anyone know how I can get rid of it so I can create it again?

Many thanks.

Last edited by MadeInGermany; 12-21-2017 at 09:08 AM.. Reason: added code tags
# 2  
Old 12-20-2017
Code:
ls -ld Pi-share | od -c

Please post the output of the above command. What UNIX are you using?

It looks like the file system itself is corrupted. We may have to resort to a tool like fsck.
# 3  
Old 12-20-2017
Just ls -ld Pi-share will show a missing x-bit.
ls may read the directory contents with the file names, but may not access the inodes of the files with the attributes and a link to the data.
It is a bug (or feature?) in GNU ls to then show ???? for the attributes.
In contrast, Unix ls and old GNU ls say "filename: permission denied" on stderr and nothing on stdout.
# 4  
Old 12-20-2017
I think the file system is hosed - and the directory permissions are history. GNU ls displays ? for unprintable characters in the locale. I believe.
# 5  
Old 12-21-2017
I give an example, so everybody can reproduce.
Code:
mkdir newdir
touch newdir/file1
touch newdir/file2
chmod -x newdir

Unix (and very old GNU ls/glibc)
Code:
ls -l newdir
newdir/file2: Permission denied
newdir/file1: Permission denied
total 0

Old GNU ls
Code:
ls -l newdir
total 0
?--------- ? ? ? ?            ? file1
?--------- ? ? ? ?            ? file2

GNU ls
Code:
ls -l newdir
ls: cannot access newdir/file2: Permission denied
ls: cannot access newdir/file1: Permission denied
total 0
-????????? ? ? ? ?            ? file1
-????????? ? ? ? ?            ? file2

These 2 Users Gave Thanks to MadeInGermany For This Post:
Corona688 (12-21-2017) RudiC (12-21-2017)

|
Thread Tools Search this Thread
Search this Thread:
Advanced Search

More UNIX and Linux Forum Topics You Might Find Helpful
How to remove attributes of a file? yifangt UNIX for Dummies Questions & Answers 6 07-04-2014 06:29 PM
User attributes not update in user file newaix AIX 1 10-07-2011 06:49 AM
Help with can't get execution attributes rama krishna UNIX for Advanced & Expert Users 1 04-28-2011 05:37 PM
Split file based on multi valued attributes snukala Solaris 7 02-06-2011 02:16 AM
Using cp: preserving file/folder attributes and auto creating folders pcwiz Shell Programming and Scripting 1 08-11-2009 05:19 PM
Generate the File Attributes in the system saurabhchokshi Shell Programming and Scripting 3 06-12-2009 07:58 PM
Capture all the contents between two attributes giri_luck Shell Programming and Scripting 7 10-28-2008 11:17 AM
Problems with any ls attributes Sarccastik Dude UNIX for Dummies Questions & Answers 3 04-09-2008 01:57 PM
file attributes and exception krem UNIX Desktop Questions & Answers 1 09-03-2006 09:45 PM
Assigning file attributes to variables olimiles Shell Programming and Scripting 5 08-18-2006 10:31 AM
file attributes Hitori Shell Programming and Scripting 1 07-12-2006 04:12 PM
how to find system attributes merope UNIX for Dummies Questions & Answers 3 04-24-2006 10:00 AM
file attributes hytechpro Shell Programming and Scripting 2 09-16-2005 10:32 AM
rcp and file attributes jhansrod Shell Programming and Scripting 2 05-26-2005 12:28 PM
Need to view all the attributes for a file/node dpalmer UNIX for Advanced & Expert Users 2 10-03-2001 12:10 AM