When configuring VPN connections in Ubuntu through network-manager-pptp the connections don’t get displayed until a reboot due to a bug. In the bugtracker I found a solution which makes the connections available without a reboot.
First, restart dbus
sudo /etc/init.d/dbus restart
Then run the NetworkManager applet by opening a command window with ALT+F2 and typing in nm-applet.
Da ich meine Rechner relativ oft neu aufsetze, ist es ziemlich nervig, jedes Mal diverse VPN-Verbindungen per Hand einrichten zu müssen. Deshalb hab ich eine Runde im Netz gesucht und bis auf ein VB-Script in einem Forumpost nicht viel gefunden. Da das Script aber tut, was es soll, habe ich es schnell auf ein deutsches Windows umgeschrieben und um die Möglichkeit mehrerer Verbindungen erweitert. Einfach das Connections-Array anpassen, als dateiname.vbs abspeichern und ausführen. Macht Spaß dabei zuzusehen
Getestet unter Windows XP Pro, sollte aber auch unter Windows 2000 funktionieren. Keine Ahnung wie es unter Vista aussieht, wenn es jemand probiert wäre ein kurzes Feedback super.
Dim objShell
Set objShell = WScript.CreateObject("WScript.Shell")
Dim Connections
Connections = Array(Array("Verbindung 1", "127.0.0.1"), Array("Verbindung 2", "localhost"), Array("Verbindung 3", "192.168.1.1"))
With objShell
.Run "Control ncpa.cpl"
wscript.sleep 2000
End With
For i = 0 To UBound(Connections)
With objShell
.AppActivate "Netzwerkverbindungen"
wscript.sleep 500
.SendKeys "%DN"
wscript.sleep 500
.SendKeys "%W"
wscript.sleep 500
.SendKeys "%NW"
wscript.sleep 500
.SendKeys "%VW"
wscript.sleep 500
.SendKeys "%N" & Connections(i)(0) & "%W"
wscript.sleep 500
.SendKeys "%KW"
wscript.sleep 500
.SendKeys "%H" & Connections(i)(1) & "%W"
wscript.sleep 500
.SendKeys "{TAB}{TAB}{ENTER}"
wscript.sleep 500
.SendKeys "{ESC}"
wscript.sleep 500
End With
Next
Update: habe die Sleep-Zeiten auf 500ms erhöht, da ich teilweise Probleme hatte, wenn viele Verbindungen erstellt werden sollten.