dialup and cable modem

dialup and cable modem

Post by jinson » Sun, 29 Oct 2000 12:09:00



Hi,

I have a static cable modem connection. But I have
to use dialup connection to connect to my
company's private network. How do I do this. I had
to deactivate the eth0, and activate the ppp0, but
after the dialup connection established ( I can
see it from the log file), I cann't see anywhere,
I cann't ping any machines.  My company is behind
a firewall, so I have always been assigned a IP
like 192.168.20.xxx.
I guess the default gateway won't work on my
company's network. But how do I change it. Most of
the time I use my cable modem, so I have to use
that default gateway.
Under windows, I can use the dialup if I want to,
it swiched from my cable connection to the dialup
automatically. I am sure that is a way to do that
in Linux also, just I am not aware of.

Thanks for any help.

Jinsong

Sent via Deja.com http://www.deja.com/
Before you buy.

 
 
 

dialup and cable modem

Post by Clifford Kit » Mon, 30 Oct 2000 06:48:06



> I have a static cable modem connection. But I have to use dialup
> connection to connect to my company's private network. How do
> I do this. I had to deactivate the eth0, and activate the ppp0,
> but after the dialup connection established ( I can see it from
> the log file), I cann't see anywhere, I cann't ping any machines.
> My company is behind a firewall, so I have always been assigned a
> IP like 192.168.20.xxx.

That IP range is not routable so you can't get to the Internet unless
the company sets up networking to provide your outgoing packets with
a routable IP address, and then translates the IP address back to
deliver them to you.  You may or may not be concerned about this.

Quote:> I guess the default gateway won't work on my
> company's network. But how do I change it. Most of
> the time I use my cable modem, so I have to use
> that default gateway.

What you do depends on what you expect of the company connection.

Quote:> Under windows, I can use the dialup if I want to, it swiched from
> my cable connection to the dialup automatically. I am sure that is
> a way to do that in Linux also, just I am not aware of.

Try removing the pppd option "defaultroute", if present, and inserting
the line

/sbin/route add -net 192.168.20.0/24 $1

in /etc/ppp/ip-up.  That way you can have use of the cable modem
connection to the Internet while connected to the company.  Only the
packets sent to an IP address in the 192.168.20.0/24 network, will
go out the PPP interface.

You could instead add

/sbin/route add default $1

but then the cable default route to the Internet won't work.

These routes go away automatically when the PPP connection is finished
and takes down the PPP interface.

--

/* I gave up on politics when no matter who I voted for, I regretted it.
 *    -- Pepper...and Salt, WSJ */

 
 
 

dialup and cable modem

Post by jinson » Mon, 30 Oct 2000 16:28:32


Thanks,

I tried that. This doesn't seem to work.
I still think that it is the problem with the gateway. My default
gateway is 24.xxx.xxx.xxx with the device eth0.  When I dialup to my
company, I cann't use the gateway anymore. In Windows, the gateway for
my dialup is the same as the IP I was assigned (like 192.168.20.24).
How do I change the gateway while I dialup and change back when I
disconnect from the phone line?

Jinsong




> > I have a static cable modem connection. But I have to use dialup
> > connection to connect to my company's private network. How do
> > I do this. I had to deactivate the eth0, and activate the ppp0,
> > but after the dialup connection established ( I can see it from
> > the log file), I cann't see anywhere, I cann't ping any machines.
> > My company is behind a firewall, so I have always been assigned a
> > IP like 192.168.20.xxx.

> That IP range is not routable so you can't get to the Internet unless
> the company sets up networking to provide your outgoing packets with
> a routable IP address, and then translates the IP address back to
> deliver them to you.  You may or may not be concerned about this.

> > I guess the default gateway won't work on my
> > company's network. But how do I change it. Most of
> > the time I use my cable modem, so I have to use
> > that default gateway.

> What you do depends on what you expect of the company connection.

> > Under windows, I can use the dialup if I want to, it swiched from
> > my cable connection to the dialup automatically. I am sure that is
> > a way to do that in Linux also, just I am not aware of.

> Try removing the pppd option "defaultroute", if present, and inserting
> the line

> /sbin/route add -net 192.168.20.0/24 $1

