A 10-Minute Guide for Using PPP to Connect Linux to the Internet
To drop a connection you just need to kill pppd. When it exits, it will hang up the line, if you've configured the modem as I've suggested.
On most distributions this will be as simple as:
# killall -HUP pppd
If you are lucky enough to have a semi-permanent connection to your ISP, i.e., one where you can stay connected for as long as you like, you may want to have your Linux automatically redial if the telephone call drops out for some reason. Here is a simple way of doing this that assumes you have configured your PPP link to be activated by root.
The first very important step is to add this line to your /etc/ppp/options file:
This line tells pppd not to go into the background after it has successfully connected. The next step is to add a line to your /etc/inittab file that looks like this:
pd:23:respawn:/usr/sbin/pppdPut this line down with the other lines that are similiar to it—the ones that run the login program.
This line simply tells the init program that it should automatically start the /usr/sbin/pppd program and that it should automatically restart it if it dies. Provided you have your modem configured to raise Data Carrier Detect and you have configured pppd as I have described, init will ensure the pppd program is always running and re-run it if it terminates.
A word of warning—this is simple, but provides no safeguards against problems that might cause the telephone call to be successfully made and then hang up. If you experience this problem, the init program will quite happily keep re-running the pppd program until you tell it to stop. You could run up quite a telephone bill if something nasty goes wrong.
This article describes a basic PPP configuration. There are many excellent documents that provide more detailed and comprehensive information on the subject. This article should be sufficient to get you connected to the Internet in a typical configuration. If you have any problems you cannot diagnose, I strongly recommend you read the PPP-HOWTO by Robert Hart at:
Robert has done an excellent job in rewriting the HOWTO, and it should be of assistance to you.
Fast/Flexible Linux OS Recovery
On Demand Now
In this live one-hour webinar, learn how to enhance your existing backup strategies for complete disaster recovery preparedness using Storix System Backup Administrator (SBAdmin), a highly flexible full-system recovery solution for UNIX and Linux systems.
Join Linux Journal's Shawn Powers and David Huffman, President/CEO, Storix, Inc.
Free to Linux Journal readers.Register Now!
- Download "Linux Management with Red Hat Satellite: Measuring Business Impact and ROI"
- Chris Birchall's Re-Engineering Legacy Software (Manning Publications)
- The Italian Army Switches to LibreOffice
- Linux Mint 18
- Petros Koutoupis' RapidDisk
- ServersCheck's Thermal Imaging Camera Sensor
- Oracle vs. Google: Round 2
- The FBI and the Mozilla Foundation Lock Horns over Known Security Hole
- Privacy and the New Math
Until recently, IBM’s Power Platform was looked upon as being the system that hosted IBM’s flavor of UNIX and proprietary operating system called IBM i. These servers often are found in medium-size businesses running ERP, CRM and financials for on-premise customers. By enabling the Power platform to run the Linux OS, IBM now has positioned Power to be the platform of choice for those already running Linux that are facing scalability issues, especially customers looking at analytics, big data or cloud computing.
￼Running Linux on IBM’s Power hardware offers some obvious benefits, including improved processing speed and memory bandwidth, inherent security, and simpler deployment and management. But if you look beyond the impressive architecture, you’ll also find an open ecosystem that has given rise to a strong, innovative community, as well as an inventory of system and network management applications that really help leverage the benefits offered by running Linux on Power.Get the Guide