LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 08-10-2009, 07:35 AM   #1
kk2202
LQ Newbie
 
Registered: Jan 2009
Posts: 24

Rep: Reputation: 15
Strange file type - Unable to delete the file


Hi all,

My make fails with an error menitoned below:
rm: cannot remove directory `/xxx/yyy/zzz/bin': Directory not empty
make[3]: *** [dist] Error 1

when I do a ls -ltr at /xxx/yyy/zzz/bin,I see the following
$ ls -ltr
total 0
?---------+ ? ? ? ? ? test

I am not clear how this got created. And I am unable to remove this file from the directory. Due to which my make is failing.

$ rm test
rm: cannot remove `test': No such file or directory

Kindly let me know how to solve this issue. How can I remove this file rm -rf and the other options did not work.
 
Old 08-10-2009, 09:12 AM   #2
watcher69b
Member
 
Registered: Nov 2007
Location: /home/watcher69b
Distribution: RH, Fedora & CentOS
Posts: 552

Rep: Reputation: 41
file could be set immutable.


http://linuxhelp.blogspot.com/2005/1...hich-even.html
 
Old 08-10-2009, 10:29 AM   #3
tredegar
LQ 5k Club
 
Registered: May 2003
Location: London, UK
Distribution: Fedora38
Posts: 6,147

Rep: Reputation: 435Reputation: 435Reputation: 435Reputation: 435Reputation: 435
Quote:
when I do a ls -ltr at /xxx/yyy/zzz/bin,I see the following
$ ls -ltr
total 0
?---------+ ? ? ? ? ? test
This can be a sign of filesystem corruption. Perhaps you should run fsck on that partition.
 
Old 08-10-2009, 11:22 AM   #4
forrestt
Senior Member
 
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99
If you are running with selinux in enforcing mode, it will also give that type of listing if you don't have a policy setting to allow you to read the file. Since you don't want the directory, try "rm -rf xxx/yyy/zzz/bin" instead of rmdir.

HTH

Forrest
 
Old 08-10-2009, 11:51 AM   #5
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Access permissions are visible at all times, ownership is only left untranslated if the Id doesn't exist (and since SELinux operates on top of DAC this would be an odd policy rule AFAIK). So I second running fsck.

Last edited by unSpawn; 08-10-2009 at 11:53 AM.
 
Old 08-10-2009, 12:00 PM   #6
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,083

Rep: Reputation: 405Reputation: 405Reputation: 405Reputation: 405Reputation: 405
Yep.

If you can't detect file system corruption I'd also try rkhunter. The only time I've seen a rootkit on one of my machines I detected a few files like this one. I couldn't delete them and fsck didn't report anything. Finally I had to use debugfs to remove them. This was on a grsecurity hardened machine by the way.

Last edited by i92guboj; 08-10-2009 at 08:17 PM. Reason: it wasn't selinux, but grsecurity, corrected
 
Old 08-10-2009, 12:00 PM   #7
forrestt
Senior Member
 
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99
OK, odd it may be, but I've seen it many times first hand. Running fsck won't hurt in any event. Just make sure you are running it on an unmounted partition if you are in a "fixing" mode.

Forrest
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Upload file to ftp server -vsftp- but can not delete or change the file once uploaded murattas6 Linux - Server 2 06-26-2009 06:00 AM
Root Unable to delete files of unknown type Slowfamily Linux - General 1 06-20-2008 06:10 PM
Get file icon from extension, file type, or mime-type Guitarist88 Programming 3 04-21-2008 10:58 AM
Strange file attributes, can't delete and problems with apt maginotjr Ubuntu 4 04-16-2008 11:28 AM
Strange problem: can not delete file as root ?? hendrixx Linux - General 29 11-11-2004 12:46 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 12:31 AM.

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