Solved

ssh into Linux Ubuntu remotely

Posted on 2015-01-25
5
385 Views
Last Modified: 2015-02-12
A customer has the following set up:
- a Linux (Ubuntu) server (192.168.1.77)
- a VMWare virtual machine (192.168.1.75) hosted on the Linux server
- Windows Sever 2008 running on the virtual machine
- a BT Business Hub router (192.168.1.254)

At present I can RDP into the Windows Server 2008 VM remotely and from there I can PuTTy into the Linux server over the local network.

I can also remote in to the VMWare Control panel on
https://<server WAN IP address>:8333

The objective is to be able to PuTTy into the Linux server remotely, but without having to go via the VM.

In the router, port 22 and port 8333 are forwarded to the Linux server.

But when I try to PuTTy in to the Linux server remotely, the PuTTy window comes up but there is no login prompt, just a static cursor; and after a short while the connection times out.

Doing an internal (local network) port scan on the server shows that ports 22 and 8333 are open.
Doing the same scan but remotely, to the server WAN IP address shows port 22 closed and port 8333 open.

So what do I need to do to be able to open port 22 for remote  ssh access to the Linux (Ubuntu) server?
0
Comment
Question by:socross
  • 4
5 Comments
 
LVL 19

Assisted Solution

by:Peter Hutchison
Peter Hutchison earned 200 total points
ID: 40569439
You might have some firewall rules on the server restricting access or that ssh only responds from certain subnets or ip addresse which may need to be modified to allow remote access. See https://help.ubuntu.com/community/SSH/OpenSSH/Configuring
0
 
LVL 1

Author Comment

by:socross
ID: 40589172
Sorry, haven't had a chance to follow this up yet. Will get back to it asap.
0
 
LVL 1

Author Comment

by:socross
ID: 40590423
I have tried temporarily disabling the firewall in the router, but it made no difference.

Please find attached the Linux server's current sshd_config file. I made one change from the original by adding the line:
GatewayPorts yes
But this made no difference (with or without the firewall in the router)

Can anyone shed any further light on this problem please?
0
 
LVL 1

Accepted Solution

by:
socross earned 0 total points
ID: 40595658
This has now been solved. It turned out to be a combination of two things:

1) The static WAN IP of the remote server had actually been changed, unbeknown to me!

2) In the router there were too many instances of SSH applications being port forwarded. Reduced these to just one ( for PuTTY).

So thanks to Peter Hutchison, or his link on openssh, which was useful and informative, but not the route to a fix in this case.
0
 
LVL 1

Author Closing Comment

by:socross
ID: 40605234
Sorry for effectively accepting my own solution, but hopefully it may prove useful to others.
0

Featured Post

Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

825 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question