LinuxCommandLibrary

pon

Establish a dial-up connection

SYNOPSIS

pon [provider-name]

PARAMETERS

provider-name
    The name of the PPP configuration profile to use. This corresponds to a file named provider-name in the /etc/ppp/peers/ directory. This file contains specific options for the pppd daemon to establish the connection, such as modem settings, authentication details, and IP address allocation.

DESCRIPTION

The pon command is a script designed to initiate a Point-to-Point Protocol (PPP) connection on Linux systems. It acts as a user-friendly wrapper for the more complex pppd daemon, which is the core program for establishing and managing PPP links. When invoked, pon reads configuration details from a specified "provider" file, typically located in /etc/ppp/peers/, and then executes pppd using those settings. This command is commonly used for establishing dial-up modem connections, older ADSL links, or other forms of serial-based network access.

It automates the process of dialing, authenticating, and bringing up the network interface associated with the PPP link. Successful execution typically means the system has gained network connectivity through the PPP interface, such as ppp0. While pon simplifies user interaction, understanding the underlying pppd configuration files is crucial for troubleshooting or customizing the connection. It is usually paired with the poff command to gracefully terminate the PPP connection.

CAVEATS

pon requires root privileges to execute, as it manipulates network interfaces and starts system daemons. It is heavily reliant on correctly configured files in /etc/ppp/peers/, /etc/ppp/options, and authentication files like /etc/ppp/chap-secrets or /etc/ppp/pap-secrets. Debugging connection issues often requires examining the output of pppd (usually in system logs like /var/log/syslog or /var/log/daemon.log) rather than pon itself, as pon is just a wrapper. PPP connections, while still supported, are less common in modern broadband setups and are more prevalent in legacy environments or for specific VPN-like tunnels.

CONFIGURATION FILES

pon relies on a hierarchy of configuration files for its operation. The primary file is /etc/ppp/peers/provider-name, which is specified as an argument to pon. This file typically contains options passed directly to pppd, such as user, noauth, defaultroute, connect scripts, and modem details. Global pppd options can be found in /etc/ppp/options, while authentication credentials (username/password) are stored in /etc/ppp/chap-secrets or /etc/ppp/pap-secrets. These files must be correctly configured for pon to successfully establish a connection.

USAGE AND TROUBLESHOOTING

To use pon, you first need a provider configuration file in /etc/ppp/peers/. For example, if you have a file named /etc/ppp/peers/myisp, you would bring up the connection using sudo pon myisp. After execution, you can check the connection status with ip a or ifconfig to see if a ppp0 (or similar) interface is up, and ping to test connectivity. If the connection fails, review the system logs (e.g., /var/log/syslog, /var/log/daemon.log) for output from pppd, which often provides detailed error messages about authentication failures, modem issues, or script errors. The plog command can also be helpful for viewing PPP-specific logs.

HISTORY

The pon command has been a part of the standard ppp (Point-to-Point Protocol) package for Linux and Unix-like systems since its early days. Its primary purpose was to provide a simple, high-level interface for users and scripts to control the pppd daemon, which manages the actual PPP connection. It emerged as a convenience script to abstract away the numerous command-line options of pppd, allowing users to define connection profiles in separate files (e.g., for different ISPs or connection types) and invoke them with a single, memorable command. Its development has closely tracked that of the ppp daemon itself, maintaining its role as the go-to command for bringing up configured PPP links.

SEE ALSO

poff(8), pppd(8), ppp(8), plog(8)

Copied to clipboard