• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 973
  • Last Modified:

Getting vacation to work in Linux

I'm attempting to use vacation, but nothing is working. I've checked serveral other posts and I haven't found one that got it working. Maybe it just doesn't work, but I thought I'd check with the experts.

I am using Linux 2.4.29 Slackware distribution. I don't see a version option for vacation, but doing an ident give me 8.142 2004/11/02 on the vacation.c version.

In the account I want to "vacation", I ran: vacation -i, and it created vacation.db. I created a .vacation.msg file. I created a .forward file:

\ar, "|/usr/bin/vacation"

When I send a message to the ar user, it does save the message in ar's mailbox, but nothing is returned to the user. I see no info in syslog. I don't even know where to start looking.
0
jmarkfoley
Asked:
jmarkfoley
  • 2
  • 2
1 Solution
 
daveWillCommented:
look in /etc/syslog.conf on your mailserver.  There should be a line starting like mail.*  then a file name this is your maillog (/var/log/maillog on my system).  from the command line type "tail -f /you/maillog |grep ar", then in a different console send your test message again.

If this doesn't give you enough info to figure it out, post the output from the command, and I'll translate for you.
0
 
jmarkfoleyAuthor Commented:
Checking maillog showed a group writable .forward complaint, so I removed that group permission and ran it again. This time, I received an error email that said:

   ----- The following addresses had permanent fatal errors -----
"|/usr/bin/vacation"
    (reason: Command line usage error)
    (expanded from: <ar@server.novatec-inc.com>)

You can see my vacation command above. No command arguments. The relavant mailllog entry was:

Aug  3 19:34:41 server vacation[17596]: uid 701: usage: vacation [-a alias] [-C cfpath] [-d] [-f db] [-i] [-j] [-l] [-m msg] [-R returnaddr] [-r interval] [-s sender] [-t time] [-U] [-x] [-z] login

which impiled that I had to specify 'login', so I changed my .forward specification to "|/usr/bin/vacation ar" and that worked!

I'm going to experiment with this a bit. I would like the response to be on every message, but it looks like I can only do -r 1 which is one per day. -r 0 appears to mean once EVER. Any suggestions on this?

Also, I have several aliases for this account, but I don't see from the man page that I can specify more that one. Can I do -a alias1,alias2,alias3? Or: -a alias1 -a alias2 -a alias3? Or should I just do -j? Will -j do what I want?

(Frankly having to say "vacation ar" seem redundant. What other possibility could there be for 'login'?

I'll post my test results, but please give me some feedback on the above. THX
0
 
daveWillCommented:
There are reasons why it you don't want to respond to every message, what whould happen if two people were responding to every message, then one of them sent a message to the other.(I'll give you a hint, it involves a lot of work for the mail server admin)

If you don't care and want to respond any way you can look here: http://www.sns.ias.edu/~jns/wp/2006/01/31/configuring-vacation-mail-with-procmail/
and  replace this line of his procmail recipe:
| formail -rD 8192 vacation.cache
with this
| formail -rD 8192 /dev/null

I'm not sure about the aliases...

Why "vacation ar"?  the reason for this is so you can use vacation in the alias file and similar places- like if you had a generic "permanent" vacation message for deleted accounts.  I don't think it gets a lot of use, but it must have seemed like a good idea when the first wrote it.

0
 
jmarkfoleyAuthor Commented:
Well, I can forego the response to every message thing. Daily will be OK.

What about the alias question and the use of -j?
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now