HOWTO:Ubuntu下VPN解决方案 (pptp方法更新在63楼,l2tp+ipsec方法在145楼)
-
- 帖子: 15
- 注册时间: 2007-07-22 22:07
- 来自: zhejiang
-
- 帖子: 15
- 注册时间: 2007-07-22 22:07
- 来自: zhejiang
- rhfcaesar
- 帖子: 2996
- 注册时间: 2005-11-17 15:45
- 来自: 湖北
feisty下的方法:
1. 安装附件里的包。
2. sudo apt-get remove network-manager network-manager-gnome
3. sudo pico /etc/ppp/peers/vpnnet, 添加:
4. sudo pico /etc/ppp/options.pptp, 注释掉 require-mppe-128
5. sudo pico /etc/ppp/pap-secrets, 在最后一行添加:
youruserID PPTP yourpassword
##注意:如果认证方式是chap,那么就编辑chap-secrets文件,而不是pap-secrets。
6. 启动:
sudo pon vpnnet
7. 关闭:
sudo poff vpnnet[/code]
1. 安装附件里的包。
2. sudo apt-get remove network-manager network-manager-gnome
3. sudo pico /etc/ppp/peers/vpnnet, 添加:
代码: 全选
pty "pptp vpn.classnet.cuhk.edu.hk --nolaunchpppd"
##注意: vpn.classnet.cuhk.edu.hk换成你自己的VPN服务器地址
file /etc/ppp/options.pptp
remotename PPTP
persist
defaultroute
usepeerdns
name youruserID
5. sudo pico /etc/ppp/pap-secrets, 在最后一行添加:
youruserID PPTP yourpassword
##注意:如果认证方式是chap,那么就编辑chap-secrets文件,而不是pap-secrets。
6. 启动:
sudo pon vpnnet
7. 关闭:
sudo poff vpnnet[/code]
- 附件
-
- pptp-linux_1.7.0-2ubuntu2_i386.deb
- (40.98 KiB) 已下载 1007 次
上次由 rhfcaesar 在 2007-10-20 22:22,总共编辑 3 次。
-
- 帖子: 900
- 注册时间: 2006-11-23 13:04
- iridiumcao
- 帖子: 245
- 注册时间: 2007-01-18 18:05
- 来自: Shanghai
- 联系:
- rhfcaesar
- 帖子: 2996
- 注册时间: 2005-11-17 15:45
- 来自: 湖北
- rhfcaesar
- 帖子: 2996
- 注册时间: 2005-11-17 15:45
- 来自: 湖北
- jude511
- 帖子: 22
- 注册时间: 2007-08-25 23:56
[问题]
********************************************************************************************************
Do you want to continue [Y/n]? y
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = "en_US:en",
LC_ALL = (unset),
LC_CTYPE = "zh_CH.UTF-8",
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
(Reading database ... 116017 files and directories currently installed.)
Removing network-manager ...
* Stopping network connection manager NetworkManager [ OK ]
* Stopping network events dispatcher NetworkManagerDispatcher [ OK ]
********************************************************************************************************
楼主,我在执行第二条指令时,出现以上对话。是不是跟lc有关,我该怎样设置?
Do you want to continue [Y/n]? y
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = "en_US:en",
LC_ALL = (unset),
LC_CTYPE = "zh_CH.UTF-8",
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
(Reading database ... 116017 files and directories currently installed.)
Removing network-manager ...
* Stopping network connection manager NetworkManager [ OK ]
* Stopping network events dispatcher NetworkManagerDispatcher [ OK ]
********************************************************************************************************
楼主,我在执行第二条指令时,出现以上对话。是不是跟lc有关,我该怎样设置?
- rhfcaesar
- 帖子: 2996
- 注册时间: 2005-11-17 15:45
- 来自: 湖北
-
- 帖子: 5
- 注册时间: 2007-08-28 16:41
Re: [问题]
樓主您好
我是採用pptpconfig設定連線
我的錯誤訊息如下
Using interface ppp0
pptpconfig: monitoring interface ppp0
Connect: ppp0 <--> /dev/pts/1
PAP authentication succeeded
Could not determine remote IP address: defaulting to 10.64.64.64 #這remote ip 上哪去改預設值呀?
Cannot determine ethernet address for proxy ARP
local IP address 192.168.202.11
remote IP address 10.64.64.64
primary DNS address 168.95.1.1
secondary DNS address 168.95.192.1
pptpconfig: pppd process exit status 0 (started)
ip route replace 202.39.48.161 via 192.168.1.1 dev eth1 src 192.168.1.5
pptpconfig: routes added to remote networks
ip route replace default dev 'ppp0'
Cannot find device "ppp0"
pptpconfig: command failed, exit code 255 #這東西不知道哪裡有可以查對照知道是什麼錯誤的??
pptpconfig: default route changed to use tunnel
pptpconfig: DNS changes made to /etc/resolv.conf
pptpconfig: connected
勞煩解答
感激不盡
我是採用pptpconfig設定連線
我的錯誤訊息如下
Using interface ppp0
pptpconfig: monitoring interface ppp0
Connect: ppp0 <--> /dev/pts/1
PAP authentication succeeded
Could not determine remote IP address: defaulting to 10.64.64.64 #這remote ip 上哪去改預設值呀?
Cannot determine ethernet address for proxy ARP
local IP address 192.168.202.11
remote IP address 10.64.64.64
primary DNS address 168.95.1.1
secondary DNS address 168.95.192.1
pptpconfig: pppd process exit status 0 (started)
ip route replace 202.39.48.161 via 192.168.1.1 dev eth1 src 192.168.1.5
pptpconfig: routes added to remote networks
ip route replace default dev 'ppp0'
Cannot find device "ppp0"
pptpconfig: command failed, exit code 255 #這東西不知道哪裡有可以查對照知道是什麼錯誤的??
pptpconfig: default route changed to use tunnel
pptpconfig: DNS changes made to /etc/resolv.conf
pptpconfig: connected
勞煩解答
感激不盡