Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

cron output to an external email

511 views
Skip to first unread message

Javier Villegas

unread,
Oct 23, 2003, 9:09:38 AM10/23/03
to
Hi

I am using contrab in Solaris 8 for make my Oracle DB Backup and every day I
saw the log in the Solaris Mailbox.

I need to send this log to an Internet email.

Do you know how can I do it ?

Thanks

Javier from Argentina

Barry Margolin

unread,
Oct 23, 2003, 11:03:51 AM10/23/03
to
In article <igQlb.319697$tq.2...@fe12.atl2.webusenet.com>,

Javier Villegas <ma...@impsat1.com.ar> wrote:
>I am using contrab in Solaris 8 for make my Oracle DB Backup and every day I
>saw the log in the Solaris Mailbox.
>
>I need to send this log to an Internet email.
>
>Do you know how can I do it ?

Pipe the command's output to a mail command.

--
Barry Margolin, barry.m...@level3.com
Level(3), Woburn, MA
*** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.

Javier Villegas

unread,
Oct 23, 2003, 11:41:14 AM10/23/03
to
Could you give me an example ?

Thanks


"Barry Margolin" <barry.m...@level3.com> wrote in message
news:r5Slb.182$lK3...@news.level3.com...

Noel R. Nihill

unread,
Oct 23, 2003, 12:30:59 PM10/23/03
to

"Javier Villegas" <ma...@impsat1.com.ar> wrote in message
news:lsSlb.168788$K84....@fe09.atl2.webusenet.com...

Please don't top-post.

> "Barry Margolin" <barry.m...@level3.com> wrote in message
> news:r5Slb.182$lK3...@news.level3.com...
> > In article <igQlb.319697$tq.2...@fe12.atl2.webusenet.com>,
> > Javier Villegas <ma...@impsat1.com.ar> wrote:
> > >I am using contrab in Solaris 8 for make my Oracle DB Backup and every
> day I
> > >saw the log in the Solaris Mailbox.
> > >
> > >I need to send this log to an Internet email.
> > >
> > >Do you know how can I do it ?
> >
> > Pipe the command's output to a mail command.
> >

> Could you give me an example ?

10 3 * * * /home/fatherted/bin/wurfle -z | /bin/mailx -s "Wah!"
som...@foo.bar.net

> Thanks
>
> > --
> > Barry Margolin, barry.m...@level3.com


--
Noel R. Nihill
UNIXŽ platform development
Motorola NSS
I *could* be arguing in my spare time.


Ron Blout

unread,
Nov 11, 2003, 10:41:08 PM11/11/03
to

"Javier Villegas" <ma...@impsat1.com.ar> wrote in message
news:igQlb.319697$tq.2...@fe12.atl2.webusenet.com...

> Hi
>
> I am using contrab in Solaris 8 for make my Oracle DB Backup and every day
I
> saw the log in the Solaris Mailbox.
>
> I need to send this log to an Internet email.
>
> Do you know how can I do it ?

try this: mail xx...@yyyyy.net < "/full_path_to/your_log_file" (leave out
the quotes)
where xxxxx and yyyyy are valid email "parts" and "your_log_file" is the
log you wish to send. Not the "<" redirect symbol.

I do this on a Linux box so it should also work for you.


>
> Thanks
>
> Javier from Argentina
>
>
>


Ron Blout

unread,
Nov 11, 2003, 10:49:56 PM11/11/03
to

"Ron Blout" <nos...@nospam.com> wrote in message
news:oZhsb.24328$9M3....@newsread2.news.atl.earthlink.net...

>
> "Javier Villegas" <ma...@impsat1.com.ar> wrote in message
> news:igQlb.319697$tq.2...@fe12.atl2.webusenet.com...
> > Hi
> >
> > I am using contrab in Solaris 8 for make my Oracle DB Backup and every
day
> I
> > saw the log in the Solaris Mailbox.
> >
> > I need to send this log to an Internet email.
> >
> > Do you know how can I do it ?
>
> try this: mail xx...@yyyyy.net < "/full_path_to/your_log_file" (leave
out
> the quotes)
> where xxxxx and yyyyy are valid email "parts" and "your_log_file" is the
> log you wish to send. Note the "<" redirect symbol.

>
> I do this on a Linux box so it should also work for you.

Also make an entry in a crontab. as root for example do: crontab -e and
put in something like
0 3 * * * /cron_scripts/producer_cron.sh > /dev/null 2>&1
this will cause a file by the name of test.sh conatain the mail
xx...@yyyyy.net < "/full_path_to/your_log_file" to run at 3am.
>
>
> >
> > Thanks
> >
> > Javier from Argentina
> >
> >
> >
>
>


Ron Blout

unread,
Nov 11, 2003, 10:52:35 PM11/11/03
to

"Ron Blout" <nos...@nospam.com> wrote in message
news:E5isb.24339$9M3....@newsread2.news.atl.earthlink.net...

>
> "Ron Blout" <nos...@nospam.com> wrote in message
> news:oZhsb.24328$9M3....@newsread2.news.atl.earthlink.net...
> >
> > "Javier Villegas" <ma...@impsat1.com.ar> wrote in message
> > news:igQlb.319697$tq.2...@fe12.atl2.webusenet.com...
> > > Hi
> > >
> > > I am using contrab in Solaris 8 for make my Oracle DB Backup and every
> day
> > I
> > > saw the log in the Solaris Mailbox.
> > >
> > > I need to send this log to an Internet email.
> > >
> > > Do you know how can I do it ?
> >
> > try this: mail xx...@yyyyy.net < "/full_path_to/your_log_file" (leave
> out
> > the quotes)
> > where xxxxx and yyyyy are valid email "parts" and "your_log_file" is
the
> > log you wish to send. Note the "<" redirect symbol.
> >
> > I do this on a Linux box so it should also work for you.
>
> Also make an entry in a crontab. as root for example do: crontab -e and
> put in something like (ITS GETTING LATE)
> 0 3 * * * /cron_scripts/test.sh > /dev/null 2>&1
> this will cause a file by the name of test.sh containing the entry:

Bit Twister

unread,
Nov 11, 2003, 10:58:45 PM11/11/03
to
On Wed, 12 Nov 2003 03:41:08 GMT, Ron Blout wrote:
>
> "Javier Villegas" <ma...@impsat1.com.ar> wrote in message
> news:igQlb.319697$tq.2...@fe12.atl2.webusenet.com...
>> Hi
>>
>> I am using contrab in Solaris 8 for make my Oracle DB Backup and every day
> I
>> saw the log in the Solaris Mailbox.
>>
>> I need to send this log to an Internet email.
>>
>> Do you know how can I do it ?
>
> try this: mail xx...@yyyyy.net < "/full_path_to/your_log_file" (leave out
> the quotes)
> where xxxxx and yyyyy are valid email "parts" and "your_log_file" is the
> log you wish to send. Not the "<" redirect symbol.

If that does not work try
mailx -s "subject text" xx...@yyyyy.net < /full/ilename_here

kgy...@mailcity.com

unread,
Nov 14, 2003, 4:18:58 PM11/14/03
to
"Javier Villegas" <ma...@impsat1.com.ar> wrote in message news:<igQlb.319697$tq.2...@fe12.atl2.webusenet.com>...
Cerate an .forward file in Oracle DB Backup user's home directory and put
that email address where you need to send this log.

--Jules

Rusty Wright

unread,
Dec 12, 2003, 12:33:25 AM12/12/03
to
Make sure you use the full pathname for mail or mailx, whichever one
you use.
0 new messages