I would "sudo chown -R weewx:weewx /var/www/html/weather" so the directory 
and its contents are owned by the weewx user that the weewx process runs 
as. 

On Saturday, June 1, 2024 at 1:18:32 PM UTC-7 Rob Cranfill wrote:

> Thanks for the idea, but that didn't fix it.
>
> On Saturday, June 1, 2024 at 12:42:47 PM UTC-7 Warren Gill wrote:
>
>> There might be files left over from pre-upgrade that are still owned by 
>> www-data (daybarometer.png, for example). I'd just go into the 
>> /var/www/html/weather/ directory and remove everything and let weewx build 
>> new ones. Or, chown weewx:weewx * in the weather directory
>>
>>
>> On Sat, Jun 1, 2024 at 2:22 PM Rob Cranfill <robcr...@gmail.com> wrote:
>>
>>> Hey, all!
>>>
>>> Just upgraded to 5.02 from 4.10.something, and now WeeWX can't output to 
>>> my web server directory. I'm sure it's some dumb permissions thing I'm 
>>> missing, but I am not seeing it.
>>>
>>> I get a bazillion errors like this in the log:
>>>
>>> Jun 01 12:16:15 pi4 weewxd[3424852]: ERROR weewx.imagegenerator: Unable 
>>> to save to file '/var/www/html/weather/daybarometer.png' [Errno 13] 
>>> Permission denied: '/var/www/html/weather/daybarometer.png':
>>>
>>> My new install is running as user weewx, as intended:
>>> rob@pi4: $ ps aux | grep wee
>>> weewx    3424852  4.9  2.8 358576 53528 ?        Ssl  11:38   1:42 
>>> python3 /usr/share/weewx/weewxd.py /etc/weewx/weewx.conf
>>>
>>> I added that user to some groups (for my USB interface and the HTML 
>>> directory)
>>> rob@pi4: $ groups weewx
>>> weewx : weewx dialout www-data
>>>
>>> And here are the permissions along that directory path. See anything 
>>> untowards?
>>> drwxr-xr-x 12 root root 4.0K Dec  7 20:36 /var
>>> drwxr-xr-x 3 root root 4.0K Dec  7 20:36 /var/www/
>>> drwxr-xr-x 4 www-data www-data 4.0K Jun  1 10:58 /var/www/html/
>>> drwxrwxr-x 6 www-data www-data 4.0K Jun  1 11:25 /var/www/html/weather/
>>>
>>> Thanks for any suggestions. I can post more info if that will help. The 
>>> logs show nothing else interesting that I can see.
>>>
>>>  /rob
>>>  
>>>
>>> -- 
>>> 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/08ee001f-caa9-4982-9f13-1c2be9d3bdaan%40googlegroups.com
>>>  
>>> <https://groups.google.com/d/msgid/weewx-user/08ee001f-caa9-4982-9f13-1c2be9d3bdaan%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/84d2493d-eddb-43f6-8687-9bb02fdc5683n%40googlegroups.com.

Reply via email to