Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

exim: unrecognized service

Discussion in 'E-mail Discussion' started by burgerkill, Mar 19, 2014.

  1. burgerkill

    burgerkill Member

    Joined:
    Nov 14, 2012
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    hello cPanel
    please advise why I cannot find exim command on my cpanel server

    Code:
    root@will [~]# /etc/init.d/exim restart
    -bash: /etc/init.d/exim: No such file or directory
    Code:
    root@will [~]# service exim restart
    exim: unrecognized service
    Code:
    root@will [~]# locate exim | more
    /etc/antivirus.exim
    /etc/cpanel_exim_system_filter
    /etc/exim
    /etc/exim.aclspam
    /etc/exim.conf
    /etc/exim.conf.dist
    /etc/exim.conf.localopts
    /etc/exim.conf.mailman2.dist
    /etc/exim.conf.mailman2.exiscan.dist
    /etc/exim.crt
    /etc/exim.key
    /etc/exim.pl
    /etc/exim.pl.local
    /etc/exim_trusted_configs
    /etc/eximrejects
    /etc/chkserv.d/exim
    /etc/exim/perl
    /etc/exim/perl/Digest
    /etc/exim/perl/Digest/Perl
    /etc/logrotate.d/exim
    /etc/pam.d/exim
    /etc/rc.d/rc0.d/K30exim
    /etc/rc.d/rc1.d/K30exim
    /etc/rc.d/rc2.d/S80exim
    /etc/rc.d/rc3.d/S80exim
    /etc/rc.d/rc4.d/S80exim
    /etc/rc.d/rc5.d/S80exim
    /etc/rc.d/rc6.d/K30exim
    
    but exim still can running well and can only be restarted via WHM
    Code:
    root@will [/etc/init.d]# netstat -ntlp | grep exim
    tcp        0      0 0.0.0.0:25                  0.0.0.0:*                   LISTEN      25313/exim
    tcp        0      0 0.0.0.0:587                 0.0.0.0:*                   LISTEN      25313/exim
    tcp        0      0 0.0.0.0:465                 0.0.0.0:*                   LISTEN      25313/exim
    tcp        0      0 :::25                       :::*                        LISTEN      25313/exim
    tcp        0      0 :::587                      :::*                        LISTEN      25313/exim
    tcp        0      0 :::465                      :::*                        LISTEN      25313/exim
    
    whether the possibility of a hack? please help to fix my exim. thx
     
  2. dalem

    dalem Well-Known Member
    PartnerNOC

    Joined:
    Oct 24, 2003
    Messages:
    2,741
    Likes Received:
    76
    Trophy Points:
    203
    Location:
    SLC
    cPanel Access Level:
    DataCenter Provider
    /etc/init.d/exim

    Code:
    #!/bin/sh
    #
    # exim          This shell script takes care of starting and stopping
    #               exim.
    #
    # chkconfig: 2345 80 30
    # description: Exim is a Mail Transport Agent, which is the program \
    #              that moves mail from one machine to another.
    # processname: exim
    # config: /etc/exim.conf
    # pidfile: /var/run/exim.pid
    
    # RedHat or Suse?
    if [ -e "/etc/SuSE-release" ]; then
        SUSE=1
        DAEMONIZE=''
        RESULT='done'
    else
        REDHAT=1
        DAEMONIZE='daemon'
        RESULT=''
    fi
    
    if [ -x "/usr/local/cpanel/3rdparty/bin/clamd" ]; then
        CLAMD=/usr/local/cpanel/3rdparty/bin/clamd
    else
        CLAMD=/usr/sbin/clamd
    fi
    
    if [ "$REDHAT" = "1" ]; then
        # Source function library.
        if [ -e "/etc/init.d/functions" ]; then
            . /etc/init.d/functions
        else
            if [ -e "/etc/rc.d/init.d/functions" ]; then
            . /etc/rc.d/init.d/functions
            fi
        fi
    
        # Source networking configuration
        if [ -f /etc/sysconfig/network ]; then
            . /etc/sysconfig/network
        fi
    
        # Networking check is different for SuSE so moved check here
        # Check that networking is up for Red Hat
        [ ${NETWORKING} = "no" ] && exit 0
    fi
    
    if [ "$SUSE" = "1" ]; then
        # Source rc status functions
        . /etc/rc.status
    
        # Source networking functions
        #. /etc/sysconfig/network/scripts/functions
    
    fi
    
    
    
    
    DAEMON=yes
    QUEUE=1h
    
    # Source exim configureation.
    if [ -f /etc/sysconfig/exim ] ; then
        . /etc/sysconfig/exim
    fi
    
    LANG=C
    export LANG
    
    
    [ -f /usr/sbin/exim ] || exit 0
    
    # See how we were called.
    case "$1" in
      start)
        # Start daemons.
    
        # EXIM
        if [ ! -e "/etc/eximdisable" ]; then
            if [ -x "$CLAMD" -a ! -e "/etc/clamddisable" ]; then
                echo -n "Starting clamd: "
                    rm -f /var/clamd
                    $DAEMONIZE $CLAMD
                echo
            fi
            if [ -e "/etc/exim_outgoing.conf" ]; then
                echo -n "Starting exim: "
                TMPDIR=/tmp $DAEMONIZE /usr/sbin/exim $([ "$DAEMON" = yes ] && echo -bd)
                echo $RESULT
                echo -n "Starting exim-outgoing: "
                        TMPDIR=/tmp $DAEMONIZE /usr/sbin/exim $([ "$DAEMON" = yes ] && echo -C) \
                                          $(echo /etc/exim_outgoing.conf) \
                                          $([ -n "$QUEUE" ] && echo -q$QUEUE)
                echo $RESULT
            else
                echo -n "Starting exim: "
                TMPDIR=/tmp $DAEMONIZE /usr/sbin/exim $([ "$DAEMON" = yes ] && echo -bd) \
                                              $([ -n "$QUEUE" ] && echo -q$QUEUE)
                echo $RESULT
            fi
            /scripts/ckillall -9 antirelayd
            if [ ! -e "/etc/antirelayddisable" ]; then
                if [ ! -e "/usr/local/cpanel/libexec/tailwatchd" ]; then
                    echo -n "Starting antirelayd: "
                    $DAEMONIZE /usr/sbin/antirelayd
                    echo $RESULT
                fi
            fi
        fi
    
        # SPAMD
        if [ -x "/usr/local/cpanel/etc/init/startspamd" ]; then
            /usr/local/cpanel/etc/init/startspamd
        elif [ -x "/scripts/restartsrv_spamd" ]; then
            /scripts/restartsrv_spamd
        else
            if [ ! -e "/etc/spamdisable" ]; then
                if [ -e "/etc/cpspamd.conf" ]; then
                    . /etc/cpspamd.conf
                fi
                if [ -x "/usr/bin/spamd" ]; then
                    echo -n "Starting spamd: "
                    $DAEMONIZE /usr/bin/spamd -d ${local+"--local"} --allowed-ips=${allowedips-127.0.0.1} \
                      ${timeouttcp+"--timeout-tcp="}${timeouttcp} ${timeoutchild+"--timeout-child="}${timeoutchild} \
                      --pidfile=${pidfile-"/var/run/spamd.pid"} --max-children=${maxchildren=5} \
                      ${maxconnperchild+"--max-conn-per-child="}${maxconnperchild} \
                      ${maxspare+"--max-spare="}${maxspare}
                    echo $RESULT
                fi
            fi
        fi
        touch /var/lock/subsys/exim
        ;;
      stop)
        # Stop daemons.
        if [ -x "$CLAMD" ]; then
            [ ! -e "/etc/clamddisable" ] && echo -n "Shutting down clamd: "
            killproc clamd
            [ ! -e "/etc/clamddisable" ] && echo $RESULT
        fi
        echo -n "Shutting down exim: "
        killproc exim
        echo $RESULT
        if [ ! -e "/etc/antirelayddisable" ]; then
            if [ ! -e "/usr/local/cpanel/libexec/tailwatchd" ]; then
                echo -n "Shutting down antirelayd: "
                killproc antirelayd
                /scripts/ckillall -9 antirelayd
                echo $RESULT
            fi
        fi
        echo -n "Shutting down spamd: "
        killproc spamd
        echo $RESULT
        rm -f /var/lock/subsys/exim
        ;;
      restart)
        $0 stop
        $0 start
        ;;
      status)
        if [ "$SUSE" = "1" ]; then
            echo -n exim
            rc_status -v
        else
            status exim
        fi
        ;;
      *)
        echo "Usage: exim {start|stop|restart|status}"
        exit 1
    esac
    
    exit 0
    
    
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,802
    Likes Received:
    1,896
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello :)

    Does cPanel attempt to install Exim when using the "/usr/local/cpanel/scripts/check_cpanel_rpms" command?

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. burgerkill

    burgerkill Member

    Joined:
    Nov 14, 2012
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator

    wow!!!
    My problem now has been resolved. many thanks michael :D
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice