Wake-On-Lan RSync between two OpenMediaVault Servers

  • Hi,

    A little background. I live pretty much on top of a mountain. There is no internet service here (can't wait for StarLink). I use my phone as a hot spot but the speeds are about the same as dial-up (if that on some days). So my option of backing up all my files to the cloud is a pipe dream. My solution that I turned to is OpenMediaVault. I have an OpenMediaVault server in my house with an 8Tb drive attached to it. In the shed cellar I have another OpenMediaVault server on Raspberry Pi 4 with 2Gb of memory with another 8Tb drive attached. I have it in the shed (God forbid) in case of a forest fire. The shed server is using a 25 watt solar panel and battery as there is no power in the shed.


    I have a RSync job setup on my home OpenMediaVault server to run at 2am to back up all files to the shed server.


    Instead of having the shed server on all day long (especially in winter with little sun hours) I thought Wake-On-Lan would be my solution. I'm new to Wake-On-Lan and have read many articles about it in the past two days. It sounds great for what I'm looking to do.


    On the shed server I enabled Wake-On-Lan in the network portion of OpenMediaServer. I use OpenWRT and created a static IP for both OpenMediaServers and updated the network settings on both servers with the static IP's.


    My question:

    I read the man pages on RSync and don't see an option to be able to send Wake-On-Lan command when starting the RSync job; including an option to run a script that perform the Wake-On-Lan.


    Again, I'm new to this. Can anyone provide me with some advice or point me in the right direction on how I can send the Wake-On-Command packets when starting the RSync job at 2am to the shed server?


    Thank you in advance for your time on helping me.


    David

    🏔Salida CO UTC-6 (Mountain, outdoor, and animal lover)

    Python developer, web developer (php, MySQL, WordPress), pilot, and teacher 👨‍🏫.

    Amateur Extra, amateur radio (ham radio) - K0BCJ

    * Please excuse any spelling or grammar mistakes I was born with severe dyslexia.

    • Offizieller Beitrag

    AFAIK the RPi does not support WOL.


    Otherwise you could just start a script on the home server that wakes up the RPI, waits some time to boot it up and start the rsync job.

    If you put a real time clock to the RPi you might be able to start up the RPi at a specific time using the rtcwake command.

  • Ahhh, I didn't realize Rasp dosn't have Wake-On-Lan functionality. Great idea. I'll just stop at ACE Hardware and get a hardware timer.

    Thanks for taking the time to help with my question.

    🏔Salida CO UTC-6 (Mountain, outdoor, and animal lover)

    Python developer, web developer (php, MySQL, WordPress), pilot, and teacher 👨‍🏫.

    Amateur Extra, amateur radio (ham radio) - K0BCJ

    * Please excuse any spelling or grammar mistakes I was born with severe dyslexia.

  • WastlJ

    Hat das Label gelöst hinzugefügt.
    • Offizieller Beitrag

    Another option could be to gracefully shut down the RPi with a scheduled job and restart it with a switchable power socket (time switch).

    What an ingenious idea.

    System Backup Typo alert: Under the Linux section the command should be sudo umount /dev/sda1 NOT sudo unmount /dev/sda1

    Backup Data Disk to Backup Disk on Same Machine: In a Scheduled Job:rsync -av --delete /srv/dev-disk-by-uuid-f8814ed9-9a5c-4e1c-8830-426968c20ea3/ /srv/dev-disk-by-uuid-e67439d5-00a3-4942-bd5f-b84ab86aa850/ Don't forget trailing slashes, and BE CAREFUL. (HT: Getting Started with OMV5)

    Equipment - Thinkserver TS140, NanoPi M4 (v.1), Odroid XU4 (Using DietPi): PiHole

  • Thank you! :) I'll post some pictures as soon as I have it finished. Just waiting for the weather proof container from Amazon to arrive next Tuesday. I added a BME280 sensor to the Rasp Pi to monitor temperature and humidity inside the box. Plus, even when StarLink comes online I'll still be saving about 40.00 a month in cloud storage. And, again when StarLink comes online I can just add NextCloud through Docker if I need access for my files when away from home.

    🏔Salida CO UTC-6 (Mountain, outdoor, and animal lover)

    Python developer, web developer (php, MySQL, WordPress), pilot, and teacher 👨‍🏫.

    Amateur Extra, amateur radio (ham radio) - K0BCJ

    * Please excuse any spelling or grammar mistakes I was born with severe dyslexia.

  • I've done this several ways... both ways short 2 pins on the controller that are connected to the pins on the mobo's PWR pins.


    esp8266, rpi Zero or ATTiny+nRF24.


    Technically, I haven't done what you need to do with the ATTiny+RF24, but knowing that you need good range plus low power because of solar, I have to mention them. I'm using ATTiny+RF24 for lavalier mic's with a certain driver as it's kind of the only DiY realtime audio streaming solution non-techie people like me can achieve (I'll link it below). But while setting that up, I discovered a whole range of power saving options for the RF24 that are useful. In fact, I found a video opposite of the ones I used just for you :-). It's pretty amazing how low the current can go, ultimately you want power down mode.


    Reducing the Power Consumption of the nRF24L01 Transceiver


    Pair that with an ATTiny, and you should be well within the camp of solar friendly. You might be able to use MISO and MSIO directly from the RF24, but I don't know that for sure and I'm surely not the person to make that definitive statement (but it's worth looking into :-).


    And for any of you looking for a cheap way in to real time audio streaming where the latency DOESN'T SUCK...


    https://github.com/nRF24/RF24Audio


    Forgot, the esp8266 *might* also be an option, but the sleep mode (which will save power) can be buggy or flat out broken. If you have enough power for the esp8266, you might want to just skip it and get a esp32. I'm currently working with the 32's and the power consumption seems identical to what the 8266 used to give me for my use cases, even with the extra core.

  • Oh, that’s awesome. I just ordered 2 set transceiver kit with the NRF24L01. And it has SMA antennas which is awesome for my project. That way I can use a SMA cable and place the antenna outside of the enclosure giving me better range. Thanks for the info!!!

    🏔Salida CO UTC-6 (Mountain, outdoor, and animal lover)

    Python developer, web developer (php, MySQL, WordPress), pilot, and teacher 👨‍🏫.

    Amateur Extra, amateur radio (ham radio) - K0BCJ

    * Please excuse any spelling or grammar mistakes I was born with severe dyslexia.

  • wildernessfamily Did you ever use the NRF24L01 for this application? I'm using an attiny45 with a 433mhz receiver but the receiver always pulls a constant ~3ma even though the tiny in power down is pulling just .5 micro. With a 1/4 antenna the range isn't great either, maybe 15 meters (reliably). So, I was wondering if you used the NRF in power down or standby-1 and what the range & response times were. The only nice thing about the 433 and the attiny is that I really don't need any other components (for my usage at least), but that 3ma is a killer. Anyways, I only need to receive.


    I ordered some more off of Ali so I'll find out in a few weeks, but I'm just fishing for good news when using these things at farther non-power hungry modes, as I've only used them in microphones were there just a few meters away and at full tilt.

  • This didn't work out for me, but if you have a garden or something similar and you're running a small solar panel...


    http://www.gammon.com.au/forum/?id=12821


    A neat feature in that link is that he's using a large capacitor as a UPS. Anyways, this satisfies the topic of solar+low power NAS control, at least in perspective of through-hole components (I think, depends on how long the communication with this particular device needs to last).

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!