LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 09-10-2005, 03:29 PM   #1
ozymandias
Member
 
Registered: Aug 2005
Location: West Midlands, UK
Posts: 61

Rep: Reputation: 15
Problem setting up network with PPPOE


I am trying to set up my Debian system to network with another machine. I have a fixed IP address, and want to use fixed network IP addresses. I connect to my ISP using PPPOE with an ADSL ethernet modem attached to eth0 - this works fine. However, when I try to configure my other ethernet socket (eth1) to connect to my other computer I can't seem to connect from the other machine. On the second machine I am using manual connection with an IP address of 192.168.0.100 and a gateway of 192.168.0.1
I know that I need to configure my internal network interface - but I am confused about what exactly ppp0 is all about!
I'd be very grateful for some advice about what needs configuring - is it the routing that's going wrong - or - (as I suspect) is it just that I don't really understand enough yet!

Any help gratefully appreciated!

--------------------------------------------------

my routing table looks like:
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
vispahg2.birmin * 255.255.255.255 UH 0 0 0 ppp0
192.168.0.0 * 255.255.255.0 U 0 0 0 eth1
default vispahg2.birmin 0.0.0.0 UG 0 0 0 ppp0

the results of ifconfig look like:
eth0 Link encap:Ethernet HWaddr 00:90:27:0F:A5:30
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:867 errors:0 dropped:0 overruns:0 frame:0
TX packets:946 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:428988 (418.9 KiB) TX bytes:121928 (119.0 KiB)
Interrupt:10 Base address:0xbc00 Memory:cffff000-cffff038

eth1 Link encap:Ethernet HWaddr 00:0B:6A:CE:0B:8C
inet addr:192.168.0.100 Bcast:192.168.0.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:56 errors:0 dropped:0 overruns:0 frame:0
TX packets:1 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:7023 (6.8 KiB) TX bytes:42 (42.0 b)
Interrupt:11 Base address:0xd400

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:44 errors:0 dropped:0 overruns:0 frame:0
TX packets:44 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:2800 (2.7 KiB) TX bytes:2800 (2.7 KiB)

ppp0 Link encap:Point-to-Point Protocol
inet addr:83.217.~~~.~~~ P-t-P:213.120.198.41 Mask:255.255.255.255
UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1492 Metric:1
RX packets:721 errors:0 dropped:0 overruns:0 frame:0
TX packets:802 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:3
RX bytes:404303 (394.8 KiB) TX bytes:99523 (97.1 KiB)
 
Old 09-10-2005, 04:06 PM   #2
Snowbat
Member
 
Registered: Jun 2005
Location: q3dm7
Distribution: Mandriva 2010.0 x86_64
Posts: 338

Rep: Reputation: 31
Re: Problem setting up network with PPPOE

Quote:
Originally posted by ozymandias
On the second machine I am using manual connection with an IP address of 192.168.0.100 and a gateway of 192.168.0.1
However, your first machine also uses 192.168.0.100 for its IP address, which isn't going to work:
eth1 Link encap:Ethernet HWaddr 00:0B:6A:CE:0B:8C
inet addr:192.168.0.100 Bcast:192.168.0.255 Mask:255.255.255.0

I suggest you reconfigure eth1 to use IP address 192.168.0.1 since it is normal practice to have a gateway (which your Debian box will be) at .1. Give the second machine an IP address of 192.168.0.2 and route add default gw 192.168.0.1

To give the second machine access to the internet, you'll want to set up NAT routing on the Debian box and enable packet forwarding. Here's how to do it in Mandrake - I'm not sure if Debian differs:

/sbin/modprobe iptable_nat
/sbin/iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE
echo 1 > /proc/sys/net/ipv4/ip_forward

You'll also want to enter your ISP nameserver details on the second machine. You'll find these in /etc/resolv.conf on the Debian machine when your connection is up.
 
Old 09-10-2005, 06:16 PM   #3
ozymandias
Member
 
Registered: Aug 2005
Location: West Midlands, UK
Posts: 61

Original Poster
Rep: Reputation: 15
Thanks! I had previously tried other IP combinations as I thought that they couldn't both share 192.168.0.100! But I tried it in case you were supposed to name the network card IP address the same as the computer you wanted to attach to it - obvoiusly not the case.
I'll try whaty you suggest - thanks for the help!
Ozymandias
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with setting up network card / network ssmeets Linux - Hardware 3 11-03-2005 03:46 PM
setting up network problem ... tomazN Linux - Networking 1 10-01-2005 02:35 PM
Setting up PPPOE connection UmneyDurak Fedora 1 03-10-2005 05:04 PM
Require assistance setting up PPPoe with firewall (2 NIC's) roggs Linux - Networking 3 12-09-2004 12:48 PM
setting up rp-pppoe server in suse 9.0 penguin_n00b Linux - Networking 1 04-05-2004 04:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 09:12 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration