[SOLVED] Cannot access shared internet connection

Issues related to configuring your network
Post Reply
asimo
Posts: 4
Joined: 2011/09/16 14:59:35

[SOLVED] Cannot access shared internet connection

Post by asimo » 2011/09/16 15:05:20

Hi all,

I recently upgraded from Centos4 to centoc6, and i'm having trouble with accessing internet, which is provided by an xp machine that shares its connection; i't been working like a charm with centos 4, but now i cant access the internet;

in ifcfg-eth0 I added the xp machine's IP as gateway, don't know what to do else, I didn't remember doing anything more on centos4

Thanks

kmuzheri
Posts: 15
Joined: 2011/08/29 10:52:14

Re: Cannot access shared internet connection

Post by kmuzheri » 2011/09/20 12:30:20

What is the Windows XP machine using to share the internet. Is it using SQUID?
Anyway, on CentOS 6, I observed it doesnt enable the NIC by default. If using the GUI, I would go on the network icon, left click it then click on SYSTEM ETH0. It would activate it. Alternatively, I use the ifconfig command as follows:

ifconfig eth0 on

If this doesnt work, can you post more information describing the problem in more detail.

Hope it helps

asimo
Posts: 4
Joined: 2011/09/16 14:59:35

Re: Cannot access shared internet connection

Post by asimo » 2011/09/21 10:01:21

Hi, i'm sorry i don't know what SQUID is, I have two ethernet adapters on my xp machine, one connected to the internet box, the other one to a switch, where several other machines are connected, including my centos 6. On Xp i just used the "share my connection" option on the first ethernet, which builds a bridge between the two adapters hence sharing the connection with other machines on the switch. on the other machines all i had to do is provide the xp machine's local IP as the default GATEWAY, and it was enough to get acces to the internet. That's what i did on centos4 and it worked; on centos 6, the first errors i had was indeed due to the adapters being off by default, even if i activated them during setup; after seeing that onboot=off in the ifcfg-eth0, i changed that to "on" and network was working; but in that file, there was no trace of GATEWAY, although i did specify it in Network Manager. so I added it manually but with no luck, i deactivated NM as i've read it could be creating some issues, but still nothing; i can ping the xp machine correctly, 0% lost packets

what else can i check?

User avatar
TrevorH
Site Admin
Posts: 33219
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Cannot access shared internet connection

Post by TrevorH » 2011/09/21 10:06:13

Look in /etc/sysconfig/network as that probably has the gateway in it, maybe you made a typo?

asimo
Posts: 4
Joined: 2011/09/16 14:59:35

Re: Cannot access shared internet connection

Post by asimo » 2011/09/21 11:31:20

There was no gateway in this file, so i added it, restarted network service but still nothing (i use ping google.com to check, and i get "unknown host")

asimo
Posts: 4
Joined: 2011/09/16 14:59:35

Re: Cannot access shared internet connection

Post by asimo » 2011/09/21 12:34:57

SOLVED!

The file pointed above led me to a fedora forum, which suggested to create a file named route-eth0 in /etc/sysconfig/network-scripts/, which contains:

[code]default via Gateway.ip.here dev eth0[/code]


I restarted network service and that's it!

Can someone tell me how to modify the thread title to add [SOLVED]

User avatar
AlanBartlett
Forum Moderator
Posts: 9345
Joined: 2007/10/22 11:30:09
Location: ~/Earth/UK/England/Suffolk
Contact:

[SOLVED] Cannot access shared internet connection

Post by AlanBartlett » 2011/09/21 18:51:29

[quote]
Can someone tell me how to modify the thread title to add [SOLVED]
[/quote]
Unfortunately you will not be able to do so. There is a one hour window in which a user may edit the last post committed to a thread.

We recommend that a user should add [SOLVED] or [RESOLVED] to the subject line of the last post to the thread and then, in due course, a moderator will notice & make the appropriate addition to the subject line of the initial post.

That I have now done, on your behalf and for posterity.

Post Reply