Dogbert
Dogbert

Reputation: 222108

Find files created in a particular ssh session or date

How can I find all the files that were created by a particular session using ssh?

Or search for files that were created/modified on a particular date?

Upvotes: 3

Views: 2266

Answers (2)

zoli2k
zoli2k

Reputation: 3458

You can list the open files on your system with lsof -n. To find files updated in the last 5 minutes find . -cmin -5.

Upvotes: 2

Jubal
Jubal

Reputation: 8717

You can use the find command with the various switches of -mtime -ctime and -atime

Quoted from this link: http://www.softpanorama.org/Tools/Find/selecting_files_by_age.shtml

To find html files that have been modified in the last seven 24-hour periods (days), I can use -mtime with the argument -7 (include the hyphen):

find . -mtime -7 -name "*.html" -print

Upvotes: 4

Related Questions