Blynk disconnects every 6 hours roughly

You will need to look at using connection management routines to monitor Blynk connection status, and if unavailable reboot the Arduino.

This is a basic example you will have to tailor to the Mega and Ethernet…