Sign up ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I've a Debian machine with this network scenario:

  1. eth0 - Internet Connection via local Router (172.20.1.x)
  2. ppp0 - Dial-up to a network without internet (10.x.x.x)

I've set pppd so it won't add any default routes to my routing table and my routing table looks like this after booting up the system:

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface         UG    0      0        0 eth0 UH    0      0        0 ppp0   U     0      0        0 eth0

With this configuration I'm able to ping, however I can't get to any machine with IP's like or etc...

Trying to fix this (with my poor knowledge) I modified my /etc/network/interfaces file to:

auto lo

iface lo inet loopback
iface eth0 inet dhcp

auto ppp0 
iface ppp0 inet ppp
    pre-up sleep 5
    provider vfp
    post-up  /sbin/route add -net netmask gw
    pre-down  /sbin/route del -net netmask gw

But apparently the command post-up /sbin/route add -net netmask gw that should add the route to make it work is not taking effect—nothing is changing on the routing table.

What am I missing? / How can I fix this? Thank you ;)

PS: If i run route add -net netmask gw after the system boots up I'm able to ping both and from the system.

share|improve this question

1 Answer 1

up vote 1 down vote accepted

to add or remove routes for ppp connections I don't use the interfaces file. I add scripts in /etc/ppp/ip-up.d and /etc/ppp/ip-down.d respectively instead. You simply can place scripts there with your route commands.

share|improve this answer
Testing now... Thx for the feedback ;) – TCB13 Jan 13 '13 at 5:10
Working just fine ;) ty! – TCB13 Jan 13 '13 at 5:15

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.