[ubuntu-in] Strange problem with too many jpg files in one folder

Ritesh Sinha sinha.k.ritesh at gmail.com
Wed Aug 25 09:25:40 BST 2010


On Wed, Aug 25, 2010 at 1:10 PM, Ramnarayan.K <ramnarayan.k at gmail.com> wrote:
> Hi
>
> I accidently deleted a folder of images( using shift+del = direct
> delete not to trash)
>
> To recover them i used recoverjpg
>
> The problem is that that recoverjpg recovered many many images. The
> drive it was reading from was 200 gig which had tonnes of images,
> thumbnails etc on it . Recoverjpg looks and tries to recover deleted
> filed.
>
> I had been using various image managers to create thumbnails and such
> thumbnails are in lakhs
>
> recoverjpg placed the recovered files in my /home/foouser/ location
>
> Now this damn folder does not open because there are too many files in that
>
> I am un able to see and access this folder and any tool from command
> line gives up with the arguement
>
> unable to execute /bin/mv: Argument list too long
>
> whether is mv or chmod i get the same error message
>
> My problem is that there are too many thumbnails under 100 kb - i can
> safely del this but don't know a specific command that will do this
>
> I need to target specific sizes in the mv / rm command so that enmasse
> i can delete what is nonsense and focus on the files i lost which will
> / should be over 800 kb
>

# find $SOURCEFOLDER -type f -size +800 -name '*.jpg' -exec mv {}
$DESTFOLDER/. \;

This should move all jpg files above 800KB to DESTFOLDER.

> any idea how this can be achieved
>
> thanks
> ram
>
> --
> ubuntu-in mailing list
> ubuntu-in at lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/ubuntu-in
>



More information about the ubuntu-in mailing list