SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post your questions about SoftEther VPN software here. Please answer questions if you can afford.
Post Reply
lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Thu Jul 20, 2023 9:35 am

Hello all,

lately I installed SoftEther VPN server on my Windows 2019 Server. I configured it to use OpenVPN. Everything works ok (I hope I setup everything correctly). Right now when I'm connecting mobile phone, I'm receiving an IP from my local subnet: 192.168.0.*, I have access to my server files and my external IP is changing from LTE IP to my internet IP. So for me is everything ok, but in a while I found 2 strange problems.

1. SecureNAT and Virtual DHCP server
I do not change any settings there, I leave standard ones.
So when I was using SecureNAT and Virtual DHCP server I was receiving IP from standard settings 192.168.30.*, so ok, no problem with that, but I saw, that all devices in my network, which were not connecting through VPN (for examle printer) were forced to use SoftEather Virtual DHCP server instead of my router DHCP. When I uncheck Virtual DHCP server or disable SecureNAT I back to router subnet.
Why it happens?

2. LAN file transfer speed.
When SoftEther server is started it decrease local transfer speed between my server and my PC. When SoftEther is OFF I've got 1Gbps connection, when is ON I've got something like 500Mbps and because of that my connection to server throught RDP is also lagging.
Local PC is connecting to the server without VPN connection.

Any idea why those 2 problems exist?

If you need more information, just let me know.

solo
Posts: 1287
Joined: Sun Feb 14, 2021 10:31 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by solo » Thu Jul 20, 2023 9:52 am

1 - you have enabled both a local bridge and SNAT which is unacceptable

2 - it may be a side-effect of #1

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Thu Jul 20, 2023 10:41 am

Thanks for your reply.
When I found problem with DHCP I turned off SecureNAT.
Yesterday I found problem with LAN transfer speed and it works normally only when I set SoftEther offline.

Reinstalling the server and configuring it once again can help?

solo
Posts: 1287
Joined: Sun Feb 14, 2021 10:31 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by solo » Thu Jul 20, 2023 11:11 am

Remove local bridge.

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Thu Jul 20, 2023 11:35 am

SecureNat is disabled, Local bridge removed. Now LAN transfer is ok, but without the Local bridge I cannot connect to VPN.

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Thu Jul 20, 2023 2:00 pm

I removed Local bridge and then I setup SecureNAT on standard settings. I'm able to connect to VPN, my PC in LAN was not forced to use virtual DHCP from SoftEather, but unfortunately LAN transfer speed has not changed.
Transfer speed is approx 50Mb/s and lag internet connection.
When I was copying file from server to my PC through LAN and I was connected to the PC through VPN under the phone I was losing the connection.

Any clue what is wrong?

solo
Posts: 1287
Joined: Sun Feb 14, 2021 10:31 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by solo » Thu Jul 20, 2023 2:33 pm


lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Thu Jul 20, 2023 3:21 pm

I'm using the latest version of the server. :(

Can it be some kind of conflict with l2tp/ipsec VPN which I earlier setup on Windows 2019 Server? Right now I still keep this VPN.

solo
Posts: 1287
Joined: Sun Feb 14, 2021 10:31 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by solo » Thu Jul 20, 2023 5:00 pm

Yes. For a test install SE server on another LAN PC or a VM.

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Fri Jul 21, 2023 8:02 am

I made fast test and I disabled Routing and remote access in windows server, so my l2tp vpn does not working. It has not changed the speed.
I will try to find some time on weekend to check SoftEther on my PC.

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Sat Jul 22, 2023 10:35 am

I installed SoftEther on my PC and everything is ok. Then I reinstalled and configured once again on my server and speed is decreased.

What else I can check?

This is quite strange.

solo
Posts: 1287
Joined: Sun Feb 14, 2021 10:31 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by solo » Sat Jul 22, 2023 3:54 pm

As admin merge into the registry...
REG ADD HKLM\SYSTEM\CurrentControlSet\Control\SafeBoot\Network\SEVPNSERVER /ve /t REG_SZ /d Service
...and boot it in "Safe Mode with Networking" for a test.
If OK now, I'll post further instructions.

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Sat Jul 22, 2023 5:03 pm

Done.

But unfortunately hard to say. When I was uploading from server to PC the speed reach approx 80 Mb/s, when I was downloading from PC to server it was approx 60 Mb/s.

Right now in normal mode with turned off VPN downloading from server is still ok, but uploading is worst approx 30 Mb/s :S.

solo
Posts: 1287
Joined: Sun Feb 14, 2021 10:31 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by solo » Sat Jul 22, 2023 5:57 pm

Use LAN Speed Test v1.3 (Lite) https://totusoft.com/lanspeed

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Sun Jul 23, 2023 7:12 am

Something is broken.

It was upload from PC to Server. The upload is horrible.
You do not have the required permissions to view the files attached to this post.

solo
Posts: 1287
Joined: Sun Feb 14, 2021 10:31 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by solo » Sun Jul 23, 2023 9:12 am

Is it the same in "Safe Mode with Networking"?

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Sun Jul 23, 2023 10:47 am

