Connect To The Internet Using Your Broadband Connection On A Linux System

Published Date
01 - May - 2008
| Last Updated
01 - May - 2008
Connect To The Internet Using Your Broadband Connection On A Linu...

Linux installed? Now let's go online…

Several readers have made the jump to Linux, but they haven’t got their Internet connections running. In our country, broadband is accessed in many different ways—ADSL, wired networks, WiMAX, etc. We connect using different diallers and authentication techniques, so unfortunately, we can’t depend on one single universal dialler when running Linux. In this short How To, we’ll try and explain the most common type of connections.

Connecting Using A USB Data Card

One of the easiest ways to get online these days is to use a data card. They’re not fast but they’re flexible and you can connect within minutes by plugging in the USB dongle. While on Windows, it’s simple. While on Linux, there are formalities, so to speak, that need to be completed before you can start dialling.
First we need to make sure that the USB data card has been detected by your distribution. Connect your USB data card first. Then, we need to first login into root, then type the following.


A list of connected devices will be displayed, and you should find your data card from the list. Look for a line with the vendor mentioned as Vendor=_______, and a Product ID as ProdID=______.
Next, we need to run modprobe. Type modprobe usbserial vendor=________ product=________ using the same information that we got from the device list. Once that’s done, type dmesg.

Check for network

Edit the /etc/wvdial.conf using a text editor such as vi. You will find a new connection called [Dialer cdma]. Enter the necessary information there, and save the file. Finally, type in the command wvdial cdma to dial the connection. You can also use try using sudo wvdialconf to configure your connection. Once the connection has been setup, you might want to go check whether the newly created connection is being used in Ubuntu under Administration > Network.

Connecting Using PPPoE (PPP Over Ethernet)

These days, PPPoE is one of the most popular ways of connecting to the Internet. It’s used a lot on ISPs that use wired networks and cable modem connections. On Windows, a PPPoE dialling connection can be setup using a Network connection wizard, but on Linux, we need to use a program called pppoeconf. Run this program as a root from a console.

All network cards are first scanned

The first thing that happens is that the device will look for all network cards installed on your machine. Make sure your LAN cable is plugged in and then proceed. The application will then scan for a PPPoE server on your ISP end. When it does, you will be asked to use the connection as your Internet connection. Proceed and you will be asked to enter the username and password for the connection. You can leave the rest of the settings as they are.

The final step dials the connection itself

Usually, the ISP provides you with the DNS server information automatically when you dial, so you need not enter any name servers either. At the end, you can choose to have the connection dialled. You can also dial the connection using the command pon to turn on the connection, and poff to turn off the connection.

Connecting With cURL To A Web-based Login

Although PPPoE is the simplest and the most flexible way anyone can connect to an ISP, there are many ISPs that require users to login using their Web interface. For that, there’s hardly any automation that can be done except using a little known program called cURL. cURL is available for Linux, Windows and a whole lot of other OSes. You can download it from It is used to access sites using username and passwords, so it can be used to enter a user and password on your ISP’s login page.

Unzip cURL in a suitable folder, and then open a command prompt window and browse to that location. You can use enter a command in a text file in Notepad and save it as a BAT file. All you need to know is the URL for your ISPs login page and obviously your username and password.

Create an entry – curl –d “username=_________&password=___________” https://<url_for_login>. Save the file and exit. The same entry can be entered in the command prompt. The BAT file can be run to login, or a  batch file can be scheduled to start on startup, so you can have your connection turned on when the computer boots. 

Rossi FernandesRossi Fernandes