Andrea3000 Posted April 18, 2022 Share Posted April 18, 2022 Hi, I’m putting together a storage server and I’m planning to install Unraid and use the ZFS plugin to have a native ZFS pool as my main storage. The client that will use the storage server the most, runs MacOS. Currently I backup my data via USB using Time Machine. Once the server will be up and running I plan to use ZFS snapshots to create periodic snapshots of all my datasets. Is there a way to access the ZFS snapshots via Time Machine, in a similar way to what can be done in Windows with shadow copies? In other words, is there a plug-in that allows to present the ZFS snapshot to MacOS as it were a Time Machine backup? Quote Link to comment
gyto6 Posted April 23, 2022 Share Posted April 23, 2022 (edited) You need to set a Zvol to receive an APFS on your pool dataset. https://openzfsonosx.org/wiki/Time_Machine_Backups No plug-in to clearly talk about, only a few commands relative to ZFS and NFS. Edited April 23, 2022 by gyto6 Quote Link to comment
Andrea3000 Posted April 23, 2022 Author Share Posted April 23, 2022 12 hours ago, gyto6 said: You need to set a Zvol to receive an APFS on your pool dataset. https://openzfsonosx.org/wiki/Time_Machine_Backups No plug-in to clearly talk about, only a few commands relative to ZFS and NFS. Thank you for the reply. Maybe I misunderstood that article, but what I would like to do is to let Unraid and ZFS handle the snapshots of the data on the server, even when the Mac is off. I would then like to use the Time Machine interface on the Mac to browse through the snapshots and restore files and folders if I need. Is that possible? Quote Link to comment
gyto6 Posted April 24, 2022 Share Posted April 24, 2022 (edited) 16 hours ago, Andrea3000 said: Thank you for the reply. Maybe I misunderstood that article, but what I would like to do is to let Unraid and ZFS handle the snapshots of the data on the server, even when the Mac is off. I would then like to use the Time Machine interface on the Mac to browse through the snapshots and restore files and folders if I need. Is that possible? It is. Concerning the automatic snapshot, I'll let you do your choice. Dont forget that a snapshot is not a backup. But sending your snapchots (with Sanoid or ZnapZend) on another system through SSH, USB disk (not prefered) or ISCSI is a backup if the second system is out of touch of the first (fire, stealth.. ) I conclude that most of your files is located on your Unraid only, so what matters is the smb config. It requires the "fruit" argument to let MacOS handle zfs snapshots as Truenas does. https://blog.gwlab.page/building-nas-with-zfs-afp-for-time-machine-d8d67add1980 Edited April 24, 2022 by gyto6 Quote Link to comment
gyto6 Posted April 24, 2022 Share Posted April 24, 2022 I'll add that, in the link provided, the user set a 32k recordsize. That's important because it refers to APFS default sector size. So it's important for interoperability to use this recordsize for your dataset. Quote Link to comment
Andrea3000 Posted June 2, 2022 Author Share Posted June 2, 2022 (edited) Sorry @gyto6 for the very late reply, it took me much longer than expected to source the components to build the server. I've now created a zfs dataset, and created few snapshots using: zfs snapshot -r myPool/myDataset@now I can see the snapshot being created with "zfs list -t snapshot" NAME USED AVAIL REFER MOUNTPOINT myPool/myDataset@now 1.28M - 1.32M - I've also created an SMB share that points to myDataset and I can access it via MacOS without issues. I went through both of the guides that you linked in the posts above but I can't find a way to make the snapshots accessible to MacOS via SMB. Am I missing something? To be more specific, if on the server I browse to: /myPool/myDataset/.zfs/snapshot I can see the snapshot named "now" that I have created: /myPool/myDataset/.zfs/snapshot# ls -a ./ ../ now/ From MacOS, if I browse to the share "myDataset" and then to the snapshot directory, I don't see any snapshot: ****@192 snapshot % pwd /Volumes/myDataset/.zfs/snapshot ****@192 snapshot % ls -a . .. Edited June 2, 2022 by Andrea3000 Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.