Feature #387
Updated by Daniel Curtis almost 10 years ago
h1. BIG SCARY WARNING!!!
Permitting root logins is a *+VERY BAD IDEA+*, please reconsider before continuing this guide.
---
Unlike many Linux distributions, FreeBSD by default disables ‘root’ login over SSH, If you do need to enable remote root logins over SSH, using key-based logins would be a good idea; the more secure way of gaining remote admin access to your server would ideally be logging in as an alternative user and then using SUDO to perform any administrative tasks.
* First edit the SSH daemon configuration file:
<pre>
vi /etc/ssh/sshd_config
</pre>
* Find this line:
<pre>
#PermitRootLogin no
</pre>
* and change it to:
<pre>
PermitRootLogin yes
</pre>
Basically you should have removed the hash ‘#’ from the start of the line (uncomment the line basically) and then change ‘no’ to ‘yes’, save the file and then restart the SSH daemon like so..
<pre>
service sshd restart
</pre>
And your done, you should now be able to login as ‘root’ over SSH on your FreeBSD server!