The officially official Devuan Forum!

You are not logged in.

#1 2020-09-05 16:44:44

Haines
Member
Registered: 2017-04-29
Posts: 5  

Delete a file with corrupted attributes

I have a situation in which a directory cannot be deleted  because it is read only. However the ls -la command run on it returns:

    d????????? ? ?    ?        ?            ? install-tl-20180702

If I run ls on it I get:

    ls: cannot access 'install-tl-20180702': Input/output error

So the file has neither ownership nor permissions. 

Tried to remount as rw and run chmod 600 on it, but cannot do so because the file is "read only".

Is zeroing the partition the only way to get rid of these fossils?

Offline

#2 2020-09-05 17:37:04

golinux
Administrator
Registered: 2016-11-25
Posts: 3,316  

Re: Delete a file with corrupted attributes

I am currently dealing with a misbehaving external harddrive that would not mount because of this error:

Error when trying to mount:
Failed to open directory "cstwo".
Error when getting information for file '/media/xxxxxx/cstwo/600':
Input/output error.

There is currently a long thread on DNG about what I have done to get it back in shape short of the nuclear option.

Start by running SMART to get some general info about the state of your drive.

In the end an fsck fixed things for me.

Offline

#3 2020-09-05 19:57:07

Head_on_a_Stick
Member
From: London
Registered: 2019-03-24
Posts: 3,125  
Website

Re: Delete a file with corrupted attributes

golinux wrote:

Good grief, you had help from Bruce Perens? What a legend...

@OP: which filesystem is this?

Can we see

file install-tl-20180702
stat install-tl-20180702

Brianna Ghey — Rest In Power

Offline

#4 2020-09-05 20:17:30

golinux
Administrator
Registered: 2016-11-25
Posts: 3,316  

Re: Delete a file with corrupted attributes

Head_on_a_Stick wrote:
golinux wrote:

Good grief, you had help from Bruce Perens? What a legend...

Yeah, he's been around the campfire since the beginning and pops in on occasion.   I have had some off-list as well as official contact with him over the years . . .

Offline

Board footer