WeeWx sometimes fails to start on reboot

66 views
Skip to first unread message

Kev D

unread,
Jun 24, 2019, 9:13:02 AM6/24/19
to weewx-user
Hi all,

I was doing some searching on this but not sure the best way to proceed. The current issue is upon reboot of my Ubuntu server, sometimes WeeWX will not start with this error in the logs.

Jun 24 02:00:58 osboxes weewx[791]: import of driver failed: enp0s3: That device is not up (<type 'exceptions.Exception'>)
Jun 24 02:00:58 osboxes weewx[791]: engine: Unable to load driver: enp0s3: That device is not up
Jun 24 02:00:58 osboxes weewx[791]:     ****  Exiting...

This is easily resolved by just restarting WeeWx, but if I don't catch this then it will not capture any data. The best solution I found in searching was to add a delay in the "/etc/init.d/weewx"  script to wait for these interfaces to be active. Do you think this would be alright and if so do you know where I should place this in the file? Or is there another way to deal with this issue?

Thanks in advance!

Kev

Thomas Keffer

unread,
Jun 24, 2019, 5:33:20 PM6/24/19
to weewx-user
You could try the loop_on_init flag. (Look here for documentation, last item under "General" heading). This won't fix anything, but it will cause WeeWX to keep trying, rather than exiting.

-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+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/d86476d4-25fb-41a0-85d6-ace778b914a8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Kev D

unread,
Jun 25, 2019, 9:24:35 AM6/25/19
to weewx-user
Thanks, Thomas! this worked perfectly, on the first fail it waited 60 seconds and tried again:

Jun 25 09:18:38 osboxes weewx[789]: engine: retrying...
Jun 25 09:18:38 osboxes weewx[789]: engine: Using configuration file /etc/weewx/weewx.conf
Jun 25 09:18:38 osboxes weewx[789]: engine: Loading station type Interceptor (user.interceptor)
Jun 25 09:18:38 osboxes weewx[789]: interceptor: MainThread: driver version is 0.45
Jun 25 09:18:38 osboxes weewx[789]: interceptor: MainThread: device type: observer
Jun 25 09:18:38 osboxes weewx[789]: interceptor: MainThread: sensor map: None
Jun 25 09:18:38 osboxes weewx[789]: interceptor: MainThread: mode is sniff
Jun 25 09:18:38 osboxes weewx[789]: interceptor: MainThread: sniff iface=enp0s3 promiscuous=0

On a side note, I really need to review the documentation better before posting in here :)

Cheers,

Kev


On Monday, June 24, 2019 at 5:33:20 PM UTC-4, Thomas Keffer wrote:
You could try the loop_on_init flag. (Look here for documentation, last item under "General" heading). This won't fix anything, but it will cause WeeWX to keep trying, rather than exiting.

-tk

On Mon, Jun 24, 2019 at 6:13 AM Kev D <kevs...@gmail.com> wrote:
Hi all,

I was doing some searching on this but not sure the best way to proceed. The current issue is upon reboot of my Ubuntu server, sometimes WeeWX will not start with this error in the logs.

Jun 24 02:00:58 osboxes weewx[791]: import of driver failed: enp0s3: That device is not up (<type 'exceptions.Exception'>)
Jun 24 02:00:58 osboxes weewx[791]: engine: Unable to load driver: enp0s3: That device is not up
Jun 24 02:00:58 osboxes weewx[791]:     ****  Exiting...

This is easily resolved by just restarting WeeWx, but if I don't catch this then it will not capture any data. The best solution I found in searching was to add a delay in the "/etc/init.d/weewx"  script to wait for these interfaces to be active. Do you think this would be alright and if so do you know where I should place this in the file? Or is there another way to deal with this issue?

Thanks in advance!

Kev

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

Andrew Milner

unread,
Jun 25, 2019, 10:02:30 AM6/25/19
to weewx-user
Don't worry - you are far from being the only one who posts before perusal - so welcome to the PPPers !!!!!
Reply all
Reply to author
Forward
0 new messages