Peter,
Ah ha! that jogged my memory... Even though openssh is in the IMAGE_INSTALL
group I still need to add "openssh-sshdgenkeys" since I'm splitting the openssh
package.
After adding "openssh-sshdgenkeys" into my image recipe service was installed
as expected but it is not getting enabled, even though I explicitly specified
to enable. Maybe I'm misunderstanding here...
SYSTEMD_AUTO_ENABLE:${PN}-sshdgenkeys = "enable"
For testing purposes, I started it manually:
root@localhost:~# systemctl status sshdgenkeys.service
* sshdgenkeys.service - OpenSSH Key Generation
Loaded: loaded (/lib/systemd/system/sshdgenkeys.service; static)
Active: inactive (dead)
root@localhost:~# systemctl start sshdgenkeys.service
root@localhost:~# systemctl status sshdgenkeys.service
* sshdgenkeys.service - OpenSSH Key Generation
Loaded: loaded (/lib/systemd/system/sshdgenkeys.service; static)
Active: active (exited) since Wed 2024-04-17 13:47:27 UTC; 2s ago
Process: 640 ExecStart=/usr/libexec/openssh/sshd_check_keys (code=exited,
status=0/SUCCESS)
Main PID: 640 (code=exited, status=0/SUCCESS)
Apr 17 13:47:24 localhost systemd[1]: Starting OpenSSH Key Generation...
Apr 17 13:47:26 localhost sshd_check_keys[646]: unknown option -- G
Apr 17 13:47:26 localhost sshd_check_keys[646]: OpenSSH_8.9p1, OpenSSL 3.0.8 7
Feb 2023
Apr 17 13:47:26 localhost sshd_check_keys[646]: usage: sshd [-46DdeiqTt] [-C
connection_spec] [-c host_cert_file]
Apr 17 13:47:26 localhost sshd_check_keys[646]: [-E log_file] [-f
config_file] [-g login_grace_time]
Apr 17 13:47:26 localhost sshd_check_keys[646]: [-h host_key_file]
[-o option] [-p port] [-u len]
Apr 17 13:47:27 localhost systemd[1]: Finished OpenSSH Key Generation.
root@localhost:~#
The output shows that the service is loaded but inactive. When I start it
manually, it becomes active, but I encounter a strange error: "unknown option
-- G." It seems like the version of sshd_check_keys script being used is newer
and expects "sshd -G," whereas my .bbappend file is for version 8.9p1.
I'm not sure why this discrepancy is occurring. Any thoughts?
Cheers,
Nitesh
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#62950): https://lists.yoctoproject.org/g/yocto/message/62950
Mute This Topic: https://lists.yoctoproject.org/mt/105575419/21656
Mute #systemd:https://lists.yoctoproject.org/g/yocto/mutehashtag/systemd
Mute #yocto:https://lists.yoctoproject.org/g/yocto/mutehashtag/yocto
Mute #kirkstone:https://lists.yoctoproject.org/g/yocto/mutehashtag/kirkstone
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-