Web Hosting Talk







View Full Version : Sendmail problems


djlightning
05-23-2002, 03:27 PM
I am trying to figure out where to start looking for this problem at being that it could stem from a few different areas.

My server has a few Nuke sites on it and that is what lead me to find this problem in the first place. It is not sending out passwords at all. Further digging lead me to believe that it is not a problem with the CMS. I can send and recieve via outlook, it does catch the email in IMP as well. If I send mail using IMP it says "Message sent successfully. " The email however never gets to the destanation.

Then I started looking at Sendmail and the DNS to see if that may be the case. When I go to etc/rc.d/init.d and try to restart sendmail I get this
[root@localhost init.d]# ./sendmail restart
Shutting down sendmail: FAILED]
Starting sendmail: sendmail: usage: sendmail [ -t ] [ -fsender ] [ -Fname ] [ -bp ] [ -bs ] [ arg ... ] FAILED]
[root@localhost init.d]#

I am allmost willing to bet this is the problem but I dont know if Plesk took over this like it has with a few other things. If this is the problem how do I get it back up??
Then again it could be something not right with the DNS but I do believe that the settings are correct since everything else resolves.

Any clues, ideas or insight would be great.
Thank you

Hostnix
05-23-2002, 03:29 PM
Looks like it's having a problem starting the daemon.

Copy and paste the /etc/init.d/sendmail script here....


:)

djlightning
05-23-2002, 03:39 PM
#!/bin/bash
#
# sendmail This shell script takes care of starting and stopping
# sendmail.
#
# chkconfig: 2345 80 30
# description: Sendmail is a Mail Transport Agent, which is the program \
# that moves mail from one machine to another.
# processname: sendmail
# config: /etc/sendmail.cf
# pidfile: /var/run/sendmail.pid

# Source function library.
. /etc/rc.d/init.d/functions

# Source networking configuration.
. /etc/sysconfig/network

# Source sendmail configureation.
if [ -f /etc/sysconfig/sendmail ] ; then
. /etc/sysconfig/sendmail
else
DAEMON=no
QUEUE=1h
fi

# Check that networking is up.
[ ${NETWORKING} = "no" ] && exit 0

[ -f /usr/sbin/sendmail ] || exit 0

RETVAL=0
prog="sendmail"

start() {
# Start daemons.

echo -n $"Starting $prog: "
/usr/bin/newaliases > /dev/null 2>&1
if test -x /usr/bin/make -a -f /etc/mail/Makefile ; then
make -C /etc/mail -q
else
for i in virtusertable access domaintable mailertable ; do
if [ -f /etc/mail/$i ] ; then
makemap hash /etc/mail/$i < /etc/mail/$i
fi
done
fi
daemon /usr/sbin/sendmail $([ "$DAEMON" = yes ] && echo -bd) \
$([ -n "$QUEUE" ] && echo -q$QUEUE)
RETVAL=$?
echo
[ $RETVAL -eq 0 ] && touch /var/lock/subsys/sendmail
return $RETVAL
}

stop() {
# Stop daemons.
echo -n $"Shutting down $prog: "
killproc sendmail
RETVAL=$?
echo
[ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/sendmail
return $RETVAL
}

# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
restart|reload)
stop
start
RETVAL=$?
;;
condrestart)
if [ -f /var/lock/subsys/sendmail ]; then
stop
start
RETVAL=$?
fi
;;
status)
status sendmail
RETVAL=$?
;;
*)
echo $"Usage: $0 {start|stop|restart|condrestart|status}"
exit 1
esac

exit $RETVAL

Hostnix
05-23-2002, 03:46 PM
Hmm, the script looks good....

Did you remove sendmail as your MTA?

What happens if you run /usr/sbin/sendmail -bd -q1h

?

djlightning
05-23-2002, 04:06 PM
[root@localhost sbin]# ./sendmail -bd -q1h
sendmail: usage: sendmail [ -t ] [ -fsender ] [ -Fname ] [ -bp ] [ -bs ] [ arg ... ]
[root@localhost sbin]#

By the way:
OS: RH7.2
Plesk 2.5

Hostnix
05-23-2002, 04:26 PM
Looks like you're running qmail, which means the default sendmail init script won't work.

To be sure do this:

ls -al /usr/sbin/sendmail

It should point to qmail somewhere.

Good luck. :)

djlightning
05-23-2002, 06:49 PM
Sure enough it lies in /usr/local/psa/qmail/sbin. So how I do I check to see if this qmail is working properly? If this is not the problem it surely must be some DNS issue.

Thanks