Welcome to the Cumulus Support forum.
Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024
Cumulus MX V4 beta test release 4.0.0 (build 4019) - 03 April 2024
Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)
Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki
Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024
Cumulus MX V4 beta test release 4.0.0 (build 4019) - 03 April 2024
Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)
Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki
External programs
Moderator: mcrossley
- laulau
- Posts: 678
- Joined: Tue 13 Oct 2009 10:52 pm
- Weather Station: WeatherDuino Pro2
- Operating System: Win 7
- Location: Meyenheim, Alsace, FR
- Contact:
External programs
Hi,
I recently upgrade to Cumulus MX 3.2.5 buil3061 and it seem sthat my dayly external program not run as before.
it's a "batch file (.cmd) that calls a ftp command. if i run it manually it does what expected but it fails at rollower !
Could someone help me about this ?
Thanks
I recently upgrade to Cumulus MX 3.2.5 buil3061 and it seem sthat my dayly external program not run as before.
it's a "batch file (.cmd) that calls a ftp command. if i run it manually it does what expected but it fails at rollower !
Could someone help me about this ?
Thanks
-
- Posts: 884
- Joined: Sat 16 Jul 2016 11:59 pm
- Weather Station: Davis VP2+ & GW1000 (Standalone)
- Operating System: Win10 Pro / rPi Buster
- Location: Australia
Re: External programs
Just checked mine since I'm also now on 3062 & it's still working fine.
It's just a file called DayEnd.bat
Not sure how lone I was on 3061, but may have missed the issue if it was present.
Cheers.
It's just a file called DayEnd.bat
Code: Select all
@echo off
echo Waiting a few seconds for End of Day to complete.
ping localhost -n 5 > nul
copy "\\WEATHER-PC\Cumulus\data\dayfile.txt" + "\\WEATHER-PC\CumulusMX\data\dayfile.txt" "\\WEATHER-PC\CumulusMX\Scripts\dayfile-merged.txt" /b /y
cd \cumulusmx
Rem cumulusutils Top10 pwsFWI SysInfo Graphs MapsOn
cumulusutils Top10 pwsFWI SysInfo Graphs
"C:\CumulusMX\scripts\fnr.exe" --cl --dir "C:\CumulusMX\utils" --fileMask "graphs.txt" --find "'Normal', color: 'black'," --replace "'Normal', color: 'lightgray', lineWidth: 12,"
"C:\CumulusMX\scripts\fnr.exe" --cl --dir "C:\CumulusMX\utils" --fileMask "graphs.txt" --find "'Normal', color: 'black'," --replace "'Normal', color: 'lightgray', lineWidth: 12,"
ftp -s:"\\WEATHER-PC\CumulusMX\Scripts\ftp.txt"
Ping localhost -n 5 > nul
CD\
Cheers.
:Now: :Today/Yesterday:
Main Station Davis VP2+ Running Via Win10 Pro.
Secondary Stations, Ecowitt HP2551/GW1000 Via rPi 3 & 4 Running Buster GUI.
:Local Inverell Ecowitt Station: :Remote Ashford Ecowitt Station:
Main Station Davis VP2+ Running Via Win10 Pro.
Secondary Stations, Ecowitt HP2551/GW1000 Via rPi 3 & 4 Running Buster GUI.
:Local Inverell Ecowitt Station: :Remote Ashford Ecowitt Station:
- mcrossley
- Posts: 12765
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: External programs
There have been no (intended!) changes the external program processing since Steve's last build 3043.
- laulau
- Posts: 678
- Joined: Tue 13 Oct 2009 10:52 pm
- Weather Station: WeatherDuino Pro2
- Operating System: Win 7
- Location: Meyenheim, Alsace, FR
- Contact:
Re: External programs
My batch file runs well from the command line but hangs when initiated from CMX external program!
It's the ftp command , the connection is ok but the 'D:\CumulusMX\data\testfile.txt ' hangs !
It's the ftp command , the connection is ok but the 'D:\CumulusMX\data\testfile.txt ' hangs !
- mcrossley
- Posts: 12765
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: External programs
Perhaps if you post the batch file we can take a look and make suggestions?
-
- Posts: 884
- Joined: Sat 16 Jul 2016 11:59 pm
- Weather Station: Davis VP2+ & GW1000 (Standalone)
- Operating System: Win10 Pro / rPi Buster
- Location: Australia
Re: External programs
Just while on external programs, it's unclear when they are precisely run.
Are they executed after all internal processes are completed & all files for the interval updated & closed, or could they be triggered such that the timing of other process overlap if the internal processes & file writes have not completed, particularly on slower machine or big data sets.
I vaguely recall some initial issues with creating my script above, where it bombed as if the dayfile was in use.
As you can see I added some pings for a delay at the beginning & it work fine after that & ever since.
Phil
Are they executed after all internal processes are completed & all files for the interval updated & closed, or could they be triggered such that the timing of other process overlap if the internal processes & file writes have not completed, particularly on slower machine or big data sets.
I vaguely recall some initial issues with creating my script above, where it bombed as if the dayfile was in use.
As you can see I added some pings for a delay at the beginning & it work fine after that & ever since.
Phil
:Now: :Today/Yesterday:
Main Station Davis VP2+ Running Via Win10 Pro.
Secondary Stations, Ecowitt HP2551/GW1000 Via rPi 3 & 4 Running Buster GUI.
:Local Inverell Ecowitt Station: :Remote Ashford Ecowitt Station:
Main Station Davis VP2+ Running Via Win10 Pro.
Secondary Stations, Ecowitt HP2551/GW1000 Via rPi 3 & 4 Running Buster GUI.
:Local Inverell Ecowitt Station: :Remote Ashford Ecowitt Station:
- laulau
- Posts: 678
- Joined: Tue 13 Oct 2009 10:52 pm
- Weather Station: WeatherDuino Pro2
- Operating System: Win 7
- Location: Meyenheim, Alsace, FR
- Contact:
Re: External programs
The batch file colled at rollower(uploadDF.cmd):
dayfileftp.txt:
savec.bat:
('mois' and 'an' variables are updated in CMX extra webfile)
I didn't make any change since a while but for the moment the ftp command hangs at rollower!
Code: Select all
ftp -s:D:\CumulusMX\dayfileftp.txt
call D:\CumulusMX\savec.bat
"C:\Program Files (x86)\GnuWin32\bin\wget" "http://....
Code: Select all
open ftp.laurentmey.fr
login******
passw***
cd /www//meteo
put D:\CumulusMX\data\dayfile.txt
cd /www//domo
put P:\DomoData\domodayfile.txt
quit
Code: Select all
@echo off
set source=D:\CumulusMX\data
set dest=P:\Meteo\CumulusMX\data
set mois=01
set an=20
echo copy %mois%%an%.txt
if %mois%==01 copy "%source%\janv%an%log.txt" "%dest%"
if %mois%==02 copy "%source%\f?vr%an%log.txt" "%dest%"
if %mois%==03 copy "%source%\mars%an%log.txt" "%dest%"
if %mois%==04 copy "%source%\avr%an%log.txt" "%dest%"
if %mois%==05 copy "%source%\mai%an%log.txt" "%dest%"
if %mois%==06 copy "%source%\juin%an%log.txt" "%dest%"
if %mois%==07 copy "%source%\juil%an%log.txt" "%dest%"
if %mois%==08 copy "%source%\ao?t%an%log.txt" "%dest%"
if %mois%==09 copy "%source%\sept%an%log.txt" "%dest%"
if %mois%==10 copy "%source%\oct%an%log.txt" "%dest%"
if %mois%==11 copy "%source%\nov%an%log.txt" "%dest%"
if %mois%==12 copy "%source%\d?c%an%log.txt" "%dest%"
copy "%source%\dayfile.txt" "%dest%"
copy "%source%\*.ini" "%dest%"
I didn't make any change since a while but for the moment the ftp command hangs at rollower!
- mcrossley
- Posts: 12765
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: External programs
Does the "ftp" command require administrator rights?
ftp.exe is on the cmd path?
Otherwise I'm not sure, have you checked in the process list that the FTP command is actually running?
Also try adding a simple command before the FTP, just to make sure the batch file is running. Say something like...
Any reason you aren't just using the CMX extra files facility to do these transfers and copies?
Then you'd just have to do the "wget" in the external program script.
ftp.exe is on the cmd path?
Otherwise I'm not sure, have you checked in the process list that the FTP command is actually running?
Also try adding a simple command before the FTP, just to make sure the batch file is running. Say something like...
Code: Select all
@echo %date% %time% Batch started > D:\CumulusMX\DailyBatchLog.txt
Then you'd just have to do the "wget" in the external program script.
- laulau
- Posts: 678
- Joined: Tue 13 Oct 2009 10:52 pm
- Weather Station: WeatherDuino Pro2
- Operating System: Win 7
- Location: Meyenheim, Alsace, FR
- Contact:
Re: External programs
I'm not sure that external program runs AFTER the CMX extra files facility !?
The point where it hangs: The connection is ok but the ftp put timed out !
The point where it hangs: The connection is ok but the ftp put timed out !
You do not have the required permissions to view the files attached to this post.
- mcrossley
- Posts: 12765
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: External programs
OK, the problem is on the line with response code 425
"Could not open data connection to port 56299"
Your FTP program is opening the control connection to port 21 on the remote host, but the data connection to the dynamic port (56299 in this case) is failing. So you can send commands and get responses but you cannot transfer any data.
No idea why.
"Could not open data connection to port 56299"
Your FTP program is opening the control connection to port 21 on the remote host, but the data connection to the dynamic port (56299 in this case) is failing. So you can send commands and get responses but you cannot transfer any data.
No idea why.
- mcrossley
- Posts: 12765
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: External programs
The Extra files are processed at the end of the EOD process (after external programs) and are uploaded at the next archive interval after the EOD process completes.
- laulau
- Posts: 678
- Joined: Tue 13 Oct 2009 10:52 pm
- Weather Station: WeatherDuino Pro2
- Operating System: Win 7
- Location: Meyenheim, Alsace, FR
- Contact:
Re: External programs
That's why i first upload my dayfile and then use php script to update the remote database.
BTW how do you proceed ?
The strange thing is that it works when i manually execute the batch file.
BTW how do you proceed ?
The strange thing is that it works when i manually execute the batch file.
- mcrossley
- Posts: 12765
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: External programs
Sounds like a permissions thing to me - or firewall.