I would guess that, for some reason, the file /var/www/html/weewx/#FTP.last
was protected. Perhaps weewx was run as root, but now you're running it as
a non-root user?

Try deleting it:

*sudo rm /var/www/html/#FTP.last*


It's used only to optimize the FTP transfer. It will be regenerated at the
next reporting cycle.

-tk

On Tue, Oct 1, 2024 at 5:41 AM Marco P. Ferrara <[email protected]>
wrote:

> Hi there,
> I have a Raspberry Pi (named pi-radar) with weewx 5.1.0 with python3 that
> receives data though Interceptor on a ecowitt protocol, generates pages
> with the Belchertown skin and then should FTP to an external server.
>
> I have the following error that drops out:
>
> Oct 01 14:26:02 pi-radar weewxd[39953]: INFO weewx.reportengine: Copied 3
> files to /var/www/html/weewx
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ftpgenerator: (0): caught exception '<class 'PermissionError'>': [Errno 13]
> Permission denied: '/var/www/html/weewx/#FTP.last'
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****  Traceback (most recent call last):
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****    File "/usr/share/weewx/weewx/reportengine.py", line 519, in run
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****      n = ftp_data.run()
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****          ^^^^^^^^^^^^^^
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****    File "/usr/share/weewx/weeutil/ftpupload.py", line 226, in run
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****      self.save_last_upload(timestamp, fileset, hashdict)
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****    File "/usr/share/weewx/weeutil/ftpupload.py", line 258, in
> save_last_upload
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****      with open(timestamp_file_path, "wb") as f:
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> Oct 01 14:26:08 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****  PermissionError: [Errno 13] Permission denied:
> '/var/www/html/weewx/#FTP.last'
> Oct 01 14:26:13 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ftpgenerator: (1): caught exception '<class 'PermissionError'>': [Errno 13]
> Permission denied: '/var/www/html/weewx/#FTP.last'
> Oct 01 14:26:13 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****  Traceback (most recent call last):
> Oct 01 14:26:13 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****    File "/usr/share/weewx/weewx/reportengine.py", line 519, in run
> Oct 01 14:26:13 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****      n = ftp_data.run()
> Oct 01 14:26:13 pi-radar weewxd[39953]: ERROR weewx.reportengine:
> ****          ^^^^^^^^^^^^^^
>
> When I run the reports manually they get uploaded correctly. Any idea what
> could generate the issue?
>
> Thanks!
> --
> MPF
>
> --
> 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 on the web visit
> https://groups.google.com/d/msgid/weewx-user/a133f7c6-416f-4c0c-a77b-c8f55b3ab6c3n%40googlegroups.com
> <https://groups.google.com/d/msgid/weewx-user/a133f7c6-416f-4c0c-a77b-c8f55b3ab6c3n%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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/CAPq0zEC2oEw9OX8pDkU0eKNsZJW5oBRo1SSOM6iK2eNJ_x1jDA%40mail.gmail.com.

Reply via email to