Replies: 2 comments 11 replies
-
Well the first thing you can do to see if the startup hook is running is get into unifios shell and look at the status of the udm-boot.service. If that is running it should be fine. Does this file end .sh? It should otherwise it will get filtered |
Beta Was this translation helpful? Give feedback.
-
Troubleshooting udm-boot.service in systemd@nickmac88, I know this is a bit late, but I came upon your post while troubleshooting this same issue on my UDM-Pro. @VeniceNerd was on the right track, troubleshooting the systemd unit file. While both of you have probably already resolved the issue, I wanted to post in case it helps others and to offer an answer, closing this thread (hopefully). Without going on too much about systemd, I'd like to highlight a few commands that would've helped ya'll zero in on the culprit. In this specific scenario, after @boostchicken pointed to the "udm-boot.service" unit file, my troubleshooting process proceeded as follows:
Here we start to understand how the service functions, within the UniFi-OS container. @VeniceNerd , to answer your last question, "loaded, active, exited" is the appropriate status. The type "oneshot" indicates that the service will run once and exit. Digital Ocean has a pretty good systemd overview with practical explanations.
@nickmac88, your issue seems be an invalid directory structure. The udm-boot.service will only traverse the target directory to a depth of 1, as observed in the "ExecStart=" directive of the unit file. If you ran the setup script within the UniFi-OS container, the appropriate directory structure would be missing. The persistence of /mnt/data/ is only achieved on the linux host, not inside of any of the application containers, thus the udm-boot.service pulls the startup scripts from the linux host and into the UniFi-OS application container. @nickmac88 , your installation command indicates you ran the setup from within the UniFi-OS application container.
@nickmac88 , pay close attention to the terminal prompt you're working in.
|
Beta Was this translation helpful? Give feedback.
-
I consider myself a pretty smart guy and i have been researching this for some time with no success so hoping someone will be bale to point me in the right direction. First, I'm starting to get a little frustrated with all of the things this "PRO" router does not come with OOTB but that aside, i am bought in at this point.
I followed all of the directions for the setup of this Boot Utilities, but no matter what i do my script does not start on boot. I am able to start my script manually and it works just fine, i have the correct #!/bin/sh , I have the file in the correct directory, i have made my script executable. My script is similar to the following. My ultimate goal is to auto connect one of my VLANs to a VPN. Any help would be fantastic.
I don't think my issue is with the script below, i was able to follow the install instructions for the boot service fairly easily. Honestly no idea where i need to look to find the issue.
#!/bin/sh
cd /mnt/data/split-vpn/openvpn/pia
source ./vpn.conf
/mnt/data/split-vpn/vpn/updown.sh ${DEV} pre-up &> pre-up.log
nohup openvpn --config filename.ovpn
--route-noexec
--up /mnt/data/split-vpn/vpn/updown.sh
--down /mnt/data/split-vpn/vpn/updown.sh
--auth-user-pass username_password.txt
--dev-type tun --dev ${DEV}
--script-security 2
--ping-restart 15
--mute-replay-warnings &> openvpn.log &
Beta Was this translation helpful? Give feedback.
All reactions