fexecve failed, disabling re-exec: No such file or directory
Ondrej Jombik
jombik at platon.org
Tue Jun 4 05:40:51 AWST 2024
Dropbear was working well for me for 12+ years (since 2012) in
combination with initrd and LUKS. Problems started only after I upgraded
home server to Debian/12 (Bookworm).
To mitigate problem I completelly reinstalled dropbear-initramfs and
dropbear-bin packages and configured it from scratch. I also regenerated
all the hosts keys and SSH connection keys -- both are ed25519 now.
My problem is that Dropbear does not accept my private key. In Dropbear
logs I see it is failing with this error message:
Jun 03 21:21:24 fexecve failed, disabling re-exec: No such file or directory
So I included strace binary into my initrd so I can see what is
happening inside Dropbear execution. Then I started Dropbear manually
from the initramfs like this:
strace -ff -s 110 /usr/sbin/dropbear -p 2222 -F -E 2>&1
Here is strace except which is failing:
[pid 647] execveat(5, "", ["/usr/sbin/dropbear", "-p", "2222", "-F", "-E", "-2", "8"], 0x7ffce5b5bb78 /* 35 vars */, AT_EMPTY_PATH <unfinished ...>
[pid 642] read(8, "cpu: 3\n clock 0:\n .base: 000000003090162a\n .index: 0\n .resolution: 1 nsecs\n .get_time: ktime_"..., 4096) = 3654
[pid 647] <... execveat resumed>) = -1 ENOENT (No such file or directory)
[pid 642] read(8, <unfinished ...>
[pid 647] openat(AT_FDCWD, "/etc/localtime", O_RDONLY|O_CLOEXEC <unfinished ...>
[pid 642] <... read resumed>"Tick Device: mode: 1\nPer CPU device: 2\nClock Event Device: lapic\n max_delta_ns: 257685158444\n min_delta_"..., 4096) = 909
[pid 647] <... openat resumed>) = -1 ENOENT (No such file or directory)
[pid 642] read(8, <unfinished ...>
[pid 647] getpid( <unfinished ...>
[pid 642] <... read resumed>"", 4096) = 0
[pid 647] <... getpid resumed>) = 647
[pid 642] close(8 <unfinished ...>
[pid 647] write(2, "[647] Jun 03 21:21:24 fexecve failed, disabling re-exec: No such file or directory\n", 83[647] Jun 03 21:21:24 fexecve failed, disabling re-exec: No such file or directory
<unfinished ...>
The first and the last lines are the important ones.
Dropbear is adding "-2 8" to parameters and then it tries to re-exec
itself. Here it is where I need a bit of help.
1. What is the purpose of -2 option?
2. Is "8" a filedescriptor ID?
3. Why is error message "No such file or directory" when
/usr/sbin/dropbear clearly exists?
(NOTE: also /sbin/dropbear does exist)
4. What exactly is failing here? execveat()?
I know this must be some kind of weird problem, since I was unable to find
anything related on the internet. Therefor any ideas, comments, or notes
would be welcomed. Thanks!
--
Ondrej JOMBIK
Platon Technologies, s.r.o., Hlavna 3, Sala SK-92701
+421222111321 - info at platon.net - https://platon.net
Blog: Pellegriniho zmluva o domene .SK je nevypovedatelna
https://jombik.blog.sme.sk/c/528753/pellegriniho-zmluva-o-domene-sk-je-nevypovedatelna.html
My current location: Bratislava, Slovakia
My current timezone: UTC +1:00 (CET)
(updated automatically)
More information about the Dropbear
mailing list