Spawn chunks might work differently if there was no player there in a long time.
The Minecraft wiki says:
Each dimension has its own "idle timeout." Without a player or forceloaded chunks in the overworld, this timeout eventually expires. When the timeout expires, some behaviors such as entity processing stop for spawn chunks and the rest of the dimension. The timeout can be reset by frequently sending entities through a portal.
If you can use operator commands on the server, you can use the
/forceload command to keep the chunks loaded, when no players are near or are online. (More details here)
If you have no operator rights, or you just don't want to use commands, you could try and build a machine that loads the chunks (e.g. the machine in this video), but this might not work.
And here's some additional info on chunk loading, if something's still wrong.