I’ve got a couple of services that rely on a network connection starting with systemd. I’ve had them starting correctly on other servers by using After=network.target. I’ve also tried After=network-online.target but neither are working on here. I have a feeling both are firing before a network connection has started. Thus things are starting, not able to lock onto their port and are dying on boot. Any thoughts?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Try adding them in the very bottom of /etc/rc.local* so they’re the last thing that is started which would mean they’re started after networking is. <br> <br>*systemd ignores /etc/rc.local - please see http://superuser.com/questions/278396/systemd-does-not-run-etc-rc-local
Hm. It’s a solution but I’d much rather do it right. I’m more worried about the underlying problem of such an important part of systemd not doing what it should and the effects that might be having elsewhere.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.