Virtual Domains and Users Mandriva 2008.1 Problem

Discussion in 'Server Operation' started by wiremeister, Mar 9, 2010.

  1. wiremeister

    wiremeister New Member

    Hello All,

    Have run in to a wall with this tutorial: http://www.howtoforge.com/virtual-users-domains-postfix-courier-mysql-squirrelmail-mandriva2008.1. I can send emails internally in the server (delivered to maildir), but cannot access pop3 or smtp externally. Connections are being refused at 127.0.0.1:10024 for incoming mail, and I cannot connect with a client in any way. The service that is supposed to listen at 10024. Is it Courier, Amavisd, or Dovecot?? One or all do not appear to be running. Postfix is listening to 10025 as it is configured by the HowTo. Any help would be appreciated. Have been running this version for two years with no problems until recently.

    Result of Telnet localhost 25:
    ehlo localhost
    250-mail.(domain).com
    250-PIPELINING
    250-SIZE 10240000
    250-VRFY
    250-ETRN
    250-STARTTLS
    250-AUTH LOGIN PLAIN
    250-AUTH=LOGIN PLAIN
    250-ENHANCEDSTATUSCODES
    250-8BITMIME
    250 DSN
    quit
    221 2.0.0 Bye
    Connection closed by foreign host.

    Result of netstat -tap:

    Active Internet connections (servers and established)
    Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
    tcp 0 0 *:35489 *:* LISTEN -
    tcp 0 0 *:nfs *:* LISTEN -
    tcp 0 0 *:mysql-im *:* LISTEN 4999/mysqlmanager
    tcp 0 0 *:30020 *:* LISTEN 4346/python
    tcp 0 0 mail.(domain).c:10025 *:* LISTEN 9986/master
    tcp 0 0 *:mysql *:* LISTEN 5037/mysqld
    tcp 0 0 *:netbios-ssn *:* LISTEN 4314/smbd
    tcp 0 0 mail.(domain).com:783 *:* LISTEN 5780/spamd.log
    tcp 0 0 *:sunrpc *:* LISTEN 3889/portmap
    tcp 0 0 *:http *:* LISTEN 5412/httpd
    tcp 0 0 *:x11 *:* LISTEN 4143/X
    tcp 0 0 *:81 *:* LISTEN 5088/ispconfig_http
    tcp 0 0 *:53908 *:* LISTEN 5755/rpc.mountd
    tcp 0 0 *:ftp *:* LISTEN 5617/proftpd: (acce
    tcp 0 0 [IP]-Connecti:domain *:* LISTEN 5592/named
    tcp 0 0 mail.(domain).:domain *:* LISTEN 5592/named
    tcp 0 0 *:39799 *:* LISTEN 4032/rpc.statd
    tcp 0 0 *:smtp *:* LISTEN 9986/master
    tcp 0 0 mail.(domain).co:rndc *:* LISTEN 5592/named
    tcp 0 0 *:https *:* LISTEN 5412/httpd
    tcp 0 0 *:microsoft-ds *:* LISTEN 4314/smbd
    tcp 0 0 *:7741 *:* LISTEN 3916/lisa
    tcp 0 0 *:imaps *:* LISTEN 3997/couriertcpd
    tcp 0 0 *:pop3s *:* LISTEN 4095/couriertcpd
    tcp 0 0 *:pop3 *:* LISTEN 4092/couriertcpd
    tcp 0 0 *:imap *:* LISTEN 3994/couriertcpd
    tcp 0 0 *:x11 *:* LISTEN 4143/X
    tcp 0 0 *:ssh *:* LISTEN 4188/sshd

    Excerpt from mail warnings.log

    Mar 8 18:15:35 mail amavis[7327]: (!)Net::Server: 2010/03/08-18:15:35 Couldn't open pid file "/var/lib/amavis/amavisd.pid" [Permission denied].\n\n at line 318 in file /usr/lib/perl5/vendor_perl/5.10.0/Net/Server.pm

    Excerpt from syslog:
    Mar 8 20:14:52 mail postfix/smtp[10340]: 6FFE94435F: to=<[email protected]>, relay=none, delay=11120, delays=11120/0.04/0/0, dsn=4.4.1, status=deferred (connect to 127.0.0.1[127.0.0.1]:10024: Connection refused)

    Thanks in advance!
     
  2. falko

    falko Super Moderator ISPConfig Developer

    amavisd should listen on port 10024. What's the output of
    Code:
    ls -la /var/lib/amavis/
    ?
     
  3. wiremeister

    wiremeister New Member

    Thanks Falko. The output of ls -la /var/lib/amavis/ is:

    drwxr-xr-x 2 root root 4096 2010-03-08 17:11 ./
    drwxr-xr-x 41 root root 4096 2010-03-08 17:11 ../

    The /var/lib/amavis folder was not created during the initial setup. The amavis folder was something I added while staring at this for a few hours. I have also tried to uninstall and reinstall/reconfigure amavis following the tutorial.


    Amavis does not appear to want to run. The error I keep getting is there is no .pid file at /var/lib/amavis/amavis.pid. There is in fact nothing in /var/lib/amavis. Amavis appears to stop at that point with a fatal error.

    When attempting Amavis Reload I get this response:
    The amavisd daemon is apparently not running, no PID file /var/lib/amavis/amavisd.pid

    The fatal error seems to be coming in the /usr/lib/perl5/vendor_perl/5.10.0/Net/Server.pm file here:

    ### allow for a pid file (must be done after backgrounding and chrooting)
    ### Remove of this pid may fail after a chroot to another location...
    ### however it doesn't interfere either.
    if( defined $prop->{pid_file} ){
    if( eval{ create_pid_file( $prop->{pid_file} ) } ){
    $prop->{pid_file_unlink} = 1;
    }else{
    $self->fatal( $@ );
    }
    }

    At this point I could wish to be more of a programmer......
     
    Last edited: Mar 9, 2010
  4. falko

    falko Super Moderator ISPConfig Developer

    I guess the folder must be owned by the amavis user and group instead of root.
     
  5. wiremeister

    wiremeister New Member

    That does make some sense to me. Is the amavis.pid file supposed to be created during the initial compilation of amavisd and NET::SERVER? I have noticed reading several forums that it appears to be created sometimes, and sometimes not (for example Apple OS). Should this file be created using the mods in your tutorial? Or can amavisd operate without it by another mod to the .conf file? Any clues that anyone can provide would be greatly appreciated.:)
     
  6. wiremeister

    wiremeister New Member

    Solved the problem by going to Mandriva 2009.0. This time the .pid file was created during set up. All is well. Just don't know why the same file was not created in 2008.1.

    Thanks as always for your help Falko!! :D
     

Share This Page