Page 1 of 2 12 LastLast
Results 1 to 10 of 15

Thread: Cannot SSH into network device

  1. #1
    Join Date
    Nov 2008
    Posts
    2,153
    Blog Entries
    1

    Default Cannot SSH into network device

    I am trying to connect to a network device using ssh.

    I get the following result:-

    Code:
    Unable to negotiate with 192.168.169.132 port 22: no matching host key type found. Their offer: ssh-rsa
    
    I have spent a long time on Google trying to find solution but still not getting a connection.

    Please can somebody help.

  2. #2
    Join Date
    Mar 2011
    Location
    Sauerland
    Posts
    6,625

    Default AW: Cannot SSH into network device

    Is this your Server?
    Code:
    192.168.169.132
    Change on the Server:
    PasswordAuthentication no
    to
    PasswordAuthentication yes

    in /etc/ssh/sshd_config

    Restart the ssh-Server.

  3. #3
    Join Date
    Sep 2012
    Posts
    6,950

    Default Re: Cannot SSH into network device

    Quote Originally Posted by Budgie2 View Post
    Code:
    Unable to negotiate with 192.168.169.132 port 22: no matching host key type found. Their offer: ssh-rsa
    
    I have spent a long time on Google trying to find solution but still not getting a connection.
    Code:
    ssh -o "HostKeyAlgorithms ssh-rsa" user@hostname
    Quote Originally Posted by Sauerland View Post
    Is this your Server?
    Code:
    192.168.169.132
    Change on the Server:
    PasswordAuthentication no
    How is host key related to authentication? Authentication happens after connection to host is established.

  4. #4
    Join Date
    Nov 2008
    Posts
    2,153
    Blog Entries
    1

    Default Re: AW: Cannot SSH into network device

    Quote Originally Posted by Sauerland View Post
    Is this your Server?
    Code:
    192.168.169.132
    Change on the Server:
    PasswordAuthentication no
    to
    PasswordAuthentication yes

    in /etc/ssh/sshd_config

    Restart the ssh-Server.
    Many thanks. A couple of questions:
    The IP address is the fixed address of the remote (client?) network device.
    My laptop is on another dhcp address on same subnet.
    I have no sshd_config file, only two directories ssh_config.d and sshd_config.d
    I assume I create a sshd_config file but am not sure about syntax and context. Should I just create the sshd_config file and have one line PasswordAuthentication yes?


  5. #5
    Join Date
    Nov 2008
    Posts
    2,153
    Blog Entries
    1

    Default Re: Cannot SSH into network device

    I have tried the suggested fix and now I get a different error:-
    Code:
    Unable to negotiate with 192.168.169.132 port 22: no matching cipher found. Their offer: aes256-cbc,3des-cbc
    
    What is missing here. Is it a problem with out of date firmware on the network device or some setting on my laptop?

  6. #6
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    32,069
    Blog Entries
    15

    Default Re: Cannot SSH into network device

    Hi
    So you need to be more clear in describing the issue

    The target system is 192.168.169.132, your on a host at the same ip address 192.168.169.xxx?

    Say you want to setup root user access;

    Code:
    ssh-copy-id root@192.168.169.132
    If just your user to the same user on 192.168.169.132 then just copy-id to the ip address.

    No local configuration required....
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

  7. #7
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    32,069
    Blog Entries
    15

    Default Re: Cannot SSH into network device

    Quote Originally Posted by Budgie2 View Post
    I have tried the suggested fix and now I get a different error:-
    Code:
    Unable to negotiate with 192.168.169.132 port 22: no matching cipher found. Their offer: aes256-cbc,3des-cbc
    
    What is missing here. Is it a problem with out of date firmware on the network device or some setting on my laptop?
    Hi
    The cipher option.....

    Code:
    ssh -Q cipher
    
    ssh -c aes256-cbc user@host
    
    ssh -c 3des-cbc user@host
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

  8. #8
    Join Date
    Nov 2008
    Posts
    2,153
    Blog Entries
    1

    Default Re: Cannot SSH into network device

    I shall explain in more detail.

    I have an APC UPS which has a Network Management Card (NMC) on which I was trying to update the firmware. This was supposed to be done using an APC Windoze app and I implemented this using a copper connection from NIC configured on the same subnet.

    Unfortunately the update crashed before completion and left me with a broken system which I was not able to revive but which I could still access because the IP remained working and I was able to access using ftp. Looking round all the accessible directories on the device it seems that there could be quite a lot missing including the config.ini file.

    My plan is therefore to copy the config.ini from another NMC borrowed from a working system. There are instructions for doing this in the APC manuals but I need to access both devices using ftp.

    I had been trying to access the working device first using ssh because I am working across network with wifi and managed switches in between and was not sure about ftp. This is where I have reached.

    The ssh exercise was me being side tracked as I really should be using ftp but I do need to follow the APC instructions for getting the good config.ini from my working device and all attempts get me connection refused thus:-
    Code:
    alastair@localhost:~> ftp 192.168.169.132 
    ftp: Can't connect to `192.168.169.132:21': Connection refused 
    ftp: Can't connect to `192.168.169.132:ftp'
    
    This was with the working machine plugged into the network but I have physical access so could use a copper connection if that would be better. This is where I am stuck.

    If my plan fails and the damaged NMC still fails, there are instructions for how to start over using a serial connection. These are clear but I shall need help with using the USB to serial adaptor which I have but have no idea how to configure and then I have to root the machine!

    If you have time helping me to ftp to the working machine please tell me where I should start as that would at least get me a copy of the working config.ini file.

    Regards,
    Budge.

  9. #9
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    32,069
    Blog Entries
    15

    Default Re: Cannot SSH into network device

    Hi
    Surely there is a way to restore from such a situation? Like a factory reset, recover from being bricked etc....?
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

  10. #10
    Join Date
    Nov 2008
    Posts
    2,153
    Blog Entries
    1

    Default Re: Cannot SSH into network device

    Not found a factory reset but only one link on the APC website which seems hopeful:-
    Video: Using Network Management Card 2 (NMC2) bootmonitor to recover/upgrade firmware
    This requires using serial port connection. On further searching and reading I think I should go straight to this but will need help with setting up the USB-serial connection. It gives me the port parameters but finding which connection is the one on my laptop is a challenge. This is how it starts...

    Resolution
    The BootMonitor is roughly equivalent to the BIOS in a computer system. It offers users the ability to connect to it by using a serial communications cable. Once connected the user can query the BootMonitor for NMC related information, upload firmware files and reset/format the NMC by issuing relevant commands (a full list of commands is available in Appendix A at the end of this guide).
    The following steps highlight how to connect to the NMC BootMonitor (Steps 1 - 3), how to reset the card to the default factory settings (Steps 4 - 5) and how to upload firmware files by using XMODEM (Steps 6 - 10).
    I shall try and follow this and call for help when connected.

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •