LINUX.ORG.RU

Vpn соединение в Salix

 , , , ,


0

1

У меня vpn подключение к интернету. В установленном wicd к впн не подключиться, networkmanager устанавливать в слакваре довольно геморройно, поэтому решил через терминал.

Установил pptp 1.72, pppd был уже установлен. Содержимое /etc/ppp/peers/vpn:

name 1038
remotename PPTP
debug
lock
deflate 0
defaultroute
pty "pptp 192.168.100.100 --nolaunchpppd"

Содержимое /etc/ppp/options.pptp:

###############################################################################
# $Id: options.pptp,v 1.3 2006/03/26 23:11:05 quozl Exp $
#
# Sample PPTP PPP options file /etc/ppp/options.pptp
# Options used by PPP when a connection is made by a PPTP client.
# This file can be referred to by an /etc/ppp/peers file for the tunnel.
# Changes are effective on the next connection.  See "man pppd".
#
# You are expected to change this file to suit your system.  As
# packaged, it requires PPP 2.4.2 or later from http://ppp.samba.org/
# and the kernel MPPE module available from the CVS repository also on
# http://ppp.samba.org/, which is packaged for DKMS as kernel_ppp_mppe.
###############################################################################

# Lock the port
lock

# Authentication
# We don't need the tunnel server to authenticate itself
auth

# We won't do PAP, EAP, CHAP, or MSCHAP, but we will accept MSCHAP-V2
# (you may need to remove these refusals if the server is not using MPPE)
refuse-pap
refuse-eap
refuse-chap
refuse-mschap
refuse-mschap-v2

# Compression
# Turn off compression protocols we know won't be used
nobsdcomp
nodeflate

# Encryption
# (There have been multiple versions of PPP with encryption support,
# choose with of the following sections you will use.  Note that MPPE
# requires the use of MSCHAP-V2 during authentication)

# http://ppp.samba.org/ the PPP project version of PPP by Paul Mackarras
# ppp-2.4.2 or later with MPPE only, kernel module ppp_mppe.o
# {{{
# Require MPPE 128-bit encryption
#require-mppe-128
# }}}

# http://polbox.com/h/hs001/ fork from PPP project by Jan Dubiec
# ppp-2.4.2 or later with MPPE and MPPC, kernel module ppp_mppe_mppc.o
# {{{
# Require MPPE 128-bit encryption
#mppe required,stateless
# }}}

mtu 1000
mru 1000
deflate 0
defaultroute

В /etc/ppp/chap-secrets написал 1038 * «пароль» *

В терминале набираю pppd call vpn (от рута) В интернет не заходит. Но на сайт провайдера заходит. То есть не получается залогиниться, как я понимаю. На винде также, если воткнуть кабель и не подключаться, то можно зайти на сайт провайдера, но в интернет нет.

Вобщем, прошу помочь разобраться с этим.


Ответ на: комментарий от nixtrian

В debug:

Mar 26 12:38:29 darkstar pppd[2335]: using channel 1
Mar 26 12:38:30 darkstar pppd[2335]: sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4a80ce0c> <pcomp> <accomp>]
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [LCP ConfReq id=0x1 <mru 1460> <magic 0xdb9b62c4> <auth chap MD5>]
Mar 26 12:38:31 darkstar pppd[2335]: sent [LCP ConfAck id=0x1 <mru 1460> <magic 0xdb9b62c4> <auth chap MD5>]
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [LCP ConfRej id=0x1 <pcomp> <accomp>]
Mar 26 12:38:31 darkstar pppd[2335]: sent [LCP ConfReq id=0x2 <asyncmap 0x0> <magic 0x4a80ce0c>]
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [LCP ConfAck id=0x2 <asyncmap 0x0> <magic 0x4a80ce0c>]
Mar 26 12:38:31 darkstar pppd[2335]: sent [LCP EchoReq id=0x0 magic=0x4a80ce0c]
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [CHAP Challenge id=0x1 <bb1e684a1d1af3d01bb123050ae050f75294b4027eca34f84581732d7f5032152d875f4aa1>, name = ""]
Mar 26 12:38:31 darkstar pppd[2335]: sent [CHAP Response id=0x1 <430c46dfcb65dfef6a8efce910b98a5d>, name = "1038"]
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [LCP EchoRep id=0x0 magic=0xdb9b62c4]
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [CHAP Success id=0x1 "Welcome"]
Mar 26 12:38:31 darkstar pppd[2335]: sent [CCP ConfReq id=0x1 <bsd v1 15>]
Mar 26 12:38:31 darkstar pppd[2335]: sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0>]
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [IPCP ConfReq id=0x1 <addr 10.100.0.5>]
Mar 26 12:38:31 darkstar pppd[2335]: sent [IPCP ConfAck id=0x1 <addr 10.100.0.5>]
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [LCP ProtRej id=0x1 80 fd 01 01 00 07 15 03 2f]
Mar 26 12:38:31 darkstar pppd[2335]: Protocol-Reject for 'Compression Control Protocol' (0x80fd) received
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [IPCP ConfRej id=0x1 <compress VJ 0f 01>]
Mar 26 12:38:31 darkstar pppd[2335]: sent [IPCP ConfReq id=0x2 <addr 0.0.0.0>]
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [IPCP ConfNak id=0x2 <addr 81.30.58.37>]
Mar 26 12:38:31 darkstar pppd[2335]: sent [IPCP ConfReq id=0x3 <addr 81.30.58.37>]
Mar 26 12:38:31 darkstar pppd[2335]: rcvd [IPCP ConfAck id=0x3 <addr 81.30.58.37>]
Mar 26 12:38:32 darkstar ntpd[1869]: new interface(s) found: waking up resolver

