hide window on startup option... doesn't hide window on startup

92 views
Skip to first unread message

andrew.p...@gmail.com

unread,
Jun 10, 2016, 11:05:48 PM6/10/16
to tunnelblick-discuss
El Capitan.

jkbull...gmail.com

unread,
Jun 10, 2016, 11:21:43 PM6/10/16
to tunnelblick-discuss, andrew.p...@gmail.com
Thanks for your report, but it works for me.

What window is not being hidden? The window "Startup window" that should be hidden is Tunnelblick's "splash" window – not the "VPN Details" window. It is this window:

If the VPN Details window is showing up when you login, you may have a "login item" that specifies Tunnelblick. Remove any such login items from your  "Users & Groups" System Preferences. Tunnelblick has its own mechanism for launching when you log in. (It launches if it was running when you last logged out or restarted or shut down your computer, or if there are any active VPNs.) Another possibility is that you are clicking a Tunnelblick icon in the Dock twice. The first click launches Tunnelblick and the second click shows the "VPN Details" window.

On Friday, June 10, 2016 at 11:05:48 PM UTC-4, <> wrote:
El Capitan.

dcs...@gmail.com

unread,
Oct 12, 2016, 6:32:44 AM10/12/16
to tunnelblick-discuss, andrew.p...@gmail.com
Unfortunately, VPN Details windows shows up every time I login: nothing in Login Items in Users&Groups. Mavarericks 10.9.5 & Tunnelblick 3.6.8 (build 4625)

Tunnelblick developer

unread,
Oct 12, 2016, 7:25:06 AM10/12/16
to tunnelblick-discuss, andrew.p...@gmail.com, dcs...@gmail.com
Quit Tunnelblick and logout. Then log back in and see if Tunnelblick launches.

If it does, you have something on your computer that is causing Tunnelblick to be launched. Remove that, and the problem will be fixed.

The only other thing I can think of is that you have a duplicated launch agent plist. Please try the following command in Terminal:

ls -l ~/Library/LaunchAgents | grep tunnelblick

and post the result.

dcs...@gmail.com

unread,
Oct 12, 2016, 7:38:21 AM10/12/16
to tunnelblick-discuss, andrew.p...@gmail.com, dcs...@gmail.com
1.Quit Tunnelblick and logout. Then log back in and see if Tunnelblick launches.
Done - it's not launches.
2. ls -l ~/Library/LaunchAgents | grep tunnelblick
Done
-rw-r--r--  1 Denis  staff  588 Sep 26 19:03 net.tunnelblick.tunnelblick.LaunchAtLogin.plist

Still when I log out with VPN connected and login back I see the Tunnelblick main window: Where configuration, Appearance, Preferences.
Have no clue why it's happening.

Tunnelblick developer

unread,
Oct 12, 2016, 7:52:02 AM10/12/16
to tunnelblick-discuss, andrew.p...@gmail.com, dcs...@gmail.com
I'm sorry you're having this problem, it sounds like a real nuisance.

1. You probably understood this, but my instructions were not very clear. Instead of

Quit Tunnelblick and logout. Then log back in and see if Tunnelblick launches.

I should have written

Quit Tunnelblick and logout. Then log back in and see if Tunnelblick icon appears in the menu bar.

That is, should not be looking for the "VPN Details" window, you are looking for the Tunnelblick icon in the menu bar. If the icon is in the menu bar, then something else is launching Tunnelblick.

2. The Terminal output is good; there's no duplicated .plist.

The only other thing I can think of to try is to 
  1. Quit Tunnelblick
  2. Remove the .plist with the following Terminal command (all on one line)
    rm -f ~/Library/LaunchAgents/net.tunnelblick.tunnelblick.LaunchAtLogin.plist
  3. Logout
