I was following this tutorial to configure a pptp connection between my centos 6 VPS and my fedora 22 workstation. There's only one thing I did different from that tutorial: I installed pptpd from the epel repository instead of the link provided.
I added the following rules to my iptables following the tutorial:
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE && iptables-save
iptables --table nat --append POSTROUTING --out-interface ppp0 -j MASQUERADE
iptables -I INPUT -s 10.0.0.0/8 -i ppp0 -j ACCEPT
iptables --append FORWARD --in-interface eth0 -j ACCEPT
I also added the following rule to make sure my farewall is not blocking my connection request:
iptables -A INPUT -s XXX.XXX.XXX.XXX -j ACCEPT
Where XXX.XXX.XXX.XXX is my workstation public fixed ipv4.
When i run:
pppd call pptpserver
ip route add 10.0.0.0/8 dev ppp0
I get RTNETLINK answers: Network is down
for a few tries the I get Cannot find device "ppp0"
.
From journalctl -f
I get:
pppd[7632]: pppd 2.4.5 started by user, uid 0
pppd[7632]: Using interface ppp0
pppd[7632]: Connect: ppp0 <--> /dev/pts/5
NetworkManager[1186]: <info> (ppp0): new Generic device (driver: 'unknown' ifindex: 15)
NetworkManager[1186]: <info> (ppp0): exported as /org/freedesktop/NetworkManager/Devices/14
pptp[7633]: anon log[main:pptp.c:333]: The synchronous pptp option is NOT activated
NetworkManager[1186]: <info> (ppp0): No existing connection detected.
pptp[7640]: anon log[ctrlp_rep:pptp_ctrl.c:258]: Sent control packet type is 1 'Start-Control-Connecti...equest'
pptp[7640]: anon log[ctrlp_disp:pptp_ctrl.c:758]: Received Start Control Connection Reply
pptp[7640]: anon log[ctrlp_disp:pptp_ctrl.c:792]: Client connection established.
pptp[7640]: anon log[ctrlp_rep:pptp_ctrl.c:258]: Sent control packet type is 7 'Outgoing-Call-Request'
pptp[7640]: anon log[ctrlp_disp:pptp_ctrl.c:877]: Received Outgoing Call Reply.
pptp[7640]: anon log[ctrlp_disp:pptp_ctrl.c:916]: Outgoing call established (call ID 0, peer's call ID 256).
A few secounds later:
pppd[7632]: LCP: timeout sending Config-Requests
pppd[7632]: Connection terminated.
avahi-daemon[874]: Withdrawing workstation service for ppp0.
gnome-session[2254]: Gjs-Message: JS LOG: Removing a network device that was not added
pppd[7632]: Modem hangup
pptp[7633]: anon warn[decaps_hdlc:pptp_gre.c:220]: short read (-1): Input/output error
pptp[7633]: anon warn[decaps_hdlc:pptp_gre.c:232]: pppd may have shutdown, see pppd log
pppd[7632]: Exit.
pptp[7640]: anon log[callmgr_main:pptp_callmgr.c:245]: Closing connection (unhandled)
pptp[7640]: anon log[ctrlp_rep:pptp_ctrl.c:258]: Sent control packet type is 12 'Call-Clear-Request'
pptp[7640]: anon log[call_callback:pptp_callmgr.c:84]: Closing connection (call state)
Does anybody has any clue what is wrong with my connection? Is it in my workstation or on the server?
Thanks
Turn off and clear iptables and perform a connection test. If it works, more than likely you don't have to proper iptables config to make pptp work.
If it works with iptables cleared and disabled, then you should probably read this: PPTP IPTables routing issue