hdactrl constantly reopens itself causing extensive memory usage.
Operation system: Ubuntu 12.04 x64
Steps to reproduce:
1) modify the /etc/networking/interfaces
2) write lock the same file with chattr +i
3) wait a few hours
Wanted to disable DNS server on amahi, but proves very difficult to do, so instead changed my dns to point to my actual dns server. After about 6 hours or so it revers changes. So I decided to write lock the interfaces file. But once I did that my system started crashing processes due to out of memory errors (I have swap turned off). After looking into it I discovered that hdactrl respawns itself if it comes into an error, as many times as it can until you run out of ram. Killing all the processes immediately released over 3GBs of ram.
It appears that when hdactrl encounters a lock protected file it kills the old thread and spawns a new thread, only it isn't killing the old thread.
How I fixed it:
I know this isn't a proper fix, but I just modified hdactrl under the print_debian_network function to say dns-nameservers IPAddress. Sadly I don't remember the original settings, and stupidly I didn't back it up.
#1 Updated by bigfoot65 over 8 years ago
Caution, disabling the DNS server may cause Amahi to break. If you follow the same guidance for disabling DHCP, it should stop it permanently.
It should not hurt to leave DNS running for the HDA to use. You can redirect your clients to the same DNS you use for your router. You can also set the HDA DNS to anything you want as well.
Also available in: Atom