What's new

[Solved] Avahi-daemon causing AC-1900P to become virtually unresponsive, consuming ~50% CPU

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

nateracecar5

New Around Here
I know this question has been asked before, but the responses didn't help. Basically this is our problem

After our router has been on for around about 5 minutes, the avahi-daemon starts freaking out and starts taking up immense amounts of CPU. This goes on for hours before calming down, before starting up again. This is causing both our 2.4 GHz networks and 5GHz networks to be virtually unusable. At the same time, wired connections aren't affected. I've SSH'd into the network, and used top to view the CPU usage, and at the same time monitored the CPU meters on the configuration home page (See screenshots). Both of the meters are showing CPU spikes ranging from 15% to 50%, though I've seen it go up to 60%. It's so frustrating that we paid $200+ for this router, and yet we can't even use the dang thing.

Doing some reading, the avahi-daemon is for Apple products (Particularly for Bonjour), if I'm correct. We have two MacBooks, two iPhones, two iPads, an Apple TV, and an iMac on our network. One of those MacBooks is not usually on, but the Apple TV is connected via Ethernet. Now I want to refrain from disabling this. We have the option of installing DD-WRT if needed, and we're already running asuswrt-merlin because we thought flashing that would fix this exact problem (News flash: It didn't). This is becoming a huge problem for us. I, personally, am an online college student, so not having internet 9 times out of 10 is hurting my studies.

I don't understand why this usually dormant service would be continually using 50% of our CPU. None of us can use Wi-Fi anymore, and it's a pain to get into the router configuration panel because of the high CPU usage.

Also, we have changed a couple of things in our router to try and fix this problem, including changing our DNS server to 8.8.8.8. I don't know if this matters, but if you need the status of a current setting, please ask and I'll get it to you. Any help would be appreciated, so I'd be more than happy to help you back. We've tried quite literally everything at this point short of replacing it with our old router, and so we're trying to not end up wasting $200. Also, it's out of warranty. In the terminal screenshot, usernames have been redacted.

EDIT: This problem has been resolved. Please see my comment below for solution.
 

Attachments

  • Screen Shot 2017-09-20 at 3.43.06 PM.png
    Screen Shot 2017-09-20 at 3.43.06 PM.png
    49.3 KB · Views: 693
  • Screen Shot 2017-09-20 at 3.41.00 PM.png
    Screen Shot 2017-09-20 at 3.41.00 PM.png
    181.3 KB · Views: 561
Last edited:
Make sure you don't use the .local extension as your LAN's local domain, as it would conflict with it. I recommend using .lan instead (i.e. myhome.lan).

If Avahi goes into a loop, it means there's either a config conflict somewhere, or a specific device is causing it to crash. You might want to try troubleshooting by only turning a few clients on at a time until you spot a problematic client.

You can check your System Log too for any hint as to what might be happening.
 
Make sure you don't use the .local extension as your LAN's local domain, as it would conflict with it. I recommend using .lan instead (i.e. myhome.lan).

If Avahi goes into a loop, it means there's either a config conflict somewhere, or a specific device is causing it to crash. You might want to try troubleshooting by only turning a few clients on at a time until you spot a problematic client.

You can check your System Log too for any hint as to what might be happening.

What do you mean by changing my extension? In the router, the extension line for DHCP is blank. Is that what I need to change? Also, the system log isn't saying anything weird, however a lot of our devices are making multiple DHCP requests within minutes. We have a Vizio smart TV, and it made at least 20 DHCP requests within an hour one night.
 
What do you mean by changing my extension? In the router, the extension line for DHCP is blank. Is that what I need to change?
He's referring to the DHCP setting of "Domain Name". If it's blank then that's fine, leave it. Just so long as it's not ".local" because that's what avahi uses.
Also, the system log isn't saying anything weird, however a lot of our devices are making multiple DHCP requests within minutes. We have a Vizio smart TV, and it made at least 20 DHCP requests within an hour one night.
That's quite common and can be ignored.

You said you didn't want to disable avahi, why not if it's causing you problems? Your devices will probably work the same without it.

Do you have a USB drive attached to the router? Are you using the router as a media server or time machine backup?
 
Last edited:
avahi is usually good to keep around - if one has an Apple TV on the WLAN/LAN, it's a suitable host, and one can disable Avahi on the router itself if needed.

The comment about .local - absolutely true, don't name your inhouse domain as .local, as this will conflict - .home or .lan is a much better approach.

.local is bonjour/avahi related, and unfortunately, some versions of Windows server's AD will set .local if the domain is not specified (microsoft's goof)
 
