Please read the posts in the Announcements section about the current status of Cumulus development now that I have retired

Please read this post before posting

Latest Cumulus release v1.9.4 (build 1099) - Nov 28 2014
Latest Cumulus MX release - v3.0.0 build 3043 Jan 20 2017. See this post for download

Struggling with SFTP

Other discussion about creating web sites for Cumulus that doesn't have a specific subforum

Moderators: daj, TNETWeather

User avatar
Toxic17
Posts: 817
Joined: Mon May 19, 2014 10:45 pm
Weather Station: Davis VPro2 Plus
Operating System: Debian 9.5 Stretch
Location: Bangor, NI
Contact:

Re: Struggling with SFTP

Postby Toxic17 » Thu Aug 17, 2017 2:59 pm

meteozusterhof wrote:If I type winscp.exe in the prompt, it opens the GUI of winscp.

So WinSCP appears to be properly installed. It is the scripting part that does not seem to work.


ok instead of using winscp.exe use winscp.com

Code: Select all

winscp.com /script="C:\Cumulus\sftp-cmds.txt" /log="C:\Cumulus\winscp.log" /loglevel=2
Regards Simon

https://www.conligwx.org
https://www.conligwx.org/pws/
https://twitter.com/conligwx
Davis Vantage Pro2+ - CumulusMX v3.0.0 (build 3043) + Saratoga/PWS
Image

User avatar
mcrossley
Posts: 5186
Joined: Thu Jan 07, 2010 9:44 pm
Weather Station: Davis VP2
Operating System: Stretch Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Struggling with SFTP

Postby mcrossley » Thu Aug 17, 2017 4:16 pm

I'd be interested to see the output from the command > dir c:\cumulus\sftp*

meteozusterhof
Posts: 13
Joined: Wed Jul 13, 2011 2:14 pm
Weather Station: WS-4000
Operating System: Windows 7
Location: Leiden, the Netherlands
Contact:

Re: Struggling with SFTP

Postby meteozusterhof » Thu Aug 17, 2017 9:36 pm

If I use winSCP.com instead of .exe in the bat, I get a brief glimpse of a window syaing that a file was not found.
-----
Weatherstation Zusterhof, Leiden, the Netherlands
http://www.meteozusterhof.nl

meteozusterhof
Posts: 13
Joined: Wed Jul 13, 2011 2:14 pm
Weather Station: WS-4000
Operating System: Windows 7
Location: Leiden, the Netherlands
Contact:

Re: Struggling with SFTP

Postby meteozusterhof » Thu Aug 17, 2017 9:39 pm

Mark, that results in:

Code: Select all

C:\Cumulus>dir c:\cumulus\sftp*
 
 Directory of c:\cumulus

08/14/2017  15:09             1,899 sftp-cmds.txt.txt
08/17/2017  23:33                97 sftp.bat
               2 File(s)          1,996 bytes
               0 Dir(s)  38,999,916,544 bytes free
-----
Weatherstation Zusterhof, Leiden, the Netherlands
http://www.meteozusterhof.nl

User avatar
Toxic17
Posts: 817
Joined: Mon May 19, 2014 10:45 pm
Weather Station: Davis VPro2 Plus
Operating System: Debian 9.5 Stretch
Location: Bangor, NI
Contact:

Re: Struggling with SFTP

Postby Toxic17 » Thu Aug 17, 2017 9:55 pm

meteozusterhof wrote:If I use winSCP.com instead of .exe in the bat, I get a brief glimpse of a window syaing that a file was not found.


because it doesnt find sftp-cmds.txt

you have named it sftp-cmds.txt.txt
Regards Simon

https://www.conligwx.org
https://www.conligwx.org/pws/
https://twitter.com/conligwx
Davis Vantage Pro2+ - CumulusMX v3.0.0 (build 3043) + Saratoga/PWS
Image

meteozusterhof
Posts: 13
Joined: Wed Jul 13, 2011 2:14 pm
Weather Station: WS-4000
Operating System: Windows 7
Location: Leiden, the Netherlands
Contact:

Re: Struggling with SFTP

Postby meteozusterhof » Thu Aug 17, 2017 10:34 pm

YAY!!!!!! IT WORKS!

The principle problem appears indeed to have been that I hadn't noticed the redundant .txt.txt

It does now connect, produce a winscp.log, and indeed files are transfered!

For the latter, after looking at the log, I had to solve a few things, more exactly, turns out the lines in the script had to be:

Code: Select all

put "C:\Cumulus\realtime.txt" WWW/weer/realtime.txt
put "C:\Cumulus\web\index.htm" WWW/weer/index.htm


etc...

Thank you all very much for your help!!!!
:D
-----
Weatherstation Zusterhof, Leiden, the Netherlands
http://www.meteozusterhof.nl

