weewx stop reporting (or crash?) few time per day ????

1,994 views
Skip to first unread message

Marc Aubry

unread,
Dec 15, 2016, 9:00:03 PM12/15/16
to weewx-user
Hi 
i'm running weewx 3.6.2-1 on a raspberry pi 2 connected to the lan via cable and a deported mysql database server hosted on ubuntu linux computer.
weewx report on local webserver hosted on the same rapberry as the weewx server and on a ftp server at the following: http://web.cubadak-paradisovillage.com/weather

weewx stop reporting few times per day and probably crash because nothing appear in the syslog file after the last report (check below for extract of my syslog file during the last crash and my weewx conf file).
To restart the weewx i do a reboot of the raspberry or stop and start of the service.
what can i do to monitor if the weewx service crash and diagnose the cause of the crash ????
thanks in advance for your help.


syslog:
Dec 15 21:05:31 weatherstation weewx[600]: genimages: Generated 12 images for StandardReport in 2.36 seconds
Dec 15 21:05:31 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx
Dec 15 21:05:35 weatherstation weewx[600]: cheetahgenerator: Generated 1 files for report forecast in 3.96 seconds
Dec 15 21:05:35 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx/forecast
Dec 15 21:10:15 weatherstation weewx[600]: manager: added record 2016-12-15 21:10:00 WIB (1481811000) to database 'weewx'
Dec 15 21:10:16 weatherstation weewx[600]: manager: added record 2016-12-15 21:10:00 WIB (1481811000) to daily summary in 'weewx'
Dec 15 21:10:16 weatherstation weewx[600]: forecast: WUThread: WU: downloading forecast from 'http://api.wunderground.com/api/XXXXXXXXXXXXec50/hourly10day/q/-1.217,100.400.json'
Dec 15 21:10:17 weatherstation weewx[600]: restx: PWSWeather: Published record 2016-12-15 21:10:00 WIB (1481811000)
Dec 15 21:10:17 weatherstation weewx[600]: restx: Wunderground-PWS: Published record 2016-12-15 21:10:00 WIB (1481811000)
Dec 15 21:10:20 weatherstation weewx[600]: forecast: WUThread: WU: got 240 forecast records
Dec 15 21:10:20 weatherstation weewx[600]: forecast: WUThread: WU: saved 240 forecast records
Dec 15 21:10:20 weatherstation weewx[600]: forecast: WUThread: WU: deleted forecasts prior to 1481206220
Dec 15 21:10:27 weatherstation weewx[600]: cheetahgenerator: Generated 7 files for report StandardReport in 11.10 seconds
Dec 15 21:10:34 weatherstation weewx[600]: genimages: Generated 12 images for StandardReport in 7.39 seconds
Dec 15 21:10:34 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx
Dec 15 21:10:38 weatherstation weewx[600]: cheetahgenerator: Generated 1 files for report forecast in 3.93 seconds
Dec 15 21:10:38 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx/forecast
Dec 15 21:17:01 weatherstation CRON[1378]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Dec 15 22:17:01 weatherstation CRON[1403]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)

weewx conf file:
# WEEWX CONFIGURATION FILE
#
# Copyright (c) 2009-2015 Tom Keffer <tke...@gmail.com>
# See the file LICENSE.txt for your rights.

##############################################################################

# This section is for general configuration information.

# Set to 1 for extra debug info, otherwise comment it out or set to zero
debug = 0

# Root directory of the weewx data file hierarchy for this station
WEEWX_ROOT = /

# How long to wait before timing out a socket (FTP, HTTP) connection
socket_timeout = 20

# Do not modify this. It is used when installing and updating weewx.
version = 3.6.2

##############################################################################

#   This section is for information about the station.

[Station]
    
    # Description of the station location
    location = "Cubadak Island, West Sumatra"
    
    # Latitude and longitude in decimal degrees
    latitude = -1.217
    longitude = 100.400
    
    # Altitude of the station, with unit it is in. This is downloaded from
    # from the station if the hardware supports it.
    altitude = 5, meter
    
    # Set to type of station hardware. There must be a corresponding stanza
    # in this file with a 'driver' parameter indicating the driver to be used.
    station_type = WH23xx
    
    # If you have a website, you may specify an URL
    
    # The start of the rain year (1=January; 10=October, etc.). This is
    # downloaded from the station if the hardware supports it.
    rain_year_start = 1
    
    # Start of week (0=Monday, 6=Sunday)
    week_start = 6

##############################################################################

#[WH23XX]
# This section is for the weewx weather station simulator

# The time (in seconds) between LOOP packets.
#loop_interval = 2.5

# The simulator mode can be either 'simulator' or 'generator'.
# Real-time simulator. Sleep between each LOOP packet.
#mode = simulator
# Generator.  Emit LOOP packets as fast as possible (useful for testing).
#mode = generator

# The start time. If not specified, the default is to use the present time.
#start = 2011-01-01 00:00

# The driver to use:
#driver = user.wh23xx

##############################################################################

#   This section is for uploading data to Internet sites

[StdRESTful]
    
    [[StationRegistry]]
        # To register this weather station with weewx, set this to true
        register_this_station = true
    
    [[AWEKAS]]
        # This section is for configuring posts to AWEKAS.
        
        # If you wish to do this, set the option 'enable' to true,
        # and specify a username and password.
        enable = false
        username = replace_me
        password = replace_me
    
    [[CWOP]]
        # This section is for configuring posts to CWOP.
        
        # If you wish to do this, set the option 'enable' to true,
        # and specify the station ID (e.g., CW1234).
        enable = false
        station = replace_me
    
    # If this is an APRS (radio amateur) station, uncomment
    # the following and replace with a passcode (e.g., 12345).
    #passcode = replace_me (APRS stations only)
    
    [[PWSweather]]
        # This section is for configuring posts to PWSweather.com.
        
        # If you wish to do this, set the option 'enable' to true,
        # and specify a station and password.
        enable = true
        station = CUBADAK
        password =xxxxxxxxxxxxxxx
    
    [[WOW]]
        # This section is for configuring posts to WOW.
        
        # If you wish to do this, set the option 'enable' to true,
        # and specify a station and password.
        enable = false
        station = replace_me
        password = replace_me
    
    [[Wunderground]]
        # This section is for configuring posts to the Weather Underground.
        
        # If you wish to do this, set the option 'enable' to true,
        # and specify a station (e.g., 'KORHOODR3') and password.
        enable = true
        station = IWESTSUM3
        password = xxxxxxxxxxxx
        
        # Set the following to True to have weewx use the WU "Rapidfire"
        # protocol. Not all hardware can support it. See the User's Guide.
        rapidfire = False

##############################################################################

#   This section specifies what reports, using which skins, to generate.

[StdReport]
    
    # Where the skins reside, relative to WEEWX_ROOT
    SKIN_ROOT = /etc/weewx/skins
    #SKIN_ROOT = ~/weewx/skins
    # Where the generated reports should go, relative to WEEWX_ROOT
    HTML_ROOT = /var/www/html/weewx
    
    # The database binding indicates which data should be used in reports.
    data_binding = wx_binding
    
    # Each of the following subsections defines a report that will be run.
    
    [[StandardReport]]
        # See the customizing guide to change the units, plot types and line
        # colors, modify the fonts, display additional sensor data, and other
        # customizations. Many of those changes can be made here by overriding
        # parameters, or by modifying templates within the skin itself.
        
        # The StandardReport uses the 'Standard' skin, which contains the
        # images, templates and plots for the report.
        skin = sofaskin
        [[[Units]]]
            [[[[Groups]]]]
                group_altitude = meter
                group_speed2 = knot
                group_pressure = mbar
                group_rain = mm
                group_rainrate = mm_per_hour
                group_temperature = degree_C
                group_degree_day = degree_C_day
                group_speed = knot
    [[forecast]]
        HTML_ROOT = /var/www/html/weewx/forecast
        skin = forecast
    
    [[FTP]]
        # FTP'ing the results to a webserver is treated as just another report,
        # albeit one with an unusual report generator!
        skin = Ftp
        
        # If you wish to use FTP, uncomment and fill out the next four lines.
        password = marcoind
        server = web.cubadak-paradisovillage.com
        path = /docs/weather
        
        # Set to True for an FTP over TLS (FTPS) connection. Not all servers
        # support this.
        secure_ftp = False
        
        # To upload files from something other than what HTML_ROOT is set
        # to above, specify a different HTML_ROOT here.
        #HTML_ROOT = /var/www/html/weewx
        
        # Most FTP servers use port 21
        port = 21
        
        # Set to 1 to use passive mode, zero for active mode
        passive = 1
    
report_timing = */15 * * * *
    [[RSYNC]]
        # rsync'ing to a webserver is treated as just another report
        skin = Rsync
        
        # If you wish to use rsync, you must configure passwordless ssh using
        # public/private key authentication from the user account that weewx
        # runs as to the user account on the remote machine where the files
        # will be copied.
        #
        # The following three lines determine where files will be sent.
        #server = replace with the rsync server name, e.g, www.threefools.org
        #path = replace with the rsync destination directory (e.g., /weather)
        #user = replace with the rsync username
        
        # Rsync can be configured to remove files from the remote server if
        # they don't exist under HTML_ROOT locally. USE WITH CAUTION: if you
        # make a mistake in the remote path, you could could unintentionally
        # cause unrelated files to be deleted. Set to 1 to enable remote file
        # deletion, zero to allow files to accumulate remotely.
        delete = 0

##############################################################################

#   This service acts as a filter, converting the unit system coming from
#   the hardware to a unit system in the database.

[StdConvert]
    
    # The target_unit affects only the unit system in the database. Once
    # chosen it cannot be changed without converting the entire database.
    # Modification of target_unit after starting weewx will result in
    # corrupt data - the database will contain a mix of US and METRIC data.
    #
    # The value of target_unit does not affect the unit system for
    # reporting - reports can display US, Metric, or any combination of units.
    #
    # In most cases, target_unit should be left as the default: US
    #
    # In particular, those migrating from a standard wview installation
    # should use US since that is what the wview database contains.
    
    # DO NOT MODIFY THIS VALUE UNLESS YOU KNOW WHAT YOU ARE DOING!
    target_unit = METRIC    # Options are 'US', 'METRICWX', or 'METRIC'

##############################################################################

#   This section can adjust data using calibration expressions.

[StdCalibrate]
    
    [[Corrections]]
        # For each type, an arbitrary calibration expression can be given. 
        # It should be in the units defined in the StdConvert section.
        # Example:
        foo = foo + 0.2
        radiation = radiation * 292
##############################################################################

#   This section is for quality control checks. If units are not specified,
#   values must be in the units defined in the StdConvert section.

[StdQC]
    
    [[MinMax]]
        barometer = 900, 1100
        outTemp = 10, 60
        inTemp = 10, 60
        outHumidity = 0, 100
        inHumidity = 0, 100
        windSpeed = 0, 90
        pressure = 900, 1100
rain=0, 300
##############################################################################

#   This section controls the origin of derived values.

[StdWXCalculate]
    
    [[Calculations]]
        # Derived quantities are calculated by this service. Possible values are:
        #  hardware        - use the value provided by hardware
        #  software        - use the value calculated by weewx
        #  prefer_hardware - use value provide by hardware if available,
        #                      otherwise use value calculated by weewx
        
        pressure = prefer_hardware
        barometer = prefer_hardware
        altimeter = prefer_hardware
        windchill = prefer_hardware
        heatindex = prefer_hardware
        dewpoint = prefer_hardware
        inDewpoint = prefer_hardware
        rainRate = prefer_hardware
        radiation = hardware
##############################################################################

#   For hardware that supports it, this section controls how often the
#   onboard clock gets updated.

[StdTimeSynch]
    
    # How often to check the weather station clock for drift (in seconds)
    clock_check = 14400
    
    # How much it can drift before we will correct it (in seconds)
    max_drift = 5

##############################################################################

#   This section is for configuring the archive service.

[StdArchive]
    
    # If the station hardware supports data logging then the archive interval
    # will be downloaded from the station. Otherwise, specify it (in seconds).
    archive_interval = 300
    
    # If possible, new archive records are downloaded from the station
    # hardware. If the hardware does not support this, then new archive
    # records will be generated in software.
    # Set the following to "software" to force software record generation.
    record_generation = hardware
    
    # Whether to include LOOP data in hi/low statistics
    loop_hilo = True
    
    # The data binding used to save archive records
    data_binding = wx_binding

##############################################################################

#   This section binds a data store to a database.

[DataBindings]
    
    [[wx_binding]]
        # The database must match one of the sections in [Databases].
        # This is likely to be the only option you would want to change.
        database = archive_mysql
        # The name of the table within the database
        table_name = archive
        # The manager handles aggregation of data for historical summaries
        manager = weewx.wxmanager.WXDaySummaryManager
        # The schema defines the structure of the database.
        # It is *only* used when the database is created.
        schema = schemas.wview.schema
    [[forecast_binding]]
        database = forecast_sqlite

##############################################################################

#   This section defines various databases.

[Databases]
    
    # A SQLite database is simply a single file
    [[archive_sqlite]]
        database_type = SQLite
        database_name = weewx.sdb
    
    # MySQL
    [[archive_mysql]]
        database_type = MySQL
        database_name = weewx
    [[forecast_sqlite]]
        database_name = forecast.sdb
        database_type = SQLite

##############################################################################

#   This section defines defaults for the different types of databases.

[DatabaseTypes]
    
    # Defaults for SQLite databases
    [[SQLite]]
        driver = weedb.sqlite
        # Directory in which the database files are located
        SQLITE_ROOT = /var/lib/weewx
    
    # Defaults for MySQL databases
    [[MySQL]]
        driver = weedb.mysql
        # The host where the database is located
        host = minux.cubadak
        # The user name for logging in to the host
        user =xxxxx
        # The password for the user name
        password =xxxxxxx

##############################################################################

#   This section configures the internal weewx engine.

[Engine]
    
    [[Services]]
        # This section specifies the services that should be run. They are
        # grouped by type, and the order of services within each group
        # determines the order in which the services will be run.
        prep_services = weewx.engine.StdTimeSynch
        data_services = ,
        process_services = weewx.engine.StdConvert, weewx.engine.StdCalibrate, weewx.engine.StdQC, weewx.wxservices.StdWXCalculate
        archive_services = weewx.engine.StdArchive, user.forecast.ZambrettiForecast, user.forecast.WUForecast
        restful_services = weewx.restx.StdStationRegistry, weewx.restx.StdWunderground, weewx.restx.StdPWSweather, weewx.restx.StdCWOP, weewx.restx.StdWOW, weewx.restx.StdAWEKAS
        report_services = weewx.engine.StdPrint, weewx.engine.StdReport

##############################################################################

[WH23xx]
    # This section is for Fine Offset WH23xx stations
    
    # The model name such as Tycon, or TP2700
    model = MiSol WH2310
    
    # The driver to use
    driver = user.wh23xx

##############################################################################

# Options for extension 'forecast'
[Forecast]
    data_binding = forecast_binding
   # [[XTide]]
   #     location = "INSERT_LOCATION_HERE (e.g., Boston)"
    [[Zambretti]]
        hemisphere = south
    [[WU]]
        api_key = b89d63b44524ec50
   # [[NWS]]
   #     lid = "INSERT_LOCATION_ID_HERE (e.g., MAZ014)"
   #     foid = "INSERT_FORECAST_OFFICE_ID_HERE (e.g., BOX)"





mwall

unread,
Dec 15, 2016, 9:14:07 PM12/15/16
to weewx-user
On Thursday, December 15, 2016 at 9:00:03 PM UTC-5, Marc Aubry wrote:
weewx stop reporting few times per day and probably crash because nothing appear in the syslog file after the last report (check below for extract of my syslog file during the last crash and my weewx conf file).
To restart the weewx i do a reboot of the raspberry or stop and start of the service.
what can i do to monitor if the weewx service crash and diagnose the cause of the crash ????

marc,

first of all, be sure that you are running the latest version of the wh23xx driver (0.7 as of 15dec2016).

for the (fairly rare) cases where weewx is dying without spitting out anything to the log, run weewx directly:

sudo weewxd /etc/weewx/weewx.conf

if you are logged in remote via ssh, you might want to run screen first - that way if you lose the connection to the machine running weewx, you can reconnect later.  do a 'screen -l' followed by 'screen -r xxx' and you'll pick up where you left off.

m

Andrew Milner

unread,
Dec 15, 2016, 9:17:29 PM12/15/16
to weewx-user
I had exactly the same thing happen to me on an RPi2, with external HDD running MySQL on debian wheezy.

After failing to identify the root cause of the problem, but thinking many times I'd found it, I switched a new rpi3 running Jessie into production use - again with external hdd (which I also boot from).  Since the switch it's not failed.

So whether it is the RPi2, wheezy or what I don't know - but I'm pretty sure it's not weewx as that was the same on both Pis

Pretty sure it's not the sdcard as I use external hdd and powered usb on both systems.  OK - the disk drive is also different on both systems - but interestingly the old now retired RPi2 has just been idling along since being retired.

Marc Aubry

unread,
Dec 15, 2016, 9:26:02 PM12/15/16
to weewx-user
Hi
thanks for the tip. 
i just run weewx under a screen bash and will monitor it.
:)

Marc Aubry

unread,
Dec 15, 2016, 9:27:56 PM12/15/16
to weewx-user
Hi,
Thanks for your reply.
I'm running jessie on a rpi 2
i can give a try on rpi3 i have one in stock.

thanks

Marc Aubry

unread,
Dec 15, 2016, 9:45:39 PM12/15/16
to weewx-user
Hi 
how do i know which version of the wh23xx driver i'm running? it's should be in user.wh23xx but i can't find the location.

to reinstall the driver is it enough to do :
wget -O weewx-wh23xx.zip https://github.com/matthewwall/weewx-wh23xx/archive/master.zip 
wee_extension --install weewx-wh23xx.zip
and restart weewx ????
 

On Friday, December 16, 2016 at 9:14:07 AM UTC+7, mwall wrote:

mwall

unread,
Dec 15, 2016, 9:51:46 PM12/15/16
to weewx-user
On Thursday, December 15, 2016 at 9:45:39 PM UTC-5, Marc Aubry wrote:
Hi 
how do i know which version of the wh23xx driver i'm running? it's should be in user.wh23xx but i can't find the location.

the driver version is reported in the log soon after weewx starts up

or you can find it in the driver code:

grep VERSION user/wh23xx.py
 

to reinstall the driver is it enough to do :
wget -O weewx-wh23xx.zip https://github.com/matthewwall/weewx-wh23xx/archive/master.zip 
wee_extension --install weewx-wh23xx.zip
and restart weewx ????


that would do it!

m

Marc Aubry

unread,
Dec 16, 2016, 7:49:59 PM12/16/16
to weewx-user
Hi,
The sever hasn't crashed last night, so the problem seem to be solved.
to solve it i did the following:
sudo apt-get update 
to upgrade all the raspbian dependencies

wee_extension --install weewx-wh23xx.zip
to upgrade the wh23xx driver
i still don't know what wass crashing weewx? i' m still monitoring it because i'm not convinced by this solution :)
Thanks for your help.

Marc Aubry

