To conserve disk space, I removed /boot from most of my jails, and when I do that, freebsd-update refuses to run saying that "Cannot identify running kernel".
freebsd-update fetches the kern.bootfile sysctl, then checks that the corresponding directory exists.
The security.jail.jailed sysctl can be used to determine if we are running in a jail; FreeBSD-update could check that sysctl and ignore failure to find a kernel if so. We should still update the kernel if found, but silently ignore if not.
Drop freebsd-update PRs which were assigned to me. I'm not working on this code any more.
this is not a bug. freebsd-update fetch command doesn't know your freebsd version because no zfs release to /boot.
$ zpool list
$ zfs list
if you are seen boot run:
$ zpool import bootpool
you can try it:
$ freebsd-update fetch
A jail does not have any bootable filesystem, it is a jail.
It would be indeed much cleaner if freebsd-update natively supported jails without a /boot. Although as a workaround you can use the following:
freebsd-update --currently-running "RELEASE VERSION YOU RUN IN THE JAIL"
# freebsd-update --currently-running 12.0 fetch install
src component not installed, skipped
Cannot identify running kernel
Have you tried this too:
freebsd-update --currently-running 12.0-RELEASE fetch install