Delay Weewx at start up or reboot

122 views
Skip to first unread message

Timothy L

unread,
Aug 18, 2019, 10:43:45 PM8/18/19
to weewx-user
Is it possible to delay weewx at start up or reboot with a cron job etc?It is desired to delay it for 45 seconds. Thank you

Graham Eddy

unread,
Aug 18, 2019, 10:48:42 PM8/18/19
to weewx...@googlegroups.com
it is possible to delay weewx for 45 seconds from boot.
the method depends upon the type of your operating system and configuration
____________
Graham Eddy

On 19 Aug 2019, at 12:43 pm, Timothy L <lecoqacr...@gmail.com> wrote:

Is it possible to delay weewx at start up or reboot with a cron job etc?It is desired to delay it for 45 seconds. Thank you

--
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/87dd0ddd-15be-404d-ad95-00820fc80f83%40googlegroups.com.

Thomas Keffer

unread,
Aug 19, 2019, 7:56:38 AM8/19/19
to weewx-user
Put this in the file user/extensions.py:

import time
time.sleep(45)

On Sun, Aug 18, 2019 at 7:43 PM Timothy L <lecoqacr...@gmail.com> wrote:
Is it possible to delay weewx at start up or reboot with a cron job etc?It is desired to delay it for 45 seconds. Thank you

--

Timothy L

unread,
Aug 19, 2019, 8:44:08 AM8/19/19
to weewx-user
Using the raspbian operating system with latest Buster release. How may it be accomplished on this raspberry pi?Thank you

Andrew Milner

unread,
Aug 19, 2019, 9:21:28 AM8/19/19
to weewx-user
if you do as Thomas suggested you are changing a weewx file - so weewx will put itself to sleep and give you your delay.  It is not specific to any computer type.

Carl Muellner

unread,
Aug 19, 2019, 4:59:38 PM8/19/19
to weewx-user
Thomas -

     Is this intended for the file "/var/share/weewx/user/extensions.py" ?  I am running my weewx installation on Ubuntu,

     Thanks!

   -  Carl

On Monday, August 19, 2019 at 6:56:38 AM UTC-5, Thomas Keffer wrote:
Put this in the file user/extensions.py:

import time
time.sleep(45)

On Sun, Aug 18, 2019 at 7:43 PM Timothy L <lecoqacr...@gmail.com> wrote:
Is it possible to delay weewx at start up or reboot with a cron job etc?It is desired to delay it for 45 seconds. Thank you

--
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.

vince

unread,
Aug 19, 2019, 5:45:20 PM8/19/19
to weewx-user
On Sunday, August 18, 2019 at 7:43:45 PM UTC-7, Timothy L wrote:
Is it possible to delay weewx at start up or reboot with a cron job etc?It is desired to delay it for 45 seconds. Thank you


I hate to ask, but why would you want or need to do that ?
Just curious...

Thomas Keffer

unread,
Aug 19, 2019, 6:14:28 PM8/19/19
to weewx-user

     Is this intended for the file "/var/share/weewx/user/extensions.py" ?  I am running my weewx installation on Ubuntu,

Yes. All files in the 'user' directory are preserved through upgrades, so you don't have to worry about losing the addition if you upgrade. The file user/extensions.py is run before the engine starts up, so it will do they delay before anything else.

-tk

Timothy L

unread,
Aug 19, 2019, 7:25:02 PM8/19/19
to weewx-user
Thank You worked perfectly. I appreciate the help


On Monday, August 19, 2019 at 6:56:38 AM UTC-5, Thomas Keffer wrote:
Put this in the file user/extensions.py:

import time
time.sleep(45)

On Sun, Aug 18, 2019 at 7:43 PM Timothy L <lecoqacr...@gmail.com> wrote:
Is it possible to delay weewx at start up or reboot with a cron job etc?It is desired to delay it for 45 seconds. Thank you

--
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.

Timothy L

unread,
Aug 19, 2019, 7:25:57 PM8/19/19
to weewx-user
Thank you. It worked as described

Timothy L

unread,
Aug 19, 2019, 7:28:36 PM8/19/19
to weewx-user
Just wanted all loading processes to start before weewx and be sure of good network connectivity. It also allows me to to backup of the database before starting weewx with a cron job. Thank you
Reply all
Reply to author
Forward
0 new messages