unread,
Dec 21, 2016, 12:15:50 AM12/21/16
to weewx-user
Unfortunately the weewx server is still crashing without notification 
I was running it manually in screen bash session with the following command:
sudo weewxd /etc/weewx/weewx.conf
at 11:am the server stop reporting
the last thing show on the ssh monitor was:
LOOP:   2016-12-21 11:00:19 WIB (1482292819) altimeter: 1012.5004014, appTemp: 34.6412658736, barometer: 1012.77085478, cloudbase: 980.601230983, dateTime: 1482292819, dewpoint: 22.0758236992, heatindex: 33.2451096311, humidex: 39.2910732879, inDewpoint: 67.7493146686, inHumidity: 69, inTemp: 26.0, light: 81225.0, maxSolarRad: 959.011497146, outHumidity: 63, outTemp: 29.9, pressure: 1012.2, radiation: 669.264, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 6, windchill: 29.9, windDir: None, windGust: 0.0, windGustDir: None, windSpeed: 0.0
REC:    2016-12-21 11:00:00 WIB (1482292800) altimeter: 1012.49513572, appTemp: 34.1633055484, barometer: 1012.76626398, cloudbase: 964.458379722, dateTime: 1482292800.0, dewpoint: 21.8473922208, ET: 0.00744922107877, heatindex: 32.6166945788, humidex: 38.723504012, inDewpoint: 68.0579883866, inHumidity: 69.7368421053, inTemp: 26.0, interval: 5, light: 80407.9894737, maxSolarRad: 953.543006372, outHumidity: 63.4210526316, outTemp: 29.5421052632, pressure: 1012.19473684, radiation: 716.813894737, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 6.36842105263, windchill: 29.5421052632, windDir: None, windGust: 0.0, windGustDir: None, windrun: 17.1915342026, windSpeed: 0.0

The cscreen was blocked on that last message and no more data from the weather station was displayed

No error message in the syslog.
if i manually stop the script with CTRL C snd start it again manually everything start again normally 
How can i identify the source of the crash?

as mentionned in my previous post, this is my config:
weewx 3.6.2-1 on a raspberry pi 2 connected to the lan via cable and a deported mysql database server hosted on ubuntu linux computer.
weewx report on local webserver hosted on the same rapberry as the weewx server and on a ftp server at the following: http://web.cubadak-paradisovillage.com/weather

any assistance will be welcome....

Andrew Milner

unread,
Dec 21, 2016, 1:05:20 AM12/21/16
to weewx-user
Does the log not give you some clues as to what is happening?

Post the log here so we can take a look.

Marc Aubry

unread,
Dec 21, 2016, 3:11:10 AM12/21/16
to weewx-user
hi,
as already posted above the syslog doesn't show anything.

below, you'll find an extract of the syslog
Dec 15 21:05:31 weatherstation weewx[600]: genimages: Generated 12 images for StandardReport in 2.36 seconds
Dec 15 21:05:31 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx
Dec 15 21:05:35 weatherstation weewx[600]: cheetahgenerator: Generated 1 files for report forecast in 3.96 seconds
Dec 15 21:05:35 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx/forecast
Dec 15 21:10:15 weatherstation weewx[600]: manager: added record 2016-12-15 21:10:00 WIB (1481811000) to database 'weewx'
Dec 15 21:10:16 weatherstation weewx[600]: manager: added record 2016-12-15 21:10:00 WIB (1481811000) to daily summary in 'weewx'
Dec 15 21:10:16 weatherstation weewx[600]: forecast: WUThread: WU: downloading forecast from 'http://api.wunderground.com/api/XXXXXXXXXXXXec50/hourly10day/q/-1.217,100.400.json'
Dec 15 21:10:17 weatherstation weewx[600]: restx: PWSWeather: Published record 2016-12-15 21:10:00 WIB (1481811000)
Dec 15 21:10:17 weatherstation weewx[600]: restx: Wunderground-PWS: Published record 2016-12-15 21:10:00 WIB (1481811000)
Dec 15 21:10:20 weatherstation weewx[600]: forecast: WUThread: WU: got 240 forecast records
Dec 15 21:10:20 weatherstation weewx[600]: forecast: WUThread: WU: saved 240 forecast records
Dec 15 21:10:20 weatherstation weewx[600]: forecast: WUThread: WU: deleted forecasts prior to 1481206220
Dec 15 21:10:27 weatherstation weewx[600]: cheetahgenerator: Generated 7 files for report StandardReport in 11.10 seconds
Dec 15 21:10:34 weatherstation weewx[600]: genimages: Generated 12 images for StandardReport in 7.39 seconds
Dec 15 21:10:34 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx
Dec 15 21:10:38 weatherstation weewx[600]: cheetahgenerator: Generated 1 files for report forecast in 3.93 seconds
Dec 15 21:10:38 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx/forecast
Dec 15 21:17:01 weatherstation CRON[1378]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Dec 15 22:17:01 weatherstation CRON[1403]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)


Andrew Milner

unread,
Dec 21, 2016, 3:54:17 AM12/21/16
to weewx-user
what happens if you run as a daemon and do not monitor the output via ssh?

Looks like a processor/Linux issue rather than a weewx problem though - since the last log entry was 1038 - not 1100 - although you still had loop records at 1100.

Have you tried without the forecast module enabled - just to try and isolate the problem if it is within weewx?

gjr80

unread,
Dec 21, 2016, 5:11:47 AM12/21/16
to weewx-user
I am wondering what the history is here. Is this a new weewx install or an upgrade? I see you have data on your web site (nice site by the way) from 2014, is that from weewx or some other app/source? If from weewx, did weewx ever operate trouble free? I guess I am wondering what has changed?

Gary

Marc Aubry

unread,
Dec 21, 2016, 6:40:59 AM12/21/16
to weewx-user
Hi,
The weewx is a new install from less than a month, when i set up my new WH2310 weather station. The data before that have been imported in weewx with the weewx import tool from cumulus archive file from a WR200 oregon scientific. The sensor pole of the WRM200 became loose and the sensor have finished in the sea. no one could be salvage i then have purchased a Misol WH2310 clone weather station. which is not compatible with cumulus which bring me to weewx set up on a raspberry :)
the weewx have always crashed like that since first installed. Nothing appear in the syslog or on the console. the weewx just stop working. it still appear as runnicg process but no report or any archive are running....
You'l find my old cumulus website at the following :

Andrew Milner

unread,
Dec 21, 2016, 7:35:43 AM12/21/16
to weewx-user
So let's be clear about this.  You are running
a) A new raspberry pi
b) A new install of weewx
c) A new weather station which is a WH2310 clone

Has the rpi run weewx under simulator for any period?
Has the weather station run on another system for a period?
Has standard weewx, without forecasting and maybe without ftp/rsync run for any period??

What model rpi are you using, which operating system and what kind of power supply and SD card?

Try and connect a screen and keyboard to the rpi and see if you can get any sense from the rpi when weewx appears to freeze - I would be most surprised if your problems are caused by weewx itself - far more likely to be power, sdcard, os, rpi related .....

Marc Aubry

unread,
Dec 21, 2016, 8:38:12 PM12/21/16
to weewx-user
Hi
Thanks for your reply
i have mark below in red my answers to your questions...
 
So let's be clear about this.  You are running
a) A new raspberry pi   YES
b) A new install of weewx  YES
c) A new weather station which is a WH2310 clone YES

Has the rpi run weewx under simulator for any period?   NO
Has the weather station run on another system for a period? NO
Has standard weewx, without forecasting and maybe without ftp/rsync run for any period?? NO

What model rpi are you using, which operating system and what kind of power supply and SD card?
   RPI 2 B+ raspbian Jessie 8  kernel  4.4.34-v7+ power supply is samsung 5V 2A from smasung galaxy note 3

Try and connect a screen and keyboard to the rpi and see if you can get any sense from the rpi when weewx appears to freeze - I would be most surprised if your problems are caused by weewx itself - far more likely to be power, sdcard, os, rpi related .....
   it's not going to be easy to connect any monitor or keyboard due to the physical location of the rpi but i will try. i used rpi for the headless capability and the small size   and use ssh or screen bash under ssh as console to communicate with the pi. I did try to ssh monitor during more than 24h and no error message has been printed on the console neither in the syslog. when the weewx stop the rest of rpi processes seem to work normally. i can run vnc session and do some python scripting with pygame remotely (as example becausenot use during normal production day:) 
i can easily try a different SD card, a different power supply and a different RPI board.
i can try the simulator during 24 h because i'm more and more suspecting a communication problem between the wh2310 and the weewx driver but i'm reluctant to do that because of the lost of recording data during that test.

Andrew Milner

unread,
Dec 21, 2016, 10:49:03 PM12/21/16
to weewx-user
Seems like you have to choose between running in 'live' mode with the system 'crashing' multiple times per day or running in 'test' mode whilst trying to find out why it is 'crashing'.  If the station hasd a logger, which I believe the 2310 has, then you should be able to retrieve lost data by resetting the database back in time and restarting weewx.

I rarely run weewx off the command line, always using daemon mode, so do not know what effect command line running and monitoring has on the rpi.

I'd first try a different power supply and/or use a powered hub.  The Rpi is notorious for dodgy power problems - and if you are using the usb port and Ethernet this would be my first change.  Dodgy sd cards also cause problems - sandisk 10's I think seem to be the most reliable in the rpi I believe.

You could try and switch to using SQLite as an experiment for a couple of days - onboard the rpi - and see if this reduces the 'crashes' - again, after the test you put it all back to your original db in weewx.conf and weewx will catch up from the station so u should not lose any data whilst testing.

These are just some things and tests which can be tried.

If you come back with testing comments/results - do make sure we know exactly the configuration you have been testing and post the output from wee_debug and the log with your posting together with your comments/questions.  The more data we have the easier it is to help.

mwall

unread,
Dec 21, 2016, 11:24:28 PM12/21/16
to weewx-user
Marc, please disable the forecast search list extension, then run weewxd directly, with debug=1 in weewx.conf

m

Marc Aubry

unread,
Dec 21, 2016, 11:40:08 PM12/21/16
to weewx-user
if i disable the forecast search list extension am i going to loose the WU and Zambtretti forecast?
i'll give a try on my next monitoring. right now i have change the SD card. next try will be to change the power supply, so maybe on the next next try :)
i have already implemented the debug= 1 in this current monitorint.
tks 

mwall

unread,
Dec 22, 2016, 12:29:03 PM12/22/16
to weewx-user
On Wednesday, December 21, 2016 at 10:49:03 PM UTC-5, Andrew Milner wrote:
Seems like you have to choose between running in 'live' mode with the system 'crashing' multiple times per day or running in 'test' mode whilst trying to find out why it is 'crashing'.  If the station hasd a logger, which I believe the 2310 has, then you should be able to retrieve lost data by resetting the database back in time and restarting weewx.

andrew,

the wh23xx stations have a logger, but the driver is not yet able to read records from the logger.  we know how to decode the records, but we do not yet have a  protocol for getting the records from the logger reliably.

m

mwall

unread,
Dec 22, 2016, 12:35:03 PM12/22/16
to weewx-user
On Wednesday, December 21, 2016 at 11:40:08 PM UTC-5, Marc Aubry wrote:
if i disable the forecast search list extension am i going to loose the WU and Zambtretti forecast?

that is correct.

i doubt that the forecast code is failing, but it might be consuming memory that causes a low memory condition that causes a failure elsewhere.

you might consider running with only the standard skin that comes with weewx, at least until we figure out what is causing the failure.

how much memory does the rpi have?

when you to a 'top' while weewx is running, what do you see for the memory summary?

if you do a 'ps aux | grep weewx', what do you see for VSZ and RSS for the weewx process?

m

Andrew Milner

unread,
Dec 22, 2016, 2:00:57 PM12/22/16
to weewx-user
Matthew - thanks for the correction.  I was hoping that you would eventually join this thread - especially since we have now established it is a totally new installation with no previous 'working' history.  I still think this is reminiscent of my rpi2 B+ that just started freezing for no apparent reason, and no reason I could ever establish.;  Since I swapped o rpi3 and Jessie I have not had a glitch - and for 3 years on the rpi2 I never had a problem .... until it started just 'freezing'.  I still, to this day, have not resolved what causes the failures.  The difference ijn my setup is that I was running wheezy and when it froze I could notget in via ssh either.

vince

unread,
Dec 22, 2016, 2:53:44 PM12/22/16
to weewx-user
On Thursday, December 22, 2016 at 11:00:57 AM UTC-8, Andrew Milner wrote:
Matthew - thanks for the correction.  I was hoping that you would eventually join this thread - especially since we have now established it is a totally new installation with no previous 'working' history.  I still think this is reminiscent of my rpi2 B+ that just started freezing for no apparent reason, and no reason I could ever establish.;  Since I swapped o rpi3 and Jessie I have not had a glitch - and for 3 years on the rpi2 I never had a problem .... until it started just 'freezing'.  I still, to this day, have not resolved what causes the failures.  The difference ijn my setup is that I was running wheezy and when it froze I could notget in via ssh either.


On the original model-B, I've had the 'could not get in via ssh' many times even when it was answering pings and even http requests.   That almost always was an imminent SD card death.  Sometimes a reimaging using the same card worked, but eventually the time to get messed up again tended to shrink (guessing as the SD got shakier and shakier).  That's with just 'motion' running reading a USB webcam, with a couple trivial cron jobs running occasionally.

 

 

Marc Aubry

unread,
Dec 22, 2016, 9:36:20 PM12/22/16
to weewx-user
hi
it's rpi2 B+ so it should be 1G and the rpi is dedicated for weewx, i just enable ssh and vncserver.
for the memory i have a lot of it according to 'top' command
top - 09:27:47 up  2:20,  2 users,  load average: 0.07, 0.07, 0.07
Tasks: 143 total,   1 running, 142 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.8 us,  0.1 sy,  0.0 ni, 99.1 id,  0.0 wa,  0.0 hi,  0.0 si,  0.0 st
KiB Mem:    947732 total,   358672 used,   589060 free,    42040 buffers
KiB Swap:   102396 total,        0 used,   102396 free.   182152 cached Mem
below the output of ps aux | grep weewx
 ps aux | grep weewx
root       608  6.1  3.4  86252 32480 ?        Sl   07:08   8:41 python /usr/bin/weewxd --daemon --pidfile=/var/run/weewx.pid /etc/weewx/weewx.conf
pi        1425  0.0  0.1   4280  1852 pts/0    S+   09:30   0:00 grep --color=auto weewx

i'll get back to strd skin but i had already this crash when i was setting up and learning weewx so i doubt the skin is in cause.

Marc Aubry

unread,
Dec 22, 2016, 9:39:03 PM12/22/16
to weewx-user
the rpi is not freezing.... everything seem to work fine, only weewx is freezing and not logging or reporting anything. while weewx crash i can still access to rpi via ssh or vnc snd if i do sudo sevice weewx stop and sudo service weewx start or reboot the pi everything come back in order

Marc Aubry

unread,
Dec 22, 2016, 9:41:53 PM12/22/16
to weewx-user
yesterday i did change the SD card but weewx stop working the same.

mwall

unread,
Dec 22, 2016, 9:52:14 PM12/22/16
to weewx-user
On Thursday, December 22, 2016 at 9:36:20 PM UTC-5, Marc Aubry wrote:
hi
it's rpi2 B+ so it should be 1G and the rpi is dedicated for weewx, i just enable ssh and vncserver.
for the memory i have a lot of it according to 'top' command
top - 09:27:47 up  2:20,  2 users,  load average: 0.07, 0.07, 0.07
Tasks: 143 total,   1 running, 142 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.8 us,  0.1 sy,  0.0 ni, 99.1 id,  0.0 wa,  0.0 hi,  0.0 si,  0.0 st
KiB Mem:    947732 total,   358672 used,   589060 free,    42040 buffers
KiB Swap:   102396 total,        0 used,   102396 free.   182152 cached Mem
below the output of ps aux | grep weewx
 ps aux | grep weewx
root       608  6.1  3.4  86252 32480 ?        Sl   07:08   8:41 python /usr/bin/weewxd --daemon --pidfile=/var/run/weewx.pid /etc/weewx/weewx.conf
pi        1425  0.0  0.1   4280  1852 pts/0    S+   09:30   0:00 grep --color=auto weewx

i'll get back to strd skin but i had already this crash when i was setting up and learning weewx so i doubt the skin is in cause.


marc,

those memory numbers do not look unreasonable.  you might want to look at the numbers for the standard skin versus the responsive skin.  be sure to let weewx run for 5 or 6 archive intervals before you look at the memory numbers.

i have been reviewing the driver code, and there is a chance that the driver is looping continuously, trying to get data from usb.

please update to the latest wh23xx driver (v 0.8).  update process is as you did before.

this adds more logging that will help us determine if the usb comms are the problem.

m

Marc Aubry

unread,
Dec 23, 2016, 3:00:01 AM12/23/16
to weewx-user
ok, i'll update the driver 
please find attached the syslog file of the last crash 14:05
weewxsyslog.7z

Marc Aubry

unread,
Dec 23, 2016, 3:18:51 AM12/23/16
to weewx-user
ok
driver updated with the following:

sudo wee_extension --install weewx-wh23xx.zip
sudo service weewx stop
sudo service weewx start

please find attached the wee_debug file
wee.debug

Marc Aubry

unread,
Dec 24, 2016, 1:27:01 AM12/24/16
to weewx-user
this morning crash syslog (see attachfile)ed 
the weewx has stop working from 8:37 to 1:30 until i reboot the rpi.
maybe i have a network issue...
i'll try to use a fix ip instead of static address delivered by my dhcp ...
which going to be the same nbut form my ddwrt routr i prefer to use the dhcp/dnsmasq to atribute even the fix ip.
weewxsyslog.7z

Glenn McKechnie

unread,
Dec 24, 2016, 3:31:51 AM12/24/16
to weewx...@googlegroups.com
There's certainly a network problem, and with your database on a remote machine ( Database host: minux.cubadak ) then something has to give ...

[...]

Dec 24 08:35:19 weatherstation weewx[606]: manager: added record 2016-12-24 08:35:00 WIB (1482543300) to database 'weewx'
Dec 24 08:35:19 weatherstation weewx[606]: manager: added record 2016-12-24 08:35:00 WIB (1482543300) to daily summary in 'weewx'
Dec 24 08:35:19 weatherstation weewx[606]: forecast: MainThread: Zambretti: starting thread

[...]

Dec 24 08:38:03 weatherstation weewx[606]: wh23xx: read_record: cmdbuf: 02 02 04 04 (len=4)
Dec 24 08:39:31 weatherstation dhcpcd[433]: eth0: DHCPv6 REPLY: No Binding
Dec 24 08:44:40 weatherstation dhcpcd[433]: eth0: DHCPv6 REPLY: No Binding
Dec 24 08:46:28 weatherstation dhcpcd[433]: eth0: fe80::ba27:ebff:fe6d:f9db router available
Dec 24 08:51:26 weatherstation dhcpcd[433]: eth0: fe80::ba27:ebff:fe6d:f9db router available
Dec 24 08:51:27 weatherstation dhcpcd[433]: eth0: fe80::ba27:ebff:fe6d:f9db router available
Dec 24 08:52:35 weatherstation dhcpcd[433]: eth0: failed to renew DHCPv6, rebinding
Dec 24 08:52:35 weatherstation dhcpcd[433]: eth0: fe80::ba27:ebff:fe6d:f9db: DHCPv6 REPLY missing IA Address
Dec 24 08:52:35 weatherstation dhcpcd[433]: eth0: no useable IA found in lease