> in /etc/ppp/ip-up.  That way you can have use of the cable modem
> connection to the Internet while connected to the company.  Only the
> packets sent to an IP address in the 192.168.20.0/24 network, will
> go out the PPP interface.

> You could instead add

> /sbin/route add default $1

> but then the cable default route to the Internet won't work.

> These routes go away automatically when the PPP connection is finished
> and takes down the PPP interface.

> --

> /* I gave up on politics when no matter who I voted for, I regretted
it.
>  *    -- Pepper...and Salt, WSJ */

Sent via Deja.com http://www.deja.com/
Before you buy.
 
 
 

dialup and cable modem

Post by Clifford Kit » Tue, 31 Oct 2000 02:08:29



> How do I change the gateway while I dialup and change back when I
> disconnect from the phone line?

Post exact copies (cut-and-paste) of the outputs of "route -n" before
and after connecting with dialup.  Then maybe I'll understand the
problem better than I do from your narrative.

--

/* Editing with vi is a lot better than using a huge swiss army knife.
   Use =} to wrap paragraphs in vi.  Or put   map ^] !}fmt -72^M   in
   ~/.exrc and use ^] to wrap to 72 columns or whatever you choose. */

 
 
 

dialup and cable modem

Post by jinson » Tue, 31 Oct 2000 06:40:41


Before dialup, here is the outpur from route -n:
Destination     Gateway         Genmask         Flags Metric Ref    Use
Iface
24.19.214.63    0.0.0.0         255.255.255.255 UH    0      0        0
eth0
192.168.0.1     0.0.0.0         255.255.255.255 UH    0      0        0
eth1
192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0
eth1
24.0.0.0        0.0.0.0         255.0.0.0       U     0      0        0
eth0
127.0.0.0       0.0.0.0         255.0.0.0       U     0      0        0
lo
0.0.0.0         24.19.214.1     0.0.0.0         UG    0      0        0
eth0

after dialup, the output is:
192.168.20.12   0.0.0.0         255.255.255.255 UH    0      0        0
ppp0
192.168.0.1     0.0.0.0         255.255.255.255 UH    0      0        0
eth1
192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0
eth1
127.0.0.0       0.0.0.0         255.0.0.0       U     0      0        0
lo
0.0.0.0         192.168.20.12   0.0.0.0         UG    0      0        0
ppp0

get any clues?

Jinsong




> > How do I change the gateway while I dialup and change back when I
> > disconnect from the phone line?

> Post exact copies (cut-and-paste) of the outputs of "route -n" before
> and after connecting with dialup.  Then maybe I'll understand the
> problem better than I do from your narrative.

> --

> /* Editing with vi is a lot better than using a huge swiss army knife.
>    Use =} to wrap paragraphs in vi.  Or put   map ^] !}fmt -72^M   in
>    ~/.exrc and use ^] to wrap to 72 columns or whatever you choose. */

Sent via Deja.com http://www.deja.com/
Before you buy.
 
 
 

dialup and cable modem

Post by Clifford Kit » Wed, 01 Nov 2000 00:51:20



> Before dialup, here is the outpur from route -n:
> Destination     Gateway         Genmask         Flags Metric Ref    Use
> Iface
> 24.19.214.63    0.0.0.0         255.255.255.255 UH    0      0        0
> eth0
> 192.168.0.1     0.0.0.0         255.255.255.255 UH    0      0        0
> eth1
> 192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0
> eth1
> 24.0.0.0        0.0.0.0         255.0.0.0       U     0      0        0
> eth0
> 127.0.0.0       0.0.0.0         255.0.0.0       U     0      0        0
> lo
> 0.0.0.0         24.19.214.1     0.0.0.0         UG    0      0        0
> eth0

Okay, this shows a default route through the eth0 interface via the
IP address 24.19.214.1

Quote:> after dialup, the output is:
> 192.168.20.12   0.0.0.0         255.255.255.255 UH    0      0        0
> ppp0
> 192.168.0.1     0.0.0.0         255.255.255.255 UH    0      0        0
> eth1
> 192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0
> eth1
> 127.0.0.0       0.0.0.0         255.0.0.0       U     0      0        0
> lo
> 0.0.0.0         192.168.20.12   0.0.0.0         UG    0      0        0
> ppp0

