← Back to team overview

touch-packages team mailing list archive

[Bug 1370523] Re: After Precise->Trusty, no /etc/ssh/ssh_host_ed25519_key is created

 

*** This bug is a duplicate of bug 1005440 ***
    https://bugs.launchpad.net/bugs/1005440

The openssh-server.postint does have code to create missing host keys:

host_keys_required() {
        hostkeys="$(get_config_option HostKey)"
        if [ "$hostkeys" ]; then
                echo "$hostkeys"
        else
                # No HostKey directives at all, so the server picks some
                # defaults depending on the setting of Protocol.
                protocol="$(get_config_option Protocol)"
                [ "$protocol" ] || protocol=1,2
                if echo "$protocol" | grep 1 >/dev/null; then
                        echo /etc/ssh/ssh_host_key
                fi
                if echo "$protocol" | grep 2 >/dev/null; then
                        echo /etc/ssh/ssh_host_rsa_key
                        echo /etc/ssh/ssh_host_dsa_key
                        echo /etc/ssh/ssh_host_ecdsa_key
                        echo /etc/ssh/ssh_host_ed25519_key
                fi
        fi
}

And running "dpkg-reconfigure openssh-server" fixes the issue.

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to openssh in Ubuntu.
https://bugs.launchpad.net/bugs/1370523

Title:
  After Precise->Trusty, no /etc/ssh/ssh_host_ed25519_key is created

Status in “openssh” package in Ubuntu:
  New

Bug description:
  After upgrading a Precise (12.04.5) host to Trusty (14.04.1) the
  OpenSSH server keeps complaining about a missing host key:
  /etc/ssh/ssh_host_ed25519_key

  # grep -cF 'Could not load host key: /etc/ssh/ssh_host_ed25519_key' /var/log/auth.log
  203

  It seems the OpenSSH package doesn't run "ssh-keygen -A" in postinst.

  Workaround: run ssh-keygen -A as root:

  # ssh-keygen -A
  ssh-keygen: generating new host keys: RSA1 ED25519 


  More information on the upgraded machine:

  # lsb_release -rd
  Description:	Ubuntu 14.04.1 LTS
  Release:	14.04
  # apt-cache policy openssh-server
  openssh-server:
    Installed: 1:6.6p1-2ubuntu2
    Candidate: 1:6.6p1-2ubuntu2
    Version table:
   *** 1:6.6p1-2ubuntu2 0
          500 http://archive.ubuntu.com/ubuntu/ trusty-updates/main amd64 Packages
          100 /var/lib/dpkg/status
       1:6.6p1-2ubuntu1 0
          500 http://archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages

  ProblemType: Bug
  DistroRelease: Ubuntu 14.04
  Package: openssh-server 1:6.6p1-2ubuntu2
  ProcVersionSignature: Ubuntu 3.13.0-35.62-generic 3.13.11.6
  Uname: Linux 3.13.0-35-generic x86_64
  ApportVersion: 2.14.1-0ubuntu3.4
  Architecture: amd64
  Date: Wed Sep 17 09:35:34 2014
  InstallationDate: Installed on 2013-01-04 (620 days ago)
  InstallationMedia: Ubuntu 12.04.1 LTS "Precise Pangolin" - Release amd64 (20120822.4)
  ProcEnviron:
   LANGUAGE=en_CA:en
   TERM=xterm
   PATH=(custom, no user)
   LANG=en_CA.UTF-8
   SHELL=/bin/bash
  SourcePackage: openssh
  UpgradeStatus: Upgraded to trusty on 2014-08-29 (18 days ago)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/openssh/+bug/1370523/+subscriptions


References