Bug 1431368
Summary: | noip client fails unless (re)started manually | ||||||
---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Mark Knoop <mark> | ||||
Component: | noip | Assignee: | Sergio Basto <sergio> | ||||
Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
Severity: | unspecified | Docs Contact: | |||||
Priority: | unspecified | ||||||
Version: | 25 | CC: | davidafrick, lfelia, sergio | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | noip-2.1.9-22.fc26 noip-2.1.9-22.fc25 noip-2.1.9-22.fc24 noip-2.1.9-22.el7 | Doc Type: | If docs needed, set a value | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2017-05-02 15:56:33 UTC | Type: | Bug | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
Mark Knoop
2017-03-11 16:46:23 UTC
See here for the same symptoms: https://archlinuxarm.org/forum/viewtopic.php?f=31&t=8951 Hi, It works for me. I think after NetworkManager start in boot, you still not have network therefore you may try edit connections of NetworkManager and check "all users may connect to this network" in general tab, specially if you connect via wifi with password. Also we can add in /etc/NetworkManager/dispatcher.d one networkmanager dispatcher after network up it will call the script to restart noip cat 40-noip #!/bin/sh case "$2" in up|down|vpn-up|vpn-down) /bin/systemctl --no-block try-restart noip.service || : ;; esac copied from 10-sendmail Hi, thanks. It's a wired ethernet connection, "Make available to other users" is already checked. I'll try this dispatcher.d script and report back. Although I can understand that the network might be not fully up for the first try, I don't understand why the noip client still can't connect 30 minutes later unless restarted. Yes, the dispatcher script works, I removed the "down" cases though. cat 40-noip #!/bin/sh case "$2" in up|vpn-up) /bin/systemctl --no-block try-restart noip.service || : ;; esac But this does seem quite "wasteful": noip is now started and stopped 4 times in the boot process. Is there no way in all of systemd's features to wait for available hostname resolution? It works for me without dispatcher, can you post "cat boot.log | grep ... [1] ? See mine, noip just start after "Network Name Resolution", so at time of starting no-ip , we should already have network. [1] cat /var/log/boot.log | grep -iP "no-ip|net" [ OK ] Reached target Network (Pre). Starting Network Manager... [ OK ] Started Network Manager. [ OK ] Reached target Network. Starting Network Name Resolution... Starting Network Manager Script Dispatcher Service... [ OK ] Started Network Name Resolution. Starting No-IP Dynamic DNS Update Client... [ OK ] Started Network Manager Script Dispatcher Service. [ OK ] Started No-IP Dynamic DNS Update Client. No info in my boot.log, but this excerpt from the journal shows that it is starting after "Network Name Resolution", but is still unable to gethostbyname. Mar 12 15:00:33 localhost systemd[1]: Started Network Name Resolution. Mar 12 15:00:33 localhost systemd[1]: Starting No-IP Dynamic DNS Update Client... Mar 12 15:00:33 localhost noip2[793]: v2.1.9 daemon started with NAT enabled Mar 12 15:00:33 localhost noip2[793]: Can't gethostbyname for dynupdate.no-ip.com Mar 12 15:00:33 localhost systemd[1]: Started No-IP Dynamic DNS Update Client. Mar 12 15:00:33 localhost noip2[793]: Can't get our visible IP address from ip1.dynupdate.no-ip.com (In reply to Mark Knoop from comment #6) > No info in my boot.log could you send all boot.log instead , very weird , but doesn't seems to me a noip problem . Have you selinux enabled , if yes disable and try again , send me boot.log with or without grep , please . Selinux in permissive mode makes no difference. boot.log is empty - is it not deprecated in favour of journalctl now? I do not have rsyslog installed. > boot.log is empty - is it not deprecated in favour of journalctl now?
no , you should have /var/log/boot.log ... I have and the computers that I had check have . I use:
syslog-ng-3.6.2-5.fc24.x86_64
syslog-ng-geoip-3.6.2-5.fc24.x86_64
syslog-ng-json-3.6.2-5.fc24.x86_64
syslog-ng-libdbi-3.6.2-5.fc24.x86_64
syslog-ng-redis-3.6.2-5.fc24.x86_64
syslog-ng-smtp-3.6.2-5.fc24.x86_64
I have also had the same problem, exact same indications. Someone on Archlinux list thought it was maybe a firewall rule so I tried his solution and added an outgoing direct rule: # firewall-cmd --direct --get-all-rules ipv4 filter OUTPUT 0 -o enp2s8 -p tcp --dport 8245 -j ACCEPT but that has not made a difference. I also tried a 5 second sleep in the startup but that also makes no difference. may you attach the /var/log/boot.log ? Created attachment 1269027 [details]
/var/log/boot.log
Added /var/log/boot.log (md5: a046fd4852ede1693c50f55cf842feb7) per Sergio Monteiro Basto's request. I have removed the ANSI codes.
(In reply to Sergio Monteiro Basto from comment #11) > may you attach the /var/log/boot.log ? Done, Sergio I added the following to the [UNIT} section and now it works at boot: [UNIT] ...<stuff> BindsTo=NetworkManager.service After=NetworkManager.service Here is a diff
$ diff /usr/lib/systemd/system/noip.service noip.service.orig
4,5c4
< BindsTo=NetworkManager.service
< After=network.target systemd-resolved.service NetworkManager.service
---
> After=network.target systemd-resolved.service
(In reply to Veteran from comment #15) > Here is a diff > $ diff /usr/lib/systemd/system/noip.service noip.service.orig > 4,5c4 > < BindsTo=NetworkManager.service > < After=network.target systemd-resolved.service NetworkManager.service > --- > > After=network.target systemd-resolved.service Hello , to show this correctly is: diff noip.service.orig /usr/lib/systemd/system/noip.service -up (first .orig file and with -up switches ) I thinking systemd-resolved.service may confuse this service because you don't haveit enabled and if you try just with After=network.target ? - After=network.target systemd-resolved.service + After=network.target $ diff noip.service.orig /usr/lib/systemd/system/noip.service -up --- noip.service.orig 2017-04-05 12:43:59.016024216 -0400 +++ /usr/lib/systemd/system/noip.service 2017-04-05 12:44:19.913146203 -0400 @@ -1,7 +1,8 @@ [Unit] Description=No-IP Dynamic DNS Update Client Requires=systemd-resolved.service -After=network.target systemd-resolved.service +BindsTo=NetworkManager.service +After=network.target systemd-resolved.service NetworkManager.service [Service] Type=forking Sergio, I don't understand your comment. What don't I have enabled? $ systemctl status noip ● noip.service - No-IP Dynamic DNS Update Client Loaded: loaded (/usr/lib/systemd/system/noip.service; enabled; vendor preset: disabled) Active: active (running) since Wed 2017-04-05 12:47:59 EDT; 1 day 3h ago Main PID: 1191 (noip2) CGroup: /system.slice/noip.service └─1191 /usr/sbin/noip2 -c /etc/no-ip2.conf Apr 05 12:47:59 backrow systemd[1]: Starting No-IP Dynamic DNS Update Client... Apr 05 12:47:59 backrow systemd[1]: Started No-IP Dynamic DNS Update Client. Apr 05 12:47:59 backrow noip2[1191]: v2.1.9 daemon started with NAT enabled Apr 05 12:48:00 backrow noip2[1191]: xxxxxxx.ddns.net was already set to 68.228.xxx.xx. # systemctl status systemd-resolved.service ● systemd-resolved.service - Network Name Resolution Loaded: loaded (/usr/lib/systemd/system/systemd-resolved.service; disabled; vendor preset: disabled) Active: active (running) since Wed 2017-04-05 12:47:59 EDT; 1 day 3h ago Docs: man:systemd-resolved.service(8) http://www.freedesktop.org/wiki/Software/systemd/resolved http://www.freedesktop.org/wiki/Software/systemd/writing-network-configuration-managers http://www.freedesktop.org/wiki/Software/systemd/writing-resolver-clients Main PID: 1174 (systemd-resolve) Status: "Processing requests..." Tasks: 1 (limit: 4915) CGroup: /system.slice/systemd-resolved.service └─1174 /usr/lib/systemd/systemd-resolved Apr 05 12:47:59 backrow systemd[1]: Starting Network Name Resolution... Apr 05 12:47:59 backrow systemd-resolved[1174]: Positive Trust Anchors: Apr 05 12:47:59 backrow systemd-resolved[1174]: . IN DS 19036 8 2 49aac11d7b6f6446702e54a1607371607a1a41855200fd2ce1cdde32f24e8fb5 Apr 05 12:47:59 backrow systemd-resolved[1174]: Negative trust anchors: [...stuff...] Apr 05 12:47:59 backrow systemd-resolved[1174]: Switching to system DNS server 8.8.8.8. Apr 05 12:47:59 backrow systemd[1]: Started Network Name Resolution. Veteran, I meant the attach file /var/log/boot.log don't have reference to "Starting Network Name Resolution" [1] like I see in my /var/log/boot.log [1] cat /var/log/boot.log | grep -iP "no-ip|net|Reso" but systemd-resolved.service is not enabled at startup (vendor preset: disabled) but somehow now it started in yours computer I guess. In my case, the same, not marked as enabled but appears in boot log ... Anyway could be enough start noip after Reached target Network. I don't want add more rules to noip.service, from man systemd.unit, BindsTo= doesn't seems a good option. Thanks for yours reports, ah and thanks for explicitly give the feed back that you haven't understand what I wrote, let me know if happens again. Best regards I have the same issue and found this report while searching for solutions. I tried modifying /usr/lib/systemd/system/noip.service as mentioned by Veteran and still have same result. Adding /etc/NetworkManager/dispatcher.d does work. Thanks Sergio for that suggestion. could you edit /usr/lib/systemd/system/noip.service and set after with just : After=network.target run systemctl daemon-reload and reboot Thanks for quick reply. I tried editing /usr/lib/systemd/system/noip.service as suggested. I actually tried that first. I did not do the "systemctl daemon-reload" after I made the change, so I removed the "40-noip" file from /etc/NetworkManager/dispatcher.d and tried that and rebooted. Still same result. ● noip.service - No-IP Dynamic DNS Update Client Loaded: loaded (/usr/lib/systemd/system/noip.service; enabled; vendor preset: disabled) Active: active (running) since Sun 2017-04-09 17:32:58 CDT; 3min 20s ago Process: 812 ExecStart=/usr/sbin/noip2 -c /etc/no-ip2.conf (code=exited, status=0/SUCCESS) Main PID: 821 (noip2) Tasks: 1 (limit: 4915) CGroup: /system.slice/noip.service └─821 /usr/sbin/noip2 -c /etc/no-ip2.conf Apr 09 17:32:57 server4.localdomain noip2[821]: v2.1.9 daemon started with NAT enabled Apr 09 17:32:57 server4.localdomain systemd[1]: Starting No-IP Dynamic DNS Update Client... Apr 09 17:32:57 server4.localdomain noip2[821]: Can't gethostbyname for dynupdate.no-ip.com Apr 09 17:32:57 server4.localdomain noip2[821]: Can't get our visible IP address from ip1.dynupdate.no-ip.com Apr 09 17:32:58 server4.localdomain systemd[1]: Started No-IP Dynamic DNS Update Client. I do have another question. Even though it appears to fail when the service starts, how can you tell that subsequent attempts are failing? Whenever the status is returned using systemctl, the timestamp still shows the first failed attempt. David, many thanks for your test , unfortunately this service was forced to changed to systemd which doesn't work correctly ! David and replace /usr/lib/systemd/system/noip.service unit section with : [Unit] Description=No-IP Dynamic DNS Update Client PartOf=NetworkManager.service After=network.target the requires=systemd-resolved.service could be the problem ... Thanks Sergio. I removed the "requires=systemd-resolved.service" from /usr/lib/systemd/system/noip.service. $ cat /usr/lib/systemd/system/noip.service [Unit] Description=No-IP Dynamic DNS Update Client After=network.target [Service] Type=forking TimeoutStartSec=30 ExecStart=/usr/sbin/noip2 -c /etc/no-ip2.conf Restart=on-failure RestartSec=30 [Install] WantedBy=multi-user.target Still getting same result. ● noip.service - No-IP Dynamic DNS Update Client Loaded: loaded (/usr/lib/systemd/system/noip.service; enabled; vendor preset: disabled) Active: active (running) since Tue 2017-04-11 21:30:06 CDT; 11min ago Process: 808 ExecStart=/usr/sbin/noip2 -c /etc/no-ip2.conf (code=exited, status=0/SUCCESS) Main PID: 812 (noip2) Tasks: 1 (limit: 4915) CGroup: /system.slice/noip.service └─812 /usr/sbin/noip2 -c /etc/no-ip2.conf Apr 11 21:30:05 server4.localdomain systemd[1]: Starting No-IP Dynamic DNS Update Client... Apr 11 21:30:06 server4.localdomain noip2[812]: v2.1.9 daemon started with NAT enabled Apr 11 21:30:06 server4.localdomain noip2[812]: Can't gethostbyname for dynupdate.no-ip.com Apr 11 21:30:06 server4.localdomain noip2[812]: Can't get our visible IP address from ip1.dynupdate.no-ip.com Apr 11 21:30:06 server4.localdomain systemd[1]: Started No-IP Dynamic DNS Update Client. David and others could you test if /usr/lib/systemd/system/noip.service with [1] , works for you ? probably I'm fix the package with it but if you caould test it before will be nice ? to test : edit /usr/lib/systemd/system/noip.service systemctl daemon-reload reboot Thanks, [1] [Unit] Description=No-IP Dynamic DNS Update Client Wants=network-online.target After=network-online.target Thanks much Sergio, I added the [1] at the very beginning and that seemed to resolve the issue. Just to be clear, I did not make any other changes so mine does not match the sample you sent exactly. [1] [Unit] Description=No-IP Dynamic DNS Update Client After=network.target In any case, this seemed to resolve the issue, for me at least. Thanks again. Dave Thanks Sergio, Yes, this works now, without the NetworkManager dispatcher script. network-online is clearly the appropriate target. Although https://www.freedesktop.org/wiki/Software/systemd/NetworkTarget/ (last section) suggests that the client should really be able to handle this better. My complete unit file for clarity: # cat /usr/lib/systemd/system/noip.service [Unit] Description=No-IP Dynamic DNS Update Client Wants=network-online.target After=network-online.target [Service] Type=forking TimeoutStartSec=30 ExecStart=/usr/sbin/noip2 -c /etc/no-ip2.conf Restart=on-failure RestartSec=30 [Install] WantedBy=multi-user.target noip-2.1.9-22.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-edfadd40b4 noip-2.1.9-22.fc25 has been submitted as an update to Fedora 25. https://bodhi.fedoraproject.org/updates/FEDORA-2017-8442b739dd noip-2.1.9-22.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2017-f2ffbabc49 noip-2.1.9-22.el7 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-947d317c65 noip-2.1.9-22.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-8442b739dd noip-2.1.9-22.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-f2ffbabc49 noip-2.1.9-22.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-edfadd40b4 noip-2.1.9-22.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-947d317c65 noip-2.1.9-22.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report. noip-2.1.9-22.fc25 has been pushed to the Fedora 25 stable repository. If problems still persist, please make note of it in this bug report. noip-2.1.9-22.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report. noip-2.1.9-22.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report. |