Recently we had a storm here, the electricity was gone for a few days and I had a lot of time to think about things. Naturally I thought about this website and how important it must be to you. This website has to become more reliable, that much is clear.
The storm was so wild that a tree came down on top of my cars bonnet.
Anyway, you clicked on this for the backup story so here it is.
If you can recall from this older post, this website is being served from this raspberry pi. A little problem with the default storage on the pi is that it's microSD storage, a flash memory with about 100,000 writes per location before it dies. This just won't do. Your ability to read this website means everything to me. I have to make sure there are backups written to the much more reliable mSATA drive in the picture.
So I got to work making a simple backup script that would use rsync to copy the files to a new location. The reason I used rsync was so I could more easily change it to store this backup somewhere on the network (as if changing one line wasn't easy enough already). Usually I would just make a cronjob to run this script but today I was in the mood to learn something new, something controversial...
![]() | ![]() |
I decided to try making a systemd service and timer to run that service every week. This was relatively simple, not as simple as making a cronjob but still pretty simple. The picture on the left is the service, and on the right is the timer to run that service.
Of course I had spelled Calendar incorrectly and that was holding the whole thing up. For that I am sorry, it won't happen again.
I had done it, the timer was working perfectly. I don't expect a thanks or a medal. your eyes on this website are all I need.
Just as proof to you, and to myself that this would work, the script was run off schedule one time and one time only. It worked
It was nice to finally try making a systemd service and I think I will do it this way from now on unless a better way happens to cross my path. Backing up is important and is a simple thing to do, something that shouldn't be forgotten. If only I had backed up my car a little bit. It still runs by the way, it just needs a new headlight and some dents need to be ironed out but it could have been a lot worse. Thanks for reading and I hope you have a great day.
You can check out a list of all the blog posts by clicking here
You can get back to the homepage by clicking here