Install ssh server on embedded device

Adam picture Adam · Apr 22, 2014 · Viewed 8.3k times · Source

I'm trying to connect to an embedded device through ssh. However, when trying to connect, I always get a connection refused message even when I try changing the port number. I've tried everything to resolve this issue, from changing the file in /etc/ssh/ to accept the specific port number, to sudo iptables -A INPUT -p tcp --dport ssh -j ACCEPT .

After reading some comments, it came to me that maybe one of the problems is that I don't have ssh installed on my embedded device. So, how do I infact install ssh on an embedded device? I'm working with a FOX G20 V board with an ATMEL AT91SAM9G20.

I would appreciate any help since I've been stuck on this problem for several days now.

Answer

Rahul R Dhobi picture Rahul R Dhobi · Apr 22, 2014

You need to cross compile OpenSSH for your embedded device,Follow below steps

  1. Download OpenSSH from http://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-6.6p1.tar.gz
  2. extract it and cross-compile it using toolchain

    ./configure --host="board architecture"

    make

  3. Copy sshd from compiled source and download it in your embedded device and run it

    /path/sshd

  4. Try to connect with your embedded device