Hi,
You are probably going to need to do a little research. This or similar questions have come up a number of times over the years. You will find there are many solutions, some good, some better, but I suspect each being suitable in the users own circumstances. A few thoughts:
1. Unless you are using an extremely short archive interval there should be no need to stop WeeWX
2. A safe approach is to make a local copy of your database and then compress/transfer/rename or otherwise process this local copy
3. There can be a tendency to want to backup immediately after midnight, that is fine but the first archive period after midnight can be a busy period for WeeWX. Schedule your backup for the next archive period or later or once you are certain WeeWX has finished archiving/reporting etc.
4. What ever solution you adopt check that it works, I know of at least one user who thought they were backing up their sqlite db only to find when the crunch came their backup was corrupt/unreadable.
You might find
this thread has some helpful information.
Gary