# PPP: unrecognized option 'eth0' [SOLVED]

## Darkshine

I had a home router based on Gentoo Linux using 2.6.28 kernel on x86. The router had a eth1 interface with ppp0 started inside it. Everyting had been working fine. I replaced that router by another one based on Gentoo Linux 2.6.24 kernel on x86_64 (amd64), moved the configurtaion settings from old to the new router and tried to start a ppp0 on a new machine. It fails with very strange mesage:

```
$ /etc/init.d/net.ppp0 start

* Bringing up interface ppp0

*   Starting pppd in ppp0...

/usr/sbin/pppd: unrecognized option 'eth0'

pppd version 2.4.4

Usage: /usr/sbin/pppd [ options ], where options are:

        <device>        Communicate over the named device

        <speed>         Set the baud rate to <speed>

        <loc>:<rem>     Set the local and/or remote interface IP

                        addresses.  Either one may be omitted.

        asyncmap <n>    Set the desired async map to hex <n>

        auth            Require authentication from peer

        connect <p>     Invoke shell command <p> to set up the serial line

        crtscts         Use hardware RTS/CTS flow control

        defaultroute    Add default route through interface

        file <f>        Take options from file <f>

        modem           Use modem control lines

        mru <n>         Set MRU value to <n> for negotiation

See pppd(8) for more options.

*   start-stop-daemon: failed to start `/usr/sbin/pppd'

*   Failed to start PPP                                                                                               [ !! ]

* WARNING: net.ppp0 not under our control, aborting
```

I have net-dialup/ppp at the same versions (2.4.4-r21) on old and new machines, the ppp-related settings are equal:

/etc/conf.d/net:

```
config_eth0=( "10.100.102.50 netmask 255.255.0.0 brd 10.100.255.255" )

mac_eth0="00:1e:8c:7a:c6:e3"

dns_servers_eth0="<dns server>"

config_ppp0=( "ppp" )

link_ppp0="eth0"

plugins_ppp0=( "pppoe" )

username_ppp0='<user>'

password_ppp0='<password>'

pppd_ppp0=(

       "noauth"

       "defaultroute"

       "usepeerdns"

       "holdoff 3"

       "child-timeout 60"

       "lcp-echo-interval 15"

       "lcp-echo-failure 3"

       noaccomp noccp nobsdcomp nodeflate nopcomp novj novjccomp debug

)

depend_ppp0() {

    need net.eth0

}

```

On a new machine I use eth0 for ppp0. The eth0 interface is up and running and I can ping provider's server. It seems something is incorrect in /etc/init.d/net script. I tried to debug it  - the script fails in start() function in the cycle of loading modules. It loads few modules successfully and fails when loading "pppd_pre_start" module. I don't know is it kernel's or some runscript's module.

I have all necessary PPP modules loaded in the kernel on a both machines (I checked with "lsmod | grep ppp"), the openrc portage on a new machines is at a latest version. What is wrong? Do you need any other info to check?

I saw the similar problems on the forum, but I still don't know how to fix this one.

https://forums.gentoo.org/viewtopic-t-690654.html

https://forums.gentoo.org/viewtopic-t-493456.htmlLast edited by Darkshine on Thu Oct 15, 2009 10:14 pm; edited 1 time in total

----------

## user

Hi Darkshine,

possible pppd options are broken. Replace temp. /usr/sbin/pppd by a wrapper script and catch all options that was piping to /usr/sbin/pppd.

```
#!/bin/sh

echo $@

/usr/sbin/pppd.real $@

```

pppd options should look like

```
/usr/sbin/pppd unit 0 user <username> ppp0 linkname ppp0 lock updetach persist holdoff 1 defaultroute noauth lcp-echo-interval 60 hide-password maxfail 0 connect true plugin rp-pppoe.so eth0

```

----------

## Darkshine

Thank you for the comment. Actually, I found that CONFIG_PACKET option is not set in my kernel. I enabled it and also CONFIG_PACKET_MMAP just to be sure that all network packet-related functionalities are enabled in the kernel. I have recompiled it and now ppp works fine.

I believe that CONFIG_PACKET option should be described in the gentoo handbook somehow. I found in the handbook that CONFIG_PACKET option is necessary for the WPA supplicant, but there are no information that it is needed for PPP. It is just my thoughts, I don't know if this kernel option is applicable for the newest kernels.

----------

## mrness

Fixed in net-dialup/ppp-2.4.4-r24 postinst() by displaying a warning about missing CONFIG_PACKET.

----------

## Darkshine

 *mrness wrote:*   

> Fixed in net-dialup/ppp-2.4.4-r24 postinst() by displaying a warning about missing CONFIG_PACKET.

 

thanks.

----------

