PDA

View Full Version : cấu hình VPN bị lổi! không hiểu tại sao?giải thích dùm



hoangdien900
22-05-2011, 05:34 PM
http://farm3.anhso.net/upload/20110522/17/o/anhso-172756_vpn.jpg
cau hinh:
-cac router khac cau hinh ket noi voi nhau.(có thể ping với nhau)
R2
en
conf t
hostname R2

int f0/1
ip add 193.1.1.1 255.255.255.0
no shut

int f0/0
ip add 192.1.1.1 255.255.255.0
no shut
exit

ip route 0.0.0.0 0.0.0.0 193.1.1.2
ip route 193.1.2.0 255.255.255.0 193.1.2.1


crypto isakmp policy 1
authentication pre-share
hash sha
encryption aes 128
group 2
exit


crypto isakmp key 123 address 193.1.2.1 255.255.255.255


crypto ipsec transform-set myset esp-aes 128 esp-sha-hmac

crypto map name 10 ipsec-isakmp
set peer 193.1.2.1
set transform-set myset
match address 101
access-list 101 permit ip 192.1.1.0 0.0.0.255 192.1.2.0 0.0.0.255

int f0/1
crypto map name

R3:

en
conf t
hostname R3

int s1/0
ip add 193.1.2.1 255.255.255.0
no shut

int f0/0
ip add 192.1.2.1 255.255.255.0
no shut
exit


ip route 0.0.0.0 0.0.0.0 193.1.2.2
ip route 193.1.1.0 255.255.255.0 193.1.1.1


crypto isakmp policy 1
authentication pre-share
hash sha
encryption aes 128
group 2
exit

crypto isakmp key 123 address 193.1.1.1 255.255.255.255

crypto ipsec transform-set myset esp-aes 128 esp-sha-hmac


crypto map name 10 ipsec-isakmp
set peer 193.1.1.1
set transform-set myset
match address 101
access-list 101 permit ip 192.1.1.0 0.0.0.255 192.1.2.0 0.0.0.255


int s1/0
crypto map name


--------------------------> sau khi kết nối xong thì 2 máy pc không thể ping với nhau được ,cứ bị access-list chặng? không hiểu cấu hình sai chổ nào,hay thiếu chổ nào? hướng dẩn và giải thích dùm.cảm ơn
http://farm3.anhso.net/upload/20110522/17/o/anhso-173822_untitled.jpg

lamvantu
22-05-2011, 11:24 PM
Hi bạn, mình nghĩ lỗi chỗ này nè bạn: ( Crypto ACL phải được xây dựng 1 cách đối xứng ở 2 đầu VPN gateway.)
Trên R3:
access-list 101 permit ip 192.1.1.0 0.0.0.255 192.1.2.0 0.0.0.255
Sửa lại là:
access-list 101 permit ip 192.1.2.0 0.0.0.255 192.1.1.0 0.0.0.255
Thử nha bạn. Thank bạn.