I am using 8 M broadband for China Telecom, and the Internet is also expensive. Record the network configuration process of CentOS 6.4. The following statements are executed with the root permission. Enter the su press enter in the command line and enter the root password to use the root permission.
--------------------------------------------------------------------------------
First, put disc 1 into the optical drive. Then, execute the following command:
Mount/dev/cdrom/mnt
Cd/mnt
Rpm-ivh ppp * rp-pppo *
After installation, continue.
[Root @ localhost ~] # Pppoe-setup --------------- install PPPOE here
Welcome to the PPPoE client setup. First, I will run some checks on
Your system to make sure the PPPoE client is installed properly...
LOGIN NAME
Enter your Login Name (default root): xy170638010214 --------------- Enter the Internet dialing account here
INTERFACE
Enter the Ethernet interface connected to the PPPoE modem
For Solaris, this is likely to be something like/dev/hme0.
For Linux, it will be ethX, where 'x' is a number.
(Default eth0): --------------- press the Enter key here (select the correct Nic. If you connect to the computer through a network cable, select eth0, however, if you use a wireless connection router, select wlan0. I didn't select the network adapter at the beginning. As a result, when the adsl-start is last executed, an error is returned:/usr/sbin/adsl-start: line 217: 4044 Terminated $ CONNECT "$ @">/dev/null 2> & 1, where 4044 seems to change every time, and some are later than 3907. Note .)
Do you want the link to come up on demand, or stay up continuously?
If you want it to come up on demand, enter the idle time in seconds
After which the link shoshould be dropped. If you want the link
Stay up permanently, enter 'no' (two letters, lower-case .)
NOTE: Demand-activated links do not interact well with dynamic IP
Addresses. You may have some problems with demand-activated links.
Enter the demand value (default no): --------------- press Enter here
DNS
Please enter the IP address of your ISP's primary DNS server.
If your ISP claims that 'the server will provide dynamic DNS address ',
Enter 'server' (all lower-case) here.
If you just press enter, I will assume you know what you areppp
Doing and not modify your DNS setup.
Enter the DNS information here: --------------- Enter the server here to automatically obtain the DNS
PASSWORD
Please enter your Password: ---------------
Enter the Internet dialing Password
Please re-enter your Password: --------------- enter the Internet dialing Password here
USERCTRL
Please enter 'yes' (three letters, lower-case.) if you want to allow
Normal user to start or stop DSL connection (default yes): --------------- enter yes
FIREWALLING
Please choose the firewall rules to use. Note that these rules are
Very basic. You are strongly encouraged to use a more sophisticated NTHQB198529CFO
Firewall setup; however, these will provide basic security. If you
Are running any servers on your machine, you must choose 'none' and
Set up firewalling yourself. Otherwise, the firewall rules will deny
Access to all standard servers like Web, e-mail, ftp, etc. If you
Are using SSH, the rules will block outgoing SSH connections which
Allocate a privileged source port.
The firewall choices are:
0-NONE: This script will not set any firewall rules. You are responsible
For ensuring the security of your machine. You are STRONGLY
Recommended to use some kind of firewall rules.
1-STANDALONE: Appropriate for a basic stand-alone web-surfing workstation
2-MASQUERADE: Appropriate for a machine acting as an Internet gateway
For a LAN
Choose a type of firewall (0-2): 0 --------------- enter 0 here
Start this connection at boot time
Do you want to start this connection at boot time?
Please enter no or yes (default no): y --------------- enter y
** Summary of what you entered **
Ethernet Interface: eth0
User name: xy170638010214
Activate-on-demand: No
DNS addresses: Supplied by ISP's server
Firewalling: NONE
User Control: yes
Accept these settings and adjust configuration files (y/n )? Y --------------- enter y
Adjusting/etc/sysconfig/network-scripts/ifcfg-ppp0
Adjusting/etc/ppp/chap-secrets and/etc/ppp/pap-secrets
(But first backing it up to/etc/ppp/chap-secrets.bak)
(But first backing it up to/etc/ppp/pap-secrets.bak)
Congratulations, it shocould be all set up!
Type '/sbin/ifup ppp0' to bring up your xDSL link and '/sbin/ifdown ppp0'
To bring it down.
Type '/sbin/pppoe-status/etc/sysconfig/network-scripts/TS'
To see the link status.
[Root @ localhost ~] # Pppoe-start --------------- after the PPPOE device is activated, the system automatically returns the result
[Root @ localhost ~] # (This indicates that the link is successful. If it fails, an error is returned .)
[Root @ localhost ~] # Pppoe-status ------------- view the PPPOE status
Pppoe-status: Link is up and running on interface ppp0
6: ppp0: mtu 1492 qdisc pfifo_fast state UNKNOWN qlen 3
Link/ppp
Inet 113.14.36.24 peer 113.14.32.1/32 scope global ppp0 --------------- the IP address is assigned to you. You can see that you have successfully logged on to this account. We can ping the Baidu IP address to see if it is okay, so we can go online.
[Root @ localhost ~] # Ping 121.14.88.14
PING 121.14.88.14 (121.14.88.14) 56 (84) bytes of data.
64 bytes from 121.14.88.14: icmp_seq = 1 ttl = 54time = 17.7 MS
64 bytes from 121.14.88.14: icmp_seq = 2 ttl = 54 time = 17.7 MS
64 bytes from 121.14.88.14: icmp_seq = 3 ttl = 54time = 17.6 MS
64 bytes from 121.14.88.14: icmp_seq = 4 ttl = 54time = 17.7 MS
64 bytes from 121.14.88.14: icmp_seq = 5 ttl = 54 time = 17.7 MS
^ C64 bytes from 121.14.88.14: icmp_seq = 6 ttl = 54 time = 17.6 MS
64 bytes from 121.14.88.14: icmp_seq = 7 ttl = 54 time = 17.7 MS
64 bytes from 121.14.88.14: icmp_seq = 8 ttl = 54 time = 17.6 MS
64 bytes from 121.14.88.14: icmp_seq = 9 ttl = 54 time = 17.7 MS
64 bytes from 121.14.88.14: icmp_seq = 10 ttl = 54 time = 17.7 MS
64 bytes from 121.14.88.14: icmp_seq = 11 ttl = 54 time = 17.7 MS
64 bytes from 121.14.88.14: icmp_seq = 12 ttl = 54 time = 17.7 MS
^ C64 bytes from 121.14.88.14: icmp_seq = 13 ttl = 54 time = 18.1 MS
64 bytes from 121.14.88.14: icmp_seq = 14 ttl = 54 time = 17.6 MS
64 bytes from 121.14.88.14: icmp_seq = 15 ttl = 54 time = 17.6 MS
^ C ^ X64 bytes from 121.14.88.14: icmp_seq = 16 ttl = 54 time = 17.6 MS
^ X ^ C
--- 121.14.88.14 ping statistics ---
16 packets transmitted, 16 bytes ed, 0% packet loss, time 15895 ms
Rtt min/avg/max/mdev = 17.675/17.744/18.170/0.175 MS
[Root @ localhost ~] # Pppoe-status
Pppoe-status: Link is up and running on interface ppp0
6: ppp0: mtu 1492 qdisc pfifo_fast state UNKNOWN qlen 3
Link/ppp
Inet 113.14.36.24 peer 113.14.32.1/32 scope global ppp0
[Root @ localhost ~] #
The following are the basic operations on PPPOE:
Usage:
Dial-up Internet access pppoe-start
Block-open Internet access pppoe-stop
View pppoe-status