Enable SSH in Ubuntu 14.04 Trusty Tahr

April 15, 2014 — 20 Comments

enable ssh ubuntu 14.04

This simple tutorial is going to show you how to enable Secure Shell (SSH) service in Ubuntu 14.04 Trusty Tahr.

Secure Shell (SSH) is a cryptographic network protocol for secure data communication, remote command-line login, remote command execution, and other secure network services between two networked computers.

SSH is not enabled by default in Ubuntu, but you can easily enable this service via OpenSSH, a free version of the SSH connectivity tools developed by the OpenBSD Project.

To do so, run the command below in terminal:

sudo apt-get install openssh-server

Or install the openssh-server package via Ubuntu Software Center if you’re on Desktop edition:

install ssh server Ubuntu 14.04

Once installed, you can change the port, disable root login and do other changes by editing the config file:

sudo gedit /etc/ssh/sshd_config

Finally restart the ssh server to take place:

sudo /etc/init.d/ssh restart

That’s it. Enjoy!

I'm a freelance blogger who started using Ubuntu 5+ years ago and wishes to share my experiences and some useful tips with Ubuntu beginners and lovers. Please notify me if you find any typo/grammar/language mistakes. English is not my native language. Contact me on Google Plus or email to ubuntuhandbook1@gmail.com

20 responses to Enable SSH in Ubuntu 14.04 Trusty Tahr

  1. Thanks for the easy-to-follow tutorial. It most very helpful.

  2. Thank you. But the root user can’t connect with ssh, too. How to unlock it?

    • Edit the /etc/ssh/sshd_config file and change PermitRootLogin no into PermitRootLogin yes. Finally restart ssh service.

      • Hi I have installed Ubuntu server 14.04 on Virtualbox in my Macbook Pro. I can’t use the mouse to scroll or highlight to do cut and paste … found out you need to use openssh. So I installed it by doing sudo apt-get dist-upgrade, used my terminal to do ssh. Here is the result…
        Reynaldos-MacBook-Pro:~ reynaldobilan$ ssh bluephoenix71@inet

        ssh: connect to host inet port 22: Operation timed out

        prompt on the Ubuntu Server:

        What do I need to do in order to ssh to the server I have emulated in Vbox?

        my network settings on the Vbox settings:
        Bridge Adapter
        Promiscuous mode: Allow VMs
        Cable connected: checked

        I can ping from the terminal to the server in Vbox…

        Please help?


      • Thanks much!

        PermitRootLogin withoutpassword
        PermitRootLogin yes

      • Hi, I am trying to edit this file in my local pc but when i try to save this file it says
        Could not create a backup file while saving “/etc/ssh/sshd_config”

        What shall i do?

  3. In Trusty, Nautilus no long gives option in ‘Connect to server’ to specify type e.g. ssh & user/password. Any ideas?

  4. You want the last command to be:
    sudo service ssh restart

  5. On a new install remember to do

    sudo apt-get update


  6. This post, along with this entry https://help.ubuntu.com/community/SSH/OpenSSH/Configuring was very helpful. Thank you for explaining.
    i had a problem with the port not changing for some reason when i edited the sshd_config.
    this post helped me and it’s fine now

    now hopefully this works. i’m really new to all this, first time with ftp/sftp still a little confused about everything but i learned a lot so far. thank you

  7. Thank you for the easy and quick explanation.

    Your work on this website on helping people with Ubuntu is most appreciated.


  8. I’m on a new install of ubuntu 14.04 (64 bit). Installed gnome shell, then tried to install openssh-server. I tried both apt-get and software center – both fail. apt-get says: libck-connector0 is not installable.

    Any ideas?

  9. I have done everything right and SSH is installed but I have failed to connect to my ubuntu desktop through putty on windows.
    This is the message it gives:
    Disconnected: No authentication methods available (server sent:)
    what do i need to do????

    • This is a key issue related to PuTTY. Just search that message in Google, there’s quite a few answers explained how to solve it.

  10. Hi,
    I am able to to ssh other ubuntu system with the ip “ssh 192.168.x.x” which is in the same network ,while debugging “ssh -v ” i see the connection is established but, i am not able to acces the files of the remote machine.

    I have tried the rsa key generation and copying it to server. when i ssh with the complete name “ssh hostname@ip” i get permission denied.(public key,password).i have changed the sshd_config files and restarted but facing the same issue.

    Any idea why it is not working properly.

  11. Hi,

    My system works fine, but we are required to upgrade our version of openssh
    from (6.6 on trusty) to v6.9 or greater.

    I can actually get v6.9 to run, but the upstart commands for the daemon refuse to operate correctly after installation.

    Please see my post with all details here:

    I’ve actually tried to compile/install v7.1 too.
    It has the same sickness – works – but the upstart commands do not…

    Any ideas?


  12. ubuntu 14 desktop giving erorr why difficult ? eror mesage is here ;

    openssh-server: Depends: libck-connector0 (>= 0.2.1) but it is not going to be installed
    Depends: openssh-client (= 1:6.6p1-2ubuntu2.4) but 1:6.6p1-2ubuntu2.4 is to be installed

Leave a Reply


Text formatting is available via select HTML.

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>