How to automatically connect Windows 7 or 2008 R2 VPN on start up
How to automatically connect Windows 7 or 2008 R2 VPN on start up
Do you have a Windows 7 or 2008 R2 machine that needs to automatically connect to a VPN? Here are some instructions on configuring the Task Scheduler to do this for you.
My thanks to RpCahoon for providing his helpful post on Microsoft's Social Answers site. I'm also giving Microsoft a nod for doing such thorough job with the modern Task Scheduler.
Instructions
My thanks to RpCahoon for providing his helpful post on Microsoft's Social Answers site. I'm also giving Microsoft a nod for doing such thorough job with the modern Task Scheduler.
Instructions
- Open Task Scheduler
Start > All Programs > Accessories > System Tools > Task Scheduler - Click "Create Task" in the Actions pane on the right
- General Tab
- Provide a logical name for the task like "Auto VPN"
- Switch the running task mode to Run whether user is logged on or not
- Enable the Run with highest privileges option
- Change the "Configure for:" drop-down to Windows 7, Windows Server 2008 R2
- Triggers Tab
- Click the "New..." button
- Change "Begin the task:" to At start up
- (Optional) Enable "Delay task for" and set to 5 minutes. This give the machine a chance to idle down before launching the VPN.
- Actions Tab
- Click the "New..." button
- Enter c:\windows\system32\rasdial.exe in the "Program/script:" field. You can also browse to it if you don't want to type it or your default Windows install directory is different.
- Type the connection name in the "Add arguments" field. The rasdial.exe requires you wrap the connection name in quotes if it has spaces. You may also need to append the connection's username and password if they are required.
- Conditions Tab
- Un-check all of the options on the conditions tab.
- Settings Tab
- (Optional) enable "If the task fails, restart every:" and set to an appropriate value. I set mine to 1 hour in case there is a problem on the VPN server's end.
- (Optional) set the "Attempt to restart up to:" value to an acceptable number. My default is 72 times at a 1 hour interval. This covers long weekend.
- Save the new task
0
Please sign in to leave a comment.
Comments
0 comments