Up and Down batch files no longer working correctly

How to customize and extend your OpenVPN installation.

Moderators: TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech

Post Reply
fatman45
OpenVpn Newbie
Posts: 2
Joined: Tue Feb 16, 2016 5:12 am

Up and Down batch files no longer working correctly

Post by fatman45 » Sat Apr 08, 2023 11:12 pm

OpenVPN v2.5.8 / OpenVPN GUI v11.31.0.0 on Windows 10 Pro 64-bit.

I'm referring to the .BAT scripts that automatically execute when placed in the config folder and named connection_name_up.bat and connection_name_down.bat respectively. I'm using those scripts to map/unmap a network drive to a remote share automatically whenever I connect to my office VPN. Before the latest upgrade, those scripts worked perfectly. They still seem to run, and run without error, as the VPN Connection does not fail, and I see the message Running Connect Script as OpenVPN GUI is connecting. But the drive does not get mapped, at least, not to my login session. What I suspect is happening is that the account OpenVPN is running under is getting the drive mapped to its session, rather than it being mapped to my session, like it used to. I did this upgrade because the OpenVPN server at work was upgraded, and my old configuration settings were no longer functional. The server generates an install executable that also installs the client config with the correct settings. When I ran the executable, I right-clicked and selected Run as Administrator. Could that have caused the problem?

fatman45
OpenVpn Newbie
Posts: 2
Joined: Tue Feb 16, 2016 5:12 am

Re: Up and Down batch files no longer working correctly

Post by fatman45 » Sun Apr 09, 2023 7:30 pm

Okay, it was due to running the setup executable as Administrator. I uninstalled and reinstalled without choosing Run as Administrator and everything is working fine again.

Joci78
OpenVpn Newbie
Posts: 2
Joined: Wed Oct 18, 2023 11:58 am

Re: Up and Down batch files no longer working correctly

Post by Joci78 » Wed Oct 18, 2023 1:19 pm

I managed to solve one workstation this way, but this solution does not work on the other. :(

Both workstations have a user with administrator rights. The machines are not in the domain.

rfdarter
OpenVpn Newbie
Posts: 2
Joined: Fri Oct 25, 2024 12:32 am

Re: Up and Down batch files no longer working correctly

Post by rfdarter » Mon Nov 25, 2024 10:15 pm

I have similar problems

Post Reply