The above log snippets show the 8:37 failure you mention.

From there you reboot at 11:35 and it comes up again and appears to start working, storing data successfully from 11:40:16 through to 13:10:28

I can't see the failure you mention between 8:37 to 1:30 ie: - "the weewx has stop working from 8:37 to 1:30 until i reboot the rpi."

That confusion aside, I'd be delving into the network side of your setup as that's definitely a problem, especially when using a remote database as you are.

FWIW I've run into difficulties before with ipv6 running in tandem with ipv4. I don't insist on it for networking. If I get a lease on my internal network using ipv4 alone I'm happy, as is the network.
Having said that, your network problems could be due to anything.

Happy hunting

--
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 weewx-user+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Marc Aubry

unread,
Dec 25, 2016, 7:22:10 AM12/25/16
to weewx-user
Hi thanks for your help.
i have desactivate ipv6 on the rapsberry by adding
net.ipv6.conf.all.disable_ipv6=1
in /etc/sysctl.conf
i hope it will be enough. i don't see any ip6 address on ifconfig but can still see something in sudo netstat -lntp

tcp6       0      0 :::80                   :::*                    LISTEN      612/apache2
tcp6       0      0 :::22                   :::*                    LISTEN      499/sshd

i have as well change the address of my mysql server in weewx.conf to put the ip address instead of the domain name address, just in case i have problem with my local DNS server.

i will monitor tonight and let you know.

if i can't find anything i can alway cron reboot my rpi onece every hour. it should at least hide the problem :)



To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.

Marc Aubry

unread,
Dec 25, 2016, 10:37:19 AM12/25/16
to weewx-user
hi andrew.
Thanks for your reply,
You are probably right i should start again from a fresh install and slowly put it on load by adding functionalities.
The problem of that approach is the time it's going to take to achieve my goal. i have sometime 1 crash per day, sometime two crashes per day. to be sure that one config is valid i should wait two days to validate it. so it's going to take me around 1 month to validate the config.

Why did i chose to use a deported mysql? because long term writing on the SD card of the RPI is a forecast future SD card burn out :) 
I don't have and do not want to setup a usb Hard drive on the pi. 
I'm sure of my mysql server which is used by other deported applications on the same network including my home made arduino dust sensor 
if a small arduino is able to write on my mysql server, it should be a piece of cake for a more powerful rapsberry :)
The crash happen with he strd skin before i setup the new skin and the forecast.
The RPI itself doesn't crash, it is just weewx which stop reporting and writing in the log file, if i just restart the weewx service, everything come back in order.
I'm thinking of either a WH23xx driver problem or a network problem. for the Wh23xx driver there is not much i can do but posting my log file to the forum for further analysis.

PS: how is life in cyprus? i was living in Kapedes between 1998 and 2004 and had a beautiful time....

You could always just use a local SQLite or even MySQL database to at least see if the rpi still crashes!!

 

One of the problems is that your setup is not standard, is not simple, but does not work either!!  IMHO it is necessary to go as simple and stand\rd as possible and add in complexity – rather than doing what we are currently doing – which is simplifying things in each test.

 

Have you actually tried weewx with a local database and the standard skin – without forecasting or bootstrap or remote database or any other additions??  If so, did it still crash??

mwall

unread,
Dec 25, 2016, 3:26:35 PM12/25/16
to weewx-user


On Saturday, December 24, 2016 at 1:27:01 AM UTC-5, Marc Aubry wrote:
this morning crash syslog (see attachfile)ed 
the weewx has stop working from 8:37 to 1:30 until i reboot the rpi.
maybe i have a network issue...
i'll try to use a fix ip instead of static address delivered by my dhcp ...
which going to be the same nbut form my ddwrt routr i prefer to use the dhcp/dnsmasq to atribute even the fix ip.


marc,

there is nothing unusual in the log you posted.

since you are using mysql, you should make the weewx startup script depend on the network.  you should also make the weewx startup script depend on ntp.

but even though your network is a mess, weewx did what it was supposed to to: it failed to contact the mysql server, so it slept for two minutes.  when it tried again, the network had stabilized, and weewx startup up properly.

nothing unusual until the end of the log you posted, and there is no crash.  what stopped the log?

you should update to the latest forecast (currently at version 3.2.6).  that will eliminate the spurious 'ignoring value for ...' messages.

m

Marc Aubry

unread,
Dec 25, 2016, 8:20:16 PM12/25/16
to weewx-user
hi
i though i got it last night after having removed the ip v6 part of the rpi and hardcoding the ip address of the mysql server, the weewx did not crash for 12 hours. but this morning at 07:12 the weewx had crashed again the last line of the syslog regarding weather station is :
Dec 26 07:12:32 weatherstation weewx[602]: wh23xx: read_record: cmdbuf: 02 02 04 04 (len=4)
would it suggest a wh23xx driver going in loop ?

i have no idea how to make the weewx startup script depend on the network and ntp. please could you help me on this one....

The log is not stopped is just that nothing else happen on the machine. this rpi is dedicated only to weewx it's a headless machine connected to the lan via ethernet. the only service loaded in top of weewx is tightvnc server. it's like weewx goes in loop somewhere and stop doing anything. this morning i just restart the weewx service and everything went back on normal.

FYI my wh2310 weather station is a Misol clone of TP2700WC the bough on aliexpress.com  

mwall

unread,
Dec 26, 2016, 1:26:05 AM12/26/16
to weewx-user
On Sunday, December 25, 2016 at 8:20:16 PM UTC-5, Marc Aubry wrote:
hi
i though i got it last night after having removed the ip v6 part of the rpi and hardcoding the ip address of the mysql server, the weewx did not crash for 12 hours. but this morning at 07:12 the weewx had crashed again the last line of the syslog regarding weather station is :
Dec 26 07:12:32 weatherstation weewx[602]: wh23xx: read_record: cmdbuf: 02 02 04 04 (len=4)
would it suggest a wh23xx driver going in loop ?

was weewxd still running after 07:12:32?  could you see it when you do 'ps aux'?

the 'cmdbuf' log message is normal - the driver sends a command to the console, then the console replies.

if the driver were in an infinite loop, the driver would log it.

if the driver were timing out waiting for a reply via usb, the driver would log it.

if the console replies with a bogus or unexpected response, the driver would log it.

there is a while loop at line 630 that could theoretically result in an infinite loop, but if that were happening, there would be log messages leading up to and during it.

does any other process write to the log file after 07:12:32?  if not, then you probably have a system-wide problem, not specific to weewx.

you say that weewx stops responding frequently.  is weewxd still running each time?  does any other process write to the log after the last weewxd log entry?  is the last weewxd log entry always the same?

 
i have no idea how to make the weewx startup script depend on the network and ntp. please could you help me on this one....

if you are using an LSB init.d rc script, then you want something like this:

# Required-Start:    $local_fs $remote_fs $syslog $ntp $network

if you are using a systemd unit file, then you want something like this:

Requires=time-sync.target network.target
After=time-sync.target network.target

but that might be redundant - maybe some systemd guru could chime in...

remember - this is not the root cause of your problem - as shown in the log, weewx sleeps for two minutes, and by the time it tries a mysql connection again, the network and time are squared away.

 
The log is not stopped is just that nothing else happen on the machine. this rpi is dedicated only to weewx it's a headless machine connected to the lan via ethernet. the only service loaded in top of weewx is tightvnc server. it's like weewx goes in loop somewhere and stop doing anything. this morning i just restart the weewx service and everything went back on normal.

does anything else write to the syslog?

try running weewx with the simulator as the driver instead of wh23xx.  see if that results in the same behavior.

 
FYI my wh2310 weather station is a Misol clone of TP2700WC

 just to be clear, fine offset manufactures the stations.  they are rebranded (not cloned) by various resellers.  depending on the vendor, the WH2300 console appears to be packaged with one of three different types of instrument clusters - an all-in-one, a two-part, or a three-part cluster.

http://foshk.com/

http://foshk.com/Weather_Professional/WH2300.html

since the wh23xx driver talks to the console, the instrument cluster does not matter as far as the driver is concerned.

m

Marc Aubry

unread,
Dec 26, 2016, 7:38:49 AM12/26/16
to weewx-user
Hi
Thanks for your help.
I'll be monitoring ps -aux the next crash. So fare no more crash after the morning crash.
I think my network is all clear and good now.
This is my plan to try to solve the problem.
I'm going to set up a clean install on rpi3/jessie running with the simulator.
I need to run the two weewx in parallel on the same mysql server. I hope i can change the database name in the weewx config to run to weewx database in parallel. I still want to have the crashy conf running and replicating on my public website (it's part on my seo cross referencing strategy). On the crashy config i' m going to shedule a CRON reboot every hour to hide the problem.
Then slowly slowly i'll be loading up the new config with extra extention like skin, forecast, ftp skin etc.
If everything ok with the simulator then i'll switchoff the crashy config swap the database install the wh23xx driver on the new config and maybe everything will run smoothly as it should be :)
What do you think about this plan?
It's not going to explain the actual problem but maybe i will be able to a a config running ...

Marc Aubry

unread,
Dec 26, 2016, 9:15:48 AM12/26/16
to weewx-user
19:37 crash
yes i can see some cron task on the syslog
And yes weewx still appear in ps -aux
See below.


pi@weatherstation:~ $ sudo tail -f /var/log/syslog
Dec 26 19:37:10 weatherstation weewx[600]: wh23xx: rain_totals: {'value': 626.1} (0x14 0x14)
Dec 26 19:37:10 weatherstation weewx[600]: wh23xx: light: {'value': 228.3} (0x15 0x15)
Dec 26 19:37:10 weatherstation weewx[600]: wh23xx: uv: {'value': 0.0} (0x16 0x16)
Dec 26 19:37:10 weatherstation weewx[600]: wh23xx: uvi: {'value': 0} (0x17 0x17)
Dec 26 19:37:10 weatherstation weewx[600]: wh23xx: decoded data: {'wind_speed': {'value': 1.3}, 'gust_speed': {'value': 2.0}, 'rain_totals': {'value': 626.1}, 'in_temp': {'value': 27.5}, 'dewpoint': {'value': 22.299999999999997}, 'rain_month': {'value': 406.8}, 'out_humidity': {'value': 73}, 'light': {'value': 228.3}, 'rain_rate': {'value': 0.0}, 'heatindex': {'value': 30.200000000000003}, 'in_humidity': {'value': 65}, 'rain_day': {'value': 0.0}, 'out_temp': {'value': 27.599999999999994}, 'rel_baro': {'value': 1010.6}, 'uv': {'value': 0.0}, 'uvi': {'value': 0}, 'rain_year': {'value': 626.1}, 'rain_week': {'value': 0.0}, 'abs_baro': {'value': 1010.6}, 'wind_dir': {'value': 270}, 'windchill': {'value': 27.599999999999994}}
Dec 26 19:37:10 weatherstation weewx[600]: wh23xx: packet: {'pressure': 1010.6, 'outHumidity': 73, 'light': 228.3, 'UV': 0, 'radiation': 0.0, 'rain': 0.0, 'dateTime': 1482755831, 'windDir': 270, 'outTemp': 27.599999999999994, 'windSpeed': 1.3, 'inHumidity': 65, 'inTemp': 27.5, 'windGust': 2.0, 'usUnits': 17}
Dec 26 19:37:25 weatherstation weewx[600]: wh23xx: read_record: cmdbuf: 02 02 04 04 (len=4)
Dec 26 20:17:01 weatherstation CRON[1191]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly)
Dec 26 21:07:11 weatherstation systemd[1]: Starting Session c5 of user pi.
Dec 26 21:07:11 weatherstation systemd[1]: Started Session c5 of user pi.


pi@weatherstation:~ $ ps -aux
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
root 1 0.0 0.4 22892 4048 ? Ss 18:09 0:05 /sbin/init splash
root 2 0.0 0.0 0 0 ? S 18:09 0:00 [kthreadd]
root 3 0.0 0.0 0 0 ? S 18:09 0:00 [ksoftirqd/0]
root 5 0.0 0.0 0 0 ? S< 18:09 0:00 [kworker/0:0H]
root 7 0.0 0.0 0 0 ? S 18:09 0:09 [rcu_sched]
root 8 0.0 0.0 0 0 ? S 18:09 0:00 [rcu_bh]
root 9 0.0 0.0 0 0 ? S 18:09 0:00 [migration/0]
root 10 0.0 0.0 0 0 ? S 18:09 0:00 [migration/1]
root 11 0.0 0.0 0 0 ? S 18:09 0:00 [ksoftirqd/1]
root 13 0.0 0.0 0 0 ? S< 18:09 0:00 [kworker/1:0H]
root 14 0.0 0.0 0 0 ? S 18:09 0:00 [migration/2]
root 15 0.0 0.0 0 0 ? S 18:09 0:00 [ksoftirqd/2]
root 17 0.0 0.0 0 0 ? S< 18:09 0:00 [kworker/2:0H]
root 18 0.0 0.0 0 0 ? S 18:09 0:00 [migration/3]
root 19 0.0 0.0 0 0 ? S 18:09 0:00 [ksoftirqd/3]
root 21 0.0 0.0 0 0 ? S< 18:09 0:00 [kworker/3:0H]
root 22 0.0 0.0 0 0 ? S 18:09 0:00 [kdevtmpfs]
root 23 0.0 0.0 0 0 ? S< 18:09 0:00 [netns]
root 24 0.0 0.0 0 0 ? S< 18:09 0:00 [perf]
root 25 0.0 0.0 0 0 ? S 18:09 0:00 [khungtaskd]
root 26 0.0 0.0 0 0 ? S< 18:09 0:00 [writeback]
root 27 0.0 0.0 0 0 ? S< 18:09 0:00 [crypto]
root 28 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 29 0.0 0.0 0 0 ? S< 18:09 0:00 [kblockd]
root 31 0.0 0.0 0 0 ? S< 18:09 0:00 [rpciod]
root 32 0.0 0.0 0 0 ? S 18:09 0:00 [kswapd0]
root 33 0.0 0.0 0 0 ? S< 18:09 0:00 [vmstat]
root 34 0.0 0.0 0 0 ? S 18:09 0:00 [fsnotify_mark]
root 35 0.0 0.0 0 0 ? S< 18:09 0:00 [nfsiod]
root 44 0.0 0.0 0 0 ? S< 18:09 0:00 [kthrotld]
root 45 0.0 0.0 0 0 ? S 18:09 0:00 [kworker/1:1]
root 48 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 49 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 50 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 51 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 52 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 53 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 54 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 55 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 56 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 57 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 58 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 59 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 60 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 61 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 62 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 63 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 64 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 65 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 66 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 67 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 68 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 69 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 70 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 71 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 72 0.0 0.0 0 0 ? S< 18:09 0:00 [VCHIQ-0]
root 73 0.0 0.0 0 0 ? S< 18:09 0:00 [VCHIQr-0]
root 74 0.0 0.0 0 0 ? S< 18:09 0:00 [VCHIQs-0]
root 75 0.0 0.0 0 0 ? S< 18:09 0:00 [iscsi_eh]
root 76 0.0 0.0 0 0 ? S< 18:09 0:00 [dwc_otg]
root 77 0.0 0.0 0 0 ? S< 18:09 0:00 [DWC Notificatio]
root 79 0.0 0.0 0 0 ? S 18:09 0:00 [VCHIQka-0]
root 80 0.0 0.0 0 0 ? S< 18:09 0:00 [SMIO]
root 81 0.0 0.0 0 0 ? S< 18:09 0:00 [deferwq]
root 82 0.0 0.0 0 0 ? S 18:09 0:00 [kworker/u8:2]
root 83 0.0 0.0 0 0 ? S< 18:09 0:00 [bioset]
root 84 0.0 0.0 0 0 ? S 18:09 0:01 [mmcqd/0]
root 86 0.0 0.0 0 0 ? S 18:09 0:00 [jbd2/mmcblk0p7-]
root 87 0.0 0.0 0 0 ? S< 18:09 0:00 [ext4-rsv-conver]
root 88 0.0 0.0 0 0 ? S< 18:09 0:00 [ipv6_addrconf]
root 110 0.0 0.0 0 0 ? S< 18:09 0:00 [kworker/2:1H]
root 132 0.0 0.3 11928 3000 ? Ss 18:09 0:00 /lib/systemd/systemd-udevd
root 136 0.2 0.6 10324 6444 ? Ss 18:09 0:24 /lib/systemd/systemd-journald
root 389 0.0 0.2 5072 2412 ? Ss 18:09 0:00 /usr/sbin/cron -f
root 390 0.0 0.2 3852 2476 ? Ss 18:09 0:00 /lib/systemd/systemd-logind
avahi 401 0.0 0.2 3876 2488 ? Ss 18:09 0:00 avahi-daemon: running [weatherstation.local]
message+ 404 0.0 0.3 5720 3204 ? Ss 18:09 0:00 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation
root 421 0.0 0.0 0 0 ? S< 18:09 0:00 [cfg80211]
nobody 423 0.0 0.1 2292 1468 ? Ss 18:09 0:00 /usr/sbin/thd --daemon --triggers /etc/triggerhappy/triggers.d/ --socket /var/run/thd.socket --pidfile /var/run/thd.pid -root 424 0.0 0.1 2564 1808 ? Ss 18:09 0:00 /sbin/dhcpcd -q -b
avahi 432 0.0 0.0 3876 240 ? S 18:09 0:00 avahi-daemon: chroot helper
root 494 0.0 0.2 32144 2652 ? Ssl 18:09 0:05 /usr/sbin/rsyslogd -n
root 500 0.0 0.4 7864 4304 ? Ss 18:09 0:00 /usr/sbin/sshd -D
pi 555 0.0 0.3 4976 3252 ? Ss 18:09 0:00 /lib/systemd/systemd --user
ntp 565 0.0 0.3 5688 3684 ? Ss 18:09 0:01 /usr/sbin/ntpd -p /var/run/ntpd.pid -g -u 107:112
root 567 0.0 0.5 35892 5476 ? Ssl 18:09 0:00 /usr/sbin/lightdm
pi 570 0.0 0.1 6840 1260 ? S 18:09 0:00 (sd-pam)
root 586 0.0 0.2 5668 2768 tty1 Ss 18:09 0:00 /bin/login -f
root 587 0.0 0.2 3872 1924 ? Ss+ 18:09 0:00 /sbin/agetty --keep-baud 115200 38400 9600 ttyAMA0 vt102
root 600 10.4 3.5 96412 33980 ? Sl 18:09 18:32 python /usr/bin/weewxd --daemon --pidfile=/var/run/weewx.pid /etc/weewx/weewx.conf
root 613 0.0 0.4 7216 3796 ? Ss 18:09 0:00 /usr/sbin/apache2 -k start
www-data 616 0.0 0.4 231848 4184 ? Sl 18:09 0:04 /usr/sbin/apache2 -k start
www-data 617 0.0 0.5 235952 4748 ? Sl 18:09 0:04 /usr/sbin/apache2 -k start
root 689 0.8 2.2 31624 21336 tty7 Ss+ 18:09 1:31 /usr/lib/xorg/Xorg :0 -seat seat0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch
root 698 0.0 0.5 27808 5636 ? Sl 18:09 0:00 lightdm --session-child 19 22
lightdm 784 0.0 0.3 4976 3356 ? Ss 18:09 0:00 /lib/systemd/systemd --user
lightdm 787 0.0 0.1 6840 1260 ? S 18:09 0:00 (sd-pam)
lightdm 790 0.6 3.5 60196 33260 ? Ssl 18:09 1:06 /usr/sbin/pi-greeter
pi 800 0.0 0.4 6580 4504 tty1 S+ 18:09 0:00 -bash
root 832 0.0 0.0 0 0 ? S< 18:09 0:00 [kworker/1:1H]
root 839 0.0 0.4 9564 4208 ? S 18:09 0:00 lightdm --session-child 13 22
pi 841 0.0 0.8 11156 8060 ? S 18:10 0:05 Xtightvnc :1 -desktop X -auth /home/pi/.Xauthority -geometry 1368x768 -depth 24 -rfbwait 120000 -rfbauth /home/pi/.vnc/papi 845 0.0 0.0 1912 392 ? S 18:10 0:00 /bin/sh /home/pi/.vnc/xstartup
pi 852 0.0 1.2 50976 11380 ? Sl 18:10 0:00 /usr/bin/lxsession -s LXDE-pi -e LXDE
pi 907 0.0 0.0 3700 220 ? Ss 18:10 0:00 /usr/bin/ssh-agent /usr/bin/dbus-launch --exit-with-session x-session-manager
pi 910 0.0 0.1 3692 1500 ? S 18:10 0:00 /usr/bin/dbus-launch --exit-with-session x-session-manager
pi 911 0.0 0.2 5608 2124 ? Ss 18:10 0:00 /usr/bin/dbus-daemon --fork --print-pid 5 --print-address 7 --session
pi 917 0.0 0.6 30856 5716 ? Sl 18:10 0:00 /usr/lib/gvfs/gvfsd
pi 921 0.0 0.4 47252 4328 ? Sl 18:10 0:00 /usr/lib/gvfs/gvfsd-fuse /run/user/1000/gvfs -f -o big_writes
root 927 0.0 0.0 0 0 ? S< 18:10 0:00 [kworker/0:1H]
pi 934 0.0 1.2 20208 11392 ? S 18:10 0:00 openbox --config-file /home/pi/.config/openbox/lxde-pi-rc.xml
pi 937 0.0 0.9 30376 8952 ? Sl 18:10 0:00 lxpolkit
pi 939 0.2 2.5 93324 24328 ? Sl 18:10 0:25 lxpanel --profile LXDE-pi
pi 940 0.0 1.8 74056 17752 ? Sl 18:10 0:00 pcmanfm --desktop --profile LXDE-pi
pi 947 0.0 0.0 3700 220 ? Ss 18:10 0:00 /usr/bin/ssh-agent -s
root 950 0.0 0.6 36792 6104 ? Ssl 18:10 0:00 /usr/lib/policykit-1/polkitd --no-debug
pi 964 0.0 0.7 41852 7296 ? Sl 18:10 0:00 /usr/lib/gvfs/gvfs-udisks2-volume-monitor
root 969 0.0 0.6 54580 6352 ? Ssl 18:10 0:00 /usr/lib/udisks2/udisksd --no-debug
rtkit 973 0.0 0.2 21376 2024 ? SNsl 18:10 0:00 /usr/lib/rtkit/rtkit-daemon
root 988 0.0 0.3 5008 3456 ? Ss 18:10 0:00 /usr/lib/bluetooth/bluetoothd
pi 989 0.0 0.5 30952 5532 ? Sl 18:10 0:00 /usr/lib/gvfs/gvfs-gphoto2-volume-monitor
pi 996 0.0 0.6 42416 6436 ? Sl 18:10 0:00 /usr/lib/gvfs/gvfs-afc-volume-monitor
pi 1001 0.0 0.0 1912 96 ? S 18:10 0:00 /bin/sh /usr/bin/start-pulseaudio-x11
pi 1002 0.0 0.0 5796 596 ? S 18:10 0:00 /usr/bin/xprop -root -spy
pi 1012 0.0 0.5 29932 5244 ? Sl 18:10 0:00 /usr/lib/gvfs/gvfs-mtp-volume-monitor
pi 1021 0.0 0.5 30036 5428 ? Sl 18:10 0:00 /usr/lib/gvfs/gvfs-goa-volume-monitor
pi 1030 0.0 0.5 28292 4852 ? Ssl 18:10 0:00 /usr/lib/menu-cache/menu-cached /tmp/.menu-cached-:1-pi
pi 1033 0.0 0.6 49888 6220 ? Sl 18:10 0:00 /usr/lib/gvfs/gvfsd-trash --spawner :1.1 /org/gtk/gvfs/exec_spaw/0
root 1077 0.0 0.0 0 0 ? S 18:15 0:02 [kworker/3:0]
root 1102 0.0 0.0 0 0 ? S 18:24 0:00 [kworker/2:2]
root 1124 0.0 0.0 0 0 ? S 18:47 0:02 [kworker/0:1]
root 1147 0.0 0.0 0 0 ? S 19:16 0:00 [kworker/u8:1]
root 1174 0.0 0.0 0 0 ? S 19:27 0:00 [kworker/1:0]
root 1178 0.0 0.0 0 0 ? S 19:33 0:00 [kworker/0:2]
root 1179 0.0 0.0 0 0 ? S 19:33 0:00 [kworker/2:0]
root 1182 0.0 0.0 0 0 ? S 19:36 0:00 [kworker/3:2]
root 1208 2.1 0.5 12076 5256 ? Ss 21:07 0:00 sshd: pi [priv]
pi 1215 0.4 0.4 12076 4048 ? R 21:07 0:00 sshd: pi@pts/0
pi 1217 4.0 0.4 6488 4424 pts/0 Ss 21:07 0:00 -bash
root 1218 0.0 0.0 0 0 ? S 21:07 0:00 [kworker/u8:0]
root 1255 0.0 0.0 0 0 ? S 21:07 0:00 [kworker


mwall

unread,
Dec 26, 2016, 10:06:53 AM12/26/16
to weewx-user
On Monday, December 26, 2016 at 9:15:48 AM UTC-5, Marc Aubry wrote:
19:37 crash
yes i can see some cron task on the syslog
And yes weewx still appear in ps -aux
See below.



then this is not a crash.  a crash is when a program dies unexpectedly.

run weewx directly in a shell.  when it stops responding, look at the shell to see if there is a stack trace of exceptions.  if there is no stack trace, and you still see no log output from weewx, then control-c weewx in the shell.  at that point you will see a stack trace ending in 'KeyboardInterrrupt'.  post that stack trace.

you will solve the problem sooner by removing complexity than you will by adding more.

m

Marc Aubry

unread,
Dec 27, 2016, 1:26:05 AM12/27/16
to weewx-user
Hi
find below the last console print after weewx stop reporting and the console print after Ctrl C
i can't restart weewx by sudo weewxd /etc/weewx/weewx.conf 
stay stuck on
File "/usr/share/weewx/user/wh23xx.py", line 365, in _get_current
    time.sleep(self.retry_wait)
i have do reboot the pi to restart weewx.

Last weewx stop console print
REC:    2016-12-27 09:40:00 WIB (1482806400) altimeter: 1010.98914931, appTemp: 33.8497907262, barometer: 1011.2593677, cloudbase: 1077.32333783, dateTime: 1482806400.0, dewpoint: 21.3580215713, ET: 0.00405905271933, heatindex: 32.7730155621, humidex: 38.6958833164, inDewpoint: 67.5524896328, inHumidity: 65.0, inTemp: 26.9, interval: 5, light: 90633.1842105, maxSolarRad: 729.192357985, outHumidity: 60.1052631579, outTemp: 29.9578947368, pressure: 1010.68947368, radiation: 510.923157895, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 4.78947368421, windchill: 29.9578947368, windDir: 150.362157876, windGust: 3.60001789556, windGustDir: None, windrun: 2.26457874991, windSpeed: 2.44422267646
LOOP:   2016-12-27 09:40:17 WIB (1482806417) altimeter: 1011.09972874, appTemp: 34.1705907237, barometer: 1011.36968913, cloudbase: 1116.13758088, dateTime: 1482806417, dewpoint: 21.1888423968, heatindex: 32.82163605, humidex: 38.6869812418, inDewpoint: 67.5524896328, inHumidity: 65, inTemp: 26.9, light: 100947.1, maxSolarRad: 738.862324385, outHumidity: 59, outTemp: 30.1, pressure: 1010.8, radiation: 538.156, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 5, windchill: 30.1, windDir: 180, windGust: 3.60000894777, windSpeed: 1.08000268433
LOOP:   2016-12-27 09:40:45 WIB (1482806445) altimeter: 1010.99968069, appTemp: 34.1792613821, barometer: 1011.26944494, cloudbase: 1082.67646608, dateTime: 1482806445, dewpoint: 21.5571955446, heatindex: 33.2175572368, humidex: 39.1161062185, inDewpoint: 67.5524896328, inHumidity: 65, inTemp: 26.9, light: 100947.1, maxSolarRad: 740.481841364, outHumidity: 60, outTemp: 30.2, pressure: 1010.7, radiation: 538.156, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 5, windchill: 30.2, windDir: 135, windGust: 3.60000894777, windSpeed: 2.52000626344
after Ctrl C
^CTraceback (most recent call last):
  File "/usr/bin/weewxd", line 64, in <module>
    weewx.engine.main(options, args)
  File "/usr/share/weewx/weewx/engine.py", line 847, in main
    engine.run()
  File "/usr/share/weewx/weewx/engine.py", line 186, in run
    for packet in self.console.genLoopPackets():
  File "/usr/share/weewx/user/wh23xx.py", line 338, in genLoopPackets
    raw = self._get_current()
  File "/usr/share/weewx/user/wh23xx.py", line 365, in _get_current
    time.sleep(self.retry_wait)
KeyboardInterrupt

mwall

unread,
Dec 27, 2016, 1:58:07 AM12/27/16
to weewx-user
On Tuesday, December 27, 2016 at 1:26:05 AM UTC-5, Marc Aubry wrote:
Hi
find below the last console print after weewx stop reporting and the console print after Ctrl C
i can't restart weewx by sudo weewxd /etc/weewx/weewx.conf 
stay stuck on
File "/usr/share/weewx/user/wh23xx.py", line 365, in _get_current
    time.sleep(self.retry_wait)


now we're getting somewhere!

the wh23xx.py that you are running is not the same as the wh23xx.py from github.

please replace your /usr/share/weewx/user/wh23xx.py with this one:

https://raw.githubusercontent.com/matthewwall/weewx-wh23xx/master/bin/user/wh23xx.py

then run weewx again the same way that you just did.  this time you should see more messages in the log file when weewx becomes unresponsive (every 10 seconds, in fact).

m

Marc Aubry

unread,
Dec 27, 2016, 3:46:18 AM12/27/16
to weewx-user
ok
done....
that's weird that the wh23xx driver was not the good one because i did an update the 23 dec with the following command:
sudo wee_extension --install weewx-wh23xx.zip
i probably did something wrong...
i just run the weewxd from a screen bash and will wait for the next problem
thanks

Marc Aubry

unread,
Dec 27, 2016, 12:09:56 PM12/27/16
to weewx-user
22:18 weewx stop reporting
still present in memory with ps -aux
monitor was showing at 00:02
dateTime: 1482851803, dewpoint: 22.7833668614, heatindex: 25.9, humidex: 35.9614413056, inDewpoint: 69.7932247353, inHumidity: 74, inTemp: 26.0, light: 206.6, maxSolarRad: 0.0, outHumidity: 83, outTemp: 25.9, pressure: 1011.3, radiation: 0.0, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 0, windchill: 25.9, windDir: 270, windGust: 3.60000894777, windSpeed: 2.52000626344
LOOP:   2016-12-27 22:16:59 WIB (1482851819) altimeter: 1011.599969, appTemp: 30.5346411764, barometer: 1011.87797817, cloudbase: 393.614853462, dateTime: 1482851819, dewpoint: 22.7833668614, heatindex: 25.9, humidex: 35.9614413056, inDewpoint: 69.7932247353, inHumidity: 74, inTemp: 26.0, light: 206.6, maxSolarRad: 0.0, outHumidity: 83, outTemp: 25.9, pressure: 1011.3, radiation: 0.0, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 0, windchill: 25.9, windDir: 270, windGust: 3.60000894777, windSpeed: 2.52000626344
LOOP:   2016-12-27 22:17:16 WIB (1482851836) altimeter: 1011.599969, appTemp: 30.5346411764, barometer: 1011.87797817, cloudbase: 393.614853462, dateTime: 1482851836, dewpoint: 22.7833668614, heatindex: 25.9, humidex: 35.9614413056, inDewpoint: 69.7932247353, inHumidity: 74, inTemp: 26.0, light: 206.6, maxSolarRad: 0.0, outHumidity: 83, outTemp: 25.9, pressure: 1011.3, radiation: 0.0, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 0, windchill: 25.9, windDir: 270, windGust: 3.60000894777, windSpeed: 2.52000626344
LOOP:   2016-12-27 22:17:32 WIB (1482851852) altimeter: 1011.49992095, appTemp: 30.5346411764, barometer: 1011.77792101, cloudbase: 393.614853462, dateTime: 1482851852, dewpoint: 22.7833668614, heatindex: 25.9, humidex: 35.9614413056, inDewpoint: 69.7932247353, inHumidity: 74, inTemp: 26.0, light: 206.6, maxSolarRad: 0.0, outHumidity: 83, outTemp: 25.9, pressure: 1011.2, radiation: 0.0, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 0, windchill: 25.9, windDir: 270, windGust: 3.60000894777, windSpeed: 2.52000626344
LOOP:   2016-12-27 22:17:48 WIB (1482851868) altimeter: 1011.49992095, appTemp: 30.5346411764, barometer: 1011.77792101, cloudbase: 393.614853462, dateTime: 1482851868, dewpoint: 22.7833668614, heatindex: 25.9, humidex: 35.9614413056, inDewpoint: 69.7932247353, inHumidity: 74, inTemp: 26.0, light: 206.6, maxSolarRad: 0.0, outHumidity: 83, outTemp: 25.9, pressure: 1011.2, radiation: 0.0, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 0, windchill: 25.9, windDir: 270, windGust: 3.60000894777, windSpeed: 2.52000626344
LOOP:   2016-12-27 22:18:05 WIB (1482851885) altimeter: 1011.49992095, appTemp: 30.5346411764, barometer: 1011.77792101, cloudbase: 393.614853462, dateTime: 1482851885, dewpoint: 22.7833668614, heatindex: 25.9, humidex: 35.9614413056, inDewpoint: 69.7932247353, inHumidity: 74, inTemp: 26.0, light: 206.6, maxSolarRad: 0.0, outHumidity: 83, outTemp: 25.9, pressure: 1011.2, radiation: 0.0, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 0, windchill: 25.9, windDir: 270, windGust: 3.60000894777, windSpeed: 2.52000626344
After CTRL C
^CTraceback (most recent call last):
  File "/usr/bin/weewxd", line 64, in <module>
    weewx.engine.main(options, args)
  File "/usr/share/weewx/weewx/engine.py", line 847, in main
    engine.run()
  File "/usr/share/weewx/weewx/engine.py", line 186, in run
    for packet in self.console.genLoopPackets():
  File "/usr/share/weewx/user/wh23xx.py", line 353, in genLoopPackets
    raw = self._get_current()
  File "/usr/share/weewx/user/wh23xx.py", line 372, in _get_current
    return self._station.get_current()
KeyboardInterrupt
This time manage to start it with sudo weewxd /etc/weewx/weewx.conf
no need to reboot

mwall

unread,
Dec 27, 2016, 12:49:35 PM12/27/16
to weewx-user
On Tuesday, December 27, 2016 at 12:09:56 PM UTC-5, Marc Aubry wrote:
22:18 weewx stop reporting
still present in memory with ps -aux
monitor was showing at 00:02
...
This time manage to start it with sudo weewxd /etc/weewx/weewx.conf
no need to reboot

and what is in the log up to the time when you did the keyboard interrupt?
 

Marc Aubry

unread,
Dec 27, 2016, 7:40:49 PM12/27/16
to weewx-user
log file from 22:17 to 00:05
Dec 27 22:17:48 weatherstation weewx[1176]: wh23xx: decoded data: {'wind_speed': {'value': 0.7}, 'gust_speed': {'value': 1.0}, 'rain_totals': {'value': 626.1}, 'in_temp': {'value': 26.0}, 'dewpoint': {'value': 22.799999999999997}, 'rain_month': {'value': 406.8}, 'out_humidity': {'value': 83}, 'light': {'value': 206.6}, 'rain_rate': {'value': 0.0}, 'heatindex': {'value': 25.900000000000006}, 'in_humidity': {'value': 74}, 'rain_day': {'value': 0.0}, 'out_temp': {'value': 25.900000000000006}, 'rel_baro': {'value': 1011.2}, 'uv': {'value': 0.0}, 'uvi': {'value': 0}, 'rain_year': {'value': 626.1}, 'rain_week': {'value': 0.0}, 'abs_baro': {'value': 1011.2}, 'wind_dir': {'value': 270}, 'windchill': {'value': 25.900000000000006}}
Dec 27 22:17:48 weatherstation weewx[1176]: wh23xx: packet: {'pressure': 1011.2, 'outHumidity': 83, 'light': 206.6, 'UV': 0, 'radiation': 0.0, 'rain': 0.0, 'dateTime': 1482851868, 'windDir': 270, 'outTemp': 25.900000000000006, 'windSpeed': 0.7, 'inHumidity': 74, 'inTemp': 26.0, 'windGust': 1.0, 'usUnits': 17}
Dec 27 22:18:03 weatherstation weewx[1176]: wh23xx: read_record: cmdbuf: 02 02 04 04 (len=4)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: read_record: buf: 01 3b 04 4a 01 02 94 02 02 93 03 02 74 04 02 93 05 02 93 06 4a 07 53 08 27 80 09 27 80 0a 01 0e 0b 00 07 0c 00 0a 0e 00 00 00 00 10 00 00 00 00 11 00 00 00 00 12 00 00 0f e4 13 00 00 (len=61)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: record_size: 74
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: read_record: buf: 01 12 18 75 14 00 00 18 75 15 00 00 08 12 16 00 00 17 00 43 4a 07 53 08 27 80 09 27 80 0a 01 0e 0b 00 07 0c 00 0a 0e 00 00 00 00 10 00 00 00 00 11 00 00 00 00 12 00 00 0f e4 13 00 00 (len=61)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: read_record: rbuf: 01 02 94 02 02 93 03 02 74 04 02 93 05 02 93 06 4a 07 53 08 27 80 09 27 80 0a 01 0e 0b 00 07 0c 00 0a 0e 00 00 00 00 10 00 00 00 00 11 00 00 00 00 12 00 00 0f e4 13 00 00 18 75 14 00 00 18 75 15 00 00 08 12 16 00 00 17 00 (len=74) chksum=0x43
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: raw data: [1, 2, 148, 2, 2, 147, 3, 2, 116, 4, 2, 147, 5, 2, 147, 6, 74, 7, 83, 8, 39, 128, 9, 39, 128, 10, 1, 14, 11, 0, 7, 12, 0, 10, 14, 0, 0, 0, 0, 16, 0, 0, 0, 0, 17, 0, 0, 0, 0, 18, 0, 0, 15, 228, 19, 0, 0, 24, 117, 20, 0, 0, 24, 117, 21, 0, 0, 8, 18, 22, 0, 0, 23, 0]
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: in_temp: {'value': 26.0} (0x01 0x01)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: out_temp: {'value': 25.900000000000006} (0x02 0x02)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: dewpoint: {'value': 22.799999999999997} (0x03 0x03)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: windchill: {'value': 25.900000000000006} (0x04 0x04)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: heatindex: {'value': 25.900000000000006} (0x05 0x05)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: in_humidity: {'value': 74} (0x06 0x06)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: out_humidity: {'value': 83} (0x07 0x07)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: abs_baro: {'value': 1011.2} (0x08 0x08)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: rel_baro: {'value': 1011.2} (0x09 0x09)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: wind_dir: {'value': 270} (0x0a 0x0a)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: wind_speed: {'value': 0.7} (0x0b 0x0b)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: gust_speed: {'value': 1.0} (0x0c 0x0c)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: rain_rate: {'value': 0.0} (0x0e 0x0e)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: rain_day: {'value': 0.0} (0x10 0x10)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: rain_week: {'value': 0.0} (0x11 0x11)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: rain_month: {'value': 406.8} (0x12 0x12)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: rain_year: {'value': 626.1} (0x13 0x13)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: rain_totals: {'value': 626.1} (0x14 0x14)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: light: {'value': 206.6} (0x15 0x15)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: uv: {'value': 0.0} (0x16 0x16)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: uvi: {'value': 0} (0x17 0x17)
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: decoded data: {'wind_speed': {'value': 0.7}, 'gust_speed': {'value': 1.0}, 'rain_totals': {'value': 626.1}, 'in_temp': {'value': 26.0}, 'dewpoint': {'value': 22.799999999999997}, 'rain_month': {'value': 406.8}, 'out_humidity': {'value': 83}, 'light': {'value': 206.6}, 'rain_rate': {'value': 0.0}, 'heatindex': {'value': 25.900000000000006}, 'in_humidity': {'value': 74}, 'rain_day': {'value': 0.0}, 'out_temp': {'value': 25.900000000000006}, 'rel_baro': {'value': 1011.2}, 'uv': {'value': 0.0}, 'uvi': {'value': 0}, 'rain_year': {'value': 626.1}, 'rain_week': {'value': 0.0}, 'abs_baro': {'value': 1011.2}, 'wind_dir': {'value': 270}, 'windchill': {'value': 25.900000000000006}}
Dec 27 22:18:04 weatherstation weewx[1176]: wh23xx: packet: {'pressure': 1011.2, 'outHumidity': 83, 'light': 206.6, 'UV': 0, 'radiation': 0.0, 'rain': 0.0, 'dateTime': 1482851885, 'windDir': 270, 'outTemp': 25.900000000000006, 'windSpeed': 0.7, 'inHumidity': 74, 'inTemp': 26.0, 'windGust': 1.0, 'usUnits': 17}
Dec 27 22:18:19 weatherstation weewx[1176]: wh23xx: read_record: cmdbuf: 02 02 04 04 (len=4)
Dec 27 23:17:01 weatherstation CRON[1560]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Dec 28 00:01:53 weatherstation systemd[1]: Starting Session c7 of user pi.
Dec 28 00:01:53 weatherstation systemd[1]: Started Session c7 of user pi.
Dec 28 00:03:21 weatherstation weewx[1176]: engine: Main loop exiting. Shutting engine down.
Dec 28 00:03:21 weatherstation weewx[1176]: engine: Shutting down StdReport thread
Dec 28 00:03:21 weatherstation weewx[1176]: engine: StdReport thread has been terminated
Dec 28 00:03:21 weatherstation weewx[1176]: restx: Shut down PWSWeather thread.
Dec 28 00:03:21 weatherstation weewx[1176]: restx: Shut down Wunderground-PWS thread.
Dec 28 00:03:21 weatherstation weewx[1176]: restx: Shut down StationRegistry thread.
Dec 28 00:03:21 weatherstation weewx[1176]: engine: Keyboard interrupt.
Dec 28 00:05:00 weatherstation weewx[1647]: engine: Initializing weewx version 3.6.2
Dec 28 00:05:00 weatherstation weewx[1647]: engine: Using Python 2.7.9 (default, Sep 17 2016, 20:26:04) #012[GCC 4.9.2]
Dec 28 00:05:00 weatherstation weewx[1647]: engine: Platform Linux-4.4.38-v7+-armv7l-with-debian-8.0
Dec 28 00:05:00 weatherstation weewx[1647]: engine: Using configuration file /etc/weewx/weewx.conf
Dec 28 00:05:00 weatherstation weewx[1647]: engine: Initializing engine
Dec 28 00:05:00 weatherstation weewx[1647]: engine: Loading station type WH23xx (user.wh23xx)
Dec 28 00:05:00 weatherstation weewx[1647]: wh23xx: driver version is 0.8
Dec 28 00:05:00 weatherstation weewx[1647]: wh23xx: usb info: pyusb_version=0.4.x
Dec 28 00:05:00 weatherstation weewx[1647]: wh23xx: poll interval is 15
Dec 28 00:05:00 weatherstation weewx[1647]: wh23xx: Found device on USB bus=001 device=004
Dec 28 00:05:01 weatherstation kernel: [21308.341146] usb 1-1.2: reset full-speed USB device number 4 using dwc_otg
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service weewx.engine.StdTimeSynch
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Finished loading service weewx.engine.StdTimeSynch
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service weewx.engine.StdConvert
Dec 28 00:05:01 weatherstation weewx[1647]: engine: StdConvert target unit is 0x10
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Finished loading service weewx.engine.StdConvert
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service weewx.engine.StdCalibrate
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Finished loading service weewx.engine.StdCalibrate
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service weewx.engine.StdQC
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Finished loading service weewx.engine.StdQC
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service weewx.wxservices.StdWXCalculate
Dec 28 00:05:01 weatherstation weewx[1647]: 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
Dec 28 00:05:01 weatherstation weewx[1647]: wxcalculate: The following algorithms will be used for calculations: altimeter=aaNOAA, maxSolarRad=RS
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Finished loading service weewx.wxservices.StdWXCalculate
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service weewx.engine.StdArchive
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Archive will use data binding wx_binding
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Record generation will be attempted in 'hardware'
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Using archive interval of 300 seconds (specified in weewx configuration)
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Use LOOP data in hi/low calculations: 1
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Using binding 'wx_binding' to database 'weewx'
Dec 28 00:05:01 weatherstation weewx[1647]: manager: Starting backfill of daily summaries
Dec 28 00:05:01 weatherstation weewx[1647]: manager: Daily summaries up to date
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Finished loading service weewx.engine.StdArchive
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service user.forecast.ZambrettiForecast
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: Zambretti: forecast version 3.2.6
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: Zambretti: last forecast issued 2016-12-27 18:15:00 WIB (1482837300), requested 2016-12-27 18:15:00 WIB (1482837300)
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: Zambretti: interval=600 max_age=604800 winddir_period=1800 pressure_period=10800 hemisphere=south lower_pressure=950.0 upper_pressure=1050.0
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Finished loading service user.forecast.ZambrettiForecast
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service user.forecast.WUForecast
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: WU: forecast version 3.2.6
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: WU: last forecast issued 2016-12-27 19:30:32 WIB (1482841832), requested 2016-12-27 19:30:32 WIB (1482841832)
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: WU: interval=10800 max_age=604800 api_key=XXXXXXXXXXXXec50 location=-1.217,100.400 fc=hourly10day
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Finished loading service user.forecast.WUForecast
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service user.forecast.NWSForecast
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: NWS: forecast version 3.2.6
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: NWS: location ID (lid) is not specified
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: NWS: forecast office ID (foid) is not specified
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: NWS: forecast will not be run
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Finished loading service user.forecast.NWSForecast
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service user.forecast.OWMForecast
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: OWM: forecast version 3.2.6
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: OWM: API key (api_key) is not specified
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: OWM: forecast will not be run
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Finished loading service user.forecast.OWMForecast
Dec 28 00:05:01 weatherstation weewx[1647]: engine: Loading service user.forecast.UKMOForecast
Dec 28 00:05:01 weatherstation weewx[1647]: forecast: MainThread: UKMO: forecast version 3.2.6
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: UKMO: API key (api_key) is not specified
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: UKMO: forecast will not be run
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service user.forecast.UKMOForecast
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service user.forecast.AerisForecast
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: Aeris: forecast version 3.2.6
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: Aeris: client identifier (client_id) is not specified
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: Aeris: client secret (client_secret) is not specified
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: Aeris: forecast will not be run
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service user.forecast.AerisForecast
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service user.forecast.WWOForecast
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: WWO: forecast version 3.2.6
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: WWO: API key (api_key) is not specified
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: WWO: forecast will not be run
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service user.forecast.WWOForecast
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service user.forecast.XTideForecast
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: XTide: forecast version 3.2.6
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: XTide: location (location) has not been specified
Dec 28 00:05:02 weatherstation weewx[1647]: forecast: MainThread: XTide: forecast will not be run
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service user.forecast.XTideForecast
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service weewx.restx.StdStationRegistry
Dec 28 00:05:02 weatherstation weewx[1647]: restx: StationRegistry: Station will be registered.
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service weewx.restx.StdStationRegistry
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service weewx.restx.StdWunderground
Dec 28 00:05:02 weatherstation weewx[1647]: restx: Wunderground-PWS: Data for station IWESTSUM3 will be posted
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service weewx.restx.StdWunderground
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service weewx.restx.StdPWSweather
Dec 28 00:05:02 weatherstation weewx[1647]: restx: PWSWeather: Data for station CUBADAK will be posted
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service weewx.restx.StdPWSweather
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service weewx.restx.StdCWOP
Dec 28 00:05:02 weatherstation weewx[1647]: restx: CWOP: Posting not enabled.
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service weewx.restx.StdCWOP
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service weewx.restx.StdWOW
Dec 28 00:05:02 weatherstation weewx[1647]: restx: WOW: Posting not enabled.
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service weewx.restx.StdWOW
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service weewx.restx.StdAWEKAS
Dec 28 00:05:02 weatherstation weewx[1647]: restx: AWEKAS: Posting not enabled.
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service weewx.restx.StdAWEKAS
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service weewx.engine.StdPrint
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service weewx.engine.StdPrint
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Loading service weewx.engine.StdReport
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Finished loading service weewx.engine.StdReport
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Starting up weewx version 3.6.2
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Station does not support reading the time
Dec 28 00:05:02 weatherstation weewx[1647]: engine: Starting main packet loop.
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: read_record: cmdbuf: 02 02 04 04 (len=4)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: read_record: buf: 01 3b 04 4a 01 02 8e 02 02 93 03 02 6a 04 02 93 05 02 93 06 48 07 4e 08 27 7d 09 27 7d 0a 01 0e 0b 00 0a 0c 00 0d 0e 00 00 00 00 10 00 00 00 00 11 00 00 00 00 12 00 00 0f e4 13 00 00 (len=61)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: record_size: 74
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: read_record: buf: 01 12 18 75 14 00 00 18 75 15 00 00 08 12 16 00 00 17 00 2c 48 07 4e 08 27 7d 09 27 7d 0a 01 0e 0b 00 0a 0c 00 0d 0e 00 00 00 00 10 00 00 00 00 11 00 00 00 00 12 00 00 0f e4 13 00 00 (len=61)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: read_record: rbuf: 01 02 8e 02 02 93 03 02 6a 04 02 93 05 02 93 06 48 07 4e 08 27 7d 09 27 7d 0a 01 0e 0b 00 0a 0c 00 0d 0e 00 00 00 00 10 00 00 00 00 11 00 00 00 00 12 00 00 0f e4 13 00 00 18 75 14 00 00 18 75 15 00 00 08 12 16 00 00 17 00 (len=74) chksum=0x2c
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: raw data: [1, 2, 142, 2, 2, 147, 3, 2, 106, 4, 2, 147, 5, 2, 147, 6, 72, 7, 78, 8, 39, 125, 9, 39, 125, 10, 1, 14, 11, 0, 10, 12, 0, 13, 14, 0, 0, 0, 0, 16, 0, 0, 0, 0, 17, 0, 0, 0, 0, 18, 0, 0, 15, 228, 19, 0, 0, 24, 117, 20, 0, 0, 24, 117, 21, 0, 0, 8, 18, 22, 0, 0, 23, 0]
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: in_temp: {'value': 25.400000000000006} (0x01 0x01)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: out_temp: {'value': 25.900000000000006} (0x02 0x02)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: dewpoint: {'value': 21.799999999999997} (0x03 0x03)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: windchill: {'value': 25.900000000000006} (0x04 0x04)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: heatindex: {'value': 25.900000000000006} (0x05 0x05)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: in_humidity: {'value': 72} (0x06 0x06)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: out_humidity: {'value': 78} (0x07 0x07)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: abs_baro: {'value': 1010.9} (0x08 0x08)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: rel_baro: {'value': 1010.9} (0x09 0x09)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: wind_dir: {'value': 270} (0x0a 0x0a)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: wind_speed: {'value': 1.0} (0x0b 0x0b)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: gust_speed: {'value': 1.3} (0x0c 0x0c)
Dec 28 00:05:02 weatherstation weewx[1647]: wh23xx: rain_rate: {'value': 0.0} (0x0e 0x0e)

mwall

unread,
Dec 27, 2016, 8:26:32 PM12/27/16
to weewx-user
marc,

the problem is that pyusb/libusb should timeout when a write/read fails, but that is not happening.  but if the write/read is not failing, why are we suddenly not getting any logging?

this really smells like a hardware problem, or perhaps something with your system's logging configuration.

try the attached wh23xx-0.8p1.py

it does non-debug logging before and after every interrupt write to the usb.

m

wh23xx-0.8p1.py

Marc Aubry

unread,
Dec 27, 2016, 9:14:26 PM12/27/16
to weewx-user
hi 
do i have to rename it wh23xx.py in /usr/share/weewx/user 
or i just copy it like that.
i guess that i have to rename it :)

