0

I have to connect to a Linux server through a VPN for school. I am able to connect via Putty through my Windows Virtual Machine, and I can also connect to the VPN (Cisco AnyConnect), but I cannot connect on my native Ubuntu machine. The VPN is successful via my terminal, just not ssh. I try to ping the server, and it just sits there. When I try to ssh into the server, I get "Connection Timed Out."

What is blocking me from connecting if I can do it on my VM? Any suggestions?

Note: I left actual names and IPs out.

Here is my output when connecting to the VPN:

christopher@HAL:~$ sudo openconnect -s /etc/vpnc/vpnc-script https://secureconnect.some_university.edu
[sudo] password for christopher: 
POST https://secureconnect.some_university.edu/
Attempting to connect to server xx.xx.xx.xx:443
SSL negotiation with secureconnect.some_university.edu
Connected to HTTPS on secureconnect.some_university.edu
Got HTTP response: HTTP/1.0 302 Object Moved
GET https://secureconnect.some_university.edu/
Attempting to connect to server xx.xx.xx.xx:443
SSL negotiation with secureconnect.some_university.edu
Connected to HTTPS on secureconnect.some_university.edu
Got HTTP response: HTTP/1.0 302 Object Moved
GET https://secureconnect.some_university.edu/+webvpn+/index.html
SSL negotiation with secureconnect.some_university.edu
Connected to HTTPS on secureconnect.some_university.edu
Please enter your username and password.
GROUP: [xxxxx]:xxxxx <-- leaving name out
Please enter your username and password.
Username:<my_username>
Password:xxxxxxxxx   
POST https://secureconnect.some_university.edu/+webvpn+/index.html
Got CONNECT response: HTTP/1.1 200 OK
CSTP connected. DPD 30, Keepalive 20
/bin/sh: 1: /etc/vpnc/vpnc-script: not found
Script '/etc/vpnc/vpnc-script' returned error 127
/bin/sh: 1: /etc/vpnc/vpnc-script: not found
Script '/etc/vpnc/vpnc-script' returned error 127
Connected tun0 as 192.168.30.106, using SSL
Established DTLS connection (using GnuTLS). Ciphersuite (DTLS0.9)-(RSA)-(AES-256-CBC)-(SHA1).

Here is my attempt to ssh into the server once connected to the VPN:

christopher@HAL:~$ ssh -v xxxxxxx.some_university.edu
OpenSSH_7.2p2 Ubuntu-4ubuntu2.1, OpenSSL 1.0.2g  1 Mar 2016
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for xxxxxxx.some_university.edu
debug1: Connecting to uisacad.uis.edu [xxx.xxx.xxx.xxx] port 22.
debug1: connect to address xxx.xxx.xxx.xxx port 22: Connection timed out
ssh: connect to host xxxxxxx.some_university.edu port 22: Connection timed out
1
  • Dang....no one knows...... Not even my instructor knows how to help me on this one, or tech support, so I'm kinda stuck. I can at least use my Virtual Machine in the mean time I guess. :/ Jan 30 '17 at 6:11
0

The answer was right in front of me the entire time! These lines here:

/bin/sh: 1: /etc/vpnc/vpnc-script: not found <-- realized it here
Script '/etc/vpnc/vpnc-script' returned error 127 
/bin/sh: 1: /etc/vpnc/vpnc-script: not found
Script '/etc/vpnc/vpnc-script' returned error 127

I ran "locate vpnc-script" and I discovered that for some reason it was in /usr/share/vpnc/ when I installed it. So, I did a mkdir /etc/vpnc and then moved everything inside /usr/share/vpnc over to there, changed proper permissions, and voila! It works! I ssh'd into the server and it connected immediately! This will make things so much easier because I was sick of using my virtual machine.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.