Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Auto-connect to VPN upon system restart


20 Jul 2009   #1

Windows 7 RC (Build 7100)
 
 
Auto-connect to VPN upon system restart

I need to connect to a VPN in order to use my university's exchange email client.
Does anybody know if I can define it to connect automatically when my system starts? As it is, I need to manually connect each time (which isn't that difficult, but I rather not having to do it).

I'm using Windows 7 RC (7100), and am connected to the internet using a cable modem.

My System SpecsSystem Spec
.

29 Jan 2010   #2

Windows 7
 
 

Create a scheduled task named "Auto VPN" or something similar
Tick the Run whether user is logged on or not
Tick the Run with highest privileges
Select Configure for Windows 7, Windows Server 2008 R2 in the Configure For drop down box
Create a the trigger for the task and set the Begin the task drop down to At startup
Create an action for the task and set the action to Start a program
Set the Program/script to c:\windows\system32\rasdial.exe
Put the name of the connection to be made in the Add Arguments box*
*If the name contains spaces you will need to enclose the name in quotation marks
*You may need to additional rasdial parameters to the Add Arguments box dependant on the connection properties
Clear all task Conditions

The end result should be that your VPN connection is automatically connected on Start up. You can also configure the connection for login or even a specific user's login.

Cheers
My System SpecsSystem Spec
30 Jan 2010   #3

Stools
 
 

Quote   Quote: Originally Posted by RpCahoon View Post
Create a scheduled task named "Auto VPN" or something similar
Tick the Run whether user is logged on or not
Tick the Run with highest privileges
Select Configure for Windows 7, Windows Server 2008 R2 in the Configure For drop down box
Create a the trigger for the task and set the Begin the task drop down to At startup
Create an action for the task and set the action to Start a program
Set the Program/script to c:\windows\system32\rasdial.exe
Put the name of the connection to be made in the Add Arguments box*
*If the name contains spaces you will need to enclose the name in quotation marks
*You may need to additional rasdial parameters to the Add Arguments box dependant on the connection properties
Clear all task Conditions

The end result should be that your VPN connection is automatically connected on Start up. You can also configure the connection for login or even a specific user's login.

Cheers


Would love for this to work on my computer. But for some reason (probably the rasdial failure) it don't work. Contacted M$ and have had an appointment but they never phoned me.
My System SpecsSystem Spec
.


31 Jan 2010   #4

Windows 7
 
 

This might be a silly question but do you have rasdial.exe on your system?

You can test this by opening a command prompt and typing RASDIAL and pressing enter. You should see something like "No connections - Command Completed Successfully".

Assuming you do...

When initially setting this up I tried using RASDIAL and passing my connection name, user name and password as parameters but I couldn't get this to work. In frustration I tried the shortened version with just the connection name and it worked first time. Try using RASDIAL at a command prompt with various options to see if you can get it to work for you. Once you get the right command, the rest is fairly simple.

Yet another consideration, if you have trouble setting up the scheduled task and passing additional arguments, you can always create a simple batch file in your Windows\System folder and have the scheduled task simply call the batch file. This eliminates the need for additional arguments in your scheduled task.

I hope this will prove helpful

Cheers
My System SpecsSystem Spec
24 Jun 2011   #5

Windows 7 Ultimate x64
 
 

If i done the above in a command prompt, what would the syntax be? not to schedule the task, just to load the connection?
My System SpecsSystem Spec
24 Jun 2011   #6

 

Could have failed due to not allowing it to delay task. Set to like 2 - 3 minutes depending on how long it takes for your NIC driver to initialize.
My System SpecsSystem Spec
23 May 2012   #7

Windows XP Professional
 
 

Hi,

There is a program called VPN Dialer 2012 which accomplishes this exactly (has a wizard that is easy to step through, installs as a service, and keeps VPN connected from bootup until shutdown, and does not require logging in).

Eric
My System SpecsSystem Spec
Reply

 Auto-connect to VPN upon system restart




Thread Tools



Similar help and support threads for2: Auto-connect to VPN upon system restart
Thread Forum
Bsod-auto restart :/ BSOD Help and Support
How to get auto restart after power outage? General Discussion
Auto update restart on its own. Windows Updates & Activation
Problem in auto restart ! BSOD Help and Support
BSOD, forces restart but have auto restart off BSOD Help and Support
Auto restart even if uncheck automatic restart BSOD Help and Support
Auto-Restart Mystery Problem General Discussion

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 01:59 AM.
Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App
  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33