[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: "FATAL: kernel too old" when running mmdebootstrap'd riscv64 chroot



On 10/23/18 5:59 PM, Luke Kenneth Casson Leighton wrote>> So, Luke, use qemu-user v3.0.0 or greater and everything should be fine.
> 
>  ok, that looks like it'd work... drat:
> 
>  this was the command that failed, i re-ran it as this:
>  # strace -o log.txt -ff env --unset=APT_CONFIG /usr/sbin/chroot
> /home/lkcl/src/libreriscv/debian-riscv64-chroot dpkg --install
> --force-depends
> 
>  and got this:
>  openat(AT_FDCWD, "/lib/ld-linux-riscv64-lp64d.so.1", O_RDONLY) = 3
> 
>  which i believe is inside the chroot.
> 
>  the configure i used for qemu was this:
>  $ ./configure --target-list="riscv32-softmmu,riscv64-softmmu,riscv32-linux-user,riscv64-linux-user"
> --static --disable-glusterfs --disable-gtk --disable-usb-redir
> 
> and followed it up with cp ./riscv64-linux-user/qemu-riscv64 /tmp (and
> then to the chroot).
> 
> so i believe although qemu may have been fixed, ld-linux hasn't.
It's not a bug in glibc (ld-linux), it just checks for the present kernel to
be recent enough. And if you use the qemu version with said patch for uname,
your glibc package will be tricked it's running on a recent enough kernel
because qemu reports uname to be 4.15.0, independent of what kernel version
you are actually running.

Adrian

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaubitz@debian.org
`. `'   Freie Universitaet Berlin - glaubitz@physik.fu-berlin.de
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913


Reply to: