Re: Cron Daemon backup message too big



Someone kindly communicated to me privately, and I realized that I was
not being sufficiently complete regarding my problem.

In my backup script, I have the line:

find / -print | egrep -v "^/media|... " 2>&1 | cat -vt

What this command does is to concatenate stdout + errors and redirect
them to a terminal. This works fine when I call the command # backup.

However, when cron calls it, there's no terminal to which to send the
stdout, and so apparently it is redirected by default to a mail
message.

Could I avoid this by terminating the command line instead like this:

2>&1 /home/brownh/backup.log | cat -vt

Here I clobber the contents of backup.log, which is what I want. Is the
syntax right? Will it avoid sending stdout to a mail message?

My guess is that when I upgraded to etch, cron stdout was redirected by
default to a mail message. That's OK, except in this case it causes
exim4 to complain about the size of the message and terminate the find
command.

--

Haines Brown, KB1GRM





--
To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx
with a subject of "unsubscribe". Trouble? Contact listmaster@xxxxxxxxxxxxxxxx



Relevant Pages

  • Re: Cron Daemon backup message too big
    ... What this command does is to concatenate stdout + errors and redirect ... Could I avoid this by terminating the command line instead like this: ... though you need a redirect to the file too like so: ...
    (Debian-User)
  • Re: Problem with WSH Shell Exec StdOut
    ... catch its StdOut stream in real time. ... NeroCmd.exe is a command line utility included ... Here is the script I'm currently using: ...
    (microsoft.public.scripting.vbscript)
  • Re: Problem with WSH Shell Exec StdOut
    ... catch its StdOut stream in real time. ... then almost immediately I get a command window displaying the following: ... You have to abort the script by ending the ...
    (microsoft.public.scripting.vbscript)
  • Re: Can you duplicate Standard Output WITHOUT tee command?
    ... run where he wanted to catch stdout. ... Yes, this is a difficult command pipe, especially as written it uses ... The last file descriptor operations restore the normal meaning of stdin ...
    (comp.unix.shell)
  • Re: Problem with WSH Shell Exec StdOut
    ... catch its StdOut stream in real time. ... NeroCmd.exe is a command line utility included with or ... Here is the script I'm currently using: ...
    (microsoft.public.scripting.vbscript)