Root access via ssh on Ubuntu 410c

Hi,
I am using a USB-Ethernet dongle to ssh into my 410c running Ubuntu, I can login fine into linaro account but it doesn’t let me write into /sys/class/gpio files. How to I login to root@linaro-developer?

I found this but it wasn’t very helpful - Bug #1322567 “SSH connection failed on Linux Linaro ubuntu image...” : Bugs : Linaro Ubuntu

Thanks

hi,

root login over ssh by default (in ubuntu) is permitted only if you configured ssh keys authentication. So you would need to create a pair of SSH keys and add your key to authorized_keys first.

Alternatively, once you are logged as linaro, you can do:

sudo su -

and become ‘root’

1 Like
  1. on your 96board login as root.

  2. if you dont have a /root/.ssh directory execute
    #ssh-keygen -t rsa

  3. on your host system if you dont have a ~/.ssh directory execute
    #ssh-keygen -t rsa

  4. copy/append your host ~/.ssh/id_rsa.pub to 96board /root/.ssh/authorized_keys

  5. on your host system now edit .ssh/config and add the following lines
    Host 410c
    Hostname <ipaddres_here>
    User root

  6. From your host you should now be able to login as root by executing
    $ ssh 410c

um, It seems the editor cut part of bullet 4 in my previous comment (here is an example of my .ssh/config)

Host 410c
Hostname 192.168.211.177
User root

sudo su – did the job for me :slight_smile:

Thanks

well it is hardly the same: you are login in as linaro and then changing to root.
What I mentioned above is a way to ssh directly into the root account (in this way you avoid wasting time executing su)…I suppose is a matter of how often you need to ssh as root (for me it would be a torture having to do what you do every time I need to login in a board with root access). I guess your use case is different.

You can also do as follows on board

  1. By default, the SSH server denies password-based login for root. In /etc/ssh/sshd_config, change:

PermitRootLogin without-password

to

PermitRootLogin yes

  1. restart SSH:

sudo service ssh restart

  1. Disabled TCP checksum offload:

ethtool -K eth0 tx off rx off

  1. connect to board from host via “ssh -Y root@ipaddress”

The above steps worked for me