Hey folks,
I recently embarked on a project that involved repurposing my parents’ desktop PC to serve as a dedicated backup server. Here’s the backstory and how I made it work seamlessly for them.
My parents’ desktop PC had been lying around unused for a while, so I decided to repurpose it. I installed ZFS on a virtual machine running rest-server under Hyper-V. ZFS is a robust file system known for its data integrity features, making it perfect for storing backups securely.
While ZFS was ideal for data integrity, I also needed my parents to use the PC with Windows seamlessly for their daily tasks. To achieve this, I upgraded the PC with more RAM (yes, RAM is always the answer!) to ensure smooth operation of both the Windows environment and the virtual machine running ZFS.
To make things manageable remotely, I integrated PiKVM for remote management. This allowed me to monitor and control the PC’s power state from anywhere, ensuring it’s only powered on when needed for backups.
To streamline the backup process, I developed a Python script. This script uses PiKVM to power on the PC, checks if the ZFS virtual machine is running on Hyper-V, and initiates automated backups using Restic. Restic handles the backup of critical data to the ZFS storage, ensuring everything is securely backed up without manual intervention.
While the setup works well, I’m open to suggestions on improving efficiency or implementing additional features. If you have any advice or similar experiences to share, I’d love to hear from you!
Feel free to check out the GitHub repository where I’ve shared the automation script here.
Cheers,
Capruro