在Linux下配置pppoe,一般有以下步骤:

1. 安装pppoe软件。这个不多说,ape-get install pppoe即可。

2. 设置拨号属性:

[cpp] view plain copy

  1. root@ubuntu:~# pppoe-setup 

   详细过程如下:

     用户名:

[cpp] view plain copy

  1. USER NAME 
  2. >>> Enter your PPPoE user name (default test): test 

     接口(网卡):

[cpp] view plain copy

  1. INTERFACE 
  2. >>> Enter the Ethernet interface connected to the DSL modem 
  3. For Solaris, this is likely to be something like /dev/hme0. 
  4. For Linux, it will be ethn, where 'n' is a number. 
  5. (default eth0): eth0 

      dns:

[cpp] view plain copy

  1. >>> Enter the DNS information here: 

      密码:

[cpp] view plain copy

  1. PASSWORD 
  2. >>> Please enter your PPPoE password:     
  3. >>> Please re-enter your PPPoE password:  

      防火墙:

[cpp] view plain copy

  1. The firewall choices are: 
  2. 0 - NONE: This script will not set any firewall rules.  You are responsible 
  3. for ensuring the security of your machine.  You are STRONGLY 
  4.           recommended to use some kind of firewall rules. 
  5. 1 - STANDALONE: Appropriate for a basic stand-alone web-surfing workstation 
  6. 2 - MASQUERADE: Appropriate for a machine acting as an Internet gateway 
  7. for a LAN 
  8. >>> Choose a type of firewall (0-2): 0 

   保存设置:

[cpp] view plain copy

  1. Ethernet Interface: eth0 
  2. User name:          test 
  3. Activate-on-demand: No 
  4. DNS:                Do not adjust 
  5. Firewalling:        NONE 
  6. >>> Accept these settings and adjust configuration files (y/n)? y 

  保存成功了。

[cpp] view plain copy

  1. Congratulations, it should be all set up! 
  2. Type 'pppoe-start' to bring up your PPPoE link and 'pppoe-stop' to bring 
  3. it down.  Type 'pppoe-status' to see the link status. 

3. 开始拨号

[cpp] view plain copy

  1. root@ubuntu:~# pppoe-start 

到了这一步,如果没有问题的话,应该就可以正常连上pppoe服务器了。

但在实际操作时,我遇到了以下两个问题:
问题1:

[cpp] view plain copy

  1. root@ubuntu:~# pppoe-setup 
  2. Welcome to the Roaring Penguin PPPoE client setup.  First, I will run 
  3. some checks on your system to make sure the PPPoE client is installed 
  4. properly... 
  5. Oops, I can't execute the program '/usr/local/sbin/pppd'.  You 
  6. must install the PPP software suite, version 2.3.10 or later. 

原因:目录/usr/local/sbin/没有pppd文件

   解决方法:

将/usr/sbin/pppoe-setup脚本里PPPD=/usr/local/sbin/pppd
     改为PPPD=/usr/sbin/pppd,保存修改后即恢复可正常

问题2:

[cpp] view plain copy

  1. root@ubuntu:~# pppoe-status: Link is down (can't read pppoe PID file /var/run/pppoe.conf-pppoe.pid.pppoe) 

    尝试运行pppoe-connect,出现和问题一类似的错误

原因:同问题1所述

   解决方法和问题1中类似:
     将/usr/sbin/pppoe-connect脚本里PPPD=/usr/local/sbin/pppd
     改为PPPD=/usr/sbin/pppd,保存修改后即恢复可正常

总结:

       在配置pppoe时遇到奇怪的问题,很有可能是有相应的脚本的路径设置不当造成。