and see if the Tunnelblick icon shows up in the menu bar. (Tunnelblick will recreate this file automatically each time it is launched, so you have to make sure you don't launch Tunnelblick after removing it.)

dcs...@gmail.com

unread,
Oct 12, 2016, 8:02:09 AM10/12/16
to tunnelblick-discuss
1. There is no icon when I login back (If i disconnect, quit Tunnelblick and then login back), so it needs to be started manually.
2. Did it - it's not recreating and it needs to be started manually - the same behaviour as in point 1.

Tunnelblick developer

unread,
Oct 12, 2016, 8:18:41 AM10/12/16
to tunnelblick-discuss, dcs...@gmail.com
If the .plist is not being recreated when you launch Tunnelblick that is very odd -- the only way that should happen is if you are launching a "debug" version of Tunnelblick. If that is the case, you should see the following message in the Console Log, near (I think just after but possibly before) a message that shows the OS X version and Tunnelblick version:

DEBUG VERSION DOES NOT UPDATE LaunchAtLogin.plist.

Are you seeing that message?

Tunnelblick developer

unread,
Oct 12, 2016, 8:22:07 AM10/12/16
to tunnelblick-discuss, dcs...@gmail.com
(I forgot this):

When you started Tunnelblick manually, did the "VPN Details" window appear? (It should not appear when Tunnelblick is launched, but it should appear if you relaunch Tunnelblick when it is already running.)


On Wednesday, October 12, 2016 at 8:02:09 AM UTC-4, <> wrote:

dcs...@gmail.com

unread,
Oct 12, 2016, 9:09:38 AM10/12/16
to tunnelblick-discuss
So, let's see what I have:
1. *Tunnelblick: OS X 10.9.5; Tunnelblick 3.6.8 (build 4625); prior version 3.6.7c (build 4606)

2. It starts w/o any windows, just the icon in the tray.

P.S. Can it be related to ovpn configuration itself? Because it looks like I have similar behaviour with 10.7.4 and the same Tunnelblick version... Can't check it now.

In log:

"2016-10-12 16:00:39 *Tunnelblick: openvpnstart log:
     Warning: The bitMask setting to disable OpenVPN logging is being ignored because the configuration is starting when the computer startsThe Internet (host 'www.tunnelblick.net') is reachable; flags = 0x2
2016-10-12 16:00:42 NOTE: Tried to delete pre-existing tun/tap instance -- No Problem if failure
     NOTE: The DNS servers do not include any free public DNS servers known to Tunnelblick. This may cause DNS queries to fail or be intercepted or falsified even if they are directed through the VPN. Specify only known public DNS servers or DNS s
ervers located on the VPN network to avoid such problems."

Nothing suspicious in logs.

Tunnelblick developer

unread,
Oct 12, 2016, 10:01:35 AM10/12/16
to tunnelblick-discuss, dcs...@gmail.com
The only way I can think of for a configuration to cause this is if the configuration contains a script that launches Tunnelblick.

Tunnelblick VPN Configurations can contain scripts that are run when certain events occur, and OpenVPN configurations can contain command lines that are executed when certain events occur, see Using Scripts. Although it would be very odd, either of these could contain a command that would launch Tunnelblick.

Here are all the actions that cause the "VPN Details" window to appear:
  1. If you click "VPN Details…" in the Tunnelblick menu.
  2. If you triple-click the Tunnelblick icon in the menu bar.
  3. If you (or some program) launch Tunnelblick when it is already running as the same user.
Each time you log in, a Tunnelblick "launch agent" runs a simple script named "LaunchAtLogin.sh". It checks a user preference to see if Tunnelblick was running when the last logout occurred. If so, Tunnelblick is launched; if not, then nothing is done. Then the "launch agent" exits.

So if you logout without quitting Tunnelblick, Tunnelblick will be launched the next time you log in. If that happens and there is something else that also launches Tunnelblick, the second launch will cause the "VPN Details" window to appear.

dcs...@gmail.com

unread,
Oct 12, 2016, 10:24:21 AM10/12/16
to tunnelblick-discuss
Thx for clarification, it's standart ovpn configurations from my private server, so they contain no extra scripts etc.
As workaround I will make a scipt to auto-hide Tunnelblick window on launch :)

dcs...@gmail.com

unread,
Oct 12, 2016, 11:10:01 AM10/12/16
to tunnelblick-discuss
Additional info:
at login the icon appers in the tray, then after or during connection the main window appers - looks like it's somehow related to the log output in the main window, so it launches the main window. Hope it helps.

Tunnelblick developer

unread,
Oct 12, 2016, 11:54:24 AM10/12/16
to tunnelblick-discuss, dcs...@gmail.com
Ah. That's interesting. I found the problem: the LaunchAtLogin.sh script does more than I remembered, and does it incorrectly!

It launches Tunnelblick if any of three conditions are true, but it is testing each one separately and isn't exiting if it does launch Tunnelblick. A totally "what could I have bee thinking?" kind of bug. It could actually launch Tunnelblick up to three times!!!!

I have made a very simple fix to the source code (commit 363d058), so the problem will be fixed in the next Tunnelblick beta, which will probably be released some time next week (when new versions of OpenVPN are due to be released).

Thank you very, very much for working with me on this.

dcs...@gmail.com

unread,
Oct 12, 2016, 12:14:19 PM10/12/16
to tunnelblick-discuss, dcs...@gmail.com
You are welcome!
Thanks for your nice app!

