LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-02-2014, 01:26 PM   #1
aalger
LQ Newbie
 
Registered: Sep 2014
Location: Prine George, British Columbia Canada
Posts: 11

Rep: Reputation: Disabled
Auto respond to all incoming e-mail messages with a default subject and message


Hi All, I am new to Linux and we are migrating to a new mail system supporting a different domain name. We are using Centos, with sendmail, dovecot and squirrel webmail.

I would like to configure the system to autoreply to all incoming e-mail messages with a default message, mail subject and mail message without having to configure a .forward file or activate anything for each individual user or mailbox - I have reviewed Wing Loon's instructions but don't want to FTP a .forward file for each user.

Can this be done? I see in the Local_auto_respond configuration file a place to setup a default subject and message but have no idea where to just turn on vacaction for all users...

Any help on this is most apreciated

Last edited by aalger; 09-02-2014 at 01:29 PM. Reason: typing errors
 
Old 09-03-2014, 02:02 AM   #3
JohnFluter
LQ Newbie
 
Registered: May 2009
Posts: 6

Rep: Reputation: 0
Forgive me if I'm missing the point, I'm not an IT bod, just a user.

If you delete all users you have sent them on a permanent 'vacation'.

Surely you could set up a 'catchall' for *@myOLDdomain that could respond with the 'vacation' message.

Assuming the user names are of the style user.user@myOLDdomain mail could be copied to user.user@myNEWdomain.
 
Old 09-03-2014, 06:55 AM   #4
antiX-Dave
LQ Newbie
 
Registered: Dec 2013
Distribution: antiX
Posts: 22

Rep: Reputation: Disabled
Make a vacation user with no mail box or login ability.
Add alias in /etc/aliases for each user to vacation user and self.
Add .forward or similar on vacation user.

This way each user receives the original email and the sender receives return message from vacation stating that the company is on vacation.
 
1 members found this post helpful.
Old 09-04-2014, 02:25 PM   #5
aalger
LQ Newbie
 
Registered: Sep 2014
Location: Prine George, British Columbia Canada
Posts: 11

Original Poster
Rep: Reputation: Disabled
Good Suggestion But...

Hi antiX-Dave, Thanks for your post it is very close to the solution I am looking for, however, vacation will only send the
vacation message if the user or an aliase is in the To: or CC: field of the originating message. I can get around this problem by putting the alias in the command that goes in the .forward file. My last questions is can I use multiple aliases in the command

Example of the command I have in my .forward file

"|/usr/bin/vacation -a alias vacation"



the /usr/bin/vacation - being the patch to and program to run

the -a is the switch for an alias that would be in the To: or CC: fields of the originating message

vacation being the user or login name

So I am wondering can I use multiple aliases in the .forward file and if so what is the syntax? do I use multiple -a options
for example:
"|/usr/bin/vacation -a alias -a alias1 vacation", or do I just separate the aliases with a space or comma?

Anyone done this before, or know if I can use the -a option with multiple aliases?

Best Regards - Alan
 
Old 09-05-2014, 06:48 AM   #6
antiX-Dave
LQ Newbie
 
Registered: Dec 2013
Distribution: antiX
Posts: 22

Rep: Reputation: Disabled
Maybe you could post your vacation script so that I may try it with my development server? I can not recall having to do anything for the alias but then, I don't really use the alias file. Rather I use the sender / recipient maps....
 
1 members found this post helpful.
Old 09-05-2014, 06:35 PM   #7
aalger
LQ Newbie
 
Registered: Sep 2014
Location: Prine George, British Columbia Canada
Posts: 11

Original Poster
Rep: Reputation: Disabled
Hi All, I did find out that you can only use 1 entry (alias) with -a option in the forward file through trial and error.

In the end; I ended up implementing Vacation for each virtual user. Originally I was getting an error when trying to su - the user.

But by using the su - -s /bin/bash user to logon as the user to run the VACATION program as the user to get it to work


Thanks for your replies and antiX-Dave taking the time to respond.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
handling incoming messages charlitos Programming 13 04-03-2009 02:48 PM
How to make bitdefender antivirus auto scan incoming mail ginda Linux - Software 1 03-15-2005 10:42 AM
Postfix's default undeliverable mail message objorkum Linux - Networking 0 04-15-2004 10:46 AM
can you sort messages by subject with tin? amphibious Linux - Software 0 12-01-2003 09:31 PM
The subject is smaller than the message adoyee LQ Suggestions & Feedback 2 07-26-2003 06:33 PM


All times are GMT -5. The time now is 09:37 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration