Installing OpenSSH [SSH Connection Refused]
Guys,
Its not a big deal that you come across with errors while installing OpenSSH or any other Linux packages. In some cases, its quite time taking but believe me, its really a good experience to install complex applications in Linux as it refines lots f your inside outs and clears lots of concepts about Linux directory structures etc. However getting bit specific I am mentioning a real world problem.
Its not a new thing that while connecting to SSH port (22), some people come across with the error that refusing the connection to port 22. I haven’t remembered the exact error but it says something like Port 22: Connection refused. Basically it happens when you haven’t installed openssh library packages into your machine. Well its quite easy to resolve the issue. Either you download OpenSSH Libraries from their website, configure, and make the binaries or else take the help of apt-get. You might have also noticed that apt-get also shows some errors while connecting to the package repositories servers even though you are connected to the internet. Though it doesn’t happen always but its better to know how to overcome from this problem. For this always you should update your apt-get repository details in your localhost as sometimes the details are not synced-up. So to do this use sudo or if you are having root privileges then directly use the command
[xylux @ oracle~] $sudo apt-get update
Then your system will take sometime to updates its repository data and locations. Just wait for sometime and let it update the data. Once it gets completed then you can easily update your openssl libraries by using apt-get command again.
[xylux @ oracle~] $sudo apt-get install openssh-server
Once it gets installed then your SSH Connectivity from external IP address should work out!! Actually this is a restriction which is implemented by the developers for Ubuntu (in latest versions). As it increases security concern for your system.
DON’T implement the above process if you don’t know what you are doing!
Cheers!
XyluX