General :: Find Files Which Modifed 01 Year Before?

Oct 22, 2010

How to find files which is modifed 01 year before, with size detail

View 3 Replies


ADVERTISEMENT

General :: Find And List Files Created In A Particular Year?

Jan 31, 2011

How to find and list files and directories present the current directory which were created in, say, years 2005, 2006, and 2009 and then move them to some other location, for example, /backup. Yes, I need to list them and move simultaneously. We can use:

Code:

find . -mtime n {};

but that n is troublesome for me to figure out files/directories created in years 2005, 2006, and 2009, for instance. Is there any way to match exactly by Year Value rather than calulating the "n" (days * 24 Hours)?

System Info:

SunOS 5.8 Generic_117350-06 sun4u sparc SUNW,Ultra-Enterprise

View 3 Replies View Related

General :: List Only Today Modifed Files In Ubuntu?

Dec 30, 2010

How to list only today modify files in Linux ? How to 'scp' the today updated or modified files to another server? How to list files with modified date in Linux ? Currently am using UBUNTU 10.04

View 2 Replies View Related

General :: Delete Files Older Than 1 Year?

Sep 24, 2010

Possible Duplicate:How do I delete files greater than a certain date on linux How to delete all files in current directory and it`s sub directories older than one year ?

View 2 Replies View Related

General :: Copy Files Have 2 Year Old To Another Directory?

Apr 16, 2010

i just need to make copy files have 2 year old to another directory i know how to use cp command but i am not able to do that

View 2 Replies View Related

General :: Compress Some Folders Containing Backup Files From Last Year?

Jul 24, 2010

Today I tried to compress some folders containing backup files from last year. I right-clicked on the folders and selected compress as tar.gz. I let it work, and found that hours later, the folders were still compressing. How long is it supposed to take, anyway? I was trying to compress the two sets of backups simultaneously; together they're around 1.5 GB. They have many subdirectories.

View 4 Replies View Related

Programming :: Simple Bash To Write Files By Year To A Log File

Jan 31, 2011

I have a folder of 2 many files that the old ls just hangs.

I am trying to write some log files such as;

I don't mind doing one at a time, but I am just playing and even getting the listing I am not getting the date stamp, I have the following;

That does create the file, but all the files look like this;

So basically it's just sticking that ls inside the log file and not actually running the ls, so how can I use the above type to get files just created per year?

View 2 Replies View Related

General :: Find/grep/wc Command To Find Matching Files - Print Filename And Word Count?

Sep 11, 2009

I am trying to do a find/grep/wc command to find matching files, print the filename and then the word count of a specific pattern per file. Here is my best (non-working) attempt so far:

wc `find . ( -name "*.as" -o -name "*.mxml" ) -exec grep -H HeightResizableList {}` ;

View 10 Replies View Related

General :: Command Line - Use Find To Find Text Files?

Jul 15, 2011

Is there a way to specify to find that I only want text files (and not binary files)? Grep has an option to exclude binary files, so I thought find probably has a similar feature, but I've been unable to find it.

View 2 Replies View Related

General :: Find Setuid Files Using FIND Command?

Jan 25, 2009

I know how to search for normal files but can you let me know " How to search for 5 setuid files on the system. Also explain, for each file, why setuid mechanism is necessary for the command to function properly"

View 1 Replies View Related

General :: List/find All Regular Files In All Subdirectories Excluding Binary Files

Oct 5, 2010

I know I can do find . -type f, but that includes binary file and I couldn't find a way to exclude them with find

View 4 Replies View Related

General :: Show Previous Year When Performing Dec Backups In Jan

Jan 25, 2010

I have a script that moves files from one directory to another, based on the numeric date of the file name (i.e., 20091212 would go to the December directory). Now, since this script will be ran at the beginning of the following month (December's files to be tarred and gzipped will be performed the first day of January, and January's in February, etc.), it appears to me that the script will be tricky when it comes time to do the December files in January.

Here's part of the script:
Code:
# Define working directory and target directory.
DIR=/var/log
target=$DIR/month
hostname='uname -n' .....

I can't seem to figure out a way to carry the output of the date command to the next command, and the year for the December files will always be wrong.

View 2 Replies View Related

General :: A Script That Will Display Only The Last Login Of Each User With The Date And Year?

Apr 20, 2010

This is on an old machine that is running Solaris 7. I know that I can run the command script 'last' to get a list of who has logged in. When I do that I get a very long list of lines like:

username pts/4 100.32.11.123 Wed Dec 6 18:30 - 18:40 (00:09)

I see that the year is not posted. I have about 11 years worth of logins where users have logged in multiple times over several years.

So, here is what I need: I only need the date of the very last time a person logged in. I also need the year of that last login.

script that will do this? Something with output like

username1 pts/4 100.32.11.123 Wed Dec 6 2005 18:30 - 18:40 (00:09)
username2 pts/4 110.33.11.18 Tue Apr 20 2009 8:30 - 9:30 (01:00)
username3 pts/4 10.32.11.18 Mon Jun 12 2008 1:30 - 2:40 (01:10)
username4 pts/4 110.33.12.19 Sat Oct 10 2001 00:12 - 00:13 (00:01)
...

View 4 Replies View Related

General :: Find MP3 Files Without ID3 Tags?

Jan 21, 2011

I have a lot of mp3 files without any ID3 tag information. This is very annoying, because my iPod does not show them correctly. My Banshee shows them as "unknown artist" and the title. I would like to find them all in a bunch to batch update them.

View 2 Replies View Related

General :: Find Duplicate Files By Name ?

Jul 24, 2010

We have a huge amount of duplicate files in a folder and I would like some pointers on to writing a bash script to create a list of the duplicate files. I've seen examples that check for the md5 sum of files... but I dont need that, the file name is enough.

View 4 Replies View Related

General :: Find Which Files Were Transferred?

Nov 30, 2010

Say someone logs into a Centos Linux box and SCPs a file from /root/ called 'textfile.dat'

Is there any way to log into the Centos Linux box, later, and see that textfile.dat was SCP'd from the box?

View 9 Replies View Related

General :: Find One Day Older Files?

May 31, 2011

I used following command to sort one day older log files

Quote:

find /opt/TimesTen/tt_transaction_log/ -name "mtsDB.log*" -mtime +1 -print

following are log files which are existing, I have to delete one day older files from this location but when use above mentioned command it won't print one day older files, as i understand "-mtime" modified time, "+1" means one day older. am i correct?

Code:

-rw-rw-rw- 1 ablddb dba 268435456 May 30 17:11 mtsDB.log126985
-rw-rw-rw- 1 ablddb dba 268435456 May 30 17:17 mtsDB.log126986
-rw-rw-rw- 1 ablddb dba 268435456 May 30 17:23 mtsDB.log126987

[code].....

How can i print one day older logfiles?

View 3 Replies View Related

General :: Find Size Of The Files?

Jun 8, 2011

To find the space occupied by files modified more than 4 years ago, i tried following.I am wondering if it is right ?

Code:

find /temp -type d ! -name ".*" -mtime +1460 | wc -l |du -sh

I tried this, but this sits there for long time (of couse the path i tried has lot of files) So i am not sure if this is right.

P.S.:

SHELL=bash
OS=RHEL5

View 9 Replies View Related

General :: Find Text Within Files?

Nov 23, 2010

find text within files? detailed at Code: man grep

View 2 Replies View Related

General :: Find Big Files On The Disk?

Oct 17, 2010

How can I find big files on the my Linux disk with say more than 500MB in size?

View 2 Replies View Related

General :: Using Find To Exclude Some Files

Dec 7, 2010

I'm trying to find all java files in bash that contains the method "assign()".I would like to retrieve the same list except without the Test* files. How can I do that?

View 3 Replies View Related

General :: Find Command In Locate Pdf Files?

May 25, 2010

My goal is to find all pdf files on a remote machine, so I resort to the useful command find. So I type find .pdf or find .pdf" and I get nothing. I do the same on my machine and I get nothing. I do a regular search from the menu on my machine and I find quite a few pdf files. Would somebody please tell me what am I doing wrong?

View 5 Replies View Related

General :: Using Find And Tar With Files With Special Characters In The Name?

Jun 1, 2010

I want to archive all .ctl files in a folder, recursively.tar -cf ctlfiles.tar `find /home/db -name "*.ctl" -print`The error message :tar: Removing leading `/' from member namestar: /home/db/dunn/j: Cannot stat: No such file or directorytar: 74.ctl: Cannot stat:No such file or directoryI have these files: /home/db/dunn/j 74.ctl and j 75. Notice the extra space. What if the files have other special characters? How do I archive these files recursively?

