Re: [weewx-user] FTP upload error

133 views
Skip to first unread message

Tom Keffer

unread,
Oct 4, 2022, 11:40:33 PM10/4/22
to weewx...@googlegroups.com
1. How about some more details? In particular, could we see the [[FTP]] section of weewx.conf? Be sure to obfuscate any sensitive materials, such as text.
2. Do you know which FTP server your provider is using?

On Tue, Oct 4, 2022 at 11:01 AM vladimir...@gmail.com <vladimir...@gmail.com> wrote:
Hi,
Suddenly and out of the blue my ftp upload stopped working. The html files are generated as expected in /var/www/html/weewx
Midnight Commander  FTP client - connection successful, creating and deleting files

log
Oct  4 20:47:03 pogoda-ubuntu weewx[10451] ERROR weeutil.ftpupload: Failed uploading /var/www/html/weewx/weekwinddir.png to server xxx.timeweb.ru. Reason: 'timed out'
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine: ftpgenerator: (2): caught exception '<class 'socket.timeout'>': timed out
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****  Traceback (most recent call last):
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****    File "/usr/share/weewx/weewx/reportengine.py", line 436, in run
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****      n = ftp_data.run()
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****    File "/usr/share/weewx/weeutil/ftpupload.py", line 210, in run
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****      ftp_server.storbinary(stor_cmd, fd)
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 486, in storbinary
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****      conn = self.transfercmd(cmd, rest)
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 385, in transfercmd
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****      return self.ntransfercmd(cmd, rest)[0]
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 348, in ntransfercmd
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****      resp = self.sendcmd(cmd)
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 253, in sendcmd
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****      return self.getresp()
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 219, in getresp
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****      resp = self.getmultiline()
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 205, in getmultiline
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****      line = self.getline()
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 190, in getline
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****      line = self.file.readline(self.maxline + 1)
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/socket.py", line 480, in readline
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****      data = self._sock.recv(self._rbufsize)
Oct  4 20:47:23 pogoda-ubuntu weewx[10451] ERROR weewx.reportengine:         ****  timeout: timed out

--
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/4ca99984-b8df-493c-b168-2e8f5e3f548bn%40googlegroups.com.

vladimir...@gmail.com

unread,
Oct 25, 2022, 2:38:28 PM10/25/22
to weewx-user
God day.
i'm sorry was in the hospital
1. [[FTP]] section of weewx.conf:
[[FTP]]
        # FTP'ing the results to a webserver is treated as just another report,
        # albeit one with an unusual report generator!
        skin = Ftp

        # If you wish to use FTP, set "enable" to "true", then
        # fill out the next four lines.
        # Use quotes around passwords to guard against parsing errors.
        enable = true
        user = weewx_weewx
        password = 'weewx'
        server = web.ru  # The ftp server name, e.g, www.myserver.org
        path = /public_html    # The destination directory, e.g., /weather

        # Set to True for an FTP over TLS (FTPS) connection. Not all servers
        # support this.
        secure_ftp = False

        # To upload files from something other than what HTML_ROOT is set
        # to above, specify a different HTML_ROOT here.
        # HTML_ROOT = /var/www/html/weewx

        # Most FTP servers use port 21
        port = 21

        # Set to 1 to use passive mode, zero for active mode
        passive = 1

2. Midnight Commander  FTP client - connection successful (left - comp, right - FTP)
MC.jpg

среда, 5 октября 2022 г. в 06:40:33 UTC+3, tke...@gmail.com:

vladimir...@gmail.com

unread,
Oct 25, 2022, 2:49:10 PM10/25/22
to weewx-user
Oct 25 21:42:02 pogoda-ubuntu weewx[1056] ERROR weeutil.ftpupload: Failed uploading /var/www/html/weewx/weektempin.png to server web.ru. Reason: 'timed out'
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine: ftpgenerator: (2): caught exception '<class 'socket.timeout'>': timed out
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****  Traceback (most recent call last):
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****    File "/usr/share/weewx/weewx/reportengine.py", line 437, in run
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****      n = ftp_data.run()
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****    File "/usr/share/weewx/weeutil/ftpupload.py", line 220, in run
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****      ftp_server.storbinary(stor_cmd, fd)
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 486, in storbinary
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****      conn = self.transfercmd(cmd, rest)
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 385, in transfercmd
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****      return self.ntransfercmd(cmd, rest)[0]
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 348, in ntransfercmd
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****      resp = self.sendcmd(cmd)
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 253, in sendcmd
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****      return self.getresp()
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 219, in getresp
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****      resp = self.getmultiline()
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 205, in getmultiline
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****      line = self.getline()
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/ftplib.py", line 190, in getline
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****      line = self.file.readline(self.maxline + 1)
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****    File "/usr/lib/python2.7/socket.py", line 480, in readline
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****      data = self._sock.recv(self._rbufsize)
Oct 25 21:42:22 pogoda-ubuntu weewx[1056] ERROR weewx.reportengine:         ****  timeout: timed out

среда, 5 октября 2022 г. в 06:40:33 UTC+3, tke...@gmail.com:
1. How about some more details? In particular, could we see the [[FTP]] section of weewx.conf? Be sure to obfuscate any sensitive materials, such as text.

Tom Keffer

unread,
Oct 25, 2022, 8:55:49 PM10/25/22
to weewx...@googlegroups.com
I am unable to debug your FTP because the connection is consistently refused. I'm not sure, but with a server in Germany, but a Russian domain, you may have gotten caught up in the Ukraine conflict. 



vladimir...@gmail.com

unread,
Oct 26, 2022, 11:49:32 AM10/26/22
to weewx-user
Midnight Commander installed on the system connects perfectly to the FTP server


среда, 26 октября 2022 г. в 03:55:49 UTC+3, tke...@gmail.com:

vladimir...@gmail.com

unread,
Oct 26, 2022, 12:40:50 PM10/26/22
to weewx-user
Im deleted folder on ftp server /html_public
everything work!

среда, 26 октября 2022 г. в 03:55:49 UTC+3, tke...@gmail.com:
I am unable to debug your FTP because the connection is consistently refused. I'm not sure, but with a server in Germany, but a Russian domain, you may have gotten caught up in the Ukraine conflict. 


Reply all
Reply to author
Forward
0 new messages