Marc Aubry

unread,
Dec 27, 2016, 9:51:46 PM12/27/16
to weewx-user
done.
i'm running a screen bash weewx session and monitor it until it stop.
thanks.

My config is pretty standard for rpi2.
i install a raspbian image from raspberry pi foundation website i install tight vnc server (not needed if i had done the jessie upgrade before) and then upgrade to the last jessie release. 
after that i just follow weewx doc and wiki to run a sofaskin on local webserver  in a ram disk to avoid overwriting on mys sd card and remote ftp server. external mysql (for the same reason) and forecast extension.
for the syslog i did try to syslog to my ubuntu linux server as describe in weewx wiki to save writing on the rpi sd card but came back to original syslog config because it was apparently still writing into the local syslog file in top of the remote syslog...
i had weewx stop reporting randomly from the beginning, before i did change the skin or forecast extension or sys log modification....
i did change the rpi2 board with the same model.
i will now setup a dev config with a rpi3 board and the simulator as weather station.
right now, i keep this config running like that just if it is useful for the community to help debugging the software if it's hardware related i don't see the point to maintain a buggy system and i'll keep it up running until i can validate my new rpi3 dev platform to switch it in prod platform.

Andrew Milner

unread,
Dec 27, 2016, 10:08:09 PM12/27/16
to weewx-user
This saga really does sound like what happened to me running wheezy on RPiB - just started doing random stoppages - usually locking me out of ssh at the same time renderingdebugging difficult that I switched to rpi3 and still - touch wood - not failed since.  I am sure raspberry/debian introduced a sw change of some kind that affected the older rpi's in some manner.  Hope you eventually get to the root cause of this.  As I now do not trust my old rpiB am not sure what to do with it - try it on another project or bin it.  It's been ticking away doing nothing now ever since I decomiisioned it without failing!!  If I was you I would try weewx on the rpi3 and simulator on the rpi2 rather than what you are proposing - even though that proposal is counter-intuitive and not good practice.

Marc Aubry

unread,
Dec 27, 2016, 11:26:08 PM12/27/16
to weewx-user
hi,
i have 3 rpi 2 B+ running 24h/7d without any issue.
one is for my Music player demon and client to listen and drive my mpd server on my linux ubuntu with home made python script (i call it radio cubadak).
one is use to drive my 3d printer with repetier server
and the last one is open elec ditrib to run a rasplex client to connect to a plex media server.
2 of RPI2 B work flawlessly with with jessie 8 upgrade and the rasplex client work flawlessly with the openelec img which i guess is a wheezy ( not sure about this one because it work so well that i never need to connect via ssh).
So i'm little bit skeptical about rpi2B+ hardware problem for my weewx weather station except for my wh2310 misol weather station.
the 3 raspberry running are using the network heavily for video and audio stream without any problem, weewx is only using the network for mysql writing/reading, ftp copy and web client, so i think network side is good too. 
The mysql database hosted on my ubuntu linux server work with other application without any problem, including my homemade arduino dust density sensor (which i would love to integrate in my weewx report in the future). The linux ubuntu machine in top of the mysql is hosting as well flawlessly my plex video server, my mpd music server and audio stream and my Xeoma cctv server.

i think i'm probably facing a python bug instead of hardware failure. not a weewx python script bug but more a python interpreter bug or python linked library.
just my guess....

today i have little time in front of me i will start a RPI3B dev config with weewx and simulator. i still want to keep my buggy weewx rpi2 config up for monitoring and reporting on my public weather station website even if i have to CRON reboot the rpi every hour to hide the problem.

Andrew Milner

unread,
Dec 27, 2016, 11:39:00 PM12/27/16
to weewx-user
My rpiB ran weewx flawlessly for 3 years 24/7 running the weather station and using lighttpd/MySQL to host the website until it suddenly started misbehaving.  Even now I do not know if it is faulty or not, since it has worked flawlessly since being decommissioned from production use!!!

Per Edström

unread,
Jan 1, 2017, 3:11:30 PM1/1/17
to weewx-user
My Weewx tend to stop for various reasons so I restart Weewx every hour by a cronjob:

# m h  dom mon dow   command
59 * * * * /etc/init.d/weewx stop
0 * * * * /etc/init.d/weewx start

Jarmo Seppänen

unread,
Jan 1, 2017, 3:23:17 PM1/1/17
to weewx-user
More intelligent solution than cron would be e.g. Monit. That is of course if you don't want to fix the root cause behind the crashes.

Thomas Keffer

unread,
Jan 1, 2017, 3:28:23 PM1/1/17
to weewx-user
Per,

Weewx should not crash. If it does, that's a bug, and we would very much like to hear about it. Post the logs!

Most installations run nonstop for months without any problems. 

-tk


--
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 weewx-user+unsubscribe@googlegroups.com.

Marc Aubry

