Controlling OMV though the command line

  • I'm sure this is probably documented somewhere but my google-fu skills are failing me. I'm setting up my snapraid sync script and would like to disable some services (SAMBA, SFTP, etc) while the sync is happening to ensure that no data gets modified mid sync. Is there a way to control OMV from the command line so I can integrate it into my script?


    Thanks!

  • I'm setting up my snapraid sync script and would like to disable some services (SAMBA, SFTP, etc) while the sync is happening to ensure that no data gets modified mid sync

    You can rely on Debian basics here. Stop the respective services/daemons via systemctl in your script and start them again after your sync script finished.


    Another approach when you use rsync is to run two rsync calls directly afterwards to catch those files that have changed in between. And then checking for open files that need further attention is another good idea (see here for details or in general for some inspiration).


    The best solution is of course using storage attempts that have been developed in this century. Snapshot capable filesystems allow to 'freeze' the whole fs and then transfer the snapshot efficiently using btrfs|zfs send/receive. No downtime whatsoever or maybe just less than a second.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!