User avatar
Toxic17
Posts: 817
Joined: Mon May 19, 2014 10:45 pm
Weather Station: Davis VPro2 Plus
Operating System: Debian 9.5 Stretch
Location: Bangor, NI
Contact:

Re: Struggling with SFTP

Postby Toxic17 » Thu Aug 17, 2017 10:37 pm

glad it worked. you could now turn the logging off totally or lower the debug level. levels are

0 = normal
1 = debug 1
2 = debug 2
Regards Simon

https://www.conligwx.org
https://www.conligwx.org/pws/
https://twitter.com/conligwx
Davis Vantage Pro2+ - CumulusMX v3.0.0 (build 3043) + Saratoga/PWS
Image

User avatar
mcrossley
Posts: 5186
Joined: Thu Jan 07, 2010 9:44 pm
Weather Station: Davis VP2
Operating System: Stretch Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Struggling with SFTP

Postby mcrossley » Fri Aug 18, 2017 8:02 am

Toxic17 wrote:
meteozusterhof wrote:If I use winSCP.com instead of .exe in the bat, I get a brief glimpse of a window syaing that a file was not found.


because it doesnt find sftp-cmds.txt

you have named it sftp-cmds.txt.txt


Thought it might be that!

Altocumulus
Posts: 34
Joined: Sat May 18, 2013 1:58 pm
Weather Station: Davis pro vue+
Operating System: Windows 10 Home
Location: NE Scotland

Re: Struggling with SFTP

Postby Altocumulus » Sun Feb 11, 2018 4:42 pm

Just dropping by to ask a silly question.

Is this script instead of the extra settings in the Files Internet Configuration panel, or as well as?

You may :groan: or :bash: as appropriate :D

User avatar
mcrossley
Posts: 5186
Joined: Thu Jan 07, 2010 9:44 pm
Weather Station: Davis VP2
Operating System: Stretch Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Struggling with SFTP

Postby mcrossley » Mon Feb 12, 2018 7:05 pm

Instead of, and as well as ;) If you your server is using SFTP which Cumulus doesn't support you will have to do the uploads via an external script, the processing is still done by Cumulus.
Last edited by mcrossley on Tue Feb 13, 2018 8:59 am, edited 1 time in total.

Altocumulus
Posts: 34
Joined: Sat May 18, 2013 1:58 pm
Weather Station: Davis pro vue+
Operating System: Windows 10 Home
Location: NE Scotland

Re: Struggling with SFTP

Postby Altocumulus » Tue Feb 13, 2018 8:42 am

Thanks Mark, I'm trying to follow wiki and threads like this one.

winSCP is loaded and I've checked that I can logon to the server correctly. Server requires FTP over TLS Explicit encryption. As of yesterday evening, I hadn't got the script file to work. I have an idea I'll check this morning. The script is written solely in lower case, whilst my viewing of the windows structure on my PC has some upper case characters, the C: drive and capital C for Cumulus - I'm hoping that's all it is.

Altocumulus
Posts: 34
Joined: Sat May 18, 2013 1:58 pm
Weather Station: Davis pro vue+
Operating System: Windows 10 Home
Location: NE Scotland

Re: Struggling with SFTP

Postby Altocumulus » Tue Feb 13, 2018 9:44 am

Altocumulus wrote:Thanks Mark, I'm trying to follow wiki and threads like this one.

winSCP is loaded and I've checked that I can logon to the server correctly. Server requires FTP over TLS Explicit encryption. As of yesterday evening, I hadn't got the script file to work. I have an idea I'll check this morning. The script is written solely in lower case, whilst my viewing of the windows structure on my PC has some upper case characters, the C: drive and capital C for Cumulus - I'm hoping that's all it is.


And it's not that, so back to some further reading!

Altocumulus
Posts: 34
Joined: Sat May 18, 2013 1:58 pm
Weather Station: Davis pro vue+
Operating System: Windows 10 Home
Location: NE Scotland

Re: Struggling with SFTP

Postby Altocumulus » Tue Feb 13, 2018 10:57 am

Altocumulus wrote:
Altocumulus wrote:Thanks Mark, I'm trying to follow wiki and threads like this one.

winSCP is loaded and I've checked that I can logon to the server correctly. Server requires FTP over TLS Explicit encryption. As of yesterday evening, I hadn't got the script file to work. I have an idea I'll check this morning. The script is written solely in lower case, whilst my viewing of the windows structure on my PC has some upper case characters, the C: drive and capital C for Cumulus - I'm hoping that's all it is.


And it's not that, so back to some further reading!


Running manually shows a fleeting view at the console.

Log file suggests connection is made, but soon disconnected.


Return to “Web site - General”

Who is online

Users browsing this forum: Chapel, nitrx and 4 guests