This repo hosts all of the things I need to make my raspberry pi into a file backup server. This documents describes the general outline of how I will store my data locally and remotely as well as how I will synchronize between the two.
There are FIVE drives that will be important here:
- home = [Laptop] my laptops native storage in my home folder
- sda1 = [Laptop] the 90 GB flash drive partition attached to my laptop
- sda2 = [Laptop] the 30 GB encrypted partitoin on flash drive attached to laptop
- rpi1 = [Server] the 250 GB SSD attached to my raspberry pi
- rpi2 = [Server] the 2 TB hard drive attached to my raspberry pi
I basically have three types of data.
- SNS Small non-sensitive data - this includes program code, scripts, writing exericises, music, class work, etc.
- LNS Large non-sensitive data - this includes photos, TV shows, movies, music, Textbooks
- SEN Sensitive data - includes tax information and anything else secretive
Going forward I will make the following assumptions:
- LNS and SNS data should not be easily accessible by others, but someone with the know-how can see it if they really wanted. Basically, I don't want my peers to stumble across this. This means we need basic protection against NON-malicious actors.
- SEN data should not be accessible to anyone but me. Even an expert should not be able to obtain this data. i.e. encryption.
- SNS data will change often. Not only will files come and go, but files will also change a lot.
- LNS data will often be written once and never modified. This is true for Textbooks, Movies, Photos, Music. This means that flash drive storage is accetable here.
- SEN data is completely unpredictable. Since SEN is a catch-all that doesn't distinguish between kinds of data, we can't make any assumptions here. Also it is unclear what factor encryption has on volativity.
- SNS data should total under 30 GB. Ideally under 15 GB.
- LNS data may be large. For now, we assume under 80 GB, but that might have to change.
- SEN data is somewhere in the middle. Assume it totals under 30 GB.
(this assumption may only be temporary.)
- SNS, LNS, and SEN are all changed LOCALLY and backups are kept on the SERVER. The opposite flow never happens.
Client-Server full file redundancy with secondary backups. I'll explain what this means:
- SNS, LNS, and SEN all live somewhere locally.
- SNS, LNS, and SEN also have an identical backup on the server.
- LNS has one or more additional backups on server taken periodically.
- SNS has one or more additional backups on the server taken periodically.
On the local side:
- SNS lives on
home
- LNS lives on
sda1
- SEN lives on
sda2
On the server side:
- a nightly (?) backup of SNS exists on
rpi1
. Backup is completed viarsync
run usingcron
- a nightly (?) backup of LNS exists on
rpi1
. Backup is completed viarsync
run usingcron
- manual backups of SEN exist on
rpi1
. Backup method is TBD - There is an additional cron job that runs on the server that copies the entire backup to
rpi2