i was trying to Rsync without password to rssh shell using



ssh-copy-id -i /root/.ssh/id_rsa.pub '-p 12345 user@example'

but i couldn't got the following message

This account is restricted by rssh.
Allowed commands: rsync

If you believe this is in error, please contact your system administrator.

and that because the only working comand at rssh shell is rsync but how could i made rssh shell working without password ?


1 Answer 1


Try rsync /root/.ssh/id_rsa.pub user@example/.ssh/authorized_keys to publish your key.

ssh-copy-id is just a really basic shell script that copies your key file to the remote server. There is no magic. If there is already an authorized_keys file on the remote server, then download it, modify it and re-publish using rsync.

  • still not working i add the -e option because the remote server have custom ssh port so i got "insecure -e option not allowed" i will explain more about the issue :- i was trying to set to the remote server a user with limit directory access so i installed rssh and i trying to made ssh-key without password to put rsync command running to backup the local server files to the remote server have rssh instead to set on "root access" in case of someone can access to the remote server with root privillages
    – iLinux85
    Dec 22, 2011 at 11:38
  • If rssh is setup properly, then it should work. Using rssh on the root account seems a bit silly to me. I would have simply used a ForceCommand in your authorized_keys file for the backup key. serverfault.com/questions/323501/…
    – Zoredache
    Dec 22, 2011 at 11:45
  • Still I don't really see how you gain much. If you allow someone to arbitrarily run rsync remotely, what would stop them from simply uploading a file to disable rssh or whatever you are using to try and restrict the session?
    – Zoredache
    Dec 22, 2011 at 11:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.