[ILUG] Debian crontab

john Moylan john at nuatech.net
Thu Aug 7 11:16:43 IST 2008


Can you send mail from the command line on the debian boxes. If you can then
your local MTA is working

#> echo "test" | mail -s "test email" youraddress at example.com


If you can then add the address you want crontab mails to go to to your
crontab

eg:
MAILTO=youraddress:example.com

John

2008/8/6 Brian O'Mahony <brian.omahony at curamsoftware.com>

> Im actually still not getting the mails from the crontabs. I assume this is
> something to do with my changed uid - any idea how to resolve it?
>
> -----Original Message-----
> From: Gareth Eason [mailto:bigbro at skynet.ie]
> Sent: 06 August 2008 12:10
> To: Brian O'Mahony
> Cc: iLug Users Group
> Subject: Re: [ILUG] Debian crontab
>
> Brian O'Mahony wrote:
> > Right. Im a bit screwed here then.
> >
> > Firstly - its debian, not ubuntu, but that's probably moot.
> >
> > I set the server up Wed 23. The user I created was bomhony. Set up the
> crontabs etc.
> >
> > I then changed the passwd file to a copy of the server this will
> eventually be replacing. This meant that my account, bomahony was changed.
> When I now looked in the /var/mail folder, the bomahony file was there, but
> the permissions were billy:mail. Billy is account uid 1000. So then I went
> and tried to send a mail from bomahony to root, and got Cc: exim: failed to
> find gid for group name "Debian-exim".
> >
> > So Debian-exim user and group were missing from the passwd and group
> files (as these had been copied).
> >
> > So now once that's fixed, when I send mail from bomahony to root, it gets
> sent to bomahony.....
> >
> > So basically, the mail is now working, but I would rather it went to the
> root address. Any ideas where to change this?
> [snip]
>
>        Typically, you might want to set up an alias is /etc/aliases  (and
> run the
> newaliases command once you've saved the file.) I typically have, on Debian
> and Ubuntu servers, something like the following in my /etc/aliases file:
> ---------- 8< ----------
> root: eason
> postmaster: eason
> eason: gareth.eason at my.real.address.com
> ---------- >8 ----------
>
>        This is only one of many places to change mail routing on a UNIX
> system,
> depending on how your mail system is set up. Since this is a rather common
> requirement when setting up machines, I suggest you pick a single place for
> configuring mail routing (e.g. /etc/aliases file) and configure it
> consistently across all your servers. Otherwise it becomes a pain to try
> and
> remember where root's mail is configured on a server later on.
>
>        Best regards,
>        -->Gar
>
>
>
>
>
>
> The information in this email is confidential and may be legally
> privileged.
> It is intended solely for the addressee. Access to this email by anyone
> else
> is unauthorized. If you are not the intended recipient, any disclosure,
> copying, distribution or any action taken or omitted to be taken in
> reliance
> on it, is prohibited and may be unlawful. If you are not the intended
> addressee please contact the sender and dispose of this e-mail. Thank you.
>
> --
> Irish Linux Users' Group mailing list
> About this list : http://mail.linux.ie/mailman/listinfo/ilug
> Who we are : http://www.linux.ie/
> Where we are : http://www.linux.ie/map/
>



More information about the ILUG mailing list