Results 1 to 2 of 2
Hi
All I am trying to do is to find out which files in a given directory is larger than a certain size. for this i am using:
find /usr/abc/WebSphere/PortalServer/log/ ...
- 08-11-2008 #1Just Joined!
- Join Date
- Jun 2007
- Location
- UK
- Posts
- 14
default file size unit for ls and find
Hi
All I am trying to do is to find out which files in a given directory is larger than a certain size. for this i am using:
find /usr/abc/WebSphere/PortalServer/log/ -type f -size +41824
it gives me to 2 files, results of "ls -l" on these are:
-rw-r--r-- 1 root system 206318286 Aug 01 18:06 SystemErr_08.08.01_23.00.00.log
-rw-r--r-- 1 root system 371845536 Aug 01 20:00 SystemOut_08.08.01_23.00.00.log
The fifth column of ls output is the size of file and i cant figure out which units the find command is actually using.
I have tried to change the units find is using by: +n[K,M,G] and all commands produce same output, so it seems like i cant change the units as long as i can find out which ones they are :P. Can some one please help me in finding out which units are being used by the find and the ls commands in my example.
ps: file -size & stat command dont work on my stupid AIX box.
cheers
ali
- 08-12-2008 #2Linux User
- Join Date
- Jun 2007
- Posts
- 318
Did you look at the manpage for find (# man find)? If find works on AIX like on other *nix systems then the default is in units of 512-byte blocks. So your command using option '-size +41824' is looking for files larger than 21413888 bytes (41824*512).


Reply With Quote