0

I want to find user, size, modified date and full file path of all files in sub-directories starting from a dir. I have got to following so far:

nohup sudo \
tree /work/mydir \
-sufiD \
--noreport \
--timefmt="%Y-%m-%d" | \
sed -e 's/ \+/ /g' -e 's/\[//g' -e 's/\]//g' -e 's/\.\///g' -e 's/ /|/g' | \
tail -n+2 \
> usage_mydir.txt &

This gives me the desired output except that it lists all files; i want to filter out files say less than 10MB which will reduce my output file considerably (from over 500 MB to less than 5MB).

I am open to any other commands such as find . -type f -size +10M. But I need the owner, size and last modified time of the file.

1 Answers1

1

You can use -ls in find to get the owner size, and modification time:

find . -type f -size +10M -ls