View 2 Replies View Related

General :: Find Files That Have Been Accessed After They Were Created

Sep 10, 2010

With the find command it is easy to find files that have been modified or accessed within a given period. When a file is created, the acesss time is the same as the modify time. But as soon it is accessed (read), the access time changes, but the modify time does not. I need to find files that been accessed at all, ie. files which have access time newer than modify time. How do I do that?

View 2 Replies View Related

General :: Bash: Find Folders With Less Than X Files?

Sep 18, 2010

How would I go about finding all the folders in a directory than contain less than x number of .flac files?

View 2 Replies View Related

General :: Edit All The Files Returned By Find In Vi?

Sep 15, 2011

Something I find myself doing a lot is running a find command and then editing all of them in vi, which looks something like this:

> find . "*.txt"
./file1.txt
./file2.txt
./path/to/file3.txt
> vi ./file1.txt ./file2.txt ./path/to/file3.txt

Is there a clever & simple way to do this all in one command line?

View 3 Replies View Related

General :: Find The Difference Between Two Files In Different Servers?

Mar 18, 2010

I want to find the difference between two files in different servers , which have trust enabled to ssh without password.

Am using the following command , which shows no output. But i am able to see some difference there in the files manually.

Code:
serv1$diff .profile `ssh serv2 ls .profile`

View 1 Replies View Related

General :: Find Multiple Strings Into Files?

Mar 22, 2010

I would like to find all the files that contains the strings I'm searching.

For example (it's just an example), I would like to search all the files in "/etc" that contains "eth0" and "us", whatever where are located those 2 strings, the important is that the 2 strings are in the files listed.

It would be something like a "grep -lr 'eth0' *" and "grep -lr 'us' *" but in one time/command, so that I don't have to make a comparison of the 2 list of files resulting from the 2 "grep" commands given higher.

View 10 Replies View Related

General :: Searching For PHP Files With Find And Grep

Nov 2, 2010

I am looking for all the files that contain the text string 'moo.sql'. I ran the following:

find . -name '*.php' | grep -lir 'moo.sql' *

Unfortunately it seems to return non-php files in addition to php files. I thought the find portion of this would filter the file names so grep would only search php files.

View 3 Replies View Related

General :: How To Find Files With Unusual Size

May 18, 2010

i need help in this issue how to find files with unusual size and with unusual names of EX : just dots, names ending with space(s),names containing shell wildcard characters, names containing non-ASCII (control) characters

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved