I may be off on a tangent here, but what does the OpenHAB regional settings page look like on the 2 different systems?
(Settings->Regional Settings-> Timezone & Location)
I am also on same version of OpenHAB (4.2.1) and Ubuntu 24.04.1 and my system TZ settings look the same as yours (RTC=UTC).
No issues for me with TZ in scripts so far…(Also used to be on Ubuntu 22.x with same result).
Also, different OS, but perhaps keep your eye on this thread too, which is currently in play: