CentOS slow when network is enabled, otherwise fast
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
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.
CentOS slow when network is enabled, otherwise fast
Hi
I've installed centOS and it is slow when the network is activated, terminal takes like 10-15 seconds to start, and other stuff like screen saver also takes long to open. But when I deactivate the network in centOS everything is fast, what could be the problem?
Check out what are the network related services which are active and trying to connect to a server/client. Also check the host system can communicate with the virtualbox client
I'm using a static ip, and the host can ping the vm, everything works, samba shares, internet etc. I have a router, it's just slow for some reason. I've read somewhere else that it could be the DNS that's taking too long, but my etc/hosts seems right, so I don't know...
In case you are using dynamic dns, that might be a problem. This has nothing to do with /etc/resolv.conf. Try removing nsupdate in case you using dynamic dns.
Do you mean like dyndns.com ?My router has that feature which I have configured and forwarding port 80 to centos, I have not configured centos to use dyndns, if that was what you meant.
I'm using a static ip, and the host can ping the vm, everything works, samba shares, internet etc. I have a router, it's just slow for some reason. I've read somewhere else that it could be the DNS that's taking too long, but my etc/hosts seems right, so I don't know...
But slow DNS resolution or slow DHCP would not slow down your entire system. The cause must lie elsewhere. Try looking at the system message log:
# tail -f /var/log/messages
Now try activating the network. See what is going on.
Another trick, when a system slows down, is this:
$ top
"top" shows where the machine is spending its time, with the biggest time user at the top of the list. This should tell you why the system is slowing down.
And activating the network gives the following output:
Sep 19 19:23:12 CentOS kernel: eth0: link up, 100Mbps, full-duplex
Sep 19 19:23:14 CentOS avahi-daemon[2062]: New relevant interface eth0.IPv6 for mDNS.
Sep 19 19:23:14 CentOS avahi-daemon[2062]: Joining mDNS multicast group on interface eth0.IPv6 with address fe80::a00:27ff:fe66:ef4b.
Sep 19 19:23:14 CentOS avahi-daemon[2062]: Registering new address record for fe80::a00:27ff:fe66:ef4b on eth0.
Sep 19 19:23:16 CentOS avahi-daemon[2062]: New relevant interface eth0.IPv4 for mDNS.
Sep 19 19:23:16 CentOS avahi-daemon[2062]: Joining mDNS multicast group on interface eth0.IPv4 with address 10.0.0.101.
Sep 19 19:23:16 CentOS avahi-daemon[2062]: Registering new address record for 10.0.0.101 on eth0.
I've also looked at # top and Xorg is using the most cpu %, but it peaks at 3%, so can't be that.
Network does not seem be the issue. Disable network during boot up and later on give a static IP and then check the performance. Is some sort of NFS, NIS running ?
Nobody seems to be using IPV6 yet, and IPV6 lookups (for essential things like localhost) need to time-out before IPV4 is tried. This wastes a lot of time, even if you are not using networking:
RedHat 5 & Centos 5
Edit /etc/sysconfig/network and set "NETWORKING_IPV6" to "no"
Add/Edit the following to /etc/modprobe.conf :
alias ipv6 off
alias net-pf-10 off
Edit: You'll need to restart networking, or reboot for the changes to take effect.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.