Backup data of influxdb

Hi everyone,

Please show me the solution!
I am designing a system which collect the sensor data. There are 2 part:

Local part: Sensor send data and input to influxdb (local), all at a local PC
Server part: local PC send data to server PC over internet, and input to influxdb (server)

At normal operation, data of local influxdb and server influxdb are SAME.
However, if internet is down, there is new data in local influxdb, not in server influxdb.
After internet become up later, I want to merge local influxdb to server influxdb.

Can you tell me how to do that?
Thank you so much!