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 
<https://groups.google.com/forum/#!searchin/weewx-user/weewx.sdb$20backup%7Csort:date/weewx-user/UWHHpwkoVJ8/rWqH8gVQAgAJ>
 
has some helpful information.

Gary

On Monday, 15 June 2020 23:02:32 UTC+10, Frank von Thienen wrote:
>
> Hi all,
>
> I have not much knowlwdge about shell scripting, so I have to ask.
> I need the follwoing action in a shell script, so I can do a cron out of 
> it.
> 1. stop weewx (/etc/init.d/weewx stop)
> 2. ftp the sqlite.db from it's directory to a given directory (outside 
> raspberry) with a time stamp (so time stamp should be added while 
> transferring via ftp
> 3. start weewx (/etc/init.d/weewx start)
>
> can anyone give me a helping hand.
>
> thanks
>
> Frank
>

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/a56af203-bf5d-4b4c-8c34-88f01d7e0bc6o%40googlegroups.com.

Reply via email to