path: root/meta
diff options
authorMikko Rapeli <>2019-05-09 10:22:44 +0300
committerRichard Purdie <>2019-05-12 09:04:05 +0100
commit9b01375236e19e3366c58877c4154d7c71632984 (patch)
tree5adc2e1c135a92f639fa8e1de9b9bf616e643ea2 /meta
parentc0a0590eed7b60c8da5a496169f2ab6f19f4f06f (diff)
openssh: recommend rng-tools with sshd
Since openssl 1.1.1 and openssh which uses it, sshd startup is delayed. The delays range from few seconds to minutes and even to hours. The delays are visible in host keys generation and when sshd process is started in response to incoming TCP connection but is failing to provide SSH version string and clients or tests time out. In all cases traces show that sshd is waiting for getentropy() system call to return from Linux kernel, which returns only after kernel side random number pool is initialized. The pool is initialized via various entropy source which may be missing on embedded development boards or via rngd from rng-tools package from userspace. HW random number generation and kernel support help but rngd is till needed to feed that data back to the Linux kernel. Example from an NXP imx8 board shows that kernel random number pool initialization can take over 400 seconds without rngd, and with rngd it is initialized at around 4 seconds after boot. The completion of initialization is visible in kernel dmesg with line "random: crng init done". More details are available from: * * * * Signed-off-by: Mikko Rapeli <> Cc: Mark Hatle <> Cc: Rasmus Villemoes <> Cc: Adrian Bunk <> Signed-off-by: Richard Purdie <>
Diffstat (limited to 'meta')
1 files changed, 1 insertions, 0 deletions
diff --git a/meta/recipes-connectivity/openssh/ b/meta/recipes-connectivity/openssh/
index b971b2b1e8..976bcc53a1 100644
--- a/meta/recipes-connectivity/openssh/
+++ b/meta/recipes-connectivity/openssh/
@@ -148,6 +148,7 @@ FILES_${PN}-keygen = "${bindir}/ssh-keygen"
RDEPENDS_${PN} += "${PN}-scp ${PN}-ssh ${PN}-sshd ${PN}-keygen"
RDEPENDS_${PN}-sshd += "${PN}-keygen ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam-plugin-keyinit pam-plugin-loginuid', '', d)}"
+RRECOMMENDS_${PN}-sshd += "rng-tools"
RDEPENDS_${PN}-ptest += "${PN}-sftp ${PN}-misc ${PN}-sftp-server make sed"
RPROVIDES_${PN}-ssh = "ssh"