mirror of
https://github.com/weewx/weewx.git
synced 2026-04-22 10:37:06 -04:00
Added details on how to tell a running instance to reread its configuration file.
This commit is contained in:
26
CHANGES.txt
26
CHANGES.txt
@@ -1,21 +1,25 @@
|
||||
CHANGE HISTORY
|
||||
--------------------------------
|
||||
|
||||
1.4.0 02/21/10
|
||||
1.4.0 02/22/10
|
||||
|
||||
Changed the architecture of stats.py to one that uses very late binding. The
|
||||
SQL statements are not run until template evaluation. This reduces
|
||||
the amount of memory required (by about 10MB), reduces memory fragmentation,
|
||||
as well as greatly simplifying the code (file stats.py shed 100 lines of code).
|
||||
Execution time is approximately the same.
|
||||
Changed the architecture of stats.py to one that uses very late
|
||||
binding. The SQL statements are not run until template
|
||||
evaluation. This reduces the amount of memory required (by about 1/2),
|
||||
reduces memory fragmentation, as well as greatly simplifying the code
|
||||
(file stats.py shed over 150 lines of non-test code). Execution time
|
||||
is slightly slower for NOAA file generation, slightly faster for HTML
|
||||
file generation, the same for image generation, although your actual
|
||||
results will depend on your disk speed.
|
||||
|
||||
Now possible to tell weewx to reread the configuration file without stopping
|
||||
it. Send signal HUP to the process.
|
||||
Now possible to tell weewx to reread the configuration file without
|
||||
stopping it. Send signal HUP to the process.
|
||||
|
||||
Added option week_start. Default is 6 (Sunday).
|
||||
Added option week_start, for specifying which day a calendar week starts
|
||||
on. Default is 6 (Sunday).
|
||||
|
||||
Fixed reporting bug when the reporting time falls on a calendar month or
|
||||
year boundary.
|
||||
Fixed reporting bug when the reporting time falls on a calendar month
|
||||
or year boundary.
|
||||
|
||||
1.3.4 02/08/10
|
||||
|
||||
|
||||
@@ -876,6 +876,13 @@ could take a minute or two. I've found this process particularly slow on SuS
|
||||
some reason.</p>
|
||||
<p><span class="code">Weewx</span> will then start monitoring LOOP data, printing
|
||||
a short version of the received data on standard output, about once every two seconds.</p>
|
||||
<p>You can tell a running instance of <span class="code">weewx</span> to reread
|
||||
its configuration file by sending it the <span class="code">HUP</span> signal.
|
||||
First run <span class="code">ps</span> to find out the Process ID (PID) number
|
||||
of the instance, then send it the <span class="code">HUP</span> signal:</p>
|
||||
<p class="tty">ps -a # Note the
|
||||
PID of the weewxd.py process</p>
|
||||
<p class="tty">kill -HUP <em>pid</em> # Send it a HUP signal</p>
|
||||
<h2>7.2 <a name="Running_as_a_daemon">Running as a daemon</a></h2>
|
||||
<p>For unattended operations it is best to have <span class="code">weewx</span>
|
||||
run as a daemon, started automatically when the server is rebooted. Start by selecting the appropriate run script. They can be found under
|
||||
@@ -938,8 +945,11 @@ run at run levels 2, 3, 4 and 5. Incidentally, a nice tool for setting run level
|
||||
with Debian (Ubuntu) systems is <a href="http://sysv-rc-conf.sourceforge.net/">sysv-rc-conf</a>.
|
||||
It uses a curses interface to allow you to change easily which run level any of
|
||||
your daemons runs at. There is a similar tool on SuSE. From the start menu run the
|
||||
YAST Control Center, then look for Systesm Services (Runlevel). Pick "Expert" mode
|
||||
YAST Control Center, then look for Systems Services (Runlevel). Pick "Expert" mode
|
||||
to see the run levels.</p>
|
||||
<p>You can also tell <span class="code">weewx</span> to reread its configuration
|
||||
file without stopping by using the 'reload' option:</p>
|
||||
<p class="tty">/etc/init.d/weewx reload</p>
|
||||
<h1>8. <a name="Compatibility_with_wview">Compatibility with <span class="code">
|
||||
wview</span></a></h1>
|
||||
<p>The sqlite3 archive database used by <span class="code">weewx</span> (nominally,
|
||||
|
||||
@@ -93,7 +93,7 @@ do_reload() {
|
||||
# restarting (for example, when it is sent a SIGHUP),
|
||||
# then implement that here.
|
||||
#
|
||||
start-stop-daemon --stop --signal 1 --quiet --pidfile $PIDFILE --name $NAME
|
||||
start-stop-daemon --stop --signal 1 --quiet --pidfile $PIDFILE
|
||||
return 0
|
||||
}
|
||||
|
||||
@@ -114,16 +114,16 @@ case "$1" in
|
||||
2) [ "$VERBOSE" != no ] && log_end_msg 1 ;;
|
||||
esac
|
||||
;;
|
||||
#reload|force-reload)
|
||||
reload|force-reload)
|
||||
#
|
||||
# If do_reload() is not implemented then leave this commented out
|
||||
# and leave 'force-reload' as an alias for 'restart'.
|
||||
#
|
||||
#log_daemon_msg "Reloading $DESC" "$NAME"
|
||||
#do_reload
|
||||
#log_end_msg $?
|
||||
#;;
|
||||
restart|force-reload)
|
||||
log_daemon_msg "Reloading $DESC" "$NAME"
|
||||
do_reload
|
||||
log_end_msg $?
|
||||
;;
|
||||
restart)
|
||||
#
|
||||
# If the "reload" option is implemented then remove the
|
||||
# 'force-reload' alias
|
||||
|
||||
@@ -249,14 +249,14 @@ case "$1" in
|
||||
## signaling, do nothing (!)
|
||||
|
||||
# If it supports signaling:
|
||||
#echo -n "Reload service weewx "
|
||||
#killproc -HUP $WEEWX_BIN
|
||||
#touch /var/run/WEEWX.pid
|
||||
#rc_status -v
|
||||
echo -n "Reload service weewx "
|
||||
killproc -HUP $WEEWX_BIN
|
||||
touch /var/run/WEEWX.pid
|
||||
rc_status -v
|
||||
|
||||
## Otherwise if it does not support reload:
|
||||
rc_failed 3
|
||||
rc_status -v
|
||||
#rc_failed 3
|
||||
#rc_status -v
|
||||
;;
|
||||
status)
|
||||
echo -n "Checking for service weewx "
|
||||
|
||||
Reference in New Issue
Block a user