On Wed, Feb 12, 2003 at 02:21:43PM -0500, parv wrote:

>  find . -inum $( /bin/ls -i | fgrep '?' | awk '{print $1}' ) -print0 \
>  | xargs -0 rm -f

I'm going to go out on a limb and guess that the filename does not really
consist of question marks, but rather of unprintable characters that ls
displays as '?'.  Note:

# Note that ^A is a literal control-A, typed with control-V control-A
$ echo > ^A
$ ls
?

I recommend finding the inode number of the offending file:

$ ls -li
total 1
1238024 -rw-rw-r--  1 mph  mph  1 Feb 12 12:07 ?

The inode number in this case is 1238024.  Then you can double-check and
delete it with find:

$ find . -inum 1238024 
./+
$ find . -inum 1238024 -delete

(Note that find displays the name differently from ls.  It looks like a
bold "+" in my xterm.)

-- 
Matthew Hunt <[EMAIL PROTECTED]> * Inertia is a property
http://www.pobox.com/~mph/           * of matter.

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-questions" in the body of the message

Reply via email to