unread,
Jan 6, 2017, 11:29:49 PM1/6/17
to weewx-user
Hi guys,
Little update about my situation after Christmas new year break.
Happy new year to all of you.
first of all to avoid to monitor constantly the weewx rpi during that busy period for us, i setup a CRON reboot every hour on the Rpi, it's just hiding the problem and doesn't help to find a solution but at least my weather station is reporting almost non stop with a maximum break of 1 hour.
in the same time i have setup a RPI 3 with the following config:
jessie 8 krnl 4.4.34-v7+
weewx 3.6.2
sofaskin1.1
forecast 3.2.9
Weather station simulator driver
external mysql archive and forecast database
external ftp server with ftp skin
The rpi is connected to the LAN via ethernet wire (wifi has been disabled)
The ftp server is a iis webserver hosted on my local network, the archive and forecast database are hosted on the same linux server as the faulty weewx config.
i did not setup remote syslog or ramdisk for the local rpi webserver.
the config is running with the simulator without any issue for few day.
It is now time to connect this config with the USB WH23XX driver.
I will as well change the database target with the previous one to continue on the same database to avoid the long 3 years cumulus import file process.
if everything run smoothly (which i hope) then i will activate report to WU and the FTP target to my internet server in the weewx.conf file.
I keep you updated.

 

 






On Monday, January 2, 2017 at 3:28:23 AM UTC+7, Tom Keffer wrote:
Per,

Weewx should not crash. If it does, that's a bug, and we would very much like to hear about it. Post the logs!

Most installations run nonstop for months without any problems. 

-tk

On Sun, Jan 1, 2017 at 12:11 PM, Per Edström <peredst...@gmail.com> wrote:
My Weewx tend to stop for various reasons so I restart Weewx every hour by a cronjob:

# m h  dom mon dow   command
59 * * * * /etc/init.d/weewx stop
0 * * * * /etc/init.d/weewx start

--
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 weewx-user+...@googlegroups.com.

Andrew Milner

unread,
Jan 6, 2017, 11:41:15 PM1/6/17
to weewx-user
Pity you are not starting off with a standard installation first and then added
sofaskin
networked external archive database
forecast
networked external forecast database
one by one to have made it easier to locate/identify what, if anything, is/was causing your problems!!

Best of luck though - hope it all works out just fine- just try and change one thing at a time though as it really does make problem identification so much easier ....

Marc Aubry

unread,
Jan 7, 2017, 7:48:04 PM1/7/17
to weewx-user
I agree but but i have one weather station only, unfortunately i don't have one for dev only and my crashy config connected to the weather station is still in prod because this config replace a dead WRM200 running on cumulus since 2014 and data must still flow :)
But if the new config is good now with the simulator and start to crash or stop with the WH2310 connected there is a big chance that there is a problem between the driver and the station.

Marc Aubry

unread,
Jan 7, 2017, 7:52:54 PM1/7/17
to weewx-user
I did change one thing at a time with 24h test on the new config starting with basic config with the simulator to the full config. that's a long and tedious process that took me almost a week. That's partially why i can't stop my actual config to report in the database and on internet.
Next time i will buy directly two weather station one as dev and one as prod. This misol WH2310 are cheap enough 

Marc Aubry

unread,
Jan 13, 2017, 8:27:31 PM1/13/17
to weewx-user
Hi,
Some update about my problem,
During the last week i have setup a rpi3 raspbian jessie 8
I did use the simulator and i did take minimum 24 hours time between each config modifications to insure that the new modification was not crashing the config
this config was running flawlessly for one week.
the config was:
weewx 3.6.2
simulator
forecast 3.2.9
sofaskin
mysql LAN deported database
The rpi3 is wired connected to my lan via ethernet cable. 
Because the config was working flawlessly for a week i then plug the usb cable of the weather station and install the last WH23xx driver.
yesterday everything went fine until 20:55. at that time the weewx stop reporting.
When weewx stop reporting i can still see it with ps- aux | grep weewx.
if i restart weewx with sudo service weewx restart, the station resume the reporting.

maybe i'm wrong here but i suspect a WH23XX driver problem in between weewx and my weather station.

Please find attached syslog file, weewx_debug file, skin.conf file.

please help
syslog.zip
skin.conf
weewx.debug

Per Edström

unread,
Jan 15, 2017, 8:58:57 AM1/15/17
to weewx-user
Apparently my USB-to-COM-port converter is not stable hence causing weewx to stop (when the device changes). SO  I made a link to the current device for use in weewx.conf (details in a new thread here in the forum).
It seems to work for now..

Marc Aubry

unread,
Jan 15, 2017, 9:48:58 PM1/15/17
to weewx-user
Hi,
Thanks for this info 
i have listed the usb devices with lsusb
Bus 001 Device 004: ID 10c4:8468 Cygnal Integrated Products, Inc.
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. SMSC9512/9514 Fast Ethernet Adapter
Bus 001 Device 002: ID 0424:9514 Standard Microsystems Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
I guess that my weather station is  Device 004: ID 10c4:8468 
I will wait the next time the weewx stop reporting to check if the device number has changed.
I check in my weewx.conf file and i have no such thing as "device link" i just have the following lines referring to the driver i'm using:
[WH23xx]
    # This section is for Fine Offset WH23xx stations
    # The model name such as Tycon, or TP2700
    model = WH2310
    # The driver to use
    driver = user.wh23xx

Do i have to add the following "port = /dev/mydevice" in the weewx.conf file?

thanks for your help

Marc Aubry

unread,
Jan 16, 2017, 6:08:37 AM1/16/17
to weewx-user
Hi 
The weewx has just stop reporting and i did a lsusb command and it look the same then before it stop reporting.
so it is not a problem of usb port changing name or order.

Bus 001 Device 004: ID 10c4:8468 Cygnal Integrated Products, Inc.
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. SMSC9512/9514 Fast Ethernet Adapter
Bus 001 Device 002: ID 0424:9514 Standard Microsystems Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Andrew Milner

unread,
Jan 16, 2017, 6:34:02 AM1/16/17
to weewx-user
Does this help - altering syslogd config file :

----------------------------

As to your problem with rsyslog error messages flooding your logs, I've been trying to fix this on my Pi today.
One possible fix I found on an internet search, is to comment out the lines in the /etc/rsyslog.conf file that pipe
anything to /dev/xconsole. If /dev/xconsole does not take the data, the pipe fills up, and this causes the rsyslog
error message, then rsyslog tries to do the same thing again and again.

I commented out the last 4 lines of my /etc/rsyslog.conf file like this:
Code: Select all
#daemon.*;mail.*;\
#       news.err;\
#       *.=debug;*.=info;\
#       *.=notice;*.=warn       |/dev/xconsole

----------------------------


since weewx seemed to go quiet when the only thing going to the log were these 'error'messages from syslog.


Just an idea - namely that a full pipe is blocking weewx execution .

Andrew Milner

unread,
Jan 16, 2017, 6:37:29 AM1/16/17
to weewx-user
PS - in case you are unaware there are errors in the log connected to the forecast module and forecast page ..... don't think they are a direct cause of your problem though.



On Monday, 16 January 2017 13:08:37 UTC+2, Marc Aubry wrote:

mwall

unread,
Jan 16, 2017, 7:50:05 AM1/16/17
to weewx-user
On Sunday, January 15, 2017 at 9:48:58 PM UTC-5, Marc Aubry wrote:
Do i have to add the following "port = /dev/mydevice" in the weewx.conf file?


no.  you are using the wh23xx driver, which is for fine offset hardware including WH2310 and tycon TP2300 (among others).  this hardware is pure usb - you do not have to specify a port.

the ws23xx driver is for lacrosse WS2317 (and other) hardware that has a serial interface and requires the use of a usb-to-serial converter on computers with no serial port.

m

mwall

unread,
Jan 16, 2017, 7:52:45 AM1/16/17
to weewx-user
On Monday, January 16, 2017 at 6:08:37 AM UTC-5, Marc Aubry wrote:
Hi 
The weewx has just stop reporting and i did a lsusb command and it look the same then before it stop reporting.
so it is not a problem of usb port changing name or order.

please post the log, and please post the latest output from the terminal in which you started weewx.

m

Andrew Milner

unread,
Jan 16, 2017, 9:28:48 AM1/16/17
to weewx-user
Matthew - there was a log posted on 14 Jan of the problem - from which I derived the two comments I posted above. Andrew

Marc Aubry

unread,
Jan 16, 2017, 10:26:20 PM1/16/17
to weewx-user
Hi andrew
are your referring to this forecast error?
Jan 16 22:40:27 weatherstation weewx[645]: forecast: OWMThread: OWM: forecast failure: global name 'periods' is not defined
Jan 16 22:40:27 weatherstation weewx[645]:   File "/home/weewx/bin/user/forecas .py", line 1173, in do_forecast
I do not know where it' is coming from...
My forecast install is standard as described in the forecast instrucrion.

Marc Aubry

unread,
Jan 16, 2017, 10:29:06 PM1/16/17
to weewx-user
Hi .
Log already posted on this thread (more than once)
I'm now running weewx as service, but i will change it to run in console mode and will post the output terminal
thanks

Andrew Milner

unread,
Jan 16, 2017, 10:38:36 PM1/16/17
to weewx-user
Yes, that's what I was referring to .....

Have you tried amending the syslog.conf as I suggested in previous posting to see if that is causing your weewx to freeze?

mwall

unread,
Jan 16, 2017, 10:49:38 PM1/16/17
to weewx-user


On Monday, January 16, 2017 at 10:26:20 PM UTC-5, Marc Aubry wrote:
Hi andrew
are your referring to this forecast error?
Jan 16 22:40:27 weatherstation weewx[645]: forecast: OWMThread: OWM: forecast failure: global name 'periods' is not defined
Jan 16 22:40:27 weatherstation weewx[645]:   File "/home/weewx/bin/user/forecas .py", line 1173, in do_forecast
I do not know where it' is coming from...

well, that is embarrassing!  there is a typo in forecast.py.  at line 2642, change this:

                if 'clouds' in period and 'all' in periods['clouds']:

to this:

                if 'clouds' in period and 'all' in period['clouds']:

fixed in forecast 3.2.10

m

Marc Aubry

unread,
Jan 16, 2017, 11:33:46 PM1/16/17
to weewx-user
Yes i did.
Wait and see
So far so good
thanks

Marc Aubry

unread,
Jan 16, 2017, 11:37:30 PM1/16/17
to weewx-user
Modification done...
Thanks

mwall

unread,
Jan 16, 2017, 11:41:26 PM1/16/17
to weewx-user


On Friday, January 13, 2017 at 8:27:31 PM UTC-5, Marc Aubry wrote:
maybe i'm wrong here but i suspect a WH23XX driver problem in between weewx and my weather station.

Please find attached syslog file, weewx_debug file, skin.conf file.


from the attached syslog.1 we see:

- you have temporal chaos and an unorderly network startup.  the pi starts up with the wrong time.  weewx starts and attempts to connect to a mysql database, but the network is not up yet, so weewx sleeps for 2 minutes.  meanwhile the system continues to boot up.  eventually the network comes up and the clock is reset by ntp.

- at Jan 13 17:53:26 weewx[672] makes a log entry about decoded data.  the next log entry is Jan 13 17:17:04 by syslog, followed by what appears to be a boot sequence.  what caused the reboot?  why are there no more messages in the log?  (an orderly shutdown should have resulted in some log messages, no?)

- at Jan 13 17:17:04 weewx[645] makes its first log entry.  at Jan 13 17:17:05 the weewx[645] process attempts to connect to the mysql database and fails, so it sleeps for 2 minutes.

- at Jan 13 17:17:19 the clock jumps to Jan 13 17:54:15

- at Jan 13 20:50:51 the process weewx[645] reports 'rsync upload not requested'.  the next log entry is Jan 13 21:17:01, followed by a bunch of rsyslogd-2007 and CRON messages at what appear to be one hour intervals.

- at Jan 14 06:25:07 rsyslogd was HUPed (that and the apache message before it are probably due to logrotate doing its thing)

none of that tells us anything.  it kind of looks like there is a hardware problem.  in the case of the 645 process, the reporting continued for a little while (it is a separate thread), but then it stopped reporting too.  so nothing in the log directly indicates that there is a problem in the driver.

what is causing the system reboots?  if you are causing the system to reboot, how are you doing it?

how is the wh2310 connected to the pi?

what else is connected to the pi?  what else is running on the pi?

if you want to figure out if the driver is the problem, then you need to run weewx with only the driver and with no other services.  that means local database, not mysql.  that means no other skins or reports other than the standard skin - no forecast.

based on our experience with those other parts, they are probably not the problem.  but anything other than the problem confounds your ability to find the problem.

m

Andrew Milner

unread,
Jan 17, 2017, 12:04:46 AM1/17/17
to weewx-user
Marc - if it freezes again you should post a new log - especially since you have now made changes to both the forecast module (which should eliminate forecast related error messages) and also to syslog.conf (which hopefully removes even more logged messages).  We don't want to be looking at the wrong log for the current situation!!

Marc Aubry

unread,
Jan 17, 2017, 2:23:56 AM1/17/17
to weewx-user
Hi,
The reboot is due to the genset change every 12 hours (shift day night, i'm living off grid) and the rpi3 is not connected to an UPS, as  well for the router on which the rpi is connected on. the rpi boot probably faster than my router. So it is not exactly a reboot but a power shut down.

For the rsync error, i did not setup anything in weewx conf, because i'm not using rsync. i leave it by default.i'm just using ftp skin for normal ftp generator.
The weather station is connected to the pi via USB

Nothing else is connected to the pi. it is running in headless mode (no keyboard no monitor) i access to the pi via ssh or vnc. this pi is dedicated to weewx.
About hardware problem, if you look above on this thread you will notice that i have had the exact same problem on rpi2 with the same config and i did change it to rpi3  to validate the hardware. it is a fresh install from scratch by following the instructions in the weewx doc or forecast doc or the sofaskin doc. 
I did run the config with weewx, forecast and sofaskin with the simulator for a week flawlessly (while my buggy rpi2 config connected to the weaher station was still reporting with CRON scheduled reboot every hour to hide the problem). The weewx stop reportin only after i have connected the WH23xx driver to the weather station. I choose this approach because my online weather station website is a part of my cross referencing SEO strategy and is running since 2014 (with cumulus) and i prefer not to stop this flow of data to the web. 

I will try to connect the RPI to an UPS but i will need some work to bring the UPS cable to it...

About hard power shut down of the RPI, i know that it is not recommended and that i risk SD card problem but i have a fresh image backup of every config,  i have 3 other RPI working the same way without any problem.
one with Rasplex Open elec config for my plex media player working since more than a year without problem
one with repetier server for my 3d printer
one with home made radio player (in python) to stream the music from my mpd server.

I hope this can help to diagnose the problem
thanks for your help.

Marc Aubry

unread,
Jan 17, 2017, 2:24:24 AM1/17/17
to weewx-user
i will for sure :)

Marc Aubry

unread,
Jan 17, 2017, 3:18:08 AM1/17/17
to weewx-user
Hi,
Just stop reporting 12:15 local time
please find attached syslog.
there is a new interesting message in the syslog 
weatherstation weewx[1508]: wh23xx: get_current: could not detach kernel driver from interface 0: No data available

i was running weewx directly on the console with weewxd
the console was showing:
4630124, dewpoint: 18.1644912704, heatindex: 31.7465325172, humidex: 36.9270806694, inDewpoint: 61.3511118401, inHumidity: 44, inTemp: 29.9, luminosity: 163463.4, maxSolarRad: 1049.29595861, outHumidity: 47, outTemp: 30.8, pressure: 1010.7, radiation: 1291.36086, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 11, uv_raw: 4707, windchill: 30.8, windDir: 180, windGust: 2.52000626344, windSpeed: 1.08000268433
REC:    2017-01-17 12:15:00 WIB (1484630100) altimeter: 1011.05970952, appTemp: 32.2804131054, barometer: 1011.32893478, cloudbase: 1566.52849627, dateTime: 1484630100.0, dewpoint: 17.9667744592, ET: 0.00931318400731, heatindex: 31.3295548186, humidex: 36.4708326323, inDewpoint: 62.1629006698, inHumidity: 45.1, inTemp: 29.97, interval: 5, luminosity: 157830.85, maxSolarRad: 1048.23640656, outHumidity: 47.25, outTemp: 30.49, pressure: 1010.76, radiation: 1246.863715, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 11.0, uv_raw: 4707.0, windchill: 30.49, windDir: 185.798196225, windGust: 12.960064424, windGustDir: None, windrun: 15.3518033795, windSpeed: 5.09402532221
LOOP:   2017-01-17 12:15:24 WIB (1484630124) altimeter: 1010.99968069, appTemp: 33.4553572395, barometer: 1011.26832054, cloudbase: 1580.52915436, dateTime: 1484630124, dewpoint: 18.1644912704, heatindex: 31.7465325172, humidex: 36.9270806694, inDewpoint: 61.3511118401, inHumidity: 44, inTemp: 29.9, luminosity: 163463.4, maxSolarRad: 1049.29595861, outHumidity: 47, outTemp: 30.8, pressure: 1010.7, radiation: 1291.36086, rain: 0.0, rainRate: 0.0, usUnits: 16, UV: 11, uv_raw: 4707, windchill: 30.8, windDir: 180, windGust: 2.52000626344, windSpeed: 1.08000268433

I hope it will help....
syslog.zip

Andrew Milner

unread,
Jan 17, 2017, 4:57:14 AM1/17/17
to weewx-user
Are you certain you applied the changes?

The log still shows the error Matthew corrected occurred just around the time it stopped reporting
and
The log started to give the error that should have been cleared by my change.

However - the I/O error you got from the USB does imply a USB error situation is lurking somewhere

Since you appear to be running with network, USB radio and other possible USB devices - are you using the official WHITE 5.1V 2.5A RPi3 power supply??  The RPi is very finicky when it comes to power supplies and power spikes etc - especially where network and USB power is concerned.  I always use a powered USB hub for usb devices.  As you are running off a generator could this be a cause of issues?  The other Pis you have running do not appear to be working as hard as your weather station one will be.

Matthew did suggest disabling the foprecasting whilst trying to resolve your problems - but I see you still have forecasting enabled.

Running wioth the simulator would not be exercising the RPi in the same way as running with the station, and like Matthew I would be more suspicious of the RPi and the environment than weewx and the driver.  Keep all usb cables well away from the RPi, power supplies, screens etc.

Marc Aubry

unread,
Jan 17, 2017, 6:09:02 AM1/17/17
to weewx-user
Hi
there is only the weatherstation running on the rpi usb.
The other system you are referring are running on other rpi.
this one is dedicated to weewx only. there is no other usb device connected on it. , no keyboard, no screen, simple headless rpi without any other software installed on it except for the one installed by default by raspbian plus screen and vncserver.
the power supply is a branded 3A USB power supply and i did try with other power supply.
i did change the file /home/weewx/user/forrecat.py nd the /etc/
i did change the /etc/rsyslog.conf as suggested

Marc Aubry

unread,
Jan 17, 2017, 6:24:17 AM1/17/17
to weewx-user
Maybe i did forgot to restart weewx after the modifications. i will keep you inform if other crashes happen because i have rebooted the rpi since.
About the quality of the power provided by the genset it can be the issue, but i'm running on 2 set of generators both of them over rated for my use (yanmar 26KW 3 phases) one is older than the other and probably a little bit more dirty but the problem appear what ever generator is running, Tomorrow i'll try to connect the RPI to an UPS.

I'll try to deactivate forecast even if i'm not sure how to do it and even if the config was working fine with forecast on the simulator.
I'll try to measure the power consumption of this config but with just the power station and an ethernet cable connected on it it should be fare below the raspberry requirement.

