virtual machine not accessible by putty or ssh (port 22: Connection refused)

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite
1












I have installed ubuntu on VMware® Workstation 14 Player.



I can see the ip with ifconfig:



eth0 Link encap:Ethernet HWaddr 00:0c:29:65:af:66 
inet addr:192.168.223.129 Bcast:192.168.223.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fe65:af66/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:337 errors:0 dropped:0 overruns:0 frame:0
TX packets:362 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:40108 (40.1 KB) TX bytes:34591 (34.5 KB)
Interrupt:19 Base address:0x2000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:686 errors:0 dropped:0 overruns:0 frame:0
TX packets:686 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:54536 (54.5 KB) TX bytes:54536 (54.5 KB)


When I try to connect by ssh or putty It is not connecting and returning message:



ssh 192.168.223.129
ssh: connect to host 192.168.223.129 port 22: Connection refused






share|improve this question






















  • Are you sure that the sshd is installed and running?
    – mnille
    Apr 11 at 5:13














up vote
0
down vote

favorite
1












I have installed ubuntu on VMware® Workstation 14 Player.



I can see the ip with ifconfig:



eth0 Link encap:Ethernet HWaddr 00:0c:29:65:af:66 
inet addr:192.168.223.129 Bcast:192.168.223.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fe65:af66/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:337 errors:0 dropped:0 overruns:0 frame:0
TX packets:362 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:40108 (40.1 KB) TX bytes:34591 (34.5 KB)
Interrupt:19 Base address:0x2000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:686 errors:0 dropped:0 overruns:0 frame:0
TX packets:686 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:54536 (54.5 KB) TX bytes:54536 (54.5 KB)


When I try to connect by ssh or putty It is not connecting and returning message:



ssh 192.168.223.129
ssh: connect to host 192.168.223.129 port 22: Connection refused






share|improve this question






















  • Are you sure that the sshd is installed and running?
    – mnille
    Apr 11 at 5:13












up vote
0
down vote

favorite
1









up vote
0
down vote

favorite
1






1





I have installed ubuntu on VMware® Workstation 14 Player.



I can see the ip with ifconfig:



eth0 Link encap:Ethernet HWaddr 00:0c:29:65:af:66 
inet addr:192.168.223.129 Bcast:192.168.223.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fe65:af66/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:337 errors:0 dropped:0 overruns:0 frame:0
TX packets:362 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:40108 (40.1 KB) TX bytes:34591 (34.5 KB)
Interrupt:19 Base address:0x2000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:686 errors:0 dropped:0 overruns:0 frame:0
TX packets:686 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:54536 (54.5 KB) TX bytes:54536 (54.5 KB)


When I try to connect by ssh or putty It is not connecting and returning message:



ssh 192.168.223.129
ssh: connect to host 192.168.223.129 port 22: Connection refused






share|improve this question














I have installed ubuntu on VMware® Workstation 14 Player.



I can see the ip with ifconfig:



eth0 Link encap:Ethernet HWaddr 00:0c:29:65:af:66 
inet addr:192.168.223.129 Bcast:192.168.223.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fe65:af66/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:337 errors:0 dropped:0 overruns:0 frame:0
TX packets:362 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:40108 (40.1 KB) TX bytes:34591 (34.5 KB)
Interrupt:19 Base address:0x2000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:686 errors:0 dropped:0 overruns:0 frame:0
TX packets:686 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:54536 (54.5 KB) TX bytes:54536 (54.5 KB)


When I try to connect by ssh or putty It is not connecting and returning message:



ssh 192.168.223.129
ssh: connect to host 192.168.223.129 port 22: Connection refused








share|improve this question













share|improve this question




share|improve this question








edited Apr 11 at 9:38









Jeff Schaller

31.1k846105




31.1k846105










asked Apr 11 at 4:38









Ashfaq

63




63











  • Are you sure that the sshd is installed and running?
    – mnille
    Apr 11 at 5:13
















  • Are you sure that the sshd is installed and running?
    – mnille
    Apr 11 at 5:13















Are you sure that the sshd is installed and running?
– mnille
Apr 11 at 5:13




Are you sure that the sshd is installed and running?
– mnille
Apr 11 at 5:13










1 Answer
1






active

oldest

votes

















up vote
3
down vote



accepted










You need to install ssh server on your ubuntu:



sudo apt-get install openssh-server


Now start and enable the debian ssh server to start at system reboot.



systemctl start ssh.service

systemctl enable ssh.service


Also run netstat command to make sure that ssh port 22 is open and running.



netstat -tulnp | grep 22


then try to access...






share|improve this answer




















    Your Answer







    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "106"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    convertImagesToLinks: false,
    noModals: false,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );








     

    draft saved


    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f436913%2fvirtual-machine-not-accessible-by-putty-or-ssh-port-22-connection-refused%23new-answer', 'question_page');

    );

    Post as a guest






























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    3
    down vote



    accepted










    You need to install ssh server on your ubuntu:



    sudo apt-get install openssh-server


    Now start and enable the debian ssh server to start at system reboot.



    systemctl start ssh.service

    systemctl enable ssh.service


    Also run netstat command to make sure that ssh port 22 is open and running.



    netstat -tulnp | grep 22


    then try to access...






    share|improve this answer
























      up vote
      3
      down vote



      accepted










      You need to install ssh server on your ubuntu:



      sudo apt-get install openssh-server


      Now start and enable the debian ssh server to start at system reboot.



      systemctl start ssh.service

      systemctl enable ssh.service


      Also run netstat command to make sure that ssh port 22 is open and running.



      netstat -tulnp | grep 22


      then try to access...






      share|improve this answer






















        up vote
        3
        down vote



        accepted







        up vote
        3
        down vote



        accepted






        You need to install ssh server on your ubuntu:



        sudo apt-get install openssh-server


        Now start and enable the debian ssh server to start at system reboot.



        systemctl start ssh.service

        systemctl enable ssh.service


        Also run netstat command to make sure that ssh port 22 is open and running.



        netstat -tulnp | grep 22


        then try to access...






        share|improve this answer












        You need to install ssh server on your ubuntu:



        sudo apt-get install openssh-server


        Now start and enable the debian ssh server to start at system reboot.



        systemctl start ssh.service

        systemctl enable ssh.service


        Also run netstat command to make sure that ssh port 22 is open and running.



        netstat -tulnp | grep 22


        then try to access...







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Apr 11 at 7:45









        flik

        1485




        1485






















             

            draft saved


            draft discarded


























             


            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f436913%2fvirtual-machine-not-accessible-by-putty-or-ssh-port-22-connection-refused%23new-answer', 'question_page');

            );

            Post as a guest













































































            Popular posts from this blog

            How to check contact read email or not when send email to Individual?

            Displaying single band from multi-band raster using QGIS

            How many registers does an x86_64 CPU actually have?