Linux下pppoe设置的更多相关文章

  1. MTU介绍以及在windows和linux下怎么设置MTU值

    最大传输单元MTU(Maximum Transmission Unit,MTU)是指一种通信协议的某一层上面所能通过的最大数据包大小(以字节为单位).最大传输单元这个参数通常与通信接口有关(网络接口卡 ...

  2. Linux下如何设置和查看环境变量

    Linux的变量种类 按变量的生存周期来划分,Linux变量可分为两类: 1 永久的:需要修改配置文件,变量永久生效. 2 临时的:使用export命令声明即可,变量在关闭shell时失效. 按作用范 ...

  3. Linux下防火墙设置

    Linux下开启/关闭防火墙命令  1) 永久性生效,重启后不会复原 开启:chkconfigiptables on 关闭:chkconfigiptables off 2) 即时生效,重启后复原 开启 ...

  4. linux下dns设置详解

    DNS就是Domain Name System,它能够把形如www.21php.com这样的域名转换为211.152.50.35这样的IP地址;没有DNS,浏览21php.com这个网站时,就必须用2 ...

  5. linux下mysql设置主从

    一  主服务器修改 mysql的主从设置主要原理是 主数据库开启日志,并且创建从服务器专属账户,从服务器用该账户,读取到日志进行同步 准备两个mysql数据库(如何安装请查看,linux下mysql安 ...

  6. mysql在Linux下大小写敏感设置

    默认情况下,mysql在windows下是不区分大小写的,但是mysql在linux下大小写规则是这样的: 1.数据库名与表名是严格区分大小写的: 2.表的别名是严格区分大小写的: 3.列名与列的别名 ...

  7. 【MySql】linux下,设置mysql表名忽略大小写

    [障碍再现] 状况描述01:     在LINUX下调一个程序经常报出找不到表,但是我明明是建了表的,     测试的时候,遇到一些问题,从Windows平台访问虚拟机中的Web应用,经常报出找不到表 ...

  8. Linux下的设置静态IP命令详解

    网络配置的配置文件在/etc/sysconfig/network-scripts/下,文件名前缀为ifcfg-后面跟的就是网卡的名称,可以通过双TAB键查看然后编辑,也可以使用ifconfig查看,也 ...

  9. linux下定时任务设置

    原文http://www.blogjava.net/freeman1984/archive/2010/09/23/332715.html 觉这篇文章写的挺全的,把它拿过来存在博客里,方便以后查询. 为 ...

随机推荐

  1. USB OTG简单介绍、与普通USB线的差别

    USB有三类接口A类接口                     -----------最常见的扁平接口,四芯  VCC   GND   D+   D- B类接口                    ...

  2. anaconda、pip配置国内镜像

    一.anaconda配置镜像查看源:conda config --show-sources在Mac and Linux下:conda config --add channels https://mir ...

  3. mysqldump参数详细说明

    Mysqldump参数大全(参数来源于mysql5.5.19源码)   参数 参数说明 --all-databases  , -A 导出全部数据库. mysqldump  -uroot -p --al ...

  4. 细思极恐-你真的会写java吗?

    导语 自2013年毕业后,今年已经是我工作的第4个年头了,总在做java相关的工作,终于有时间坐下来,写一篇关于java写法的一篇文章,来探讨一下如果你真的是一个java程序员,那你真的会写java吗 ...

  5. maven打包加时间戳

    基于Maven的项目,发布时需要打包,如tar.gz.web项目打成war格式包.每次打包时希望自己加上时间戳,假如我的项目名是myproject,默认打包后名为myproject.war.而我希望的 ...

  6. Swift3.0:NSURLConnection的使用

    一.介绍 应用中也不必不可少的会使用网络通信,增强客户端和服务器的交互,可以使用NSURLConnection实现http通信. NSURLConnection提供了异步请求和同步请求两种请求方式.同 ...

  7. C#高级编程六十六天----表达式树总结【转】

    https://blog.csdn.net/shanyongxu/article/details/47257139 表达式树总结 基础 表达式树提供了一个将可执行代码转换成数据的方法.如果你要在执行代 ...

  8. [leetcode]Remove Duplicates from Sorted List @ Python

    原题地址:https://oj.leetcode.com/problems/remove-duplicates-from-sorted-list/ 题意: Given a sorted linked ...

  9. ASP.NET网站管理工具的【安全】功能无法使用问题

    在使用ASP.NET网站管理工具时,安全出现下面的问题: 出现这种情况的主要原因是,安全管理中需要创建用户和角色信息,所以要用到数据库,但是你没有设置好数据库. 可以打开vs自带的命令提示工具: 打开 ...

  10. Red Hat Enterprise Linux AS release 4 yum源

    $sudo vim /etc/yum.conf [main] cachedir=/var/cache/yum debuglevel=2 logfile=/var/log/yum.log pkgpoli ...