This problem start to drive me mad....
Thanks for your help.

Andrew Milner

unread,
Jan 17, 2017, 6:28:57 AM1/17/17
to weewx-user
Raspberry changed to a 5.1v from 5v supply for the rpi3, and the network and usb radio for the weatherstation probably use more than keyboard/mouse anyway!!

Did you check forecast to see if there was another occurrence of the error Matthew found?  The error message in the log is the same variable!!

have you tried the usb radio interface on a hub away from the pi rather than on the pi itself - just to see if it makes any difference??

Marc Aubry

unread,
Jan 17, 2017, 6:45:26 AM1/17/17
to weewx-user
This weather station is not powered by the usb but by it's own 5V power supply(or by internal nimh rechargeable battery) and it draw a little bit less than 200ma if i don't mistake.
i just check the syslog and the forecast error does not appear. so maybe i forgot to restart weewx after the modif.
sorry about that.
for now the system is running since last reboot and i wont change the genrator tonight to check if it has any influence.

thanks for your help.

Andrew Milner

unread,
Jan 17, 2017, 7:56:17 AM1/17/17
to weewx-user
Marc - I do not know the ins and outs or reasons why - but I do know that the current Raspberry power supplies are 5.1v supply and not the 5v supply they were previously.  I can only assume that there is some reason behind this change - especially since power has long been an issue with the RPi and the cause of many oddball effects..... both here with weewx and weather stations and on other installations if the forums are to be believed.  Your UPS may possibly be of no help in this regard !!!

Let's see what happens now though following your reboot!!

Marc Aubry

unread,
Jan 17, 2017, 12:10:59 PM1/17/17
to weewx-user
Remember that i have the exact same problem with a rpi2 instead of the rpi3. So i don't really belive in power issue or rpi hardware problem. The only piece of harware which is the same between the 2 config having the same problem is the weather station itself. So if it is hardware it should come from the weather station or from the power line as mentioned earlier.
Anyway so far so good. The weewx is still reporting since 8 hours.

Andrew Milner

unread,
Jan 17, 2017, 12:20:09 PM1/17/17
to weewx-user
..... or the cables .... or the physical location .... or the proximity of other cables and devices (since I bet the rpi3 is in the same physical space as the failed rpi2 and using the same physical cables to connect to the weather station routed in the same manner around your premises) ......

Still - let's see when it fails ..... and what the log says at that time .....

Marc Aubry

unread,
Jan 17, 2017, 9:33:28 PM1/17/17
to weewx-user
Hi andrew
Please find attached the syslog of the last problem. Last report time 03:55
it is not enough anymore to do sudo service weewx restart. i still have the message 
"weatherstation weewx[671]: wh23xx: get_current: could not detach kernel driver from interface 0: No data availabl"
I must reboot the rpi to get rid of it and have weewx resuming it's operation.
i have change the power supply, the usb cable connected to the station, the ethernet cable and even change the position of the cable on my ethernet hub.
the generator have not been changed last night and i'm running on the newest (cleanest) one.
if we don't find any solution for this problem, i will probably make bash or python script to check when was the last time the weewx wrote to the mysql database and if it doesn't for more than 15 minutes then trigger a reboot of the rpi.
It's is not a clean solution but it should work.
I would prefer to find a cleanest way to do it.
 
Thanks again for your help.
syslog.zip

Andrew Milner

unread,
Jan 17, 2017, 11:03:50 PM1/17/17
to weewx-user
I'm going to have to leave this to Matthew I'm afraid.  You definitely appear to have a communication issue with the weather station (READ failure) which occurs at 03:58 approximately, and there are several restarts of weewx which are automatically attempted by weewx.  As to the cause of the initial read failure and as to whether or not weewx and the driver have taken the correct expected actions as a result I am afraid Matthew's knowledge is required.  Looks somewhat similar to the classic fousb lockup issue where the usb just refuses to communicate and the only way out is a station reset in that instance.  Maybe an automatic reboot will be the only way out of your particular problem - but only Matthew can say!!


Sorry I cannot be more helpful.

mwall

unread,
Jan 17, 2017, 11:53:17 PM1/17/17
to weewx-user
marc,

the old fine offset stations are very sensitive to usb voltage, whether or not the station is powered by the usb.  perhaps the wh23xx consoles are sensitive as well.  in my short (1 year) experience with the wh23xx hardware, i find it to be considerably more robust than the 1080/2080 fine offset consoles.  the only time i have seen the wh23xx lock up is when i was doing nasty things to it over usb - never when it was just running along normally.

my guess is that you have dirty power.

most important: put the weather station, usb hub, and pi on a ups.

if you still have failures, then check the hardware (always running on a ups):

try connecting the station directly to the pi instead of via a hub.

try using a different usb hub.

try using the weather station with some other computer (not a pi).

m

Marc Aubry

unread,
Jan 18, 2017, 1:47:54 AM1/18/17
to weewx-user
Hi,
Thanks to both of you matthew and andrew for your help.
i agree with you about a problem of usb communication between the weather station and the rpi due to whatever unknown yet factor (probably dirty power?)
I'll try the following in order to track this problem:

1st. i will connect both the rpi and weather station to an ups
2nd (if problem remain) i'll connect a powered usb hub in between the rpi and the weather station even if using a 4 ports usb powered hub to connect only one low power usb device is little bit over rated.
3rd if problem still remain i will do an automatic reboot if the weewx doesn't store anything in the mysql database for more than 15 minute (3 data acquisition cycle) either by a bash script or a python script (not sure yet)

Unfortunately i do not have any linux computer near by the weather station console to setup weewx on a different platform. my linux server is located in an other building to fare away from the weather station sensor to have enough radio signal for the weather station console

About my experience with UPS. when connecting on the power line UPS does not really clean the power and when working off line have a tendency to add more noise than the powered line. I experienced that as musician doing audio recording in dirty environment. it's depend of course of the quality of the UPS but i'm using a rpi3 and a cheap weather station to keep the cost of the installation low it will not make any sens to have an expensive UPS on this setup.  

Thanks again for all the help you already have provided

Marc

Marc Aubry

unread,
Jan 25, 2017, 8:24:21 PM1/25/17
to weewx-user
Some updates about my problem.
I have try all the options mentioned above
- UPS
-Powered USB Hub
- change the power supply of the RPI and the weather station
but the problem was not solved and the the weewx was still randomly reporting.
I suspect a problem link to the weather station itselv and the USB communication with the RPI and weewx.

I gave up the diagnostic and i have now CRON scheduled a hourly reboot to hide the problem.
Thanks to all of  you for your support.

mwall

unread,
Jan 25, 2017, 10:06:40 PM1/25/17
to weewx-user
On Wednesday, January 25, 2017 at 8:24:21 PM UTC-5, Marc Aubry wrote:
Some updates about my problem.
I have try all the options mentioned above
- UPS
-Powered USB Hub
- change the power supply of the RPI and the weather station
but the problem was not solved and the the weewx was still randomly reporting.
I suspect a problem link to the weather station itselv and the USB communication with the RPI and weewx.

I gave up the diagnostic and i have now CRON scheduled a hourly reboot to hide the problem.

marc,

i just released v0.13rc1 of the weewx-wh23xx driver.  please give it a try.

it now verifies checksums on the data it reads, and it does local retries on the usb before raising exceptions that cause the weewx engine to reload everything.

none of this directly addresses the issues you were having, but the driver is definitely more robust now, so who knows?

m

Marc Aubry

unread,
Jan 29, 2017, 9:15:34 PM1/29/17
to weewx-user
Thanks,
Done...
Wait and see :)

Marc Aubry

unread,
Mar 6, 2017, 8:58:10 PM3/6/17
to weewx-user
Some updates about my weewx stopping reporting:
My linux server where i was running mysql server has\d badly crashed and is now verydead (hard disk and power supply failure).
For now i don't want to setup a new one and try to run all my previous linux services on multiple pi setup.
So i change the config of my weewx weather station to use the internal sqlite database.
and so fare since, the weewx work perfectly without any crash.

So the problem was not coming from the Wh23xx driver but from the external mysql bond.

To validate that, I still have to import all my previous cumulus data into sqlite to have a full working config.

Bostjan Potocnik

unread,
Jun 8, 2018, 8:32:43 AM6/8/18
to weewx-user
Hii

I have the same issue, I have the station WH-4000, raspberry pi 2, running weewx3.8.0. And I get this when it stops (weewx run manualy and this is what I get after Crtl+C):


LOOP:   2018-06-08 10:44:31 CEST (1528447471) altimeter: 30.0416142372, appTemp: 76.2960146314, barometer: 30.0199806062, cloudbase: 3186.62988576, dateTime: 1528447471, dewpoint: 62.7739052422, heatindex: 72.32, humidex: 81.9580545745, inDewpoint: 58.4093574867, inHumidity: 71, inTemp: 68.18, luminosity: 39342.0, maxSolarRad: 823.186025365, outHumidity: 72, outTemp: 72.32, pressure: 28.96301174, radiation: 310.8018, rain: 0.0, rainRate: 0, usUnits: 1, UV: 4, uv_raw: 1400, windchill: 72.32, windDir: 180, windGust: 1.56585929636, windSpeed: 0.671082555582
LOOP:   2018-06-08 10:44:47 CEST (1528447487) altimeter: 30.0416142372, appTemp: 76.2960146314, barometer: 30.0199806062, cloudbase: 3186.62988576, dateTime: 1528447487, dewpoint: 62.7739052422, heatindex: 72.32, humidex: 81.9580545745, inDewpoint: 58.4093574867, inHumidity: 71, inTemp: 68.18, luminosity: 42493.8, maxSolarRad: 823.720735542, outHumidity: 72, outTemp: 72.32, pressure: 28.96301174, radiation: 335.70102, rain: 0.0, rainRate: 0, usUnits: 1, UV: 4, uv_raw: 1400, windchill: 72.32, windDir: 180, windGust: 1.56585929636, windSpeed: 0.671082555582
LOOP:   2018-06-08 10:45:04 CEST (1528447504) altimeter: 30.0446567236, appTemp: 76.2960146314, barometer: 30.0230413709, cloudbase: 3186.62988576, dateTime: 1528447504, dewpoint: 62.7739052422, heatindex: 72.32, humidex: 81.9580545745, inDewpoint: 58.4093574867, inHumidity: 71, inTemp: 68.18, luminosity: 42493.8, maxSolarRad: 824.287836118, outHumidity: 72, outTemp: 72.32, pressure: 28.9659647387, radiation: 335.70102, rain: 0.0, rainRate: 0, usUnits: 1, UV: 4, uv_raw: 1400, windchill: 72.32, windDir: 180, windGust: 1.56585929636, windSpeed: 0.671082555582
^CTraceback (most recent call last):
  File "/usr/bin/weewxd", line 64, in <module>
    weewx.engine.main(options, args)
  File "/usr/share/weewx/weewx/
engine.py", line 871, in main
    engine.run()
  File "/usr/share/weewx/weewx/engine.py", line 187, in run
    for packet in self.console.genLoopPackets():
  File "/usr/share/weewx/user/wh23xx.py", line 417, in genLoopPackets
    raw = self._get_current()
  File "/usr/share/weewx/user/wh23xx.py", line 437, in _get_current
    return self._station.get_current()
KeyboardInterrupt


Andrew Milner

unread,
Jun 8, 2018, 8:56:48 AM6/8/18
to weewx-user
what is in the log for when it 'stops' ??

Bostjan Potocnik

unread,
Jun 8, 2018, 10:10:55 AM6/8/18
to weewx-user
HI,


actually not much, weewx just stops (below restarted just after 13:51):



pi@RPi2-weewx:~ $ more /var/log/syslog
...
Jun  8 10:35:26 RPi2-weewx weewx[7911]: manager: Added record 2018-06-08 10:35:00 CEST (1528446900) to database 'weewx.sdb'
Jun  8 10:35:26 RPi2-weewx weewx[7911]: manager: Added record 2018-06-08 10:35:00 CEST (1528446900) to daily summary in 'weewx.sdb'
Jun  8 10:35:27 RPi2-weewx weewx[7911]: historygenerator.pyc: Generated 8 tables in 0.37 seconds
Jun  8 10:35:27 RPi2-weewx weewx[7911]: restx: Wunderground-PWS: Published record 2018-06-08 10:35:00 CEST (1528446900)
Jun  8 10:35:31 RPi2-weewx weewx[7911]: cheetahgenerator: Generated 9 files for report StandardReport in 4.50 seconds
Jun  8 10:35:34 RPi2-weewx weewx[7911]: imagegenerator: Generated 12 images for StandardReport in 3.46 seconds
Jun  8 10:35:34 RPi2-weewx weewx[7911]: copygenerator: copied 0 files to /var/www/html/weewx
Jun  8 10:35:35 RPi2-weewx weewx[7911]: historygenerator.pyc: Generated 8 tables in 0.35 seconds
Jun  8 10:35:39 RPi2-weewx weewx[7911]: cheetahgenerator: Generated 10 files for report StandardReport-SI in 4.28 seconds
Jun  8 10:35:42 RPi2-weewx weewx[7911]: imagegenerator: Generated 12 images for StandardReport-SI in 3.69 seconds
Jun  8 10:35:42 RPi2-weewx weewx[7911]: copygenerator: copied 0 files to /var/www/html/vreme
Jun  8 10:39:02 RPi2-weewx CRON[11544]: (root) CMD (  [ -x /usr/lib/php5/sessionclean ] && /usr/lib/php5/sessionclean)
Jun  8 10:40:23 RPi2-weewx weewx[7911]: manager: Added record 2018-06-08 10:40:00 CEST (1528447200) to database 'weewx.sdb'
Jun  8 10:40:23 RPi2-weewx weewx[7911]: manager: Added record 2018-06-08 10:40:00 CEST (1528447200) to daily summary in 'weewx.sdb'
Jun  8 10:40:24 RPi2-weewx weewx[7911]: restx: Wunderground-PWS: Published record 2018-06-08 10:40:00 CEST (1528447200)
Jun  8 10:40:24 RPi2-weewx weewx[7911]: historygenerator.pyc: Generated 8 tables in 0.37 seconds
Jun  8 10:40:28 RPi2-weewx weewx[7911]: cheetahgenerator: Generated 9 files for report StandardReport in 4.52 seconds
Jun  8 10:40:31 RPi2-weewx weewx[7911]: imagegenerator: Generated 12 images for StandardReport in 3.49 seconds
Jun  8 10:40:31 RPi2-weewx weewx[7911]: copygenerator: copied 0 files to /var/www/html/weewx
Jun  8 10:40:32 RPi2-weewx weewx[7911]: historygenerator.pyc: Generated 8 tables in 0.37 seconds
Jun  8 10:40:36 RPi2-weewx weewx[7911]: cheetahgenerator: Generated 10 files for report StandardReport-SI in 4.41 seconds
Jun  8 10:40:39 RPi2-weewx weewx[7911]: imagegenerator: Generated 12 images for StandardReport-SI in 3.48 seconds
Jun  8 10:40:39 RPi2-weewx weewx[7911]: copygenerator: copied 0 files to /var/www/html/vreme
Jun  8 11:09:01 RPi2-weewx CRON[11599]: (root) CMD (  [ -x /usr/lib/php5/sessionclean ] && /usr/lib/php5/sessionclean)
Jun  8 11:17:01 RPi2-weewx CRON[11647]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jun  8 11:39:01 RPi2-weewx CRON[11667]: (root) CMD (  [ -x /usr/lib/php5/sessionclean ] && /usr/lib/php5/sessionclean)
Jun  8 12:09:01 RPi2-weewx CRON[11720]: (root) CMD (  [ -x /usr/lib/php5/sessionclean ] && /usr/lib/php5/sessionclean)
Jun  8 12:17:01 RPi2-weewx CRON[11767]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jun  8 12:39:01 RPi2-weewx CRON[11792]: (root) CMD (  [ -x /usr/lib/php5/sessionclean ] && /usr/lib/php5/sessionclean)
Jun  8 13:09:01 RPi2-weewx CRON[11847]: (root) CMD (  [ -x /usr/lib/php5/sessionclean ] && /usr/lib/php5/sessionclean)
Jun  8 13:17:01 RPi2-weewx CRON[11895]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jun  8 13:39:01 RPi2-weewx CRON[11921]: (root) CMD (  [ -x /usr/lib/php5/sessionclean ] && /usr/lib/php5/sessionclean)
Jun  8 13:44:33 RPi2-weewx systemd[1]: Starting Cleanup of Temporary Directories...
Jun  8 13:44:33 RPi2-weewx systemd[1]: Started Cleanup of Temporary Directories.
Jun  8 13:50:47 RPi2-weewx weewx[7911]: engine: Shutting down StdReport thread
Jun  8 13:50:47 RPi2-weewx weewx[7911]: engine: Keyboard interrupt.
Jun  8 13:51:11 RPi2-weewx weewx[11998]: engine: Initializing weewx version 3.8.0
Jun  8 13:51:11 RPi2-weewx weewx[11998]: engine: Using Python 2.7.9 (default, Sep 17 2016, 20:26:04) #012[GCC 4.9.2]
Jun  8 13:51:11 RPi2-weewx weewx[11998]: engine: Platform Linux-4.9.35-v7+-armv7l-with-debian-8.0
Jun  8 13:51:11 RPi2-weewx weewx[11998]: engine: Locale is 'sl_SI.utf8'
Jun  8 13:51:11 RPi2-weewx weewx[11998]: engine: Using configuration file /etc/weewx/weewx.conf
Jun  8 13:51:11 RPi2-weewx weewx[11998]: engine: Loading station type WH23xx (user.wh23xx)
Jun  8 13:51:11 RPi2-weewx weewx[11998]: wh23xx: driver version is 0.14
Jun  8 13:51:11 RPi2-weewx weewx[11998]: wh23xx: usb info: pyusb_version=0.4.x
Jun  8 13:51:11 RPi2-weewx weewx[11998]: wh23xx: poll interval is 15
Jun  8 13:51:11 RPi2-weewx weewx[11998]: wh23xx: Found device on USB bus=001 device=004
Jun  8 13:51:11 RPi2-weewx kernel: [260569.781805] usb 1-1.4: reset full-speed USB device number 4 using dwc_otg
Jun  8 13:51:11 RPi2-weewx weewx[11998]: engine: StdConvert target unit is 0x1
Jun  8 13:51:11 RPi2-weewx weewx[11998]: 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=p
refer_hardware
Jun  8 13:51:11 RPi2-weewx weewx[11998]: wxcalculate: The following algorithms will be used for calculations: altimeter=aaNOAA, maxSolarRad=RS
Jun  8 13:51:11 RPi2-weewx weewx[11998]: crt: service version is 0.18
Jun  8 13:51:11 RPi2-weewx weewx[11998]: crt: output goes to /var/www/html/vreme/realtime.txt
Jun  8 13:51:12 RPi2-weewx weewx[11998]: crt: 'None' values will be displayed as NULL
Jun  8 13:51:12 RPi2-weewx weewx[11998]: crt: units will be displayed as METRIC
Jun  8 13:51:12 RPi2-weewx weewx[11998]: crt: zambretti forecast: False
Jun  8 13:51:12 RPi2-weewx weewx[11998]: crt: binding is loop
Jun  8 13:51:12 RPi2-weewx weewx[11998]: engine: Archive will use data binding wx_binding
Jun  8 13:51:12 RPi2-weewx weewx[11998]: engine: Record generation will be attempted in 'hardware'
Jun  8 13:51:12 RPi2-weewx weewx[11998]: engine: Using archive interval of 300 seconds (specified in weewx configuration)
Jun  8 13:51:12 RPi2-weewx weewx[11998]: engine: Using binding 'wx_binding' to database 'weewx.sdb'
Jun  8 13:51:12 RPi2-weewx weewx[11998]: manager: Starting backfill of daily summaries
Jun  8 13:51:12 RPi2-weewx weewx[11998]: restx: StationRegistry: Station will be registered.
Jun  8 13:51:12 RPi2-weewx weewx[11998]: restx: Wunderground-PWS: Data for station ISLOVENI32 will be posted
Jun  8 13:51:12 RPi2-weewx weewx[11998]: restx: PWSweather: Posting not enabled.
Jun  8 13:51:12 RPi2-weewx weewx[11998]: restx: CWOP: Posting not enabled.
Jun  8 13:51:12 RPi2-weewx weewx[11998]: restx: WOW: Posting not enabled.
Jun  8 13:51:12 RPi2-weewx weewx[11998]: restx: AWEKAS: Posting not enabled.
Jun  8 13:51:12 RPi2-weewx weewx[11998]: engine: Starting up weewx version 3.8.0
Jun  8 13:51:12 RPi2-weewx weewx[11998]: engine: Starting main packet loop.
Jun  8 13:55:18 RPi2-weewx weewx[11998]: manager: Added record 2018-06-08 13:55:00 CEST (1528458900) to database 'weewx.sdb'
Jun  8 13:55:18 RPi2-weewx weewx[11998]: manager: Added record 2018-06-08 13:55:00 CEST (1528458900) to daily summary in 'weewx.sdb'
Jun  8 13:55:19 RPi2-weewx weewx[11998]: restx: StationRegistry: Published record 2018-06-08 13:55:00 CEST (1528458900)
Jun  8 13:55:19 RPi2-weewx weewx[11998]: historygenerator.pyc: Generated 8 tables in 0.47 seconds
Jun  8 13:55:24 RPi2-weewx weewx[11998]: restx: Wunderground-PWS: Published record 2018-06-08 13:55:00 CEST (1528458900)
Jun  8 13:55:29 RPi2-weewx weewx[11998]: cheetahgenerator: Generated 9 files for report StandardReport in 10.42 seconds
Jun  8 13:55:44 RPi2-weewx weewx[11998]: imagegenerator: Generated 36 images for StandardReport in 14.77 seconds
Jun  8 13:55:44 RPi2-weewx weewx[11998]: copygenerator: copied 5 files to /var/www/html/weewx
Jun  8 13:55:44 RPi2-weewx weewx[11998]: historygenerator.pyc: Generated 8 tables in 0.34 seconds
Jun  8 13:55:54 RPi2-weewx weewx[11998]: cheetahgenerator: Generated 10 files for report StandardReport-SI in 10.40 seconds
Jun  8 13:56:09 RPi2-weewx weewx[11998]: imagegenerator: Generated 36 images for StandardReport-SI in 14.80 seconds
Jun  8 13:56:09 RPi2-weewx weewx[11998]: copygenerator: copied 5 files to /var/www/html/vreme
Jun  8 14:00:30 RPi2-weewx weewx[11998]: manager: Added record 2018-06-08 14:00:00 CEST (1528459200) to database 'weewx.sdb'
Jun  8 14:00:30 RPi2-weewx weewx[11998]: manager: Added record 2018-06-08 14:00:00 CEST (1528459200) to daily summary in 'weewx.sdb'

