need to reboot router under linux when back from other connection, for browsing
Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
need to reboot router under linux when back from other connection, for browsing
Dear all,
I have a router at home, D-link DSL-2640B, that works fine with my linux laptop. Nevertheless, whenever I take my laptop to use other internet connection (eg, at my work, in this case with a proxy server) and then come back, after relaying my ip through dhcp, any trial to browse straight ahead is exteremely slow (in any browser; OK, I have a number of tabs open but my connection is not slow at all). This comes back to normality when I reboot the router, accessing it through 192.168.1.1. However, I do not observe this phenomenon when I use a windows laptop; so I guess this problem might be related to linux and how it deals with the connection (?) (in all instances I use cabled connection). Though I had some search in the web, I could not figure out what any configuration might account for this behavior. Of course, I would prefer to connect here and there, and have good internet straight on.
Would you have any point for me to look at?
Thanks,
The cable is OK yet I can reboot the modem and so things go fine afterward.
A new router might be the way to go, but I thought that if it is just a matter of configuration, it will be cheaper to fix than buying a new router, :-).
Since it does work correctly at all I see no great reason so far to replace it.(just yet)
Why it would fix it on reboot of router is part of the clue.
I get the feeling that this proxy issue and the tabs open and maybe how you are setting the proxy may be part of the issue. You didn't say it but you may also have some standby/hibernate issue.
I set my proxy manually (I use foxyproxy for automation on this). But, unfortunately, I have already observed this behavior also when I connect without a proxy, eg., when I use the laptop with other SSID that do not require it.
But, in fact, every time I go with my laptop there and there, I use to sleep it (as configured for closing the lid; formerly I used to hibernate and the same happened). Hum, might it be related to sleeping and hibernating configuration? I should say that email downloading (normally) and ping works fine; the matter seems to be only for browsing.
Thanks.
I could not get a hint with top or "system monitor".
I cannot say about slowness concerning ftp, though.
The problem is fixed when I get into (through my browser) the router and reboot it. So, every time I come back to home I have to spend two minutes with this...
Tomorrow I might try something like network restart thorough command line; the browsers I use are firefox, chrome and konqueror, all seem to present the same problem.
Thanks.
OK, two tests.
Last night, after back home, I simply restarted network and everything was fine. This is a progress yet it is much faster than rebooting the router.
Today, I did not close the laptop lid at coming home, and so internet browsing was straight forward as I plugged in the cable at home.
Therefore, my issue might be about sleep/hibernate configuration, as that was previously suspected. I should search the internet now. Anyway, any hints on this?
Wonder if simply arp cache is doing this? It shouldn't.
The normal fail on standby is that it doesn't come back at all is what I hear mostly. Your test of not closing lid seems to prove that it could be part of the issue.
Wonder if you could double check nic speeds. Wonder if it is somehow being caught in 10mbs?
Sorry I don't know the full problem right off. Most times this sort of problem goes away on next version of distro and you get to work on new problems.
Arp is how computers translate MAC addresses to IP addresses. On clean boot arp and many other static and dynamic data bases get basically set to zero. Things like dns, wins, netbios and dhcp all are set to zero. When you change proxy is should try to re-initialize this. When you restart networking it is like a cold boot too. The restart networking seemed to fix it so we may need to try to figure out which of the tcp/ip parts are failing. Arp should be a very short lived thing. I say stuff sometimes more to get ideas out.
Thanks jefro and jnihil for comments. Sorry I cannot answer more promptly. In fact I can make one test a day (transition work/home). Today I checked the speed
Speed: 100Mb/s
Duplex: Full
Yes, it seems to be pretty fine. No errors detected, neither.
A workaround I will test soon is to put a script at /etc/pm/sleep.d that restarts the network at resuming.
But one curious thing is that the other way round does not present any problem, that is, when I sleep my computer at home and get network at my work, browsing at high speed is available without any different procedure.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.