You can enable LWIP debugging messages in lwipopts.h, and forward them to some working uart.
It will be useful during initial debugging.
Stopping working after some time can ba caused be memory leaks, and debug info with name of empty pool will help.
Second possible issue is that some old (?) STM32 demo code only processed one packet per interrupt, causing extra packets to be stalled in memory.