This shows that you've remove the eth0 interface altogether and now
have a default route through the ppp0 interface via the IP address
192.168.20.2.  That's okay but you can't remove the eth0 interface
and expect to connect to the Internet.  So *don't* remove it.  The
problem then is that pppd won't add a default route through the PPP
interface.

As I implied in my previous post these are two solutions to this:

(1) Put the line

/sbin/route add -net 192.168.20.0 $1

in /etc/ppp/ip-up.  This will provide a network-specific route for any
packets to that network, so that's where they will be sent.  Any other
packets bound for any IP address that's not in that network, or in any
other local network, to go through the PPP interface.

(2) Remove the pppd default route option and put the line

/sbin/route add default $1

in /etc/ppp/ip-up.  This new default route will be the active default
route and all packets with non-local IP addresses are then sent to
the PPP interface.  You won't have Internet access through the eth0
interface in this case, since the new default route will override
the one through eth0.

Both these PPP routes disappear when the PPP link is taken down by
pppd, and in the second case the default route to eth0 automatically
becomes the active default route.  You need to make sure that the
first line of /etc/ppp/ip-up is "#!/bin/sh" since this is a shell
script run by pppd.  I don't think it inherits any enviroment, thus
the use of full pathnames.

You've said that you tried the suggestions in my previous post.  If one
of these more detailed descriptions of them doesn't get things working
the way you want then I'm clueless as to what's going on.

--

/* In my book, the first poster to resort to personal abuse in a Usenet
   debate loses by default.  -  Rod Smith */

 
 
 

dialup and cable modem

Post by Clifford Kit » Wed, 01 Nov 2000 01:06:18



> (1) Put the line
> /sbin/route add -net 192.168.20.0 $1

Rats.  The network address should be written 192.168.20.0/24

--

/* For every credibility gap, there is a gullibility fill.
                -- R. Clopton */

 
 
 

dialup and cable modem

Post by jinson » Wed, 01 Nov 2000 07:34:15


Thanks, I will try your suggestion again when I get home.

The reason I have to remove eth0 is that, if I don't remove it, I got
connected to the dialup connection but not assigned a IP address, it
said something like "not authorized", "permission deny". As I said, our
company network is behind a firewall.  Only after I deactivate the eth0
I can get an IP address.

Jinsong




> > (1) Put the line

> > /sbin/route add -net 192.168.20.0 $1

> Rats.  The network address should be written 192.168.20.0/24

> --

> /* For every credibility gap, there is a gullibility fill.
>                 -- R. Clopton */

Sent via Deja.com http://www.deja.com/
Before you buy.
 
 
 

1. Cable modem..56 modem dial up, 500K cable modem download stream...

I have 2 network cards and 1 modem in a Linux Box with RH6.
My cable modem uses the modem to start a PPP session, and the network card
is then hooked up to the VPN of the ISP.

I would like to setup a IP Masquraded Firewall to hook some of my other
boxes
behind the firewall.

I  cannot find a HOW-TO to setup the Linux box using this type of Cable
Modem.  I
have only found 2 way cable modems.  Can someone point me it the right
direction.

My problem is that I don't know how to get Linux connected, then also, how
do I configure
ipchains or ipfwadm to use the correct rule set.  Do I do the modem or the
network card.  The
network card has a static IP of 10.0.0.1 which is usally used for VPNs.  My
cable company
is of corse not supporting Linux, so I have to do it myself.  The PPP dialup
uses DHCP to
assign my address so I have dhcp setup.

Thanks in advance..

Aaron

2. Staying alive until killed

3. natbox (cable-modem) with dialup backup?

4. Sol 7 file locking problem

5. Cable Modem (COX @HOME), I NEED HELP SETTING UP MY CABLE MODEM WITH RH 5.1

6. CD-ROM Filesystem Help

7. @Home Cable Modem and RedHat 6.0 -- no packets get past the cable modem at all!

8. Unixware 1.1 install problems

9. Cox Cable installing a cable modem

10. Anyone using Cable TV Montgomery cable modems?

11. problem with nat in kernel-2.16.22 on cable modem (i-cable)

12. Yet another cable modem setup question :( (Philadelphia area Suburban Cable)

13. linux setup for cable modem service by Cable TV Montgomery/ExpressNet