Home Server Tweaking How to fix /bin/mv: Argument list too long error

How to fix /bin/mv: Argument list too long error

by SupportPRO Admin

If you are trying to move large number of files such as more than 50000 files using the command mv, you will get the error given below.
[root@server /]# mv * /path/to/move
“/bin/mv: Argument list too long”
In such cases, you can use the command given below to avoid this error ,

find /path/to/file -type f | xargs -i mv “{}” /path/to/move

If you require help, contact SupportPRO Server Admin

Server not running properly? Get A FREE Server Checkup By Expert Server Admins - $125 Value

Leave a Comment

CONTACT US

Sales and Support

Phone: 1-(847) 607-6123
Fax: 1-(847)-620-0626
Sales: sales@supportpro.com
Support: clients@supportpro.com
Skype ID: sales_supportpro

Postal Address

1020 Milwaukee Ave, #245,
Deerfield, IL-60015
USA

©2022  SupportPRO.com. All Rights Reserved