GICT knowledge base
Steps to Install Dropbear SSH Server
Published
Dropbear is a small SSH server using in Linux distributions. It is an open source software. Dropbear SSH completely runs with SSH version 2 protocol, it never supports SSH version 1. Dropbear is an advanced version of open SSH, it only uses low memory and processor resources.
Install Dropbear
1) We need to enable Dropbear repo on the server to install Dropbear.
$ wget http://ftp-stud.hs-esslingen.de/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
$ rpm -Uvh http://ftp-stud.hs-esslingen.de/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
2) Install Dropbear.
$ yum install dropbear
3) Now Dropbear is successfully installed on the server. Configure the dropbear.
$ vi /etc/init.d/dropbear
Edit following parameter on the file.
OPTIONS=” -p 222″
Replace OpenSSH with Dropbear
After installing Dropbear we need to add Dropbear to startup (chkconfig), then restart the server.
$ chkconfig dropbear on
$ service dropbear restart
Remove OpenSSH from server.
$ yum remove openssh-server
If service won’t correctly start up when changing port, we need to update SELinux to the new port number.
$ semanage port -a -t ssh_port_t -p tcp 222
If semanage doesn’t exist on server, you need to install it.
$ yum install policycoreutils-python
Common error when connect with dropbear:
‘Not able to connect “No route to host”‘
The problem is, by default linux is configured to allow port 22 to access SSH. In here we need to change this to dropbear port number 222.
To change this:
# vi /etc/sysconfig/iptables
Here I am using 222 port for dropbear SSH, so we need to enable port 222 in iptables.
# iptables -A INPUT -m state –state NEW -m tcp -p tcp –dport 222 -j ACCEPT
Then restart iptables so the changes take effect.
# service iptables save
If you need any further help please reach our support department.
Related guides
How to Restrict an SSH Key to One Command
Restrict an SSH key to one command with authorized_keys options. Protect the command and check that unwanted shell and forwarding access are denied.
Linux and CommandsSelf-Hosted Video Processing With FFmpeg: A Practical Guide
Learn how to self-host video processing on a VPS using FFmpeg, with practical commands for conversion, compression, thumbnails, and automated workflows.
Linux and CommandsHow to use nohup: Commands in Linux That Survive Terminal Closes
Keep commands running after you close the terminal. nohup examples with wget, Python, rsync, and Docker on any VPS.
Linux and CommandsHow to Fix “Too Many Open Files” Error on Linux Servers
Learn how to fix the "Too Many Open Files" error on Linux servers by understanding file descriptors, adjusting limits, and diagnosing leaks effectively.
