In my experience cp(1) is fragile, which is why I use rsync(1) for anything more than one or two files. The following should work,
rsync -av /media/bkup1/* /mnt/usb1tb This will create all the subdirectories from /media/bkup1 and copy all the files onto the mounted USB drive. Rsync is re-entrant, i.e. it will start where it left off if something happens. If you want to copy each directory separately, change the * to the name of the directory. On Wed, Jan 10, 2024 at 11:16 AM Rich Shepard <[email protected]> wrote: > In my MediaSonic Probox the backup1 drive is still formatted with xfs. > Since > XFS throws an error now and then requiring me to umount the drive, run > xfs_repair, and remount it I want to replace the filesystem with ext4. > > Currently, the drive holds 644GB. When I've tried to `cp -R /media/bkup1' > to > a 1TB USB flash drive it's taken hours and fails when the cp command hits > the spot(s) causing the errors. > > One approach I could use is to copy each of the 8 subdirectories one at a > time. Is there a better way to copy off the files so I can replace the > filesystem and re-copy the files back to it? > > TIA, > > Rich > >
