Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 29 Sep 1999 18:12:47 +0100
From:      Adam Nealis <adamn@csl.com>
To:        Ken Blundell <ken@osicom.net>
Cc:        freebsd-questions@FreeBSD.ORG
Subject:   Re: A Weird File Problem
Message-ID:  <37F2488F.175C5A64@csl.com>
References:  <000801bf0a93$ef002e60$1967eccf@osicom.net>

next in thread | previous in thread | raw e-mail | index | archive | help
> Ken Blundell wrote:
> 
> Hello,
> I've never run into this before.  It looks like a weird file problem.
> I'm running FreeBSD 2.2.2.
> Someone decided to mess up my server and now I cannot delete a couple of files.
> There is a file in the /etc dir.
> -rw-------  1 root  wheel      31243 Sep 29 00:14 gay
> If I try to do a rm on the file this is what I get back:
> # rm gay
> rm: gay: No such file or directory
> #
> What an I doing wong??
Try

find /etc -name \*gay\* -print

which will find all files matching the pattern *gay*

If there's only one of 'em, do

find /etc -name \*gay\* -exec rm {} \;

Basically, there might be some white space or non-ASCII characters in the filename
and you're not seeing this when you ls -l

> Also there is a multiple listing for the master.passwd file:
> -rw-------  1 root  wheel      30615 Sep 29 11:37 master.passwd
> -rw-r--r--  1 root  wheel         95 Sep 29 00:19 master.passwd
> Should there be two entries?  If not, how do I get rid of one of them?
No there shouldn't be two entries. It might be the same thing as for the "gay"
file above. The permissions on the second master.password look suspect, so
try

cp -p master.passwd Master.passwd
find /etc -name \*master.passwd\* -print
find /etc -name \*master.passwd\* -exec rm {} \;
cp -p Master.passwd master.passwd

Cheers,
Adam.


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?37F2488F.175C5A64>