Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
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.
I am using a server connected to several clients with scientific linux 6 .
I am using the server ( a PC which uses Ethernet cable to connect ) .
I have a problem with internet connection.
It connects for few minutes then disconnects for few minutes then re-connects for fem minutes ( 2-3 ) minutes then disconnects again for few minutes
And so on , connect and disconnect , connect and disconnect.
The connection time is no longer than 2 to 3 minutes so I am unable to do any installs I need or do anything on the internet .
I tried to open :
System >> preferences >> network connections
eth0 edit and change the value of MTU
It was automatic at first and now I am trying to give it values .
I didn't feel this made any change till now .
Can Somebody help ?
How Can I stop the internet from disconnecting very continously ?
Thanks
It connects for few minutes then disconnects for few minutes then re-connects for fem minutes ( 2-3 ) minutes then disconnects again for few minutes
And so on , connect and disconnect , connect and disconnect.
The connection time is no longer than 2 to 3 minutes so I am unable to do any installs I need or do anything on the internet .
Do you see the physical interface status drop when this happen? Or just LAN connectivity dropping?
Code:
ip link
I would suggest observing network-related messages from /var/log/messages. That might help capture what is occurring when the interface goes down.
Code:
tail -f /var/log/messages
You could also test the connected NIC with 'ethtool -t <eth-interface>' eg
1492 or 1500 seem to be the common defaults but there is never an explanation of what they could / should be but perhaps the help desk of the ISP provider should be known FIRST admitting that you have a certain connection
Do you see the physical interface status drop when this happen? Or just LAN connectivity dropping?
Code:
ip link
I would suggest observing network-related messages from /var/log/messages. That might help capture what is occurring when the interface goes down.
Code:
tail -f /var/log/messages
You could also test the connected NIC with 'ethtool -t <eth-interface>' eg
Code:
ethtool -t eth0
Code:
#ip link
gives :
1: lo: <LOOPBACK, UP, LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eth0: <BROADCAST, MULTICAST, UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP ql en 1000
link/ether 74:d4:35:11:13:90 brd ff:ff:ff:ff:ff:ff
Code:
#tail -f /var/log/messages
gives no output , and waits waits waits until I press (ctrl+c)
going to the directory : /var/log
I found a file names ( messages ) with and arrow on the north east of it
trying to open it i got the following :
Couldn't display "/var/log/messages".
There is no application installed for character device files.
Do you want to search for application to open the file ( yes/No)
Pressing Yes gives some applications need to be installed but of course installation fails due to network failure problem .
Then I got a message : Failed to find software
No new applications can be found to handle this type of file
BTW, /var/log/messages is a text file, so any editor should be able to view it. (It's more likely that you just don't have a file association for it currently.)
gives a huge output which exceeds the limit that can be posted here .
here are the first few lines :
class=dir
type=1400 audit(1435990681.885:4365): avc: denied { search } for pid=9230 comm="trivial-rewrite" name="yp" dev=dm-0 ino=3016424 scontext=system_u:system_rostfix_master_t:s0 tcontext=system_ubject_r:var_yp_t:s0 tclass=dir
type=1400 audit(1435990682.016:4366): avc: denied { search } for pid=9236 comm="bounce" name="yp" dev=dm-0 ino=3016424 scontext=system_u:system_rostfix_bounce_t:s0 tcontext=system_ubject_r:var_yp_t:s0 tclass=dir
type=1400 audit(1435990682.122:4367): avc: denied { search } for pid=9238 comm="bounce" name="yp" dev=dm-0 ino=3016424 scontext=system_u:system_rostfix_bounce_t:s0 tcontext=system_ubject_r:var_yp_t:s0 tclass=dir
Is this what you are looking for ?
can that help ?
BTW, /var/log/messages is a text file, so any editor should be able to view it. (It's more likely that you just don't have a file association for it currently.)
it really looks like a text file but with an arrow over it .
I don't know what the arrow means .
Shall I create a new one ?
What shall It contain for the internet to connect continuously ?
thanks
Can you figure out where the problem is ? or how can we solve it ?
Thanks
No, so far there is not enough information to solve your problem. When you did 'ip link' and ip route' was your connection working at this time? The output confirms that eth0 is up and configured with an IP address. To be explicit, I did say run those commands when you think the connection is down.
As for /var/log/messages, I'm not sure why it is not present. Maybe syslog is not running? Are you the administrator? Remember I'm not in front of your computer, so difficult to diagnose via a forum.
Anyway,here's some documentation for your distro. There's a search engine built-in so you can look up '/var/log/messages', 'sys' log etc http://linux.web.cern.ch/linux/scientific6/
No, so far there is not enough information to solve your problem. When you did 'ip link' and ip route' was your connection working at this time? The output confirms that eth0 is up and configured with an IP address. To be explicit, I did say run those commands when you think the connection is down.
As for /var/log/messages, I'm not sure why it is not present. Maybe syslog is not running? Are you the administrator? Remember I'm not in front of your computer, so difficult to diagnose via a forum.
Anyway,here's some documentation for your distro. There's a search engine built-in so you can look up '/var/log/messages', 'sys' log etc http://linux.web.cern.ch/linux/scientific6/
well this is what i tried :
Code:
#ping yahoo.com
and got :
ping : unknown host yahoo.com
so I think the connection is know down
I also opened the browser and tried to open any websites but it fails .
so , No internet connection
I then tried iplink and iproute and got the above mentioned outputs !
I don't know what that means /
the connection is up but a problem prevents the computer from connecting ?
Now we're getting somewhere - it's been like herding cats so far! Your link is up, IP address and gateway routing appears to be valid, but you're not able to ping a host by name which indicates that DNS is not configured/working. You can probably ping by IP address ok. For example, the following probably works
Code:
ping 98.138.253.109
Check /etc/resolv.conf for valid nameserver with
Code:
grep -i nameserver /etc/resolv.conf
If nothing is returned, that is the problem. If you're using DHCP, this would normally be added automatically. Sometimes it's the router that acts as an intermediate DNS server, sometimes it's your ISP's domain name server.
Anyway, if it's missing, you could add a public nameserver manually with something like
Now we're getting somewhere - it's been like herding cats so far! Your link is up, IP address and gateway routing appears to be valid, but you're not able to ping a host by name which indicates that DNS is not configured/working. You can probably ping by IP address ok. For example, the following probably works
Code:
ping 98.138.253.109
Check /etc/resolv.conf for valid nameserver with
Code:
grep -i nameserver /etc/resolv.conf
If nothing is returned, that is the problem. If you're using DHCP, this would normally be added automatically. Sometimes it's the router that acts as an intermediate DNS server, sometimes it's your ISP's domain name server.
Anyway, if it's missing, you could add a public nameserver manually with something like
Code:
echo "nameserver 8.8.8.8" >> /etc/resolv.conf
Then you should be able to browse again.
Code:
ping 157.55.152.112
gives :
PING 157.55.152.112 ( 157.55.152.112) 56(84) bytes of data
destination Net Unreachable ( ping to hotmail )
Code:
grep -i hotmail /etc/resolv.conf
nothing is returned .
in /etc/sysconfig/network-scripts/ifcfg-eth0
The BOOTPROTO = none ( not dhcp )
Code:
echo "yahoo 8.8.8.8" >> /etc/resolv.conf
returns nothing
then i tried
Code:
#ping yahoo.com
again gives
ping unknown host .
Opening google chrome and trying to open any website also fails !
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.