DD_WRT PPTP VPN konekcija

poruka: 3
|
čitano: 2.361
|
moderatori: pirat, XXX-Man, DrNasty, vincimus
1
+/- sve poruke
ravni prikaz
starije poruke gore
13 godina
neaktivan
offline
DD-WRT PPTP VPN konekcija

Imam slijedecu situaciju Na dvije udaljene lokacije postavljena dva DD-WRT routera (na PC Enginesu Alix)  jedan podesen kao PPTP server, a drugi kao PPTP client Na internet spojini sa ADSL modemima od istog ISP provajdera. Moj problem je slijedeći. Svak put kada se promjeni IP adresa od ISP veza mi VPn veza mi pukne i kreirami se ponovo, ali sada mogu samu pingati router, a i ne računara iza routera.Cini mi se da se IP adresa na WAN portovima od ISP-a promjeni istovremeno pošto provjader to salje sa istog servera izgleda. Routere sam podesio prema uputstvo dolje navedenom. kako riješiti problem.

 

This is a guide for creating a point to point VPN using the PPTP client and server, for people unable / bored etc... using the OpenVPN Client

I've made this small code because DD-WRT does not allow you to save a route running on a VPN tunnel on PPTP (or at least i haven't found another way), so there is no route going back from the server network to the client network.

Basically, the guide in the Wiki is fine for creating a VPN using the PPTP server and client parts of DD-WRT. I will not repeat those instructions, since they are fine. Just follow them to setup a PPTP VPN for the following locations. However, with this example only 1 site needs a PPTP server and the other PPTP client.


So, lets say we have 2 locations , LocationA and LocationB
Net details are as follows:
LocationA
Network: 192.168.1.0/24
Router IP: 192.168.1.254

LocationB
Network: 192.168.2.0/24
Router IP: 192.168.2.254

You setup the PPTP Server on LocationA and the PPTP Client on LocationB

However, while all pc's on B will be able to access any pc on A, the other is not possible (yet), because there isn't a route from A to go back to B.

To do this, log on the CLI of DD-WRT, and type the following command:

Code:

nvram set routes='route add -net 192.168.2.0 netmask 255.255.255.0 gw 192.168.2.254'nvram commit
This saves the variable "routes" with a route-add entry
However, we still need to apply this route AFTER the VPN Tunnel is up. To do this, we do the following:

(Again to save)

Code:

nvram set rc_startup='nvram get routes > /tmp/routescat /tmp/pptpd/ip-up /tmp/routes > /tmp/pptpd/ip-tempmv /tmp/pptpd/ip-temp /tmp/pptpd/ip-upchmod 700 /tmp/pptpd/ip-up'nvram commit
This basically runs on every startup, saves the route from the nvram variable to a file, and then adds that line to the last line of the ip-up script that runs when the PPTP server establishes the connection.

Poruka je uređivana zadnji put uto 13.3.2012 22:15 (drasko).
 
0 0 hvala 0
17 godina
offline
DD_WRT PPTP VPN konekcija

Nisam pročitao sve ali ako nemaš fixnu javnu IP adresu nego ti je ISP dinamički dodjeljuje onda bi trebao koristiti servis poput dyndns.org za VPN server.

 

Sori ako si to napisao, letim van pa ću kasnije pročitati sve.

Remember, remember...
 
0 0 hvala 0
13 godina
neaktivan
offline
Re: DD_WRT PPTP VPN konekcija

da postavio sam to na oba routera host NO-IP i to funkcionira. sa tom domenom se uvjek logam i pridružuje se IP broj, ali je problem kod te trenutne imjene IP broja izgubi se na trenutak konekcija i kasnije se opet uspostavi, ali sad ne mogu pingati računare iza NAT-a.

Poruka je uređivana zadnji put uto 13.3.2012 23:23 (drasko).
1
Nova poruka
E-mail:
Lozinka:
 
vrh stranice