Sasl Auth Daemon

Discussion in 'Server Operation' started by alexillsley, Jun 11, 2007.

  1. alexillsley

    alexillsley New Member

    ----- expired ----
     
    Last edited: Nov 15, 2010
  2. falko

    falko Super Moderator Howtoforge Staff

    What's in /etc/init.d/saslauthd?
    Which distribution do you use?
     
  3. alexillsley

    alexillsley New Member

    ----- expired ----
     
    Last edited: Nov 15, 2010
  4. falko

    falko Super Moderator Howtoforge Staff

    What's in /etc/default/saslauthd?
     
  5. alexillsley

    alexillsley New Member

    ----- expired ----
     
    Last edited: Nov 15, 2010
  6. falko

    falko Super Moderator Howtoforge Staff

    Please remove the colon at the end of the OPTIONS line.
     
  7. alexillsley

    alexillsley New Member

    Thanks, its fixed now:)
     
  8. dmgeurts

    dmgeurts Member

    saslauth doesn't start

    I have the same issue but no semicolon there. can start manually but not 'automatic'.

    My config files are the same as states as is the saslauthd version. Moans about:

    suzy:/etc/init.d# saslauthd start
    saslauthd[15502] :main : no authentication mechanism specified
    usage: saslauthd [options]

    If I manually specify things it starts fine:
    saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam​

    Djerk
     
  9. falko

    falko Super Moderator Howtoforge Staff

    What's in /etc/default/saslauthd?
     
  10. dmgeurts

    dmgeurts Member

    Code:
    #
    # Settings for saslauthd daemon
    #
    
    # Should saslauthd run automatically on startup? (default: no)
    START=yes
    
    # Which authentication mechanisms should saslauthd use? (default: pam)
    #
    # Available options in this Debian package:
    # getpwent  -- use the getpwent() library function
    # kerberos5 -- use Kerberos 5
    # pam       -- use PAM
    # rimap     -- use a remote IMAP server
    # shadow    -- use the local shadow password file
    # sasldb    -- use the local sasldb database file
    # ldap      -- use LDAP (configuration is in /etc/saslauthd.conf)
    #
    # Only one option may be used at a time. See the saslauthd man page
    # for more information.
    #
    # Example: MECHANISMS="pam"
    MECHANISMS="pam"
    
    # Additional options for this mechanism. (default: none)
    # See the saslauthd man page for information about mech-specific options.
    MECH_OPTIONS=""
    
    # How many saslauthd processes should we run? (default: 5)
    # A value of 0 will fork a new process for each connection.
    THREADS=5
    
    # Other options (default: -c)
    # See the saslauthd man page for information about these options.
    #
    # Example for postfix users: "-c -m /var/spool/postfix/var/run/saslauthd"
    # Note: See /usr/share/doc/sasl2-bin/README.Debian
    OPTIONS="-m /var/spool/postfix/var/run/saslauthd -r -c"
     
  11. falko

    falko Super Moderator Howtoforge Staff

    Looks ok.
    I think the problem is how you started saslauthd. If you are in /etc/init.d, use
    Code:
    [B][COLOR="Red"]./[/COLOR][/B]saslauthd start
    (not saslauthd start), and you can always use
    Code:
    /etc/init.d/saslauthd start
     
  12. dmgeurts

    dmgeurts Member

    Falco,

    Thank you for your ever helpful advice! The following is what I tried. It seems to me that I the script in /etc/init.d doesn't quite work but using /usr/sbin/saslauthd does. Now I'm sure there's a simple explanation but sadly I'm better at IP subnetting than Linux...

    Code:
    suzy:/# ps ax | grep sasl
    12754 ?        Ss     0:00 saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    12755 ?        S      0:00 saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    12756 ?        S      0:00 saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    12757 ?        S      0:00 saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    12758 ?        S      0:00 saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    11897 pts/1    S+     0:00 grep sasl
    suzy:/# /etc/init.d/saslauthd restart
    Stopping :.
    Starting :start-stop-daemon: --start needs --exec or --startas
    Try `start-stop-daemon --help' for more information.
     (already running).
    suzy:/# /etc/init.d/saslauthd stop   
    Stopping :.
    suzy:/# /etc/init.d/saslauthd start  
    Starting :start-stop-daemon: --start needs --exec or --startas
    Try `start-stop-daemon --help' for more information.
     (already running).
    suzy:/# ps ax | grep sasl            
    11985 pts/1    S+     0:00 grep sasl
    suzy:/# /etc/init.d/saslauthd start
    Starting :start-stop-daemon: --start needs --exec or --startas
    Try `start-stop-daemon --help' for more information.
     (already running).
    suzy:/# /etc/init.d/saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    Usage: /etc/init.d/saslauthd {start|stop|restart|reload|force-reload}
         or {start-instance|stop-instance|restart-instance|
             reload-instance|force-reload-instance} <instance name>
    suzy:/# /etc/init.d/saslauthd start -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    Starting :start-stop-daemon: --start needs --exec or --startas
    Try `start-stop-daemon --help' for more information.
     (already running).
    suzy:/# saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam                  
    suzy:/# ps ax | grep sasl
    12078 ?        Ss     0:00 saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    12079 ?        S      0:00 saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    12080 ?        S      0:00 saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    12081 ?        S      0:00 saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    12082 ?        S      0:00 saslauthd -m /var/spool/postfix/var/run/saslauthd -r -c -a pam
    12086 pts/1    S+     0:00 grep sasl
    suzy:/#
    Djerk
     
  13. dmgeurts

    dmgeurts Member

    Found a fix:

    http://article.gmane.org/gmane.linux.debian.devel.bugs.general/289501

    Without modifications, /etc/init.d/saslauthd start will print:

    # /etc/init.d/saslauthd start
    Starting :start-stop-daemon: --start needs --exec or --startas
    Try `start-stop-daemon --help' for more information.

    start-stop-daemon --start --quiet --pidfile /var/run/saslauthd/saslauthd.pid --name --exec
    /usr/sbin/saslauthd --test
    (already running).

    As you can see, --name is not filled.

    After editing the init-script and putting
    NAME=saslauthd
    on top of the file, the process will start just fine.​

    This was what broke saslauth starting up fine. Glad to see it has nothing to do with ispconfig at all. Only appeared after ispconfig upgrade which happened after an apt upgrade...

    Djerk
     

Share This Page