Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 03-16-2004, 03:52 PM   #1
LQ Newbie
Registered: Mar 2004
Posts: 5

Rep: Reputation: 0
How do I share my Internet Connection?

I have PC with Windows XP Pro installed, that is connected to a ADSL line through my Ethernet Card, and a laptop with Mandrake 9.2 connected with a crossed over cable.

What have I got to do, to share my Internet connection with my portable computer on Mandrake9.2?

Old 03-16-2004, 04:00 PM   #2
Registered: Feb 2004
Location: Belgium
Distribution: Suse 9.1 Pro / Gentoo
Posts: 114

Rep: Reputation: 15
You will probably only have one IP available from your provider so i think the easiest way is to put a router between the modem and the PC and laptop.
The router will get the IP address from your provider (if they use dinamic IP's)
the pc and laptop connect to the rooter witch gives the both of them an IP address
Old 03-16-2004, 05:28 PM   #3
LQ Newbie
Registered: Mar 2004
Posts: 5

Original Poster
Rep: Reputation: 0
without router.

without router.
Old 03-16-2004, 06:17 PM   #4
LQ Newbie
Registered: Feb 2004
Location: Paris
Distribution: Redhat 8.0 - Mandrake 9.0
Posts: 5

Rep: Reputation: 0
First you need enable IP Forwarding on PC Gateway:

#echo "1" > proc/sys/net/ipv4/ip_forward
#iptables -t nat -A POSTROUTING -o $internet_iface -j MASQUERADE

- $internet_iface = iface you use to connect to Internet

Now! Set ip for gateway PC (IP on your LAN)

Example: IP: an netmask

#ifconfig eth0 netmask

Restart Inteface Network to enable all change:

#/etc/init.d/network restart

Good! From client you wan connect out to Internet by Gateway. You set default gateway to use PC gatway =

Good Luck


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
Share Internet Connection sam_casperson Linux - Networking 3 02-03-2005 07:07 PM
Help! Cannot share my Internet connection... Domiriel Linux - Networking 2 11-25-2003 02:27 PM
how to share internet connection digihall7 Linux - Networking 5 10-23-2003 12:53 AM
how to share internet connection digihall7 Linux - Networking 2 09-23-2003 04:42 PM
HOW to share Internet connection zaldyd Linux - Newbie 1 07-25-2003 01:42 AM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:12 PM.

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