The current Yocto basefiles fstab mounts /var/volatile as tmpfs, which results in the loss of all files stored in /var/tmp upon reboot.
 
fstab in base-files:

https://git.yoctoproject.org/poky/tree/meta/recipes-core/base-files/base-files/fstab?h=scarthgap&id=3cc8c3520cedb66500757f843f757646da69ab30#n7

Since /var/volatile is a tmpfs, its contents are lost on reboot.
 
This commit might have introduced the issue - since /var/volatile/tmp is inside a tmpfs mount, it gets wiped on reboot, meaning /var/tmp is also cleared.

Commit - https://git.yoctoproject.org/poky/commit/meta/recipes-core/systemd/systemd/00-create-volatile.conf?h=scarthgap&id=3cc8c3520cedb66500757f843f757646da69ab30 

 
This commit links /var/tmp to /var/volatile/tmp

 

Expected Behavior

 

Impact

 

Should /var/tmp continue following standard Linux behavior by not being linked to /var/volatile/tmp, or is this change intentional for specific use cases? If persistence is desired, this approach seems problematic.

Would appreciate input from the maintainers on whether this is a bug or intended behavior.