Regards,

On Friday, December 16, 2016 at 3:00:03 AM UTC+1, Marc Aubry wrote:
Hi 
i'm running weewx 3.6.2-1 on a raspberry pi 2 connected to the lan via cable and a deported mysql database server hosted on ubuntu linux computer.
weewx report on local webserver hosted on the same rapberry as the weewx server and on a ftp server at the following: http://web.cubadak-paradisovillage.com/weather

weewx stop reporting few times per day and probably crash because nothing appear in the syslog file after the last report (check below for extract of my syslog file during the last crash and my weewx conf file).
To restart the weewx i do a reboot of the raspberry or stop and start of the service.
what can i do to monitor if the weewx service crash and diagnose the cause of the crash ????
thanks in advance for your help.


syslog:
Dec 15 21:05:31 weatherstation weewx[600]: genimages: Generated 12 images for StandardReport in 2.36 seconds
Dec 15 21:05:31 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx
Dec 15 21:05:35 weatherstation weewx[600]: cheetahgenerator: Generated 1 files for report forecast in 3.96 seconds
Dec 15 21:05:35 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx/forecast
Dec 15 21:10:15 weatherstation weewx[600]: manager: added record 2016-12-15 21:10:00 WIB (1481811000) to database 'weewx'
Dec 15 21:10:16 weatherstation weewx[600]: manager: added record 2016-12-15 21:10:00 WIB (1481811000) to daily summary in 'weewx'
Dec 15 21:10:16 weatherstation weewx[600]: forecast: WUThread: WU: downloading forecast from 'http://api.wunderground.com/api/XXXXXXXXXXXXec50/hourly10day/q/-1.217,100.400.json'
Dec 15 21:10:17 weatherstation weewx[600]: restx: PWSWeather: Published record 2016-12-15 21:10:00 WIB (1481811000)
Dec 15 21:10:17 weatherstation weewx[600]: restx: Wunderground-PWS: Published record 2016-12-15 21:10:00 WIB (1481811000)
Dec 15 21:10:20 weatherstation weewx[600]: forecast: WUThread: WU: got 240 forecast records
Dec 15 21:10:20 weatherstation weewx[600]: forecast: WUThread: WU: saved 240 forecast records
Dec 15 21:10:20 weatherstation weewx[600]: forecast: WUThread: WU: deleted forecasts prior to 1481206220
Dec 15 21:10:27 weatherstation weewx[600]: cheetahgenerator: Generated 7 files for report StandardReport in 11.10 seconds
Dec 15 21:10:34 weatherstation weewx[600]: genimages: Generated 12 images for StandardReport in 7.39 seconds
Dec 15 21:10:34 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx
Dec 15 21:10:38 weatherstation weewx[600]: cheetahgenerator: Generated 1 files for report forecast in 3.93 seconds
Dec 15 21:10:38 weatherstation weewx[600]: reportengine: copied 0 files to /var/www/html/weewx/forecast
Dec 15 21:17:01 weatherstation CRON[1378]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Dec 15 22:17:01 weatherstation CRON[1403]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)

weewx conf file:
# WEEWX CONFIGURATION FILE
#
# Copyright (c) 2009-2015 Tom Keffer <tke...@gmail.com>
# See the file LICENSE.txt for your rights.

##############################################################################

# This section is for general configuration information.

# Set to 1 for extra debug info, otherwise comment it out or set to zero
debug = 0

# Root directory of the weewx data file hierarchy for this station
WEEWX_ROOT = /

# How long to wait before timing out a socket (FTP, HTTP) connection
socket_timeout = 20

# Do not modify this. It is used when installing and updating weewx.
version = 3.6.2

##############################################################################

#   This section is for information about the station.

[Station]
    
    # Description of the station location
    location = "Cubadak Island, West Sumatra"
    
    # Latitude and longitude in decimal degrees
    latitude = -1.217
    longitude = 100.400
    
    # Altitude of the station, with unit it is in. This is downloaded from
    # from the station if the hardware supports it.
    altitude = 5, meter
    
    # Set to type of station hardware. There must be a corresponding stanza
    # in this file with a 'driver' parameter indicating the driver to be used.
    station_type = WH23xx
    
    # If you have a website, you may specify an URL
    
    # The start of the rain year (1=January; 10=October, etc.). This is
    # downloaded from the station if the hardware supports it.
    rain_year_start = 1
    
    # Start of week (0=Monday, 6=Sunday)
    week_start = 6

##############################################################################

#[WH23XX]
# This section is for the weewx weather station simulator

# The time (in seconds) between LOOP packets.
#loop_interval = 2.5

# The simulator mode can be either 'simulator' or 'generator'.
# Real-time simulator. Sleep between each LOOP packet.
#mode = simulator
# Generator.  Emit LOOP packets as fast as possible (useful for testing).
#mode = generator

# The start time. If not specified, the default is to use the present time.
#start = 2011-01-01 00:00

# The driver to use:
#driver = user.wh23xx

##############################################################################

#   This section is for uploading data to Internet sites

[StdRESTful]
    
    [[StationRegistry]]
        # To register this weather station with weewx, set this to true
        register_this_station = true
    
    [[AWEKAS]]
        # This section is for configuring posts to AWEKAS.
        
        # If you wish to do this, set the option 'enable' to true,
        # and specify a username and password.
        enable = false
        username = replace_me
        password = replace_me
    
    [[CWOP]]
        # This section is for configuring posts to CWOP.
        
        # If you wish to do this, set the option 'enable' to true,
        # and specify the station ID (e.g., CW1234).
        enable = false
        station = replace_me
    
    # If this is an APRS (radio amateur) station, uncomment
    # the following and replace with a passcode (e.g., 12345).
    #passcode = replace_me (APRS stations only)
    
    [[PWSweather]]
        # This section is for configuring posts to PWSweather.com.
        
        # If you wish to do this, set the option 'enable' to true,
        # and specify a station and password.
        enable = true
        station = CUBADAK
        password =xxxxxxxxxxxxxxx
    
    [[WOW]]
        # This section is for configuring posts to WOW.
        
        # If you wish to do this, set the option 'enable' to true,
        # and specify a station and password.
        enable = false
        station = replace_me
        password = replace_me
    
    [[Wunderground]]
        # This section is for configuring posts to the Weather Underground.
        
        # If you wish to do this, set the option 'enable' to true,
        # and specify a station (e.g., 'KORHOODR3') and password.
        enable = true
        station = IWESTSUM3
        password = xxxxxxxxxxxx
        
        # Set the following to True to have weewx use the WU "Rapidfire"
        # protocol. Not all hardware can support it. See the User's Guide.
        rapidfire = False

##############################################################################

#   This section specifies what reports, using which skins, to generate.

[StdReport]
    
    # Where the skins reside, relative to WEEWX_ROOT
    SKIN_ROOT = /etc/weewx/skins
    #SKIN_ROOT = ~/weewx/skins
    # Where the generated reports should go, relative to WEEWX_ROOT
    HTML_ROOT = /var/www/html/weewx
    
    # The database binding indicates which data should be used in reports.
    data_binding = wx_binding
    
    # Each of the following subsections defines a report that will be run.
    
    [[StandardReport]]
        # See the customizing guide to change the units, plot types and line
        # colors, modify the fonts, display additional sensor data, and other
        # customizations. Many of those changes can be made here by overriding
        # parameters, or by modifying templates within the skin itself.
        
        # The StandardReport uses the 'Standard' skin, which contains the
        # images, templates and plots for the report.
        skin = sofaskin
        [[[Units]]]
            [[[[Groups]]]]
                group_altitude = meter
                group_speed2 = knot
                group_pressure = mbar
                group_rain = mm
                group_rainrate = mm_per_hour
                group_temperature = degree_C
                group_degree_day = degree_C_day
                group_speed = knot
    [[forecast]]
        HTML_ROOT = /var/www/html/weewx/forecast
        skin = forecast
    
    [[FTP]]
        # FTP'ing the results to a webserver is treated as just another report,
        # albeit one with an unusual report generator!
        skin = Ftp
        
        # If you wish to use FTP, uncomment and fill out the next four lines.
        password = marcoind
        server = web.cubadak-paradisovillage.com
        path = /docs/weather
        
        # Set to True for an FTP over TLS (FTPS) connection. Not all servers
        # support this.
        secure_ftp = False
        
        # To upload files from something other than what HTML_ROOT is set
        # to above, specify a different HTML_ROOT here.
        #HTML_ROOT = /var/www/html/weewx
        
        # Most FTP servers use port 21
        port = 21
        
        # Set to 1 to use passive mode, zero for active mode
        passive = 1
    
report_timing = */15 * * * *
    [[RSYNC]]
        # rsync'ing to a webserver is treated as just another report
        skin = Rsync
        
        # If you wish to use rsync, you must configure passwordless ssh using
        # public/private key authentication from the user account that weewx
        # runs as to the user account on the remote machine where the files
        # will be copied.
        #
        # The following three lines determine where files will be sent.
        #server = replace with the rsync server name, e.g, www.threefools.org
        #path = replace with the rsync destination directory (e.g., /weather)
        #user = replace with the rsync username
        
        # Rsync can be configured to remove files from the remote server if
        # they don't exist under HTML_ROOT locally. USE WITH CAUTION: if you
        # make a mistake in the remote path, you could could unintentionally
        # cause unrelated files to be deleted. Set to 1 to enable remote file
        # deletion, zero to allow files to accumulate remotely.
        delete = 0

##############################################################################

#   This service acts as a filter, converting the unit system coming from
#   the hardware to a unit system in the database.

[StdConvert]
    
    # The target_unit affects only the unit system in the database. Once
    # chosen it cannot be changed without converting the entire database.
    # Modification of target_unit after starting weewx will result in
    # corrupt data - the database will contain a mix of US and METRIC data.
    #
    # The value of target_unit does not affect the unit system for
    # reporting - reports can display US, Metric, or any combination of units.
    #
    # In most cases, target_unit should be left as the default: US
    #
    # In particular, those migrating from a standard wview installation
    # should use US since that is what the wview database contains.
    
    # DO NOT MODIFY THIS VALUE UNLESS YOU KNOW WHAT YOU ARE DOING!
    target_unit = METRIC    # Options are 'US', 'METRICWX', or 'METRIC'

##############################################################################

#   This section can adjust data using calibration expressions.

[StdCalibrate]
    
    [[Corrections]]
        # For each type, an arbitrary calibration expression can be given. 
        # It should be in the units defined in the StdConvert section.
        # Example:
        foo = foo + 0.2
        radiation = radiation * 292
##############################################################################

#   This section is for quality control checks. If units are not specified,
#   values must be in the units defined in the StdConvert section.

[StdQC]
    
    [[MinMax]]
        barometer = 900, 1100
        outTemp = 10, 60
        inTemp = 10, 60
        outHumidity = 0, 100
        inHumidity = 0, 100
        windSpeed = 0, 90
        pressure = 900, 1100
rain=0, 300
##############################################################################

#   This section controls the origin of derived values.

[StdWXCalculate]
    
    [[Calculations]]
        # Derived quantities are calculated by this service. Possible values are:
        #  hardware        - use the value provided by hardware
        #  software        - use the value calculated by weewx
        #  prefer_hardware - use value provide by hardware if available,
        #                      otherwise use value calculated by weewx
        
        pressure = prefer_hardware
        barometer = prefer_hardware
        altimeter = prefer_hardware
        windchill = prefer_hardware
        heatindex = prefer_hardware
        dewpoint = prefer_hardware
        inDewpoint = prefer_hardware
        rainRate = prefer_hardware
        radiation = hardware
##############################################################################

#   For hardware that supports it, this section controls how often the
#   onboard clock gets updated.

[StdTimeSynch]
    
    # How often to check the weather station clock for drift (in seconds)
    clock_check = 14400
    
    # How much it can drift before we will correct it (in seconds)
    max_drift = 5

##############################################################################

#   This section is for configuring the archive service.

[StdArchive]
    
    # If the station hardware supports data logging then the archive interval
    # will be downloaded from the station. Otherwise, specify it (in seconds).
    archive_interval = 300
    
    # If possible, new archive records are downloaded from the station
    # hardware. If the hardware does not support this, then new archive
    # records will be generated in software.
    # Set the following to "software" to force software record generation.
    record_generation = hardware
    
    # Whether to include LOOP data in hi/low statistics
    loop_hilo = True
    
    # The data binding used to save archive records
    data_binding = wx_binding

##############################################################################

#   This section binds a data store to a database.

[DataBindings]
    
    [[wx_binding]]
        # The database must match one of the sections in [Databases].
        # This is likely to be the only option you would want to change.
        database = archive_mysql
        # The name of the table within the database
        table_name = archive
        # The manager handles aggregation of data for historical summaries
        manager = weewx.wxmanager.WXDaySummaryManager
        # The schema defines the structure of the database.
        # It is *only* used when the database is created.
        schema = schemas.wview.schema
    [[forecast_binding]]
        database = forecast_sqlite

##############################################################################

#   This section defines various databases.

[Databases]
    
    # A SQLite database is simply a single file
    [[archive_sqlite]]
        database_type = SQLite
        database_name = weewx.sdb
    
    # MySQL
    [[archive_mysql]]
        database_type = MySQL
        database_name = weewx
    [[forecast_sqlite]]
        database_name = forecast.sdb
        database_type = SQLite

##############################################################################

#   This section defines defaults for the different types of databases.

[DatabaseTypes]
    
    # Defaults for SQLite databases
    [[SQLite]]
        driver = weedb.sqlite
        # Directory in which the database files are located
        SQLITE_ROOT = /var/lib/weewx
    
    # Defaults for MySQL databases
    [[MySQL]]
        driver = weedb.mysql
        # The host where the database is located
        host = minux.cubadak
        # The user name for logging in to the host
        user =xxxxx
        # The password for the user name
        password =xxxxxxx

##############################################################################

#   This section configures the internal weewx engine.

[Engine]
    
    [[Services]]
        # This section specifies the services that should be run. They are
        # grouped by type, and the order of services within each group
        # determines the order in which the services will be run.
        prep_services = weewx.engine.StdTimeSynch
        data_services = ,
        process_services = weewx.engine.StdConvert, weewx.engine.StdCalibrate, weewx.engine.StdQC, weewx.wxservices.StdWXCalculate
        archive_services = weewx.engine.StdArchive, user.forecast.ZambrettiForecast, user.forecast.WUForecast
        restful_services = weewx.restx.StdStationRegistry, weewx.restx.StdWunderground, weewx.restx.StdPWSweather, weewx.restx.StdCWOP, weewx.restx.StdWOW, weewx.restx.StdAWEKAS
        report_services = weewx.engine.StdPrint, weewx.engine.StdReport

##############################################################################

[WH23xx]
    # This section is for Fine Offset WH23xx stations
    
    # The model name such as Tycon, or TP2700
    model = MiSol WH2310
    
    # The driver to use
    driver = user.wh23xx

##############################################################################

# Options for extension 'forecast'
[Forecast]
    data_binding = forecast_binding
   # [[XTide]]
   #     location = "INSERT_LOCATION_HERE (e.g., Boston)"
    [[Zambretti]]
        hemisphere = south
    [[WU]]
        api_key = b89d63b44524ec50
   # [[NWS]]
   #     lid = "INSERT_LOCATION_ID_HERE (e.g., MAZ014)"
   #     foid = "INSERT_FORECAST_OFFICE_ID_HERE (e.g., BOX)"





Bostjan Potocnik

unread,
Jul 10, 2018, 9:22:50 AM7/10/18
to weewx-user
Hi,

I changed the power supply. Now seems to be just fine!?!

Thanks!

Regards,

Bostjan
Reply all
Reply to author
Forward
0 new messages