I think you have several issues involved here
1) when things are running ok - weewx has a PID of 343
2) there is no explanation of why a new version of weewx with PID of 326 is
started - but the clock is wrong - so from this point onwards you will have
very mixed results!! With an RPi you should install a real time clock for
consistency as time is vital to correct running of weewx.
3) now you start with PID of 326 and 331 and finally the clock updates
The error will relate to records already in the database with the same time
as the new record - and the cause will liely be connected to wrong clock
times somewhere along the line
In all it looks more like an RPi problem - possibly power supply related or
possibly indicating an impending failure of the SD card
On Tuesday, 10 September 2019 10:17:49 UTC+3, Kike .Asekas wrote:
>
> This morning I discovered that weewx had stopped tonight. The log:
> Sep 10 01:51:13 raspberrypi weewx[343]: imagegenerator: Generated 13
> images for SeasonsReport in 6.09 seconds
> Sep 10 01:51:14 raspberrypi weewx[343]: copygenerator: copied 0 files to
> /var/www/html/weewx
> *Sep 10 01:51:14* raspberrypi weewx[343]: imageStackedWindRose: Generated
> 1 images for StackedWindRose in 0.46 seconds
> *Sep 10 01:22:46* raspberrypi weewx[326]: engine: Initializing weewx
> version 3.9.1
> Sep 10 01:22:46 raspberrypi weewx[326]: engine: Using Python 2.7.16
> (default, Apr 6 2019, 01:42:57) #012[GCC 8.2.0]
> Sep 10 01:22:46 raspberrypi weewx[326]: engine: Platform
> Linux-4.19.57+-armv6l-with-debian-10.0
> Sep 10 01:22:46 raspberrypi weewx[326]: engine: Locale is 'es_ES.UTF-8'
> Sep 10 01:22:46 raspberrypi weewx[326]: engine: pid file is
> /var/run/weewx.pid
> Sep 10 01:22:46 raspberrypi weewx[259]: Starting weewx weather system:
> weewx.
> Sep 10 01:22:47 raspberrypi weewx[331]: engine: Using configuration file
> /etc/weewx/weewx.conf
> Sep 10 01:22:47 raspberrypi weewx[331]: engine: Loading station type SDR
> (user.sdr)
> Sep 10 01:22:47 raspberrypi weewx[331]: sdr: MainThread: driver version is
> 0.64
> Sep 10 01:22:47 raspberrypi weewx[331]: sdr: MainThread: sensor map is
> {'windGust': 'wind_gust.*.FOWHx080Packet', 'windDir':
> 'wind_dir.*.FOWHx080Packet', 'windSpeed': 'wind_speed.*.FOWHx080Packet',
> 'outTemp': 'temperature.*.FOWHx080Packet', 'outHumidity':
> 'humidity.*.FOWHx080Packet', 'rain_total': 'rain_total.*.FOWHx080Packet',
> 'battery': 'battery.*.FOWHx080Packet'}
> Sep 10 01:22:47 raspberrypi weewx[331]: sdr: MainThread: deltas is
> {'rain': 'rain_total'}
> Sep 10 01:22:47 raspberrypi weewx[331]: sdr: MainThread: startup process
> 'rtl_433 -q -F json -R 32 -M utc -f 868.3M'
> Sep 10 01:22:47 raspberrypi weewx[331]: engine: StdConvert target unit is
> 0x11
> Sep 10 01:22:48 raspberrypi weewx[331]: wxcalculate: The following values
> will be calculated: barometer=prefer_hardware, windchill=prefer_hardware,
> dewpoint=prefer_hardware, appTemp=prefer_hardware,
> rainRate=prefer_hardware, windrun=prefer_hardware,
> heatindex=prefer_hardware, maxSolarRad=prefer_hardware,
> humidex=prefer_hardware, pressure=prefer_hardware,
> inDewpoint=prefer_hardware, ET=prefer_hardware, altimeter=prefer_hardware,
> cloudbase=prefer_hardware
> Sep 10 01:22:48 raspberrypi weewx[331]: wxcalculate: The following
> algorithms will be used for calculations: altimeter=aaNOAA, maxSolarRad=RS
> Sep 10 01:22:48 raspberrypi weewx[331]: engine: Archive will use data
> binding wx_binding
> Sep 10 01:22:48 raspberrypi weewx[331]: engine: Record generation will be
> attempted in 'software'
> Sep 10 01:22:48 raspberrypi weewx[331]: engine: Using archive interval of
> 300 seconds (software record generation)
> Sep 10 01:22:49 raspberrypi weewx[331]: engine: Using binding 'wx_binding'
> to database 'weewx.sdb'
> Sep 10 01:22:49 raspberrypi weewx[331]: manager: Starting backfill of
> daily summaries
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: StationRegistry: Station
> will be registered.
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: Wunderground: Posting not
> enabled.
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: PWSweather: Posting not
> enabled.
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: CWOP: Posting not enabled.
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: WOW: Posting not enabled.
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: AWEKAS: Posting not enabled.
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: MQTT: service version is
> 0.19
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: MQTT: binding to ['loop',
> 'archive']
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: MQTT: topic is
> estacion/datos
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: MQTT: desired unit system
> is METRIC
> Sep 10 01:22:49 raspberrypi weewx[331]: restx: MQTT: data will be uploaded
> to mqtt://broker.hivemq.com:1883
> Sep 10 01:22:49 raspberrypi weewx[331]: engine: Starting up weewx version
> 3.9.1
> Sep 10 01:22:49 raspberrypi weewx[331]: engine: Starting main packet loop.
> Sep 10 01:23:04 raspberrypi weewx[331]: restx: MQTT: Published record
> 2019-09-10 01:22:58 CEST (1568071378)
> *Sep 10 01:23:04* raspberrypi weewx[331]: restx: MQTT: Published record
> 2019-09-10 01:22:58 CEST (1568071378)
> *Sep 10 07:32:28* raspberrypi weewx[331]: restx: MQTT: Published record
> 2019-09-10 07:32:24 CEST (1568093544)
> Sep 10 07:32:29 raspberrypi weewx[331]: manager: *Unable to add record
> 2019-09-10 01:25:00 CEST (1568071500) to database 'weewx.sdb': UNIQUE
> constraint failed: archive.dateTime*
> Sep 10 07:32:30 raspberrypi weewx[331]: engine: Garbage collected 64
> objects
> *Sep 10 07:32:30* raspberrypi weewx[331]: restx: *MQTT: Published record
> 2019-09-10 01:25:00 CEST (1568071500)*
> Sep 10 07:32:31 raspberrypi weewx[331]: restx: StationRegistry: Published
> record 2019-09-10 01:25:00 CEST (1568071500)
>
>
> At 1:51:14 it stops for some reason(no error) and restart and returns at
> 1:22:46 !!!!!??????. At 7:32 I realize it is stopped and restart weewx
> and in this moment it gives the error of trying to insert a record that
> already exists. The one at 1:25. Also mqtt publishes at that time the
> record of 1:25
> Where can the fault be?
>
--
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/87ac0536-b1e6-4c4d-a5f3-7e23d1d85eec%40googlegroups.com.