--
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 visit https://groups.google.com/d/msgid/weewx-user/CAGTinV4Kq9SRAWX%3DRxGgqbHYxyT4dLBNtbe3FoUyWGsSD11Vpg%40mail.gmail.com.
John, slow down there, dude.
Let me set the record straight. As I stated in the PR, if you want an out-of-the-box solution, use SQLite. MySQL was never intended to be that. To use it, it must be first installed, then a root password set up then, then using the
mysql client, set up an account to be used with WeeWX, then set proper permissions for that account. Modifying the services file is just one more step in that process. It's not a "time bomb waiting to go off."
Also, weewxd does restart if MySQL is not ready. Or, if it doesn't, that's a bug. I just checked it on my Mac, and it works as it is supposed to.
Also, weewxd does restart if MySQL is not ready. Or, if it doesn't, that's a bug. I just checked it on my Mac, and it works as it is supposed to.
Not on Debian 13 Trixie running SystemD 257.8-1~deb13u2 hence the PR....
--
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 visit https://groups.google.com/d/msgid/weewx-user/3d9cb1e4-0a35-4903-b6ce-d253a536589e%40hillsandlakes.com.
The quick response to whether it might be core or extension is that it is the systemD component that is new and is somehow seems to be causing problems. But I don't recall that capability (waiting for Mysql) even being possible in sysv-init code so I think the problem has always been there.
I have kept using my own modified service files since then and update them manually if I see changes in the shipped version.
My impression was that weewx had become more resilient to the DB server disappearing for a bit, but I also have restart parameters set in my unit file. Maybe it is a difference between failing on initial connection or failing at a later stage.
My other comment (and the reason I did not reply in support of your PR) is that your changes would only be a partial solution, because it cannot account for a db server running on a different host.
This is how I was running my system at one stage and the weewx side must rely on some sort of restart/retry process when a remote mysql goes down, whether it is the server itself or the network connectivity.
" The weeWX Debian package has pre/post scripts that install the service files during updates... I can't ever remember being prompted to approve/deny SystemD service files..."Because unlike config files, the user-modified unit files should be placed in dirs like /etc/systemd/system where they simply override any unit file that is installed/updated in the default locations assigned to packages.I don't think apt/dpkg does any checks for such situations.
on the contrary, cameron's comment is exactly on point. systemd unit files are *not* conf files, so they may be replaced when you update/upgrade the weewx package. the pattern for customizing systemd units is the .d pattern.
adding a dependency in systemd is a hack, not a real fix, for a number of reasons:
1) it does not fix the problem for every operating system and init system
2) it is a dependency that does not apply to every installation,
3) it is a dependency that is not part of weewx and that could change depending on a non-weewx component of the system
just as we have to minimize python module and os dependencies, we have to minimize init dependencies. otherwise long-term support and robustness suffer. a lot. we could take the route of not having any deb/rpm
packages for weewx, and let someone else create those to include in debian or redhat or whatever. but some time ago we chose to do them, to make life easier for users and so that users could have weewx updates more
frequently (if they choose) than the os releases. we have been fairly successful in keeping weewx packages robust wrt to the changes between os releases, and consistent across multiple operating systems (and their different uses of systemd, for that specific init system)
is not the fix to make weewx retry mysql/maria/postgres connections and do nothing else until that connection is successful?
--
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 visit https://groups.google.com/d/msgid/weewx-user/CAGTinV4xKmhq%2BtXgN%2B1awU3LYpZPi%3DS%3DvU8h39TV5PRny0vHzA%40mail.gmail.com.
I would suggest focusing on the restart mechanism. The executable weewxd should restart if a database connection cannot be made. If that is not the case, then that's a bug. Document it and let us know.
--- pablo
As per previous emails, I've never experienced weeWX ever waiting or retrying, it's just now not starting on boot up either...
Forgive me for not remembering the details. Document it and post. I'm particularly interested in your comment that it is not starting on boot up.
--
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 visit https://groups.google.com/d/msgid/weewx-user/CAGTinV5PNaz%3DQne-QAcGjyoXa6hw7T0te1ue7tHEKnDVjLOz4g%40mail.gmail.com.
--- pablo
--- pablo
To view this discussion visit https://groups.google.com/d/msgid/weewx-user/48532b96-eb34-46d1-b2e3-5b4190347f01n%40googlegroups.com.
If a user chooses a database other than sqlite, this is an active decision, and the database must be provided by
No, that's makes no difference. Think of a meeting you need a special person for: I he he's not there at the appointment, what you're gonna do?
--
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 visit https://groups.google.com/d/msgid/weewx-user/6f2121bd-9b26-48e6-8bda-543a7154cfa5n%40googlegroups.com.
Sure, I can. But for someone complaining about his posting avalanche hasn't been read fully/comprehensively, I was expecting he was able to do so with a simple two-liner.
You are right that the code for connecting to a MySQL DB is there, But the Database isn't. And it is literally
--
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 visit https://groups.google.com/d/msgid/weewx-user/9c9323fe-26f4-4a6b-b841-ef38d98920c1n%40googlegroups.com.
DB, I would use postgres but no matter what, the server would be on a different machine than weewx or possibly
in a container. Regardless I d need a different startup process than with sqlite.
As far as I know weeWX has no code to do raw processing of anything, not even the config files... weeWX uses libraries to handle the content of config files, and parsing config files would be a much easier undertaking compared to something as complicated as a SQLite file...