I have two drives plugged into my Vero.
I am copying the contents of one to the other.
I need to pause or halt the operation (it’s been 48 hours and it’s only 60% complete).
Is there a command, maybe through SSH, that will stop the copying process after it finishes the current file (instead of just abandoning it mid-file).
I ask because I have had issues with ext4’s delayed allocation in the past and I don’t want to mess up what’s been done so far.
I want to stop the copy after current file completes and shut down the Vero (if that’s safe).
I have two drives plugged into my Vero.
It would depend how you initiated the copy and what filesystem you are using
If it’s taken 48 hours, you have a serious drive problem on one of the drives.
How are you doing the copy, via command line or from Kodi? Not that it really matters as there is no clean way to stop the copy after the current file is done.
In the future, you can get a little more control of a file copy by using rsync instead of a simple cp (if copying from a shell).
I personally have never, ever had corruption or lost files on an EXT4 filesystem. And I’ve been running Linux for 10+ years. Except on a failing drive, and no filesystem can help you if you have a drive failing.
I would just shut down the vero
shutdown now from the commandline then continue the copy with rsync which will automatically pick up half-copied files. Use the --info=progress2 option to see how it’s going.
Thanks for the replies!
I used the the Vero’s GUI.
Settings > File Manager > Copy.
It’s going from an NTFS to an ext4.
These are 8TB hard drives.
So I don’t think there’s an issue.
It’s just USB2.0 speeds transferring >5TB of data.
In File Manager there is an option to “Cancel file operations”.
But I would assume that would halt right in the middle of a file (which may be an 80GB UHD).
So I was just curious if there’s a stop after current file.
And I would assume that once the operation is done I could just shut down the Vero and everything should be fine, but just wanting to double check because of delayed allocation.
Didn’t know if maybe an “fsync” command should be sent prior to shutting down or unmounting the ext4 drive to be safe.
Actually - if you are copying files - use rsync.
Depending on the CPU speed, activate or deactivate compression. it depends if the CPU can handle compress/decompress the data faster when copying.
Thing is - when using rsync and you interrupt. Using the same command afterwards will check all copied files, and then continue the “sync” process where interrupted.
Thanks for the replies everyone.
My operation of copying 5.13TB of data finally completed after 80 hours.
Moving forward, I’ll definitely consider using rsync when moving small amount, but when moving terabytes worth of data I’ll probably move my drives to a different machine where I can use USB3 which I get around 170MB/s compared to the USB2 speeds of 30MB/s.
Still curious if there’s a stop after current file operation command option so if anyone knows it or knows that it doesn’t exist I’d still appreciate that answer either way.
After completing the copy I checked the contents in file manager and everything looks correct, so I did Power>Restart.
In my mind I imagine that any delayed allocation would have to be completed before a shutdown.
On next boot my new ext4 drive failed to mount and I know it’s not the USB plug because I have other drives downstream of that drive that mounted.
Okay, that’s weird, I’ll see what happens after another reboot.
The shutting down has yet to complete after at least 15 minutes so far.
It sat at
Started Update UTMP about System Runlevel Changes for a long time,
This was concerning but I waited and waited and it finally passed that, did a bunch of other things and now is just sitting on
[ OK ] Reached Target Shutdown.
I can feel the disk spinning but I don’t feel it writes happening.
How long should a wiat before pulling the plug?
Don’t wait any longer. Reached target Shutdown means the shutdown operation is complete.
I let it sit for 4 hours.
It never booted back up and the LED didn’t go red as if it shutdown either.
Tried to ssh in but no luck.
So I pulled the power and gave it a cold boot.
Still wouldn’t auto mount the new ext4 drive.
So this time I told it to power down.
Same thing, just sitting at
[ OK ] Reached target Shutdown on my TV and LED isn’t red.
I’m going to pull the power again and cold boot it with nothing attached.
Then I’ll enable debugging and try a reboot again.
Once the device says ‘Reached target Shut Down’, it is fully shut down on the OS side. It can now only be powered back on by unplugging and re-plugging the device.
Only the AO CPU remains active running U-Boot.
This is new behavior to me.
In the past if I told it to
Power>Reboot it would Reboot and if I told it to
Power>Power off system the TV would ultimately give me a No Signal and the + LED on the front of the Vero would be red.
Shut down would be fast, now it hangs on different steps.
Most commonly now it hangs on
[ OK ] Stopped D-Bus SYStem Message Bus.
^ There’s a log that should include a shutdown that got stuck and my last boot up with only the remote dongle plugged into the USB and shut down (that didn’t get stuck and was near instantaneous).
Then something you have added to your system is preventing a full shut down. A log won’t show anything unless you enable persistent journalling.
If you see ‘Reached target Shut Down’ the device is truly off and power can safely be removed.
If you see no signal and the LED becomes solid red, the device is also off, provided you haven’t selected Suspend by mistake.
After that log, I plugged in the ext4 drive by itself and Vero auto mounted it.
I went to the File Manager to look at it, looks fine.
Did a reboot and it reset and auto mounted the ext4 drive at boot up as expected.
Plugged another drive in, let it auto mount, told it to reboot.
System reset as expected, both drives auto mounted at boot up, plugged in next drive and it auto mounted so I told it to reboot again.
Put another drive on, repeat the same steps, success.
Tried the 5th drive and it doesn’t auto mount.
I feel it spin up but no mount.
Here’s the log now https://paste.osmc.tv/jokixajona
Did a reboot with the 5th drive still plugged in and it reset just fine.
Vero auto mounted 4 drives, then unmounted all of them, a notification said unsafe auto mount or something, then it mounted just 1 drive, the ext4 drive.
While retrieving this log it unmounted the ext4 drive with an unsafe message and remounted, then did it again after the log.
Not sure what the problem is for sure but if I put the et4 drive downstream of the NTFS drives then everything auto mounts.
^ That log shows me putting the drives on one by one and putting the ext4 8TB on last of the 8TB drives, then I added my two 2.5" NTFS drives.
I’ll keep an eye on it.
If you guys see anything odd in the logs then let me know.
A reboot will not hang at the shutting down message.
Usually if drives aren’t coming up this is indicative of a power issue.
How are you powering these drives?
Each drive has it’s own power supply with the exception of the two 2.5" drives which are on a powered hub.
Since I have put the ext4 drive at the end it hasn’t happened again.
Not sure why , but go figure.