1833883 Members
1855 Online
110063 Solutions
New Discussion

Files in /var/adm/syslog

 
SOLVED
Go to solution
CCIL
Frequent Advisor

Files in /var/adm/syslog

Hello Everyone

I hv one N- Class server , having 2 vpars ,
The main partition (OS is 11i)shows following file in /var/adm/syslog , the attributes of the files are also unknown & when i try to remove them it shows file does not exists ...

what could be the reason ..is it some OS problem
Amit Vichare
9 REPLIES 9
Robert-Jan Goossens
Honored Contributor

Re: Files in /var/adm/syslog

Hi,

No the problem is that the rm command can not locate your files. You can use

# rm -- file name

just execute this command for every file you want to delete.

Kind regards,

Robert-Jan.
Eugeny Brychkov
Honored Contributor
Solution

Re: Files in /var/adm/syslog

cd /var/adm/syslog
rm 6*
rm e*
rm i*
Eugeny
CCIL
Frequent Advisor

Re: Files in /var/adm/syslog

Hello !
when i try to remove the file i get the following message
"file non-existent"
Amit Vichare
Armin Feller
Honored Contributor

Re: Files in /var/adm/syslog

Hi,

find the inode of the file and remove it then:

# ls -i
# find -inum -exec rm -f {} \;

Perhaps that helps.

Regards ...
Armin
Eugeny Brychkov
Honored Contributor

Re: Files in /var/adm/syslog

BTW, try fsck'ing volume first. Some files have same size, maybe there's problem with inode table
Eugeny
john korterman
Honored Contributor

Re: Files in /var/adm/syslog

Hi,
you have file names with spaces, perhaps a result of failed redirection. Try to get hold of the file names first by quoting, e.g.

# ls -l "64, minor i"

or by using single qoutes. Then you can remove them.

regards,
John K.
it would be nice if you always got a second chance
Ravi_8
Honored Contributor

Re: Files in /var/adm/syslog

Hi,

it's not OS problem. you can remove the files as mentioned in the previous posts
never give up
Shoghi_1
Advisor

Re: Files in /var/adm/syslog

mv ./64* garbage
rm garbage

Do that with each file!
Bill Hassell
Honored Contributor

Re: Files in /var/adm/syslog

Someone really messed up with a command and created filenames with text strings. There are imbedded spaces but most likely, there are control characters that do not show up with an ordinary ls command. Add the -b option to show the special chars:

ll -ab

Since there aren't very many files, use this command to remove the files interactively:

/usr/bin/rm -i * .[!.]*

The first * takes care of finding files that don't start with a . and the second string finds files that start with a . but excludes the special directory file ..

You then answer y to each filename that you want to remove and n to leave the file. As mentioned, run fsck on this filesystem. Since it is the /var directory, ypou'll need to go int single user mode since virtually everything has active files in /var.


Bill Hassell, sysadmin