avahi is usually good to keep around - if one has an Apple TV on the WLAN/LAN, it's a suitable host, and one can disable Avahi on the router itself if needed.

The comment about .local - absolutely true, don't name your inhouse domain as .local, as this will conflict - .home or .lan is a much better approach.

.local is bonjour/avahi related, and unfortunately, some versions of Windows server's AD will set .local if the domain is not specified (microsoft's goof)

We don’t have any windows servers on the network. Now is it possible that the Apple TV is conflicting with Avahi on the router? We took our time machine backup off the router because we thought that was causing the problem, but that never fixed it. Should I try resetting the router since I never did after removing the backup?
 
We don’t have any windows servers on the network. Now is it possible that the Apple TV is conflicting with Avahi on the router? We took our time machine backup off the router because we thought that was causing the problem, but that never fixed it. Should I try resetting the router since I never did after removing the backup?

Just turn off Avahi on the router - that's the server side, the client still runs - the Apple TV can take over responsibility for group membership.

Just make sure that the local domain is not using .local as a TLD, that's for DNS, and see @RMerlin comment above.
 
Just turn off Avahi on the router - that's the server side, the client still runs - the Apple TV can take over responsibility for group membership.

Just make sure that the local domain is not using .local as a TLD, that's for DNS, and see @RMerlin comment above.

I hate to keep updating this thread, but I’ve tried disabling Avahi, but I can’t find anything on the internet on how to. Can you provide a link? Even a lmgtfy link would be suitable!
 
I hate to keep updating this thread, but I’ve tried disabling Avahi, but I can’t find anything on the internet on how to. Can you provide a link? Even a lmgtfy link would be suitable!
I don't think it's possible to disable it through the webUI.

If you have enabled Telnet or SSH access to the router you can log onto it an issue the following command to stop it:
Code:
service stop_mdns

But when you restart the router it will start again. To automatically disable it you can create a user script called /jffs/scripts/services-start as follows:
Code:
#!/bin/sh
logger "Stopping Avahi"
/sbin/service stop_mdns
 
Avahi cannot be disabled.

Make sure you did completely disable Time Machine on the router, just in case.
 
So tonight we decided to trash the Asus router (It had problems other than wifi) and get a new Linksys WRT32X. My college work is all online, so Wi-Fi is crucial here. We get it all setup, everything is working fine. All of a sudden, the EXACT same problem occurs on a brand new 1 hour old router. I was beyond upset. I download the logs from that router and open them. I see a bunch of Deauth logs already, so I decide I'll do some sleuthing. On a hunch I open wireshark and start sniffing everything on the network, and I mean everything. Although, that wasn't really easy considering that wireshark was full of nothing but MDNS packets from my Nexus Player.

Apparently Nexus Players running Android Oreo (Which mine is) are causing a flood of MDNS packets on the network, essentially crashing the entire thing. There have been multiple posts about this already on various different sites, but those are the first two I found. I have yet to reset it, however since I use my Xbox now for all my streaming, there's really no point in me having that thing. I'll reset it and see if I can find another use for it. Until then, it's staying unplugged so it can't do anymore damage to my network.
 
It's not the first time I see a rogue device cause a problem with Avahi, that's why I suggested trying to try isolate a potentially troublesome client device by turning them off.
 
I've seen weird stuff out of Android devices with mDNS - mostly bugs, when they work, they work, but like mentioned...
 
Similar threads

Similar threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!

Staff online

Top