How To: Ubuntu / Debian Linux Regenerate OpenSSH Host Keys

Posted on in Categories , , , , , last updated June 9, 2018

How do I regenerate OpenSSH sshd server host keys stored in /etc/ssh/ssh_host_* files? Can I safely regenerate ssh host keys using remote ssh session as my existing ssh connections shouldn’t be interrupted on Debian or Ubuntu Linux? How do I regenerate new ssh server keys? How to regenerate new host keys on a Debian or Ubuntu Linux?