Tunnelblick developer

unread,
Oct 13, 2016, 9:30:16 AM10/13/16
to tunnelblick-discuss, dcs...@gmail.com, Andrew Pennebaker
A pre-release build of Tunnelblick is available which includes a fix for this problem.

Anyone with this problem may email devel...@tunnelblick.net, to get a link to download it.

xavier....@gmail.com

unread,
Jan 7, 2017, 2:09:42 PM1/7/17
to tunnelblick-discuss, andrew.p...@gmail.com
I had this problem too, and removing net.tunnelblick.tunnelblick.LaunchAtLogin.plist solved the thing. 
I'm using 10.12.2 on a Macbook Pro 15" with Touchbar… 

Tunnelblick developer

unread,
Jan 7, 2017, 6:09:29 PM1/7/17
to tunnelblick-discuss, andrew.p...@gmail.com
Tunnelblick has a mechanism for launching itself on login: if it was running when you logged out, it will launch when you log in.
  1. There was a bug that sometimes caused Tunnelblick to sometimes show the VPN Details window at login, but that was fixed in Tunnelblick 3.6.9beta02 build 4675 (2016-11-04)

  2. If you have something else (a login item, for example) that launches Tunnelblick when you log in, that second launch will cause the VPN Details window to appear. If that is what you are seeing, then the solution is to get rid of whatever else has been set up to launch Tunnelblick.

  3. Removing net.tunnelblick.tunnelblick.LaunchAtLogin.plist won't help much because Tunnelblick puts it back if it is missing.
You can prevent Tunnelblick from launching itself at login by entering the following command in Terminal:
defaults  write  net.tunnelblick.tunnelblick  doNotLaunchOnLogin  -bool  yes
After entering the above command, you will need to quit Tunnelblick and then launch it once it for it to take effect with the next login. After that it will be in effect until you remove it. It will still allow Tunnelblick to launch in the event that a VPN is still connected, so you will see that it is connected.

To remove this preference, use:
defaults  delete  net.tunnelblick.tunnelblick  doNotLaunchOnLogin

Xavier Spirlet

unread,
Jan 8, 2017, 2:12:50 PM1/8/17
to tunnelbli...@googlegroups.com
Hi, 

I did a clean uninstall (using uninstaller) then manually deleted the startup item in my user preferences, then rebooted, then reinstalled. I did backup my configs but forgot to record my credentials, hehe ;-) anyway, problem gone. I’ll just reset my passwords now ;-) 

Many thanks
Best, 


--
You received this message because you are subscribed to a topic in the Google Groups "tunnelblick-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tunnelblick-discuss/ZxSw34Z35Yg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tunnelblick-dis...@googlegroups.com.
Visit this group at https://groups.google.com/group/tunnelblick-discuss.
For more options, visit https://groups.google.com/d/optout.

. . . . . . . . . . . . . . . . . .
. Xavier Spirlet 
. Petitpoisson
. Design graphique - Création web - Informatique
TVA BE 0886 981 955
OpenPGP public key : http://www.petitpoisson.be/xavier-pubkey.asc 

Tunnelblick developer

unread,
Jan 8, 2017, 2:23:33 PM1/8/17
to tunnelblick-discuss
Apparently "the startup item in [your] user preferences" was the "something else (a login item, for example)" that was launching Tunnelblick. If you had deleted that, you wouldn't have had to do the uninstall/reinstall, etc.

The credentials are in your login keychain, see How do I restore the login.keychain from a time machine back up in lion. (I assume that works in later versions of OS X, too.) You probably should restart your computer afterwards.

On Sunday, January 8, 2017 at 2:12:50 PM UTC-5, Xavier Spirlet wrote:
Hi, 

I did a clean uninstall (using uninstaller) then manually deleted the startup item in my user preferences, then rebooted, then reinstalled. I did backup my configs but forgot to record my credentials, hehe ;-) anyway, problem gone. I’ll just reset my passwords now ;-) 

Many thanks
Best, 

Xavier Spirlet

unread,
Jan 8, 2017, 6:51:18 PM1/8/17
to tunnelbli...@googlegroups.com
Absolutely right in both cases. I don't know. Maybe I ate something wrong this morning. Usually I'm less stupid :-/ Sorry about all that. And many thanks for coping with me today! 

--
You received this message because you are subscribed to a topic in the Google Groups "tunnelblick-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tunnelblick-discuss/ZxSw34Z35Yg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tunnelblick-discuss+unsub...@googlegroups.com.



--
Reply all
Reply to author
Forward
0 new messages