LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-14-2013, 12:51 AM   #1
LittleOldLady
LQ Newbie
 
Registered: Dec 2010
Location: Australia, Earth
Distribution: Puppy, Ubuntu Lucid and Trusty
Posts: 8
Blog Entries: 3

Rep: Reputation: 0
Dial-up internet connection unavailable if ethernet connected to LAN router


I have Ubuntu 10.04 LTS installed on an elderly HP laptop and a dialup internet connection with Dodo Australia. I also have a DLink router (which expects the internet connection to be ADSL with an ADSL modem connected to iys "input" ethernet connection).
When I connect an ethernet cable to the router, the dial-up connection becomes dormant and unavailable. I suspect that what is happening is that the defaults on the network settings preferentially use an ethernet internet connection, which, of course, we do not have.
I have read lots about networking and setup needs, but I cannot find how to fix this.
What I really want to do is set up this laptop as the internet connection for the router. I do not know how.
I use wvdial to connect to the internet in a BASH shell. That was an exercise in itself, but that is working moderately reliably.
Can anyone tell me how to keep my dial-up connection active when I connect an ethernet cable to my computer, please?
Secondly, are there tricks and tips to allow my dial-up connection to provide internet to the router. Perhaps the laptop has to pretend to the router that it is a logged-in ADSL modem?
I am pretty comfortable with using BASH (my first computers only worked at command line level) but some of the networking terminology is still a mystery to me.
Thanks in anticipation of a solution!

Last edited by LittleOldLady; 12-15-2013 at 09:34 PM. Reason: Misspleeling in subject
 
Old 12-16-2013, 12:47 AM   #2
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,654

Rep: Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255
Very likely what is happening is that the default route is being switched to use the ethernet connection - which doesn't have internet access.

I'm not sure how the Ubuntu setup would control this.

To have the system relay the internet connection requires a system flag to be set: (file should be sysctl.conf) and the parameter is: net.ipv4.ip_forward = 1

Any other host connected to the router will have to have its default route set to the IP number of Ubuntu system. When connections to internet hosts are to be made, the initial connection from that host will go to the router, then to the Ubuntu host due to the default route on that host. The Ubuntu host has its default route set to go to the modem, and the net.ipv4.ip_forward flag will direct the network stack to forward the request out the default route. In addition, any reply coming back would be forwarded to the other host.

Now frequently this has to be combined with NAT (network address translation) as the internal router is using IP numbers that are designated to be "non-routable". The Ubuntu host should be able to be configured for this so that when the request for an outside connection arrives, the port that is assigned to it by the Ubuntu host is recorded in a table. The IP destination number for the internal host is replaced by public IP number given by the modem so that replys can be forwarded appropriately.

Sometimes the modem itself is a NAT router and that can also introduce some complexity. But one step at a time. Get the Ubuntu system working allowing connections to the internet AND connections to the hosts attached to the router. This is the biggest issue - after that, it is just configuration controls on how you want the NAT forwarding to be handled.
 
1 members found this post helpful.
Old 12-18-2013, 09:40 PM   #3
LittleOldLady
LQ Newbie
 
Registered: Dec 2010
Location: Australia, Earth
Distribution: Puppy, Ubuntu Lucid and Trusty
Posts: 8
Blog Entries: 3

Original Poster
Rep: Reputation: 0
Without Gnome Network Manager

Thank you, we are making excellent progress.
One result of making the physical ethernet connection was that the Gnome Network Manager (network-manager) was removing the DNS nameserver data in /etc/resolv.conf and replacing it with a little comment which took credit for the change and redirected DNS to the router.
When I found out about this behaviour, I uninstalled network-manager and it no longer does that. Whether the Ubuntu setup does something else to make the ethernet preferential, I have not yet discovered.
A review of /etc/sysctl.conf revealed that it consisted entirely of comments, including the lines:

# Uncomment the next line to enable packet forwarding for IPv4
#net.ipv4.ip_forward=1

So I have uncommented that line.

Plugging the laptop into the router now is not disconnecting my dial-up connection, which is brilliant. I am not certain whether the change to sysctl.conf was the solution (I think not) or the uninstallation of network-manager (I think this was the baddie). However, now that the major problem is resolved, only the minor one of how to relay the connection remains.
I shall follow the tutorials on how to manually establish an ethernet connection without network-manager and when I have sorted that out, will report my progress.
 
Old 12-19-2013, 05:03 AM   #4
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,654

Rep: Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255
I have always had trouble with NetworkManager.

My configuration uses a double NAT - The internet router is a NAT device going between the ISP and 192.168.1.x local network.

I then use NAT to forward connections between 192.168.0.x (my internal network) to the internet. The area that controls this is the firewall. The 192.168 networks are designated "non-routable" which prevents Linux from automatically forwarding such connections - thus the use of NAT, which will forward them.

Clumsy, but works.
 
  


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
KVM VM Connected to lan without using a physical ethernet port rmccall2012 Linux - Virtualization and Cloud 4 05-20-2012 07:14 PM
[SOLVED] Port Forwarding inside LAN not connected to a router nor internet lmorda Linux - Networking 16 02-08-2012 02:54 PM
Remote connection problem(build a separated lan in two VPN connected lan) William17 Linux - Networking 0 12-04-2011 02:33 AM
A probleam about wireless ethernet card used PPPOE protocol dial-up connected interne yjftwo Linux - Wireless Networking 5 11-25-2004 06:02 AM
Possible Routing / DNS Issue with Dial-Up connection on LAN connected PC geesloper Linux - Networking 2 12-06-2003 07:55 PM


All times are GMT -5. The time now is 09:33 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration