[TUTORIAL] ZFS SEND snapshot from inside MACOS to Proxmox ZFS with SSH

v95klima

Member
Jun 24, 2022
80
9
13
#Similar to same topic WINDOWS
https://forum.proxmox.com/threads/z...nside-windows-to-proxmox-zfs-with-ssh.152286/
#but for MACOS, this on Sonoma:
#Add hard disk to VM or bare metal. In my case Proxmox VM added hard disk with bus device VIRTIO and RAW file format.

#Boot into MacOS
# open Terminal
#Install Brew per https://brew.sh/
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
# needs like 10 GB of free space.....

#if you need to add 10GB of hard disk space on VM macOS
#shutdown Macos
# in Proxmox under correct VM, Hardware, Disk Action, + Resize, enter 10GB
# boot into VM Macos
#open Terminal
diskutil repairdisk disk0
diskutil apfs resizeContainer disk1 0
# now you should have extra 10GB

#if you ran out of space in previous install try again
#Install Brew per https://brew.sh/
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

#after succesfull brew install, per https://formulae.brew.sh/cask/openzfs#default
brew install --cask openzfs

diskutil list
#identify disk number for added new zfs disk, [ in my case disk0 ]

sudo zpool create -f -o ashift=12 -O casesensitivity=insensitive -O normalization=formD tank disk0

#pool already imported automatically when created, go straight to
zpool status
sudo zfs create tank/data
zfs list

#enable SSH key login to ZFS server you want to send snapshot to, with no password
#test ssh to server that it works with no password

sudo zfs snapshot tank/data@v0

zfs list -t snapshot

sudo zfs send tank/data@v0 | ssh root@192.168.X.Y zfs receive proxmoxpool/sonoma

sudo zfs snapshot tank/data@v1

sudo zfs send -i tank/data@v0 tank/data@v1| ssh root@192.168.X.Y zfs receive -Fv proxmoxpool/sonoma

#works!
 
Last edited:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!