MAILTOemail@example.com 10 12 * * * /usr/local/bin/curator --dry-run --config /home/itadmin/.curator/curator.yml /home/itadmin/.curator/snapshotdaily.yml >> /home/itadmin/.curator/logs.txt 2>&1
By this all the STDOUT and STDERR are going to logs.txt.
Scenario 2 :
If i am using like this :
10 12 * * * /usr/local/bin/curator --config /home/itadmin/.curator/curator.yml /home/itadmin/.curator/snapshotdaily.yml
I am getting mail but not getting stored in logs.txt
What i want is the combination of both 1 and 2: I want my every day logs appeneded to be in logs.txt file for history purpose and also want daily logs to be sent in mail .