Windows Server 2003
--
Questions
--
Followers
Top Experts
What i want to happen is if a customer sends a message to a specific e-mail address, the person sending the message will get back, right away, a generic message as an acknowledgment  "We have received your message and will get back with you ASAP"  or something to that effect.
The links i found were confusing. Â Can someone point me in the right direction?
Using Sendmail 8.12.11 Â Redhat Linux Enterprise.
Zero AI Policy
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.
chmod +x /tmp/auto.sh
require "vacation";
vacation
:subject "Hello from autoresponder"
  "Welcome";






EARN REWARDS FOR ASKING, ANSWERING, AND MORE.
Earn free swag for participating on the platform.
1.  while tailing the logfile:    Sep  9 09:05:04 mail sendmail[20467]: o89D541O020467: from=<user@domain.com>, size=13762, class=0, nrcpts=1, msgid=<49D275F1-AA0A-4D74-
Sep  9 09:05:04 mail sendmail[20468]: o89D541O020467: to=/temp/auto.sh, ctladdr=<autotest@domain.c
Sep  9 09:05:04 mail sendmail[20468]: o89D541O020467: o89D541O020468: DSN: Can't create output
Â
2. Â message back to my mail client: Â Â Â ----- The following addresses had permanent fatal errors -----
/temp/auto.sh
  (reason: Can't create output)
  (expanded from: <autotest@domain.com>)
 ----- Transcript of session follows -----
550 5.0.0 /temp/auto.sh... Can't create output
Reporting-MTA: dns; mail.domain.com
Received-From-MTA: DNS; pix525-domain.com
Arrival-Date: Thu, 9 Sep 2010 09:05:04 -0400
Final-Recipient: RFC822; autotest@domain.com
X-Actual-Recipient: X-Unix; /temp/auto.sh
Action: failed
Status: 5.3.0
Diagnostic-Code: X-Unix; 73
Last-Attempt-Date: Thu, 9 Sep 2010 09:05:04 -0400
I think i may not understand your step 2 "Creating a Script". Â Thanks
info: |/tmp/auto.sh
Probably your aliases line looks like:
info: /tmp/auto.sh

Get a FREE t-shirt when you ask your first question.
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.
Sep 13 08:31:00 mail sendmail[12457]: o8DCV0fm012457: from=<user@somedomain.com>
Sep 13 08:31:00 mail smrsh: uid 8: attempt to use "auto.sh" (stat failed)
Sep 13 08:31:00 mail sendmail[12458]: o8DCV0fm012457: to=|/temp/auto.sh, ctladdr=<autotest@domain.c
Sep 13 08:31:00 mail sendmail[12458]: o8DCV0fm012457: o8DCV0fm012458: DSN: Service unavailable
2) Try to disable selinux temporary (setenforce 0). If 1) doesn't work.
Regards,
Arty






EARN REWARDS FOR ASKING, ANSWERING, AND MORE.
Earn free swag for participating on the platform.
I have no /etc/selinux file
I tried to run the command setenforce 0... Â Command not found
I also checked the bootloader  /boot/grub  to try to find the grub.conf file....no file there either.
Any other suggestions?
Sep 13 09:48:46 mail sendmail[14063]: o8DDmkx5014062: to=|/etc/smrsh/auto.sh, ctladdr=<autotest@domain.c
Sep 13 09:48:46 mail sendmail[14063]: o8DDmkx5014062: o8DDmkx5014063: DSN: unknown mailer error 127
I moved the auto.sh and the care.txt file into the directory you suggested. Â Here are the contents of the files.
care.txt: Â Â (it just accured to me that i should probably remove the --[cut}--)
--[cut]--
From: info <autotest@grid4.com>
Subject: this is autoresponder message
Welcome.
--[cut]--
auto.sh:  (I only have the word  "attached"  in this file.)
attached  Â
Â
Also can you repost a shell script.

Get a FREE t-shirt when you ask your first question.
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.
Repost a shell script...??
I guess the problem is here: ctladdr=<autotest@domain.c
Most probably your server has a fake hostname (either not in DNS or just non existing). And sendmail is unable to resolve it. Please check your /etc/mail/sendmail.cf for a line starting with DS<servername here>, if there is 'localhost' or something like - it's a fake name, you should change it to real domain name, then restart sendmail.
Regards,
Arty
Here is the content of the Alias File in /etc/alias:
autotest: Â Â Â |/etc/smrsh/auto.sh
Here is the content of the /etc/smrsh/auto.sh file:
#!/bin/bash
MESSAGE=/etc/smrsh/care.tx
FROM=autotest@domain.com
# our stdin is sender's message with headers
while read line
do
 # we should extract return path only
 case $line in
  ( Return-Path:* )
    # TO is a variable to keep return path
    TO=${line##Return-Path: }
    break
    ;;
 esac
done
# Some checks to avoid mail loops:
# skip empty <>, my own, postmaster and MAIER-DAEMON addresses
case $TO in
 ( *$FROM* | '<>' | *MAILER* | *DAEMON* | *DELIVERY* )
  exit 0
  ;;
esac
# Now compose new message and send it to TO
(echo To: $TO; cat $MESSAGE) | /usr/sbin/sendmail -t -f $FROM
Here is the content of the care.txt file in /etc/smrsh/care.txt:
From: info <autotest@grid4.com>
Subject: this is autoresponder message
Welcome.
Here is the message that i see when I tail the logfile on the server:
Sep 14 08:54:18 mail sendmail[29457]: AUTH=server, relay=pix525-domain.com [208.x.x.x], authid=<sender>, mech=PLAIN, bits=0
Sep 14 08:54:19 mail sendmail[29457]: o8ECsIrW029457: from=<user@someother.com>,
Sep 14 08:54:19 mail sendmail[29462]: o8ECsJs3029462: Authentication-Warning: mail.domain.com: mail set sender to autotest@domain.com using -f
Sep 14 08:54:19 mail sendmail[29462]: o8ECsJs3029462: from=autotest@domain.com, size=87, class=0, nrcpts=0, msgid=<201009141254.o8ECsJ
Sep 14 08:54:19 mail sendmail[29458]: o8ECsIrW029457: to=|/etc/smrsh/auto.sh, ctladdr=<autotest@domain.c
it appears that the message was sent, but i did not receive a message in my inbox.






EARN REWARDS FOR ASKING, ANSWERING, AND MORE.
Earn free swag for participating on the platform.
I had checked the autoresponder before initial post. If it doesn't work for you - you are doing something wrong.
Without complete non-modified logs it's hard to guess what is going wrong.
Regards,
Arty
(echo To: $TO; cat $MESSAGE) | tee /tmp/message.$$ | /usr/sbin/sendmail -t -f $FROM
Then see what is in that file after testing. Then try to send this file manually with 'cat /tmp/message.??? sendmail -t -f autotest@domain.com' (just change ??? to real number).
And provide logs of manual sending too.
Regards,
Arty

Get a FREE t-shirt when you ask your first question.
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.
Windows Server 2003
--
Questions
--
Followers
Top Experts
Windows Server 2003 was based on Windows XP and was released in four editions: Web, Standard, Enterprise and Datacenter. It also had derivative versions for clusters, storage and Microsoft’s Small Business Server. Important upgrades included integrating Internet Information Services (IIS), improvements to Active Directory (AD) and Group Policy (GP), and the migration to Automated System Recovery (ASR).