After some time playing with DietPi, trying different software and trying to find the best way to work, I think I know how I want to set up my HomeLab and the use I want to give it.
However, I’m not sure if my approach is correct or not.
I’m going to try to explain it and see if any of the wise people around here can tell me if I’m doing it right or if I’m doing something wrong.
First, let me clarify what I want to use my HomeLab for. I want to get the following:
AdGuardHome for ad blocking and privacy.
TailScale for VPN and remote connection.
Immich for photo/video backups from family smartphones.
SAMBA shared folder for files in the cloud.
Jellyfin for media player.
Arr suite for… well you know for what
Home Assistant for home automation.
CUPS for remote printing (any software for remote scanning?)
Stirling PDF for online document management.
Calibre Web for online eBook management.
To get this I have available various hardware: Raspberry Pi 3B+, Raspberry Pi 4B, Fujitsu Futro S920 and Dell Optiplex 3020 SFF.
My intention is to put all this software on 3 devices:
Raspberry Pi 4B:
Tailscale (secondary, redundancy)
AdGuardHome (secondary, redundancy)
Home Assistant
CUPS + Scanner (USB conection to the printer/scanner)
Fujitsu Futro S920:
Tailscale (primary)
AdGuardHome (primary)
SAMBA Server
Arr suite
Stirling PDF
Calibre web
Dell Optiplex 3020 SFF:
SAMBA server
Immich server
Jellyfin server
My question is:
Am I making it too complicated with 3 machines?
Would it be better to put everything on one machine to simplify it?
Do you think I’ve left out any important or useful software?
Seems fine, so RPi 4 for Home Assistant, Fujitsu Futro S920 for downloads and documents, Dell Optiplex 3020 SFF as media server. I exclude VPN, AdGuard Home and CUPS, as their resource usage should not be relevant. Whether it is needed to split it like that depends on the usage and concurrent usage of those services you expect, and the hardware capability of the two boxes I do not know.
The RPi has limited USB/storage through, so running downloads while streaming videos will surely not work well with higher resolution or without strict download limits. Whether one or two additional boxes are needed depends on their capabilities, and GPU acceleration support for decoding/encoding videos, to stream/transcode with Jellyfin. Based on the used downloader backend, it should be also possible to limit/prioritise downloads, so that seamless streaming is possible while downloads are running, just slowing them down. But I have no particular software and settings key in mind to achieve that, for network bandwidth as well as in case for disk I/O and CPU processing. Would need to have a loot at the particular downloaders. Another approach for such is using e.g. dietpi-services to reduce/set nice and I/O and CPU levels/schedulers for the downloader on systemd level for the related control group. Should work universally, but I never really tested it for this particular case.
I had thought of splitting it like this for several reasons.
The RPi4 has to be connected to the printer via USB, so I need it to be physically in the office. And since CUPS (I believe) doesn’t consume many resources, I use that same machine to have a backup system for the VPN and AdGuard. Also, since the RPi4 has Bluetooth and WiFi, I think it’s a good hub for Home Assistant.
Currently, I have this same software and Immich installed on the Fujitsu. The problem is that when uploading several files, Immich starts working and takes up 100% of the CPU for a while, so the VPN connection is slow and even Home Assistant hangs.
That’s why I had thought of installing Immich on a separate machine with a better processor, more RAM and a dedicated GPU.
I hope that this way I don’t have any system crashes.
is this really necessary? Because for DNS server, as soon as you specify both on your DHCP server, both will be used by clients. At least that’s my experience.
I’ve read on the internet that people recommend doing this so that if due to maintenance or a failure, the first DNS server is offline, the secondary one would still work.
This way, members of house wouldn’t be without internet access until I fix it.
A few days ago, I had to restart the server due to an update. And while that restart was taking place, my wife complained that the Netflix stream had been cut off…
I think, having two DNS servers would avoid that kind of failure, since if the main one wasn’t there, the secondary one would work normally and the stream wouldn’t be cut off.
Isn’t it?
If this happens when I’m at home, it’s not a problem, I can fix it in a few minutes. But if this happens when I’m away from home, it could leave my home without internet for hours.
And for the sake of my relationship…I don’t want that to happen.
I’ve started with the preparation of this whole system and I’ve started with what I think is the easiest, the RPi4B.
Thanks to DietPi I already have Home Assistant, Tailscale and AdGuard installed. Easy and simple. Thank you very much!
But on the other hand, the most important use is online printing and scanning; and although I see that from the software store I can easily install CUPS, I don’t see any for the scanner.
Can anyone recommend me some software for this purpose?
I have the Brother DCP-197C printer.
On the internet I have seen some software:
SANE (Scanner Access Now Easy), but my printer is not supported.
Simple Scann, but it depends on SANE, so I’m the same.
If Immich processing has no high priority, i.e. does not matter much whether it finishes quickly or slowly (?), you could try to reduce its nice level and I/O priority, or assign some idle scheduler, so that it does not disturb interactive UIs/consoles. If it was Immich only, an additional machine for something which happens only once in a while and does not necessarily need to finish quickly, seems overkill. But Jellyfin is there as well, is usually CPU and I/O intense as well (or there is great GPU acceleration), so would need to be tested whether Jellyfin + VPN + low priority Immich. Runs well on the Futro S920. And then there are the downloads as well, which of course could be set to low resource priorities as well.
And true, for DNS there is usually no real “fallback” implemented, but clients just send queries to all DNS servers and take the first response or so. But I mean that way, the redundancy works as well: if one DNS does no answer, there is a second instance which does. But both instances will be used concurrently, and both need to be maintained, query logs and such are split across both instances etc. You could also just try it with a single instance at first, see how reliably it works, and if really for whatever reason, your family/office complains about DNS outage due to whatever happened, or because you are doing system upgrades or stuff, then you can still think about redundancy. DNS/AdGuard Home are very low on resource usage, and even e.g. the heavy load of a Home Assistant upgrade/reinstall and stuff should not significantly disturb it on an RPi 4. I just made sure: neither AdGuard Home nor Tailscale are stopped by DietPi scripts during any maintenance tasks.
I’m going to run the Immich and Jellyfin services on the Dell Optiplex PC, for sure. I bought this machine second hand for that purpose.
Better processor, more RAM and dedicated graphics card; I hope that won’t cause any performance issues.
And for all the AdGuardHome issues, I’m going to take your advice and for the moment I’m going to leave one service running; if I see that it gives me problems, I’ll put another one to work.