Debian connected but not take IP

Post your questions about SoftEther VPN software here. Please answer questions if you can afford.
Post Reply
NSlinux
Posts: 5
Joined: Sun Nov 15, 2015 12:32 pm

Debian connected but not take IP

Post by NSlinux » Sun Nov 15, 2015 12:58 pm

Hello
i have configured my server and i testing it from my Windows Client is working very good and get the IP so when i goto showip.com i found the server IP .

but the problem at the Debian linux client is connected successfully but not get the IP
You do not have the required permissions to view the files attached to this post.

kh_tsang
Posts: 551
Joined: Wed Jul 24, 2013 12:09 pm

Re: Debian connected but not take IP

Post by kh_tsang » Mon Nov 16, 2015 11:39 pm

SoftEther VPN only connect a virtual ethernet cable to your computer, you need to manage your adapter using the way of your own operating system.

NSlinux
Posts: 5
Joined: Sun Nov 15, 2015 12:32 pm

Re: Debian connected but not take IP

Post by NSlinux » Mon Nov 16, 2015 11:46 pm

i have already virtual adapter

vpn_vpn Link encap:Ethernet HWaddr 00:ac:31:45:e5:de
inet6 addr: fe80::2ac:31ff:fe45:e5fe/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1067 errors:0 dropped:0 overruns:0 frame:0
TX packets:299 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:500
RX bytes:54566 (53.2 KiB) TX bytes:24786 (24.2 KiB)

but i don't know why is not get the IPV4 IP

raafat
Posts: 223
Joined: Fri Jul 03, 2015 2:21 pm

Re: Debian connected but not take IP

Post by raafat » Tue Nov 17, 2015 12:08 am

Did you configure your virtual adapter to run DHCP ?, if you did't, how will the virtual adapter take an ip address ?


on ubuntu i usually do some thing like this :

Once the connection is connected successfully, do this

sudo dhclient myVirtualAdapter


then verify that you virtual adapter got an ip address :

ifconfig myVirtualAdapter


then you have to see the ip address that the virtual adapter got

Good luck

NSlinux
Posts: 5
Joined: Sun Nov 15, 2015 12:32 pm

Re: Debian connected but not take IP

Post by NSlinux » Tue Nov 17, 2015 12:44 am

thank you this is good step it's take the IP
vpn_vpn Link encap:Ethernet HWaddr 00:ac:31:45:e5:de
inet addr:192.168.30.10 Bcast:192.168.30.255 Mask:255.255.255.0

but still show the original ip when connecting to any site not show the " VPN server IP "
note the server is enabled virtual NAT and is working when i try at windows machine " is show the VPN server IP " when connect to any site but at linux no
did you can advice me what i can do ?

raafat
Posts: 223
Joined: Fri Jul 03, 2015 2:21 pm

Re: Debian connected but not take IP

Post by raafat » Tue Nov 17, 2015 12:50 am

i think the problem due to routing, so post the output of the command : route -n, right after you connect to the softether server

NSlinux
Posts: 5
Joined: Sun Nov 15, 2015 12:32 pm

Re: Debian connected but not take IP

Post by NSlinux » Tue Nov 17, 2015 5:14 am

the route -n results in the screenshot i think the DHCP IP in the route table already
You do not have the required permissions to view the files attached to this post.

raafat
Posts: 223
Joined: Fri Jul 03, 2015 2:21 pm

Re: Debian connected but not take IP

Post by raafat » Wed Nov 18, 2015 2:42 am

Right, your problem with routing, the routing table says if the packet goes to the network 192.168.30.0/24, forward the packet over the VPN tunnel, otherwise let the packet goes over the local path not over the VPN tunnel, just to make sure, issue the following command, right after you connect to the softether server :

sudo route add -net 0.0.0.0 netmask 0.0.0.0 gw 192.168.30.1 dev vpn_adapter


Note that 192.168.30.1 is the host IP of your SECURENAT host (check what is secureNat host ip, before you do this, otherwise may you get trapped in your local subnet, just reboot your machine if that happens)


then test to see (:

Good luck

NSlinux
Posts: 5
Joined: Sun Nov 15, 2015 12:32 pm

Re: Debian connected but not take IP

Post by NSlinux » Wed Nov 18, 2015 11:43 pm

i made the changes and its was same thing not going thought the VPN server IP it's still going out from the machine IP , and i rebooted after reboot i found the route table back again to the original .
i don't know how i can fix this .
i testing at the windows machine everything is working good

thisjun
Posts: 2458
Joined: Mon Feb 24, 2014 11:03 am

Re: Debian connected but not take IP

Post by thisjun » Thu Nov 26, 2015 6:38 am

Please delete original default gateway after adding new.

You have to change route table everytime you connect.
You can create some script.

Post Reply