home | tech | misc | code | bookmarks (broken) | contact | README

# PPPoE connection with pppoectl

Some computers don't come with more high-level interfaces for connecting to the internet. NetBSD, for example, comes with the pppoectl(8) program, that you can use to make a connection with your DSP.

pppoectl man page is a very good resource to start with. Here I documented, similarly to the man page, how to connect to the local DSP, in this case, the brazilian Speedy (Telefonica), using a NetBSD box.

We suppose our local network interface is fxp0, which is unconfigured. We also need a pppoe0 interface, so let's create it:

# ifconfig pppoe0 create


Then, let pppoe0 use fxp0 as its ethernet device:

# pppoectl -e fxp0 pppoe0


Next, we just need to configure our PPPoE connection. We know that the authentication method to connect to Speedy (Telefonica) is PAP:

# pppoectl pppoe0 \
myauthproto=pap \


The man page show other options and even use one called hisauthproto, but we don't need it. The options shown above seem enough.

Finally we just configure the pppoe0 interface and let the remote ppp chose its address (passing 0.0.0.0 0.0.0.1):

# ifconfig pppoe0 0.0.0.0 0.0.0.1 netmask 0xffffffff up


# echo 'nameserver 8.8.8.8' > /etc/resolv.conf

# route delete default