2015/06/17

pptpsetup 文字客戶端設定 in CentOS 6


pptpsetup 文字客戶端設定 in CentOS 6

mint-HP-ProBook-4530s shell # pptpsetup --create ppp0 --server ooo.xxx.xxx.ooo --username mtxxx --password 1234xxx --encrypt --start
Connect: ppp0 <--> /dev/pts/5
CHAP authentication succeeded
MPPE 128-bit stateless compression enabled
local  IP address 172.16.15.100
remote IP address 172.16.15.254

mint-HP-ProBook-4530s shell # ifconfig ppp0
ppp0      Link encap:Point-to-Point Protocol  
          inet addr:172.16.15.100  P-t-P:172.16.15.254  Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1496  Metric:1
          RX packets:5 errors:0 dropped:0 overruns:0 frame:0
          TX packets:5 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:3 
          RX bytes:62 (62.0 B)  TX bytes:68 (68.0 B)

# 但是 default route 不對,預設只能內部連線,如果要透過這個 ip 對外有困難。

# 將預設的default 刪除,加入新的 ppp0
mint-HP-ProBook-4530s ppp # route del default
mint-HP-ProBook-4530s ppp # route add default dev ppp0
mint-HP-ProBook-4530s ppp # route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         0.0.0.0         0.0.0.0         U     0      0        0 ppp0
169.254.0.0     0.0.0.0         255.255.0.0     U     1000   0        0 eth0
172.16.15.254   0.0.0.0         255.255.255.255 UH    0      0        0 ppp0
172.17.0.0      0.0.0.0         255.255.0.0     U     0      0        0 docker0
172.24.10.0     0.0.0.0         255.255.255.0   U     0      0        0 eth0
192.168.123.0   0.0.0.0         255.255.255.0   U     0      0        0 eth0


上 myip 網站看看自己對外的 ip
https://www.whatismyip.com/

沒有留言: