I use this stanza in weewx.conf for logging:
[Logging]
version = 1
disable_existing_loggers = False
# Root logger
[[root]]
level = INFO
handlers = rotate, #console
# Additional loggers would go in the following section. This is useful
for tailoring logging
# for individual modules.
[[loggers]]
# Definitions of possible logging destinations
[[handlers]]
# Log to a set of rotating files
[[[rotate]]]
level = INFO
formatter = verbose
class = logging.handlers.RotatingFileHandler
filename = /home/patrick/weewx-data/log/weewxd.log
maxBytes = 10000000
backupCount = 4
Note: the user you run WeeWX with has to have write access to
/home/patrick/weewx-data/log
I don't know if syslog is even involved then, but if I have understood
correctly what you are trying to achieve, something like this could do the
trick.
See
https://weewx.com/docs/5.2/usersguide/monitoring/?h=logging#logging-on-macos
which apparently isn't limited to mac OS.
[email protected] schrieb am Freitag, 5. Dezember 2025 um 18:59:43 UTC+1:
> hello,
> I followed the configuration to take log from wiki but I have an error
> when I restart rsyslog.service
>
> [rsyslogd[6115]: error during config processing: omfile: creating parent
> directories for file '/home/patrick/weewx-data/log/weewx.log' failed:
> Read-only file system [v8.2504>]
>
> My install done with pip install.
>
> (weewx-venv) RPi:~/weewx-data $ ls -ail
> total 64
> 659581 drwxrwxrwx 10 patrick patrick 4096 5 déc. 17:53 .
> 1669 drwxrwxrwx 18 patrick patrick 4096 5 déc. 14:11 ..
> 659975 drwxr-xr-x 2 patrick patrick 4096 5 déc. 18:55 archive
> 659917 drwxrwxr-x 3 patrick patrick 4096 5 déc. 13:57 bin
> 659841 drwxrwxr-x 8 patrick patrick 4096 5 déc. 13:52 examples
> 660548 drwxrwxrwx 2 patrick patrick 4096 5 déc. 17:53 log
> 659977 drwxrwxrwx 4 patrick patrick 4096 5 déc. 18:55 public_html
> 659969 drwxrwxr-x 2 patrick patrick 4096 5 déc. 13:57 scripts
> 659711 drwxrwxr-x 8 patrick patrick 4096 5 déc. 13:57 skins
> 659921 drwxrwxr-x 18 patrick patrick 4096 5 déc. 13:52 util
> 659971 -rw-rw-r-- 1 patrick patrick 22882 5 déc. 16:41 weewx.conf
>
> etc/rsyslog.d/weewx.conf:
> [# Put messages from WeeWX into file(s) separate from the system log file
>
> # If you want log messages from each application in a separate file,
> # then uncomment the following two lines, and comment the weewx.log line.
> #$template WEEWX_LOGFILE,"/home/patrick/weewx-data/log/%programname%.log"
> #if $programname startswith 'wee' then ?WEEWX_LOGFILE
>
> # Put log messages from all WeeWX applications into a single file
> if $programname startswith 'wee' then
> /home/patrick/weewx-data/log/weewx.log
>
> # Finish the WeeWX rules
> if $programname startswith 'wee' then stop]
>
> I don't see where is my error of configuration
>
> Patrick
>
>
>
>
--
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 [email protected].
To view this discussion visit
https://groups.google.com/d/msgid/weewx-user/803edf7f-c291-410a-abba-6a5033aef1b4n%40googlegroups.com.