Welcome to the Cumulus Support forum.
Latest Cumulus MX V4 release
4.4.2 (build 4085) - 12 March 2025
Latest Cumulus MX V3 release
3.28.6 (build 3283) - 21 March 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
If you are posting a new Topic about an error or if you need help PLEASE read this first viewtopic.php?p=164080#p164080
Topics about the Beta trials up to Build 3043, the last build by Cumulus's founder Steve Loft. It was by this time way out of Beta but Steve wanted to keep it that way until he made a decision on his and Cumulus's future.
Moderator: mcrossley
rogerthn
Posts: 549 Joined: Thu 11 Apr 2013 6:31 pm
Weather Station: Ecowitt GW1000/GW1003
Operating System: Raspberry Pi OS bullseye aarch64
Location: Trollhättan Sweden
Contact:
Post
by rogerthn » Thu 05 May 2016 6:42 am
cp -v /home/cumulus/CumulusMX/Reports/NOAAMO$(date --date="1 days ago" +%m%d).txt /var/www/NOAA-reports > /tmp/NOAA-reports.log 2>&1
richard_newberry wrote: No nothing is in /tmp/NOAA-reports.log it's like it doesn't execute in cron under user cumulus
but If I do it when I login as cumulus and put the command in without @daily it works but in the /tmp/NOAA-reports.log it's got weird characters in it as shown in the post previous.
Try
as pi and add
Code: Select all
1 2 * * * cp -v /home/cumulus/CumulusMX/Reports/NOAAMO$(date --date="1 days ago" +%m%y).txt /var/www/NOAA-reports > /tmp/NOAA-reports.log 2>&1
This should copy the file at 1 minute past 2 (AM) every day, change 2 to whatever to copy at a different time.
i.e. if cron is running, check with
richard_newberry
Posts: 500 Joined: Tue 12 Apr 2011 10:23 pm
Weather Station: Watson W-8186
Operating System: Raspbian Bookworm & Debian 12
Location: Leicester
Contact:
Post
by richard_newberry » Fri 06 May 2016 4:47 pm
Still didnt execute. Hmmm
rogerthn
Posts: 549 Joined: Thu 11 Apr 2013 6:31 pm
Weather Station: Ecowitt GW1000/GW1003
Operating System: Raspberry Pi OS bullseye aarch64
Location: Trollhättan Sweden
Contact:
Post
by rogerthn » Fri 06 May 2016 5:55 pm
richard_newberry
Posts: 500 Joined: Tue 12 Apr 2011 10:23 pm
Weather Station: Watson W-8186
Operating System: Raspbian Bookworm & Debian 12
Location: Leicester
Contact:
Post
by richard_newberry » Fri 06 May 2016 10:34 pm
cumulus@debian:~$ /etc/init.d/cron status
● cron.service - Regular background program processing daemon
Loaded: loaded (/lib/systemd/system/cron.service; enabled)
Active: active (running) since Wed 2016-05-04 22:22:02 BST; 2 days ago
Docs: man:cron(8)
Main PID: 17634 (cron)
CGroup: /system.slice/cron.service
├─ 1017 ./eggdrop BanditBot.conf
├─ 8998 /usr/bin/atop -a -w /var/log/atop/atop_20160506 600
└─17634 /usr/sbin/cron -f
All it says
I will see if it works under root.
rogerthn
Posts: 549 Joined: Thu 11 Apr 2013 6:31 pm
Weather Station: Ecowitt GW1000/GW1003
Operating System: Raspberry Pi OS bullseye aarch64
Location: Trollhättan Sweden
Contact:
Post
by rogerthn » Sat 07 May 2016 6:33 am
Even if "my" command was
sudo /etc/init.d/cron status
this is
Strange
Do you get an update of /tmp/date.log once every minute with a line as below added with crontab -e?
Code: Select all
* * * * * echo $(date) > /tmp/date.log 2>&1
richard_newberry
Posts: 500 Joined: Tue 12 Apr 2011 10:23 pm
Weather Station: Watson W-8186
Operating System: Raspbian Bookworm & Debian 12
Location: Leicester
Contact:
Post
by richard_newberry » Sat 07 May 2016 1:49 pm
That works date.log is in /tmp every minute.
richard_newberry
Posts: 500 Joined: Tue 12 Apr 2011 10:23 pm
Weather Station: Watson W-8186
Operating System: Raspbian Bookworm & Debian 12
Location: Leicester
Contact:
Post
by richard_newberry » Sat 07 May 2016 2:03 pm
cp -v /home/cumulus/CumulusMX/Reports/NOAAMO$(date --date="1 days ago" +%m%y).txt /var/www/NOAA-reports > /tmp/NOAA-reports.log 2>&1
error message: cp: target ‘+’ is not a directory
rogerthn
Posts: 549 Joined: Thu 11 Apr 2013 6:31 pm
Weather Station: Ecowitt GW1000/GW1003
Operating System: Raspberry Pi OS bullseye aarch64
Location: Trollhättan Sweden
Contact:
Post
by rogerthn » Sat 07 May 2016 6:59 pm
WTH
Can you please show the result from
Code: Select all
echo /home/cumulus/CumulusMX/Reports/NOAAMO$(date --date="1 days ago" +%m%y).txt
AND
richard_newberry
Posts: 500 Joined: Tue 12 Apr 2011 10:23 pm
Weather Station: Watson W-8186
Operating System: Raspbian Bookworm & Debian 12
Location: Leicester
Contact:
Post
by richard_newberry » Mon 09 May 2016 7:25 am
echo /home/cumulus/CumulusMX/Reports/NOAAMO$(date --date="1 days ago" +%m%y).txt
/home/cumulus/CumulusMX/Reports/NOAAMO0516.txt
ls /var/www/NOAA-reports
NOAAMO0116.txt NOAAMO0216.txt NOAAMO0316.txt NOAAMO0416.txt NOAAMO0516.txt NOAAYR2016.txt
crontab -l
10 0 * * * cp -v /home/cumulus/CumulusMX/Reports/NOAAMO$(date --date="1 days ago") +%m%y).txt /var/www/NOAA-reports > /tmp/NOAA-reports.log 2>&1
mcrossley
Posts: 14388 Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:
Post
by mcrossley » Mon 09 May 2016 9:07 am
doesn't the cron entry need to be a shell script so the date substitution works?
richard_newberry
Posts: 500 Joined: Tue 12 Apr 2011 10:23 pm
Weather Station: Watson W-8186
Operating System: Raspbian Bookworm & Debian 12
Location: Leicester
Contact:
Post
by richard_newberry » Mon 09 May 2016 1:46 pm
mcrossley wrote: doesn't the cron entry need to be a shell script so the date substitution works?
What do you suggest the script should be
freddie
Posts: 2870 Joined: Wed 08 Jun 2011 11:19 am
Weather Station: Davis Vantage Pro 2 + Ecowitt
Operating System: GNU/Linux Ubuntu 24.04 LXC
Location: Alcaston, Shropshire, UK
Contact:
Post
by freddie » Mon 09 May 2016 2:11 pm
richard_newberry wrote: mcrossley wrote: doesn't the cron entry need to be a shell script so the date substitution works?
What do you suggest the script should be
Code: Select all
#!/bin/sh
cp -v /home/cumulus/CumulusMX/Reports/NOAAMO$(date --date="1 days ago") +%m%y).txt /var/www/NOAA-reports
Freddie
rogerthn
Posts: 549 Joined: Thu 11 Apr 2013 6:31 pm
Weather Station: Ecowitt GW1000/GW1003
Operating System: Raspberry Pi OS bullseye aarch64
Location: Trollhättan Sweden
Contact:
Post
by rogerthn » Mon 09 May 2016 6:26 pm
richard_newberry wrote: echo /home/cumulus/CumulusMX/Reports/NOAAMO$(date --date="1 days ago" +%m%y).txt
/home/cumulus/CumulusMX/Reports/NOAAMO0516.txt
ls /var/www/NOAA-reports
NOAAMO0116.txt NOAAMO0216.txt NOAAMO0316.txt NOAAMO0416.txt NOAAMO0516.txt NOAAYR2016.txt
crontab -l
10 0 * * * cp -v /home/cumulus/CumulusMX/Reports/NOAAMO$(date --date="1 days ago") +%m%y).txt /var/www/NOAA-reports > /tmp/NOAA-reports.log 2>&1
There seems to be an extra ) in crontab, one after "1 days ago" and one after +%m%y
Try to remove the first?
rogerthn
Posts: 549 Joined: Thu 11 Apr 2013 6:31 pm
Weather Station: Ecowitt GW1000/GW1003
Operating System: Raspberry Pi OS bullseye aarch64
Location: Trollhättan Sweden
Contact:
Post
by rogerthn » Mon 09 May 2016 6:55 pm
The extra ) is not all
Try as below
Code: Select all
10 0 * * * cp -v /home/cumulus/CumulusMX/Reports/NOAAMO$(date --date="1 days ago" +"\%m\%y").txt /var/www/NOAA-reports > /tmp/NOAA-reports.log 2>&1