Article Title: how to configure multi-line ADSL in Linux. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
This document describes how to configure dual-ADSL and multi-ADSL lines.
How to configure multi-line ADSL in Linux
Powered by KindGeorge http://kindgeorge.at.3322.org \ after a period of observation, it proves that the operation is good, now the setting process and method to sum up, welcome to correct.
This document describes how to configure dual-adsl and multi-adsl lines.
Lab environment:
Operating system: RedHat7.3
Two adsl instances, long term observation of line stability, dynamic IP address, bandwidth 2 M,
Three NICs: eth0 tulip, connected to the intranet
Eth1 3c59x, connected to the first adsl
Eth2 8139too, connected to the second adsl
Ethn xxxx, (if there are other ......)
Objective: to share the load by using two adsl networks to achieve simple load balancing and drive intranet access.
1. add a Nic
Insert the network card and start the machine. if you need to access the Internet through dual-line connection, you need three network cards. you can also refer to other information to configure the network card.
Configure to find the corresponding model module, for example, eth2 is 8139 Nic
[Root @ kindgeorge root] # vi/etc/modules. conf
Alias parport_lowlevel parport_pc
Alias eth0 tulip
Alias eth1 3c59x
Alias eth2 8139too
Add new lines to eth2
2. configure adsl
Method 1:
(1) run the adsl-setup program and you will be prompted to complete the configuration process step by step.
Create a dial-up profile for ppp0 and ppp1 and save the configuration, typically stored in/etc/sysconfig/network-scripts/ifcfg-ppp1
(2) determine the/etc/sysconfig/network-scripts/ifcfg-ppp0 file, where the PIDFILE parameter is set:
PIDFILE =/var/run/ppp-adsl.pid
Modify the/etc/sysconfig/network-scripts/ifcfg-ppp1 file and set the PIDFILE parameter:
PIDFILE =/var/run/ppp-adsl1.pid
If you have more lines, you can continue to add 0, 1, 2, 3 ...... And so on
This is to enable different dialers to use different PIDs. If this parameter is not modified, the second line interface cannot be started.
(3) the configuration file is generally:
USERCTL = no BOOTPROTO = dialup NAME = DSLppp1 DEVICE = ppp1 TYPE = xDSL ONBOOT = yes PIDFILE =/var/run/pppoe-adsl1.pid FIREWALL = none ping =. PPPOE_TIMEOUT = 20 LCP_FAILURE = 3 LCP_INTERVAL = 20 CLAMPMSS = 1412 CONNECT_POLL = 6 CONNECT_TIMEOUT = 60 DEFROUTE = yes SYNCHRONOUS = no ETH = eth2 (Nic corresponding to the new line) PROVIDER = DSLppp1 USER = new USER name provided by isp word 2 PEERDNS = no
|
Method 2:
(1) Direct copy
Cp/etc/sysconfig/network-scripts/ifcfg-ppp0/etc/sysconfig/network-scripts/ifcfg-ppp1
(2) modify ppp0 to ppp1,
Modify PIDFILE =/var/run/pppoe-adsl.pid to PIDFILE =/var/run/pppoe-adsl1.pid
Modify the Nic of the new connection path, for example, ETH = eth1 to ETH = eth2.
(3) add the account and password for the new line. the account and password are generally stored in/etc/ppp/chap-secrets and pap-secrets.
We only need to add the new username 2 and password 2 at the end.
The/etc/ppp/chap-secrets file is generally like this:
# Secrets for authentication using CHAP
# Client server secret IP addresses
"Username 1" * "Password 1"
"Username 2" * "password 2"
"Username n" * "password n"
[1] [2] Next page