LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise
User Name
Password
Linux - Enterprise This forum is for all items relating to using Linux in the Enterprise.

Notices



Reply
 
Search this Thread
Old 10-30-2012, 11:54 PM   #1
Anup D.
LQ Newbie
 
Registered: Jan 2012
Location: Nanded
Distribution: RHEL
Posts: 25

Rep: Reputation: Disabled
Can't delete directory - question marks showing in ls -l


On CentOS 5.8 I want to delete one directory.
When I type ls -l it shows :
?--------- ? ? ? ? ? locales

It doesn't allow me to rename, move, copy, delete, chown, chgrp, chmod it.
Every command shows only "No such file or directory"

I don't know why this "?" symbol it is showing in permissions.
What can I do to delete this directory?

Last edited by Anup D.; 10-30-2012 at 11:55 PM.
 
Old 10-30-2012, 11:58 PM   #2
arun5002
Member
 
Registered: Aug 2011
Location: Chennai,India
Distribution: Redhat,Centos,Ubuntu,Dedian
Posts: 549
Blog Entries: 5

Rep: Reputation: Disabled
whether you are trying to delete the directory with root priviledge ? are normal user ? I guess you dont have priviledge for listing & delete permission for the directory

Last edited by arun5002; 10-31-2012 at 12:00 AM.
 
Old 10-31-2012, 12:07 AM   #3
Anup D.
LQ Newbie
 
Registered: Jan 2012
Location: Nanded
Distribution: RHEL
Posts: 25

Original Poster
Rep: Reputation: Disabled
It is a Virtuozzo container. I am trying to delete it with root user.
 
Old 10-31-2012, 10:06 AM   #4
Valery Reznic
ELF Statifier author
 
Registered: Oct 2007
Posts: 669

Rep: Reputation: 134Reputation: 134
Quote:
Originally Posted by Anup D. View Post
On CentOS 5.8 I want to delete one directory.
When I type ls -l it shows :
?--------- ? ? ? ? ? locales

It doesn't allow me to rename, move, copy, delete, chown, chgrp, chmod it.
Every command shows only "No such file or directory"

I don't know why this "?" symbol it is showing in permissions.
What can I do to delete this directory?
Likely your filesystem corrupted.

Try to run fsck

Valery
 
Old 10-31-2012, 04:25 PM   #5
linosaurusroot
Member
 
Registered: Oct 2012
Distribution: OpenSuSE,RHEL,Fedora,OpenBSD
Posts: 870
Blog Entries: 2

Rep: Reputation: 219Reputation: 219Reputation: 219
If the problem was only the name I'd suggest "ls -lb".
The filename may contain non-printing characters that have messed up the output you are reading.
If that's right then something like "rm -ri ./*locales" may work.

With the permissions also looking odd I agree with the suggestion to fsck.
 
Old 10-31-2012, 11:55 PM   #6
Anup D.
LQ Newbie
 
Registered: Jan 2012
Location: Nanded
Distribution: RHEL
Posts: 25

Original Poster
Rep: Reputation: Disabled
Thank you for reply.

I tried ls -lb command it shows locales directory name in red background:
# ls -lb
?--------- ? ? ? ? ? locales

and command "rm -ri ./*locales" also giving the same error
# rm -ri ./*locales
rm: cannot lstat `./locales': No such file or directory.

It is live container with number of live clients.
fsck does not affect data ?
 
Old 11-01-2012, 10:49 AM   #7
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: CentOS
Posts: 1,610

Rep: Reputation: 674Reputation: 674Reputation: 674Reputation: 674Reputation: 674Reputation: 674
You cannot run fsck on a mounted file system. You will have to arrange a scheduled maintenance time, take the file system offline, and clean it up. You have a slightly (hopefully!) corrupted file system. There is little other choice for repairing it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] ls shows directory attributes as question marks daisychick Linux - Newbie 5 04-30-2012 04:19 PM
Using question marks in mod_rewrite kevin-fdc Linux - Server 4 03-16-2010 05:24 PM
Question marks in the directory attributes, need help fixing. jason143 Linux - Software 5 06-22-2009 02:17 AM
question marks show when doing ll abylin1 Linux - Newbie 9 01-15-2008 03:54 PM
Quotes as Question Marks in Thunderbird. Matir Linux - Software 2 07-11-2005 03:54 PM


All times are GMT -5. The time now is 11:57 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration