- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: find -size
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-20-2003 07:09 AM
10-20-2003 07:09 AM
find -size
What is the correct use of the -size parameter to find all files over 500Mb ??
I know this probably sounds trivial but I can't
seem to ge it to work correctly ...
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-20-2003 07:12 AM
10-20-2003 07:12 AM
Re: find -size
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-20-2003 07:13 AM
10-20-2003 07:13 AM
Re: find -size
1,000,000 one half KB blocks would give you 500,000KB, which should be 500MB.
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-20-2003 07:16 AM
10-20-2003 07:16 AM
Re: find -size
Syntax is:
bigfiles
It will recursively search for files larger than
------------- cut here ----------------------
# cat bigfiles
# To find any file over a certain size in a given directory
# Primarily used to locate files which might be running a filesystem out of
# space.
#
# First parameter is the filesystem or directory to begin the search from
# Second parameter is the size of the file, in characters, to find
#
#
if [ $# -eq 2 ]
then
if [ -d $1 ]
then
#ls -l `find "${1}" -xdev -size +"${2}"c -print`
find "${1}" -xdev -size +"${2}"c -print > /tmp/crslist$$
if [ -s /tmp/crslist$$ ]
then
ls -l `cat /tmp/crslist$$`
else
echo "apparently no files that large in "${1}
exit
fi
else
echo "$1 is not a directory...try again"
exit
fi
else
echo "\n\nbigfiles requires 2 parameters..."
echo "\tthe first is the beginning directory"
echo "\tthe second is the size of the file to search for\n\n"
fi
############################################
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-20-2003 07:20 AM
10-20-2003 07:20 AM
Re: find -size
find . -type f -size +524288000c ...
will list those over 500MB.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2003 12:55 AM
10-21-2003 12:55 AM
Re: find -size
find . -xdev -size +524288000c -depth -exec ls -l {} \;
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2003 01:05 AM
10-21-2003 01:05 AM
Re: find -size
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2003 01:11 AM
10-21-2003 01:11 AM
Re: find -size
250MB
find . -size 265000000c -exec ll {} \;
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2003 01:14 AM
10-21-2003 01:14 AM
Re: find -size
#find . -size +262144000c -exec ll {} \;
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2003 01:15 AM
10-21-2003 01:15 AM
Re: find -size
-size 1 will match 512 bytes
-size 1c will match 1 byte
-size +1 will match greater they 512 bytes