Octoprint slowing down internet connection


#1

What is the problem?
I’m running Octoprint on a Raspberry Pi3b. The problem I’m running into is when Octoprint is running, the internet connection for the rest of the house gets very slow.
What did you already try to solve it?
I’ve tried formatting the microSD card and putting a new image on it. But I still have the same problem.

Additional information about your setup (OctoPrint version, OctoPi version, printer, firmware, octoprint.log, serial.log or output on terminal tab, ...)

Raspberry Pi3b, latest release of Octoprint. The Printer is a Maker Select v2.1.

If I power down Octoprint, the network speed comes back to normal.

It seems to have started in the last couple of months, with no changes made, except updates of Octoprint.

I’m looking to see where I should look to find a solution other than not turning on Octoprint.


#2

If you have a session open on a computer that is showing the web cam then you're using up the bandwidth not so much slowing down the net. A webcam can pump a lot of picture data.
Does the slowdown occur when there is no webcam in operation?


#3

It just has to be running with nobody accessing Octoprint through a web browser. It’s bad enough, that I cannot access my garage door openers through the app if I’m connected to the house network. Just trying to browse websites is also painfully slow. My connection speed at home is 160Mbps. Once I shutdown Octoprint, everything comes back to normal and fast access again.

I wasn’t sure if there was something that was updated causing the problem or not. I will attempt to format the microSD card again and put a fresh image on it to see if it’s still a problem.


#4

Wow. Something sounds amiss. Do you have any plug-ins installed?
What is the speed of your local net? Hub speed?


#5

I do have plugins and one could be a problem. That’s why I will start fresh again and see what happens, then install one plugin at a time. As for speed, I think the slowest wireless point is 450Mpbs. I may run an Ethernet cable direct to it, now that I have a hub close by.

Since I only noticed this in the last couple of months, I’m thinking a plug-in update, or octoprint update.


#6

You can startup OctoPrint in a "safe" mode.
You can also disable plug-ins. Doing that in a binary search mode might track down the culprit.


#7

When you startup in “safe mode”, what does and does not function? Just want to see which way I will attack this


#8

It disables all plug-ins not bundled with OctoPrint. Basically an easy way to turn off all non standard plug-ins.
Here's the docs on Safe Mode.


#9

Perfect. Looks like a good place to start.


#10

So I had a chance to try safe mode and it didn’t really do anything. I ran multiple speed tests and the results went from 160Mbps down to 0. I also made some change in the router and same results.
I had someone come over and request something printed so I let it run and our internet was slow. I shut down the system this morning and it picked up almost right away.

This truly is odd. I’m planing on buying 2 more RPi for the other 2 printers I have and can maybe try one of those to see what happens.

BUT I’m thinking of trying the RPi3b+ instead of the regular 3b I have. So I may have to wait a bit for a stable release of Octoprint compatible with the 3b+ to come out.


#11

I have 2 Rpi´s running most the time and absolutely NO influence on my Internet connection .. As well as on my home network, where we even have 2 TV´s connected to IPTV , still i get all remaining bandwidth all time when running the Octoprint´s .. both current release, one with a cameara on 15fps also running at least 2 streams all time


#12

I have a RPi3 running inside a mirror I made that has a 32” tv inside. It’s called “magic mirror”, it didn’t bother my internet either. It’s displaying a calendar, weather that’s updated a few times an hour and other things.

For months, my RPi3 running Octoprint never interfered with the internet connection either. I’ll eventually figure it out.


#13

Just to chime in with some general info here... OctoPrint doesn't hold a constant connection to the internet or something like this. What it does is fetch the blacklist on server start once (if enabled), and if you actually utilize the web interface also fetch the plugin repository info and look for updates once per day, fetch the announcements every 8h or so. That's it. All of that is prolly less than 100kb all in all.

What it also does is offer network discovery and depending on other devices on your net, that might actually cause issues if they are misbehaving. I've never seen it happen, but just to rule this out, try disabling the Discovery Plugin.

Next step would be to install something like ntop to see if that help narrow things down.


#14

Thank you. I will have a look at your suggestions.


#15

OK, so I disabled the Discovery plugin and rebooted the system. So far it seems that the speed has picked back up. I will leave it running overnight and see how it is in the morning, unless I see a drastic reduction in speed again.


#16

If it really turns out to be the Discovery Plugin I'd love to get my hands on an octoprint.log from you. Maybe there's a way to harden it against misbehaving devices on the network spamming discovery requests (which is what I'm currently guessing might be what happened here).


#17

Turning it off seems to have helped with the speed, BUT when requesting a webpage it takes a long time still.

I ended up turning off the system last night and it all went back to normal.

I do have 2 RPi 3b+ on their way, but I won’t be able to use my normal image in it. I could always take a 3b I have elsewhere and put the micro SD in it to see if it’s octoprint or possibly the Pi itself causing the problem.

One other test I want to do before switching out the Pi, is to run it from Ethernet and turn off wifi to see if that somehow makes a difference.


#18

I turned off Wifi and connected through ethernet. I still have Discovery pluggin turned off. I'm running a print currently, and the internet speed is where it should be, like Octoprint isn't even running.


#19

Just to be specific: Are you using a stock RPI distro with octoprint installed onto it or are you using a preassembled image?

Are you sure, it is a mess with octoprint software? could you disable the service/shut down only the octoprint server without shutting down the rest of the RPI? Maybe there is another software making problems....

Can you maybe debug the problem further? Is the problem with local latency of packets (ping a local and a remote (e.g. 8.8.8.8) IP), DNS resolution or something else? Maybe you can narrow the problem further to find a solution.


#20

I’m using the Octipi image. Since connecting direct to Ethernet and removing access to wifi through the network txt file, I haven’t had anymore problem. I ran a few prints, long ones, and I had no speed issues with my internet at all.