In safe mode is better. Test from Server to PC.

Under safe mode I uninstalled drivers for ethernet card but it has not change anything.
You do not have the required permissions to view the files attached to this post.

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Sun Jul 23, 2023 3:11 pm

Maybe this will be important, I don't know.

I've got 500/50 mbps internet. My server reach only 150 mbps.
Server works on Windows server 2019 datacenter. I'm making the tests with my PC which works on Windows 11 Pro.

On my PC I reach full speed of my internet.

There's something wrong.

Cable is ok. I've got 4 cables in room. 3 are ok, one probably is damaged.

solo
Posts: 1287
Joined: Sun Feb 14, 2021 10:31 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by solo » Sun Jul 23, 2023 6:15 pm

Let's summarize:

Code: Select all

             SE off   SE on
             UP  DL   UP  DL

norm boot    13  84   13  29
safe boot    61  58   40  62
Without SoftEther there are huge differences on your system already. It could be an AV scanning everything in real time for your "safety". As you have observed on another PC, SE server does not have an impact on LAN speed.

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Sun Jul 23, 2023 10:09 pm

You are right, but unfortunately something is not ok. I do not have much things on this server. I was testing speed with turned off AV, some other programs and the speed do not increased.

This is not powerfull server, but last 5 years everything was ok. On server I had Windows 10, even an VMware with Ubuntu and everything works quite good.

Now something is messed because as I wrote in previous post I'm not able to use there full speed of my internet connection, witch I figured out right now.

I think it can be something with the drivers. Will fight with it and maybe I will upgrade system to Windows server 2022 or I will back to Windows 10.

Thank you for your support.

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Fri Jul 28, 2023 9:44 am

Ok, small update. Unfortunately SoftEther still is causing problems with LAN transfer speed. I upgraded Windows Server 2019 to 2022. This not changed anything.

Next I made the test with Ubuntu started on server from USB. Transfer between PC and Server was littel better approx 500 Mbps in both sides.
Next check was speed test from Laptop to PC on other cable, it's reach 1Gbps in both sides, after that I connected server to this cable and on Ubuntu it reach the same speed as earlier approx. 500 Mbps. So it can be some hardwer problem, or drivers... I do not know.

But when I started Windows Server and I made SoftEther offline I was able to reach approx. 800 Mbit speed on Total commander.

To sum up I'm able to reach approx 1Gbps speed but not everytime, and SoftEther is causing that the speed is reduced to 150-400 Mbps.

This is very strange problem for me.

solo
Posts: 1287
Joined: Sun Feb 14, 2021 10:31 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by solo » Fri Jul 28, 2023 12:03 pm

While I doubt it has anything to do with SoftEther, for completeness of this investigation please re-test it in different modes of operation.

#1
assuming that the bridge is still removed and SecureNAT enabled, run:
net stop sevpnserver
and then
"C:\Program Files\SoftEther VPN Server\vpnserver.exe" /usermode
- check LAN speed

#2
reboot and go: Manage VPN Server > Virtual Hub Name > VPN > Properties > Edit Virtual Hub Extended Option List:
set DisableKernelModeSecureNAT to 1
net stop sevpnserver
net start sevpnserver
- check LAN speed

#3
disable SecureNAT and enable local bridge (don't worry about VPN clients ATM)
net stop sevpnserver
net start sevpnserver
- check LAN speed

All these tests without any AV running and the bridged NIC has only TCP/IPv4 and Microsoft client/server items enabled.

lriuqs
Posts: 14
Joined: Thu Jul 20, 2023 8:59 am

Re: SoftEther VPN server - SecureNAT and LAN speed strange behavior

Post by lriuqs » Tue Aug 08, 2023 11:18 am

Hey, sorry for my late repry, I was on holidays.

NIC settings
NIC.png
#1
"C:\Program Files\SoftEther VPN Server\vpnserver_x64.exe" /usermode
Downloading from PC to server approx. 500 mbps
Uploading from server to PC approx. 900 mbps

#2
Manage Virtual Hub > Virtual Hub Properties > Edit Virtual Hub Extended Option List
Downloading from PC to server approx. 500 mbps
Uploading from server to PC approx. 700-900 mbps

#3
NO NIC.png
I enabled Softether Lightweight Network Protocol in NIC card settings

Downloading from PC to server approx. 500 mbps
Uploading from server to PC approx. 300 mbps

So I set up everything like before the tests and disabled Softether Lightweight Network Protocol in NIC card settings and speed is now acceptable.
As I wrote upper:
Downloading from PC to server approx. 500 mbps
Uploading from server to PC approx. 900 mbps

So I thing we found the problem on my server.


I even bought new NIC card, because I took into account that maybe my NIC is broken, but nothing has changed.

And another thing is Power plan in windows Server 2019. When I set up High performances my speed are near to 1 gbps, but in Power saver option transfers are lower as I wrote earlier in this post.

When I was using Windows 10 with Power saver plan the transfers speeds were not reduced.

Ok, I will play wit it now. Thank you for your help.
You do not have the required permissions to view the files attached to this post.

Post Reply