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 10-23-2005, 11:19 AM   #1
crazykiller
Member
 
Registered: Sep 2005
Posts: 58

Rep: Reputation: 15
Internet Sharing


After a couple days of sorting out my BT Voyager 100 with EciADSL Drivers ive got it working and i want to share it.

As far as i know i connect via PPP0 and i want to share it via ETH0.

How can this be done... I seen something about IP Forwarding...

But i dont know how to set it up...
 
Old 10-23-2005, 12:17 PM   #2
crazykiller
Member
 
Registered: Sep 2005
Posts: 58

Original Poster
Rep: Reputation: 15
Ok i got the connections working... i can ping from my Windows PC to my Linux PC. Only problem is when i open IE or FireFox on my Windows PC it doesnt load up the pages.
 
Old 10-23-2005, 03:50 PM   #3
fouldsy
Senior Member
 
Registered: Jan 2002
Location: St Louis, MO
Distribution: Ubuntu
Posts: 1,284

Rep: Reputation: 47
You need to be looking at NAT (network address translation) to masquerade your requests. The Linux box with your ADSL modem on needs iptable rules setting up, so anything coming in from your Windows box is sent out from your Linux machine, and data returned from the Internet is correctly sent back to Windows. Are some easy tutorials on nat + masquearding with iptables if you do a quick search - there's problem something under the 'Answers' section on here.
 
Old 10-23-2005, 03:59 PM   #4
wym
LQ Newbie
 
Registered: Oct 2005
Location: Toronto
Distribution: Red Hat 8.0
Posts: 26

Rep: Reputation: 15
How many network cards have you installed on your linux machine? I think you need 2. One is connected with your Windows machine, and the other with Internet. If NAT is complex for you, you can use "squid" as a proxy server.

Post your result of "ifconfig" and "route" here, these might help me to find out the problem.
 
Old 10-23-2005, 04:03 PM   #5
crazykiller
Member
 
Registered: Sep 2005
Posts: 58

Original Poster
Rep: Reputation: 15
In Yast2 in the Masquerade settings it says i need 2 components in order to set it up... e.g. a Modem and a Lan card... my Lan card is in the list but my modem isnt. i dont see why, i used eciadsl to install the modem and it works fine somehow i gotta get that device into the Device list in the firewall settings.
 
Old 10-23-2005, 04:17 PM   #6
michaelk
Moderator
 
Registered: Aug 2002
Posts: 26,757

Rep: Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318
ppp0 is the device that connects to the internet. Is it listed in the device list?

For manually configuring internet connection sharing.
# iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE
# echo 1 > /proc/sys/net/ipv4/ip_forward
 
Old 10-23-2005, 04:20 PM   #7
crazykiller
Member
 
Registered: Sep 2005
Posts: 58

Original Poster
Rep: Reputation: 15
Route:
Code:
Simon:/usr/local/bin # route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
rasj3nrp5.ilfor *               255.255.255.255 UH    0      0        0 ppp0
192.168.0.0     *               255.255.255.0   U     0      0        0 eth0
link-local      *               255.255.0.0     U     0      0        0 eth0
loopback        *               255.0.0.0       U     0      0        0 lo
default         *               0.0.0.0         U     0      0        0 ppp0
default         Simon.Rigby     0.0.0.0         UG    0      0        0 eth0
IFCONFIG:
Code:
Simon:/usr/local/bin # ifconfig
eth0      Link encap:Ethernet  HWaddr 00:30:05:70:5A:18
          inet addr:192.168.0.1  Bcast:192.168.0.255  Mask:255.255.255.0
          inet6 addr: fe80::230:5ff:fe70:5a18/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:25 errors:0 dropped:0 overruns:0 frame:0
          TX packets:879 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:3116 (3.0 Kb)  TX bytes:67364 (65.7 Kb)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:560 errors:0 dropped:0 overruns:0 frame:0
          TX packets:560 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:47954 (46.8 Kb)  TX bytes:47954 (46.8 Kb)

ppp0      Link encap:Point-to-Point Protocol
          inet addr:217.42.180.254  P-t-P:217.47.124.148  Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1500  Metric:1
          RX packets:750 errors:0 dropped:0 overruns:0 frame:0
          TX packets:798 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:3
          RX bytes:374852 (366.0 Kb)  TX bytes:106283 (103.7 Kb)
Which device list are you talking about?
 
Old 10-23-2005, 05:51 PM   #8
michaelk
Moderator
 
Registered: Aug 2002
Posts: 26,757

Rep: Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318
Quote:
Which device list are you talking about?
ppp0 being in the firewall settings device list.
 
Old 10-24-2005, 04:06 AM   #9
crazykiller
Member
 
Registered: Sep 2005
Posts: 58

Original Poster
Rep: Reputation: 15
No the ppp0 isnt in the firewall device list thats the problem :S If it was i think i could know how to do it.
 
Old 10-27-2005, 09:18 PM   #10
michaelk
Moderator
 
Registered: Aug 2002
Posts: 26,757

Rep: Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318Reputation: 6318
Not familar enough with yast2 to help.
 
Old 10-28-2005, 04:27 AM   #11
crazykiller
Member
 
Registered: Sep 2005
Posts: 58

Original Poster
Rep: Reputation: 15
But its ok to spam

I dont know the rules but normally if you cant help out dont say anything.
 
Old 10-28-2005, 08:20 PM   #12
wym
LQ Newbie
 
Registered: Oct 2005
Location: Toronto
Distribution: Red Hat 8.0
Posts: 26

Rep: Reputation: 15
In your Windows PC, did you setup the DNS address of your ISP?

Can Windows PC ping any Internet IPs and get replies? If yes, that means the Linux PC is sharing the Internet connection. The cause is the DNS address setting in the Windows PC.

In Windows PC, the setting should be:
IP: 192.168.0.2
Mask: 255.255.255.0
GW: 192.168.0.1
DNS: the DNS addrsss of your ISP

And if the Linux PC's IP forwarding is working fine, the Windows PC should have access to Internet. This is how my home network works.

If these don't work, I have the second solution, run squid in the Linux PC, in Windows PC's Internet browser, set proxy like this: 192.168.0.1 port 3128. This definitely works, but you need to setup something in squid.conf. If you don't know how, just say.

Last edited by wym; 10-28-2005 at 08:33 PM.
 
Old 10-29-2005, 05:06 AM   #13
crazykiller
Member
 
Registered: Sep 2005
Posts: 58

Original Poster
Rep: Reputation: 15
Got it all working great now

Thank you
 
  


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
mandrake 10.1 sharing files and internet sharing xfiles_arram Linux - Networking 0 05-21-2005 02:22 PM
internet sharing LinuxRam Linux - Networking 8 09-09-2004 08:52 AM
internet sharing trace1918 Linux - Networking 3 11-18-2003 02:04 PM
File sharing and internet sharing mullet Linux - Networking 1 10-14-2003 01:30 PM
Internet sharing from OS X to RH 7.3 ZeratulsAvenger Linux - Networking 3 07-22-2003 08:03 PM

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

All times are GMT -5. The time now is 10:06 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