You are not logged in.
I have a zfs dataset that doesnt mount automatically. i would like it to mount automatically. i have a script, it became painstaking, i left it in limbo. Im leaning to making a service so that systemd can manage it at boot, and can handle the logging if errors.
In the mean time, each time the system reboots, rsnapshot goes to back up to this mount, the mount doesnt exist, it creates the directory and follows through with the snapshot. it sees nothing, write a bunch.
now when i go to mount my zfs, its like a circus which i narrowed down to a parade in two commands
mv /san .DELETING && rm -rf .DELETING &
followed by
zfs import san
job done
im getting tired of doing it this way because each time i have to inspect the grounds before i clear it off to set up the tent for the circus by making sure theres nothing but the snapshot dir inside the /san dir, which is yet another step. Not to mention it fills up my directory and i seriously find out the hard way each time, after something breaks.
Im open to suggestions. leaning on moving the zfs mount to a system service and be done with it, or i envision theres something in rsnapshot that as a switch causes it to maybe NOT create if directory doesnt exist? I can see that being a quick fix. If the san isnt mounted, there will be no rsnapshot directory to be found, and it will fail out.
Last edited by wolfdogg (2015-11-28 21:41:04)
Offline
Zfs should import all datasets; I'm assuming you have zfs.target enabled.
What dependencies does the service that runs rsnapshot have? Does it have “After=local-fs.target”?
Offline
Ok, so ill have to look into zfs.target.enabled. It usually takes me a while to get zfs reconfigured. IN the mean time,
$ systemctl list-dependencies rsnapshot
rsnapshot.service
and im running rsnapshot via cron. geese, maybe its time i update it to a service then? Where from here? What is the zfs.target.enabled?
edit
ahh, the service enabled. forgot about this service.
zfs.target was indeed disabled.
$ systemctl is-enabled zfs.target
disabled
nice, havent seen that wiki in a while i guess, its been updated again, this is great, it needed it! FYI on that topic, I have some zfs support info on my talk page, most of which, some that hasnt, been moved over to the zfs wiki as well.
So currently im awaiting suggestions on rsnapshot if i should... cut, ok so i just looked at that wiki and i see systemctl usage on there too, so im going to definitely update my usage of rsnapshot to use it.
thanks, ill report back if i cant get the zfs to auto mount per the wiki.
Last edited by wolfdogg (2015-11-28 21:08:16)
Offline
Dude, thats such a relief, thanks for the ideas, it shed light that my system is getting outdated, i followed the automatic start here https://wiki.archlinux.org/index.php/ZFS#Configuration. it appears i may have reinstalled zfs last before the wiki was updated, because i dont think i would have missed that. A fresh reboot, and BAM my multi TB array is online and available from the get go. Thats awesome! What a relief.. I cant even tell you. This was the only maintenance task i really had, other than updating. Something so lame too, I have looked in that wiki so many times that i guess i got slack.
Last edited by wolfdogg (2015-11-28 21:42:08)
Offline