Need your advice on a budget NAS build

I did not quite understand this part . Can you explain in detail ? WOL is for a PC which has booted up and is sleeping right ?

You can power on your system using WOL, provided that your system supports it.

You have to adjust a few options in the BIOS and in the OS (at-least in the case of Windows)

Sharing a reference document for MSI motherboards

https://www.msi.com/support/technical_details/MB_Wake_On_LAN

1 Like

A lot of linux experience and very less on ZFS. Though ZFS is not so hard to understand if given some time. I had an old HDD failing while testing ZFS and I spent a lot of time understanding recovery and stuff with zdb etc. Immediately started to like it for the features it offers. But still not using it for the boot drive, only for storage HDD.

For the administrative stuff, managing ZFS, I didn’t need to do anything yet. I mean what’s there to manage? I have set auto snapshots with retention policy, incremental backups again with retention policy. Once set, I don’t need to make any changes. A simple log entry that everthing went well and once a month check if backup looks good.

For SMB permissions it was a pain initially but again, once set now no need to check anything. I just follow logs for all the containers/VM’s whenever I get time. I run a loki unified logging system so all logs are visible in a simple grafana dashboard.

Each dataset has their own permissions respective to the containers using them.

I’m running a P330 with i5-8600 and dual 3.5” 4TB HDD’s.

Imagine a PC which is in a shutdown state but still powered. If there’s IPMI functionality, the lan port always has power and if it connected to network it’ll be at like 10 MBps link speed with an IP address. You can use this always on lan port to power up your computer by sending it a magic WOL packet to it’s IP address. You can also access other stuff via IPMI.

That is a neat setup!
I have the same UPS, planning to use my router + rpi + p330 on it. Which reminds me - where did you get the replacement battery from?

I see… I would like to be more comfortable with ZFS management using the Proxmox/CLI/Cockpit, maybe it’s something I can tinker around with using a spare drive or something. Anyway this calls for some testing once I build it, would be interesting to see the difference between the approaches we discussed.

Nice, is your P330 the tower version? Asking since you mentioned dual 3.5” HDDs..

No it’s tiny. I have done some mods to it. Here:

and here:

1 Like

Love what you’ve done with it! I remember seeing something similar on reddit and wondering “dang that takes some dedication.” Great job with yours.
I really wanted to go smaller on the setup but the larger space offered by a tower seemed more logical to me at this point. I’m starting out with 2 drives, but would like to add more in the future - would prefer not having to change the setup again.

However I do want to build an opnsense router using one of these. Or maybe a steam console. Fingers crossed :crossed_fingers:

1 Like

I have mqtt+nodered automations for safe shutdown and safe startup.

I monitor the battery voltage of the inverter with a ESP8266 module and when the voltage gets low, it sends out a mqtt message to start the automated shutdown of everything connected to it. NodeRED sends shutdown signals to my proxmox nodes through simple api http web requests.

After power returns, and the battery is sufficiently charged to survive a second power outage, another mqtt message is sent out that toggles the smart plugs, triggering a “power on after power failure” start up.

I also have it set that it waits 15 mins to make sure power is stable before initiating the start up.

I’m running about 1kW of vm hosts so you might not need such an elaborate setup.

I’ve posted about this extensively here if you’re curious about how this looks, even the the IoT lead acid battery project haha.

2 Likes

I have TrueNAS as a VM on Proxmox. Storage drives are passed through from Proxmox to TrueNAS and this allows me to backup the TrueNAS installation as a whole through Proxmox Backup Server (theoretically).

You still need some sort of cloud backup, especially for immich and so on.

Thank you for the interesting and elaborate writeup. My planned setup is far simpler, hoping to use a smartplug between the wall socket and the UPS.

Shutdown logic: When the smartplug turns off, the rpi could see this and trigger a safe shutdown on the P330, leaving just the router and the pi itself powered by the UPS until the mains is back on, or the UPS runs out. Think I need to keep the pi up and running so it can see when this smartplug is back online.

Power-on logic: When the mains power is back, the UPS passes through to all devices connected to it, and I believe the P330 has a bios setting to power on when the PSU receives power. If the UPS hasn’t died by then, the pi would be running - if the mains power returns, the smartplug would receive power and the pi could tell when it is back online - and wake the P330 up using WOL.

I think I can get both scenarios to work using Homeassistant and some clever scripting?

It certainly isn’t as robust as your setup, but I think it will work just fine. Do you recommend any resources for further reading?

So you’ve passed-through the disks and not the SATA controller itself? Apart from TrueNAS missing out on SMART data, have you experienced any hiccups?

1 Like

Assuming you mean this as a general recommendation, and not because of any issues you’ve faced with Immich?

I’d like to backup snapshots to a cheap cloud storage box, but honestly I don’t see the need for it with the cold drive approach. So if the cold drive provides disaster backup and a mirrored vdev (in the home server) provides redundancy, I think that should work for me. Are you currently using a cloud backup for your data?

I always wondered about the use case of a separate UPS. I have an sinewave invertor which runs in UPS mode so do I need to invest in another UPS? The invertor has 2 150AH battery so it provides long backup, the longest power cut we had was for 12 hrs and it was able to provide backup full time. I am very new to home server hobby. I use a old 13 6th gen system with one 4tb HDD and a 128gb SSD to run the OS and for caching to host audio book shelf and calibre on it and I plan to expand it to make it a full blown NAS with other services like immich and jellyfin on it.

Ah, I forgot to mention, I’m only passing nvme and external drives, so it’s pretty straight forward. I haven’t really used internal sata drives in a nas since about 2010 — no real reason other than external drives were a safer purchase (the last time I bought an internal spinning drive online was in 2002 and back then the original packaging of an internal drive was the size of a shoebox).

Yes, I that sounds perfectly doable. I don’t have much experience with home assistant, Node-RED by itself does whatever I need it to do since nothing (home automation related) is critical.

Do look into trying out Node-RED inside home assistant, I haven’t found a single tutorial that can replace experimenting first hand, it’s very capable.

1 Like

A UPS is really best suited for power conditioning. Fluctuations, high voltage, low voltage, power surges. Inverters in UPS mode usually just means it’ll switch to battery over smaller changes in voltage instead of the normal range. The actual switching speed remains the same (slow). Over-sized desktop power supplies can often mask/buffer the slow switching time of a home inverter.

Take a look at page 7 here, to see what even different types of UPS are able to handle: https://www.eaton.com/content/dam/eaton/products/backup-power-ups-surge-it-power-distribution/au-products/Power%20Quality%20Product%20Catalogue.pdf

We have a central surge protector and voltage stabilizer built-in the panel box of our house. The switching time of my invertor is <10ms. So do I still need UPS?

Interesting.. would love to know more if this is a NAS or NAS-like setup. So you use external, 2.5” drives for actively used, live backups? Or like just for archival purposes?

Definitely. I’ve always wanted to try nodeRED, how would you say it is in terms of cpu/mem usage? I really like the drag-n-drop approach of the UI, but wondering if I should run this when I just have to set it once and forget about it.

Just remembered: I’ve seen folks mention this doesn’t always work. I know it is possible to use the pi’s GPIO pins to “press” the P330’s power button - but is it possible in NodeRED?

Edit: This is possible using the pigpiod daemon with the node-red-node-pi-gpiod service when running as a container, instead of the node-red-node-pi-gpio service commonly used when nodeRED is installed directly on the OS.

If you’ve never needed one then it’s likely you don’t need one now. It sounds like you’ve got a newer construction with higher safety standards. My parent’s house is older than me, built in the late 70s — I downgraded from a 3.2GB hard disk to a 2.1GB, just so I could get a UPS and an ergonomic keyboard in my budget for my first (new) desktop in the late 90s. Before that, I had a 386 that my uncle gave me and it would electrocute me whenever I turned it on, ha.

They’re actually 3.5" desktop drives from my chia plotting days (lockdown), they’re connected to a few 7-port tp-link hubs.

I have it as a docker container inside a debian vm under proxmox on a thin client, it works very well. One of my flows: Proxmox Thread - Home Lab / Virtualization - #213 by rsaeon

1 Like

If the Invertor is able to switch on and keep the PC alive then not needed . .

2 Likes

Gotcha, thanks for clarifying.

Thanks for this! You have a lot of posts that make for some nice reading. Will do this as I go along :slight_smile:

1 Like

Quick update: Visited Bharati Systems today and checked out the P330. Configured it with an i3-9100, 32 gigs of memory with the original 80 plus platinum PSU. They were kind enough to throw in ECC ram at no extra charge - they are 2133mhz sticks but I don’t think I’ll notice a difference for a NAS.

They’re delivering it tomorrow, fingers crossed! Can’t wait.