Bootchartd doesn't function at boot when running in QEMU

I built a default test image and enabled bootchart in the configuration options. I didn't do many other configuration changes from the default besides than changing the target system to QEMU ARM virtual machine. I'm building v21.02.3, which seems to be the latest stable release.

When this is done, I'm able to run OpenWrt in a QEMU VM by way of:

qemu-system-arm -nographic -M virt -m 64 -kernel build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/linux-armvirt_32/zImage-initramfs --append "rdinit=/sbin/bootchartd"

Bootchartd starts up, and after the ~1 minute expiration, an error pops up saying "bootchartd: can't open 'header': No such file or directory"

If instead I start / stop bootchartd manually everything works fine.

UPDATE as I'm writing this (maybe this'll help someone else, and maybe someone else can offer some insight): By default /init gets run by bootchartd. /init creates a tmpfs jail and jumps to it before calling /sbin/init. If instead I add bootchart_init=/sbin/init I bypass this tmpfs creation, and /var/log/bootlog/tgz gets created as I expect.

Hopefully this helps someone. I'm not sure if this was intended behavior, but it seems like the tempfs jail breaks bootchart.