Re: ifconfig eth0 down works but it won't go up!
From: Bruce Stewart (bruce_stewart_at_by.co.uk)
Date: 11/14/04
- Next message: Sundial Services: "Re: ifconfig eth0 down works but it won't go up!"
- Previous message: Davide Bianchi: "Re: Q: Simple way to pick up resolv.conf info from DHCP to DNS?"
- In reply to: Al. C: "Re: ifconfig eth0 down works but it won't go up!"
- Next in thread: Sundial Services: "Re: ifconfig eth0 down works but it won't go up!"
- Reply: Sundial Services: "Re: ifconfig eth0 down works but it won't go up!"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 14 Nov 2004 14:02:49 GMT
Al. C wrote:
> Timothy Murphy wrote:
>
>> Al. C wrote:
>>
>>>>> If I do ifconfig eth0 down and then an ifconfig eth0 up, I can't do
>>>>> a simple ping -c google.com. I get:
>>>>> ping: unknown host google.com
>>
>> So why do you say "ifconfig eth0 down" ??
>>
>>> I've tried runnin inetd and intet1 and inet2 and nothing seems to
>>> restore the network.... except a reboot.
>>
>> You don't say what system you're running.
>> On Redhat/Fedora you probably need to say "service network restart".
>> On other systems it might be "/etc/rc.d/init.d/network restart"
>> or something like that.
>>
>
> First of all, I'm sure in the opening post I said I run Slackware 9.1
> with KDE.
>
> OK, here is the answer (or at least AN answer.... the gurus here might
> have a better one.)
>
> It seems (for me anyway) that "ifconfig eth0 down" deletes the default
> gateway from route table. (And it makes sense if the gateway is the
> ethernet card... so if it goes down, Linux is correct in erasing an
> entry from the route table (if there is such an animal.)
>
> Did some more reading and from
>
> http://tinyurl.com/3kgm9
>
> I found that doing the command:
>
> route add default gw 129.168.1.1
>
> brings back network functionality after an "ifconfig eth0 up" command.
> The web page cited above uses a different command and the man route page
> is cryptic as hell, but after trying to put the man page together with
> the above web page, I think I figured it out.
>
> Which comes down to this. For me, if I want to use the modem AND I'm
> connected to the router at boot time, I need to do the "ifconfig eth0
> down" command and then dial out. After hanging up, I can bring DSL
> connectivity back by doing the "up" command and then the route command
> above. If I boot laptop without the cable connected to the router, I
> don't have to do the eth0 down thing. Not sure why.
>
> I really thought there was a way to be online with DSL and the modem at
> the same time, but I guess not. (Why would you want to do this? Some
> people still have dial-up to their bank to send credit card sales txns.)
>
> Thanks for the help. I hope some of this is useful to someone else
> sometime. It's been a learning experience for me.
>
> Al
Al,
You shouldn't need to drop eth0 before or after raising a ppp connection.
KInternet should handle the setup of the ppp connection, this will change
the gateway to the ppp connection, but should allow access to your local
network, in addition it can change the nameservers to the ones for your
ppp connection.
If you are directly connecting to the internet with your DSL, not through
a local network and you are using your ppp connection, you will more than
likely need a slightly more complex routing table to be able to route to
the bank IP ranges as well as the internet through the DSL connection.
Regards
Bruce.
-- Replace by by blueyonder
- Next message: Sundial Services: "Re: ifconfig eth0 down works but it won't go up!"
- Previous message: Davide Bianchi: "Re: Q: Simple way to pick up resolv.conf info from DHCP to DNS?"
- In reply to: Al. C: "Re: ifconfig eth0 down works but it won't go up!"
- Next in thread: Sundial Services: "Re: ifconfig eth0 down works but it won't go up!"
- Reply: Sundial Services: "Re: ifconfig eth0 down works but it won't go up!"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|