В messages:

Mar 26 12:38:29 darkstar kernel: [  130.940362] PPP generic driver version 2.4.2
Mar 26 12:38:29 darkstar pppd[2335]: pppd 2.4.5 started by root, uid 0
Mar 26 12:38:29 darkstar pppd[2335]: Using interface ppp0
Mar 26 12:38:29 darkstar pppd[2335]: Connect: ppp0 <--> /dev/pts/1
Mar 26 12:38:29 darkstar pptp[2336]: anon log[main:pptp.c:314]: The synchronous pptp option is NOT activated 
Mar 26 12:38:30 darkstar pptp[2342]: anon log[ctrlp_rep:pptp_ctrl.c:251]: Sent control packet type is 1 'Start-Control-Connection-Request' 
Mar 26 12:38:30 darkstar pptp[2342]: anon log[ctrlp_disp:pptp_ctrl.c:739]: Received Start Control Connection Reply
Mar 26 12:38:30 darkstar pptp[2342]: anon log[ctrlp_disp:pptp_ctrl.c:773]: Client connection established.
Mar 26 12:38:31 darkstar pptp[2342]: anon log[ctrlp_rep:pptp_ctrl.c:251]: Sent control packet type is 7 'Outgoing-Call-Request' 
Mar 26 12:38:31 darkstar pptp[2342]: anon log[ctrlp_disp:pptp_ctrl.c:858]: Received Outgoing Call Reply.
Mar 26 12:38:31 darkstar pptp[2342]: anon log[ctrlp_disp:pptp_ctrl.c:897]: Outgoing call established (call ID 0, peer's call ID 56102). 
Mar 26 12:38:31 darkstar pppd[2335]: CHAP authentication succeeded: Welcome
Mar 26 12:38:31 darkstar pppd[2335]: CHAP authentication succeeded
Mar 26 12:38:31 darkstar kernel: [  132.103621] PPP BSD Compression module registered
Mar 26 12:38:31 darkstar pppd[2335]: local  IP address 81.30.58.37
Mar 26 12:38:31 darkstar pppd[2335]: remote IP address 10.100.0.5
Mar 26 12:38:32 darkstar ntpd[1869]: Listen normally on 6 ppp0 81.30.58.37 UDP 123
Mar 26 12:38:32 darkstar ntpd[1869]: peers refreshed
Mar 26 12:39:28 darkstar ntfs-3g[2367]: Version 2012.1.15 integrated FUSE 27 
Mar 26 12:39:28 darkstar ntfs-3g[2367]: Mounted /dev/sda2 (Read-Write, label "Acer", NTFS 3.1) 
Mar 26 12:39:28 darkstar ntfs-3g[2367]: Cmdline options: rw,nosuid,nodev,uhelper=udisks2,uid=1000,gid=100,dmask=0077,fmask=0177 
Mar 26 12:39:28 darkstar ntfs-3g[2367]: Mount options: rw,nosuid,nodev,uhelper=udisks2,allow_other,nonempty,relatime,fsname=/dev/sda2,blkdev,blksize=4096,default_permissions 
Mar 26 12:39:28 darkstar ntfs-3g[2367]: Global ownership and permissions enforced, configuration type 1 
Mar 26 12:39:28 darkstar udisksd[2253]: Mounted /dev/sda2 at /run/media/artur/Acer on behalf of uid 1000
Mar 26 12:39:31 darkstar pptp[2342]: anon log[logecho:pptp_ctrl.c:677]: Echo Request received.
Mar 26 12:39:31 darkstar pptp[2342]: anon log[ctrlp_rep:pptp_ctrl.c:251]: Sent control packet type is 6 'Echo-Reply' 
Mar 26 12:39:31 darkstar pptp[2342]: anon log[logecho:pptp_ctrl.c:677]: Echo Reply received.

ArturK ()

Судя по логам соединение установилось. Провайдер не выдал DNS, но и в конфиге usepeerdns не было, осталось выяснить, остаются ли они доступны. Что говорят после установки соединения:

# ifconfig ppp0
# route
# cat /etc/resolv.conf
# ping -c4 8.8.8.8
# ping -c4 $DNS
где $DNS — ip из строк nameserver из /etc/resolv.conf?

bormant ★★★★★ ()
Последнее исправление: bormant (всего исправлений: 1 )
Вы не можете добавлять комментарии в эту тему. Тема перемещена в архив.