Jamie,
Thank you for your help. I’ve now got automatic replies working using the “Filter Mail” module in Usermin. This does the job, however it’s missing a lot of the features of the standard vacation program that can be called by sendmail. Of particular note is that vacation will not keep autoreplying to the same sender, apparently has some intelligence about not replying to mailing lists, and has a number of variables that can be included in messages. Given the choice, I’d rather use the vacation module if possible.
According to an associate of mine, the .forward file would likely work on the server if I had not chosen the “username@domain.tld” format for my user accounts. Preliminary tests indicate he’s right–I’ve got a test domain setup for mucking around with, and I changed the format of the mailboxes to username.domain, edited the .forward file so it looks like this:
\christest.domain.tld
"|/usr/bin/vacation christest.domain.tld"
And then sent an email to that account. I got a bounce back that contained the following:
----- The following addresses had permanent fatal errors -----
"|/usr/bin/vacation christest.domain.tld"
(expanded from: <christest@domain.tld>)
----- Transcript of session follows -----
550 5.7.1 /home/domain.tld/homes/christest/.forward: line 2: “|/usr/bin/vacation christest.domain.tld”… User christest.domain.tld@mail.ourserveraddress.com doesn’t have a valid shell for mailing to programs
The shell for the user is ‘/dev/null’, the default, which is obviously not valid. For testing purposes, I have changed the test user’s shell to /bin/false and got the following entry in /var/log/maillog:
Jul 27 07:07:23 devel sendmail[852]: l6RE7Jgp000852: from=<itdept@ourserveraddress.com>, size=349, class=0, nrcpts=1, msgid=<46A9FC07.4040906@ourserveraddress.com>, proto=ESMTP, daemon=MSA, relay=S010623748432.vs.shawcable.net [70.71.32.10]
Jul 27 07:07:24 devel sendmail[871]: l6RE7Jgp000852: to=\christest.domain.tld, delay=00:00:01, xdelay=00:00:00, mailer=local, pri=120349, dsn=2.0.0, stat=Sent
Jul 27 07:07:24 devel sendmail[871]: l6RE7Jgp000852: to="|/usr/bin/vacation christest.domain.tld", ctladdr=<christest@domain.tld> (2041/501), delay=00:00:01, xdelay=00:00:00, mailer=prog, pri=120349, dsn=2.0.0, stat=Sent
Almost working, but no autoreply was actually sent. We’re close, very close, but something just isn’t quite right. Not sure what.
Another issue comes up if I give the users a valid shell: they can now FTP to their home dirs, which is something I’d rather they not be able to do.
Do you know of any workaround to this problem with .forward files not being read by sendmail if the user’s account is in the format “username@domain.tld”?
Thanks,
Chris