Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DietPi-Config | No-IP: Doubled process appears #3205

Closed
johnnyt83 opened this issue Oct 25, 2019 · 3 comments
Closed

DietPi-Config | No-IP: Doubled process appears #3205

johnnyt83 opened this issue Oct 25, 2019 · 3 comments
Labels

Comments

@johnnyt83
Copy link

Hi Micha,

I just installed No-IP on a new pi zero with DietPi (6.26.3) and noticed it did not go "online" after successfully entering login credentials. I gave "5" as the new refresh interval and noticed this:

https://abload.de/img/thumbnail_img_2019102lpkk9.jpg

https://abload.de/img/thumbnail_img_2019102dwkqz.jpg

CPU usage did not even drop after 10 minutes.
Is the plugin buggy?
BTW: does the plugin prevent me from having to login into the webUI every 30 days to make my domain not expire?
best wishes.

@MichaIng
Copy link
Owner

MichaIng commented Oct 26, 2019

@johnnyt83
Many thanks for your report. Strange is that there is already an instance of noip2 running (with close to 0% usage) while the second one then has high usage. Should be only one instance.

I just checked the code:

Did it probably fail to stop the service? However this should produce an error prompt then. But to check:

systemctl status noip2

Found the reason for the wrong online state: 9b70bd5
However this does not explain the doubled binary call yet. Finally systemctl stop noip2 must success to kill/stop all of them via killall -w noip2.

Fix for wrong online state is there, but investigation of doubled process still required.

MichaIng added a commit that referenced this issue Oct 26, 2019
+ DietPi-Config | Fix No-IP online state estimation: pgrep checks for binary file without path, otherwise requires "-f" option. But since as well a manually started binary would work, outside of our systemd unit, and the systemd unit on the other hand kills every instance on stop, regardless of file path, we can and should check for the naked binary: #3205
@MichaIng MichaIng added Bug 🐞 Solution available 🥂 Definite solution has been done labels Oct 26, 2019
@MichaIng MichaIng added this to the v6.27 milestone Oct 26, 2019
@MichaIng MichaIng changed the title NO-IP buggy? DietPi-Config | No-IP: Wrong online state estimation and doubled process Oct 26, 2019
@MichaIng MichaIng modified the milestones: v6.27, v6.28 Nov 13, 2019
@MichaIng MichaIng changed the title DietPi-Config | No-IP: Wrong online state estimation and doubled process DietPi-Config | No-IP: Doubled process appears Nov 13, 2019
@MichaIng MichaIng removed the Solution available 🥂 Definite solution has been done label Nov 13, 2019
@MichaIng MichaIng modified the milestones: v6.28, v6.29 Jan 3, 2020
@MichaIng
Copy link
Owner

MichaIng commented Mar 18, 2020

@johnnyt83
I have no No-IP account, hence cannot test 100%, but noip2 -C which causes the 100% CPU usage is the config creation, hence the interactive call where you enter your mail and password. After you did so, does it hang or does Press any key to continue... appear which lets dietpi-config menu reappear?

Once idea I have is that noip2 -C, if credentials are correct, as well goes into background to run as regular daemon. If we then start the service, there would be two instances, probably causing the issue. A reboot should solve it. If this is really true, we need to manually kill the spawned noip2 process before starting the service, or add ExecStartPre=/usr/bin/killall -w noip2 to the service so that is always kills all probably running processes before starting itself. However I doubt that actually, since the noip2 -C process in your case is still running as root while it spawns the actual daemon executed with user nobody.

@MichaIng MichaIng modified the milestones: v6.29, v6.30 Mar 29, 2020
@MichaIng MichaIng modified the milestones: v6.30, v6.31 May 10, 2020
@MichaIng
Copy link
Owner

MichaIng commented Jun 1, 2020

Marking as closed due to missing reply. Feel free to reopen if the issue is still present.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants