How do move large number of files ?

Preston Hagar prestonh at
Tue Apr 13 19:22:17 UTC 2010

On Tue, Apr 13, 2010 at 2:09 PM, MirJafar Ali <mirjafarali at> wrote:
> Hello,
> I have very huge number of files in one directory that I wish to move to
> some other folder and
> the standard  "mv" just screames
> crash-06:~/DataSet$ mv file*  SFiles
> bash: /bin/mv: Argument list too long
> Can someone suggest what is may be a good solution.  of course picking one
> by one is ruled out.
> Mir

You could do something like the following:

cd ~/DataSet
find . -exec mv {} SFiles/ \;

Basically, cd to the directory and then do a find with a mv exec
command to the new directory.

Hope this helps.


More information about the ubuntu-users mailing list