I’ve been having all sorts of problems off and on with the Juniper Network VPN connection. I don’t have the exact pattern of what causes the problem, but I think I’ve seen it both with the machine hangs and when I disconnect the VPN normally. Also, keep in mind, I’m using the Mad Scientists JNC script. Anyway, what I see when I use the web interface is the GUI comes up for a couple seconds and fails. I don’t see anything conclusive in the logs other than a most likely harmless “ncui.error Got signal 17″ (a user signal). When I run the jnc script, it claims the VPN is up, but no packets are sent or received.
The problem always boils down to a problem with the /etc/resolv.conf file. It normally has stale information in it and I edit it and get some things working. What I think I really need to do is delete it and recreate a link to /run/resolvconf/resolv.conf. This last time, I had to make an empty file there. Once I had that file, I got get the VPN to start and work.
It may be related that the files /etc/jnpr-nc-hosts.bak and /etc/jnpr-nc-resolv.conf should (or perhaps should not) exist. Last time I was working on this, I recreated an empty /etc/jnpr-nc-resolv.conf file just before things started working. I had a copy of the hosts.bak lying around. I think the main problem is the Juniper scripts moves the symbolic link out of the way and creates a regular file. Next time you start up, the file is not updated and you get the stale resolv.conf file.
I also reverted the VPN changes to the hosts file, which didn’t make any difference. The thing that may be key is removing all the log files from ~/.juniper/network_connect directory.