Quantcast
Channel: Bash: mv directory one at a time - Server Fault
Browsing latest articles
Browse All 6 View Live

Answer by Craig for Bash: mv directory one at a time

Using the mv command to move files from one volume to a different volume is a copy operation. But how would you run out of space on the source volume? You would only run out of space on the target...

View Article



Answer by kalikid021 for Bash: mv directory one at a time

Just for reference, I believe the mv command doesn't do a copy then delete operation, ie having mv /home/foo /home/bar exist simultaneously for a short period. It operates more like renaming. Essential...

View Article

Answer by Florin Asăvoaie for Bash: mv directory one at a time

ls -1 | xargs -n1 -i echo mv '{}' destination Just remove the echo when happy.

View Article

Answer by dawud for Bash: mv directory one at a time

You could use rsync(1): rsync --remove-source-files /path/to/source /path/to/destination This will remove successfully transferred files from the original path.

View Article

Answer by Michael Hampton for Bash: mv directory one at a time

You want for. An example (this will just show what will be done): for item in *; do echo mv "$item" /destination/directory done When you're happy, remove echo to do it for real.

View Article


Bash: mv directory one at a time

I am trying to move all subdirectories of a folder to another share on the same server. If I do a mv *, I will run out of space since the folders are not removed until all folders get transferred. So...

View Article
Browsing latest articles
Browse All 6 View Live




Latest Images