Sponsored Content
Top Forums UNIX for Dummies Questions & Answers help with finding specific files Post 302249099 by radoulov on Monday 20th of October 2008 03:30:09 PM
Old 10-20-2008
Assuming GNU find (given your nick):

Code:
show_bigger(){ find -type f -size +"$1" -ls 2>/dev/null;}

For example:

Code:
% show_bigger 10M
1550976 66296 -rw-r--r--   1 root     root     67810654 Sep  9 20:25 ./sqldeveloper_1.5.54.40-2_all.deb
1550982 66308 -rw-r--r--   1 radoulov radoulov 67825452 Sep  9 20:24 ./sqldeveloper-1.5.54.40-1.noarch.rpm
819309 27012 -rw-r--r--   1 radoulov radoulov 27624080 Oct 16 11:58 ./fuz2y_desktop_theme_v1.2.tar.gz

Just saw you want to pass the path too, so:

Code:
show_bigger(){ find "$1" -type f -size +"$2" -ls 2>/dev/null;}

In zsh you could use (size is in bytes):

Code:
print -rl -- **/*(.DL+10000000)


Last edited by radoulov; 10-20-2008 at 04:51 PM..
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

finding specific values in a within a file

Hi everyone, Can anyone guide me on how to search through a huge file and look on specific column and if it finds a discrepancy on that column that does not conform to the specified criteria, ie (1) Numeric and (3) alpha chars F123 or G333..etc, etc! then idientify it and redirect... (3 Replies)
Discussion started by: Gerry405
3 Replies

2. Shell Programming and Scripting

Finding a specific pattern from thousands of files ????

Hi All, I want to find a specific pattern from approximately 400000 files on solaris platform. Its very heavy for me to grep that pattern to each file individually. Can anybody suggest me some way to search for specific pattern (alpha numeric) from these forty thousand files. Please note that... (6 Replies)
Discussion started by: aarora_98
6 Replies

3. Shell Programming and Scripting

finding duplicate files by size and finding pattern matching and its count

Hi, I have a challenging task,in which i have to find the duplicate files by its name and size,then i need to take anyone of the file.Then i need to open the file and find for more than one pattern and count of that pattern. Note:These are the samples of two files,but i can have more... (2 Replies)
Discussion started by: jerome Sukumar
2 Replies

4. Shell Programming and Scripting

Finding file in specific subdirectories

Hi experts problem: i have a directory "DATA" with lots of subdirectories named as date with hudge data containning files. Directory = "DATA" subdirectory = "20090611" & "20090612" ...... 20090611 = thousands of files i wanna apply find command to find all files in... (3 Replies)
Discussion started by: The_Archer
3 Replies

5. Shell Programming and Scripting

Finding a specific word

Hi, I am trying to develop a script which should find a word if a particular word exists. Below is the content of the file. insert_job: test_job ----> job name days_of_week: all start_times: "16:00" date_conditions: 1 insert_job: test_job2 ----> job name days_of_week: all... (16 Replies)
Discussion started by: rpatty
16 Replies

6. Shell Programming and Scripting

Finding minimum value out of specific rows

Hi all, I am having multiple files with the pattern given below: I need to find the minimum value of 5th column if column 1 is x and 2nd column is awh or vbn or ... (20 different strings). the output must be like: Kindly help me to figure out this prob.... Thanks in... (4 Replies)
Discussion started by: CAch
4 Replies

7. Shell Programming and Scripting

finding file with a specific range

Hi All, Thanks in advance File is generated with following format 31000000.xml to 48999999.xml 74000000.xml to 88999999.xml Above range should be find and moved into the folder named abc and below is another range should should be find and moved into folder named xyz ... (1 Reply)
Discussion started by: sujit_kashyap
1 Replies

8. Shell Programming and Scripting

Finding 4 current files having specific File Name pattern

Hi All, I am trying to find 4 latest files inside one folder having following File Name pattern and store them into 4 different variables and then use for processing in my shell script. File name is fixed length. 1) Each file starts with = ABCJmdmfbsjop letters + 7 Digit Number... (6 Replies)
Discussion started by: lancesunny
6 Replies

9. UNIX for Dummies Questions & Answers

Finding Files only under a specific FileSystem

Hi, I am using AIX and one of my file systems is getting filled up and I need to track with files are occupying more volume. Filesystem GB blocks Free %Used Iused %Iused Mounted on /dev/nhdb_lv 2110.00 63.80 97% 76525 1% /nhdb under the Mount Point /nhdb... (1 Reply)
Discussion started by: zulfi123786
1 Replies

10. Shell Programming and Scripting

Finding lines of specific size in files using sed

i am using sed to detect any lines that are not exactly 21. the following gives me the lines that ARE exactly 21. i want the opposite , i want the two lines that are not size 21 (shown in bold) type a.a 000008050110010201NNN 000008060810010201NNN 21212000008070110010201NNN... (5 Replies)
Discussion started by: boncuk
5 Replies
MAKE-KLONE-PROJECT(1)					      General Commands Manual					     MAKE-KLONE-PROJECT(1)

NAME
make-klone-project - manage a KLone based custom Debian package SYNOPSIS
make-klone-project [options] COMMAND DESCRIPTION
make-klone-project is a tool to create and manage custom webserver packages that use KLone, a framework that integrates a web site with possibly dynamic content and a web server into a single binary. The aim is to let the author to focus on editing the site specific files under webapp/ and allow creating a Debian package containing the web server and an init.d script to manage it with dpkg-buildpackage. USAGE
make-klone-project takes one non-option argument. create Create a new project directory, package-0.1 and seeds it with KLone's source and a debian/ directory. clean Remove all non-user created files and directories ie. everything but debian/copyright, debian/changelog, debian/wsp.* and webapp/. See also the -l option below. refresh Cleans the project directory as with make-klone-project clean and reseeds the KLone source and the debian/ directory. EXAMPLES
make-klone-project create -p myapp -m "Kari Pahula <kaol@debian.org>" cd myapp-0.1 (edit any files that require editing, mostly in webapp/) make-klone-project refresh dpkg-buildpackage -rfakeroot sudo dpkg -i ../myapp_0.1_i386.deb OPTIONS
-b NAME Name the created web server binary as NAME. If not specified the package name is used. -l Look for the project root directory in clean and refresh commands by changing the working directory to the parent directory until they find a file named debian/wsp.opt.maintainer in the current directory. Returns with error if none is found. Without this op- tion, only the current directory is checked for this file. The upside of using this option is that make-klone-project will be agnostic about the working directory, as long as it is somewhere inside the project tree, just like dpkg-buildpackage. The downside is that you run a greater risk of having the clean command cause unwanted data loss, if you happen to have an unfortunately named file in a wrong place. -m NAME Sets the maintainer name as NAME. -p NAME Set the package name as NAME. Only effective with the create command. If not specified, uses customkloneapp. FILES
debian/wsp.description A custom description for the package. Should be formatted like the corresponding field in the debian/control file. debian/wsp.opt.* The options set in prior calls to make-klone-project. webapp/ The user specified site tree, to be imported as the site by KLone. NOTES
Your web server will be run as a root, so you will need to use either allow_root or uid and gid options in your etc/kloned.conf. SEE ALSO
dpkg-buildpackage(1), klone(1), kloned.conf(5), kloned(8). AUTHOR
make-klone-project was written by Kari Pahula <kaol@debian.org>. 16 Sep 2007 MAKE-KLONE-PROJECT(1)
All times are GMT -4. The time now is 11:44 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy