How to autoreply to mail while you are away
If you wish to autoreply to mail that you receive while away or on vacation, you will need to use the rcvtrip program along with a .maildelivery file. This will work even if you use a mail client such as Thunderbird to POP your mail from the server. The standard Unix method of using the vacation program along with a .forward file does not work with our mail system.
To set up rcvtrip when your home directory is in AFS, do the following after reading the instructions in "man rcvtrip":
- Create a special directory in your afs home directory for the rcvtrip files. For example, cd to your home directory and run the command:
- This is very important: set the access permissions on that directory so that system:friendlyhost has read and write access. You can do this with the command:
fs sa .rcvtrip system:friendlyhost rliwDouble-check that the AFS permissions are correct by running the command: fs la .rcvtrip . You should see output like the following:
Access list for .rcvtrip is Normal rights: system:friendlyhost rliw bovik rlidwkaThe mail system needs to be able to write to a file called "triplog" in this directory. Otherwise it will respond to every single message, instead of remembering which addresses have already been responded to. This also prevents mail loops if you send yourself mail.
- Create a file in your home directory called "tripnote" which will contain the message that people who send mail to you will get in reply. You can use your favorite Unix editor to create this file (e.g. jed tripnote).
- Make an empty triplog file in your .rcvtrip directory. The easiest way to do this is with the command:
- In your home directory, make "triplog" a symbolic link to the file in your rcvtrip directory. The command:
ln -s ~/.rcvtrip/triplog ~/triplogwill do this.
- Make sure that there is breathing room in your AFS quota, since if you get a lot of mail, triplog can get large fast. If you need to raise your quota, you can change it using Jeeves. You check your AFS quota with the command:
fs lq ~
- Put this line in your ~/.maildelivery file:
default - pipe R /usr/local/bin/rcvtrip $(sender)Maildelivery will check UNIX file permissions, rather than AFS permissions, when doing its security check, so make sure that your .maildelivery file and your home directory don't give write permissions to anyone else. You can set the permissions correctly with the commands:
chmod 644 .maildeliveryand
chmod 755 ~
- Before leaving, send a test message, and if you do *not* get a reply back in a reasonable amount of time, or get multiple responses (less than 10 minutes, under normal conditions) contact us ASAP, since a mail forwarding loop from rcvtrip can bring the server to its knees.
- When you come back, remember to remove the write permissions on the .rcvtrip directory:
fs sa .rcvtrip system:friendlyhost noneAnd remove or comment out (with a #) the rcvtrip line in your .maildelivery file.