1

Topic: Amavisd not starting

==== Required information ====
- iRedMail version: 0.8.5
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- Linux/BSD distribution name and version: CentOS 6.4
- Related log if you're reporting an issue:
====
I did search, but I'm still not exactly sure what the issue relates to.  It looks like the amavisd conf in /usr/sbin actually accounts for the versioning of perl, but I could be wrong and it's not even a perl issue.  Any help would be much appreciated.


# /etc/init.d/amavisd start
Starting amavisd: fetch_modules: error loading required module MIME/Head.pm:
  Can't locate Mail/Header.pm in @INC (@INC contains: /opt/mail/lib/site_perl/5.8.2 /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 /opt/mail/lib/site_perl/5.8.2) at /usr/share/perl5/MIME/Head.pm line 120.
  BEGIN failed--compilation aborted at /usr/share/perl5/MIME/Head.pm line 120.
  Compilation failed in require at /usr/sbin/amavisd line 197.
fetch_modules: error loading required module MIME/Entity.pm:
  Can't locate Mail/Internet.pm in @INC (@INC contains: /opt/mail/lib/site_perl/5.8.2 /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 /opt/mail/lib/site_perl/5.8.2) at /usr/share/perl5/MIME/Entity.pm line 229.
  BEGIN failed--compilation aborted at /usr/share/perl5/MIME/Entity.pm line 229.
  Compilation failed in require at /usr/sbin/amavisd line 197.
fetch_modules: error loading required module MIME/Parser.pm:
  Attempt to reload MIME/Head.pm aborted.
  Compilation failed in require at /usr/share/perl5/MIME/Parser.pm line 143.
  BEGIN failed--compilation aborted at /usr/share/perl5/MIME/Parser.pm line 143.
  Compilation failed in require at /usr/sbin/amavisd line 197.
ERROR: MISSING REQUIRED BASIC MODULES:
  MIME::Head
  MIME::Entity
  MIME::Parser
  Net::Server
  Net::Server::PreFork
BEGIN failed--compilation aborted at /usr/sbin/amavisd line 237.
                                                           [FAILED]

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: Amavisd not starting

Do you have below RPM packages installed?

- perl-MIME-tools
- perl-Net-Server

3

Re: Amavisd not starting

I downloaded the rpms from here: http://www.iredmail.org/yum/rpms/6/ and tried to manually install them.
perl-MIME-tools already installed
perl-Net-Server has a newer version.

[root@mail ~]# rpm -iv perl-MIME-tools-5.427-4.el6.noarch.rpm
Preparing packages for installation...
    package perl-MIME-tools-5.427-4.el6.noarch is already installed
[root@mail ~]# rpm -iv perl-Net-Server-0.97-7.el6.noarch.rpm
Preparing packages for installation...
    package perl-Net-Server-0.99-1.el5.rf.noarch (which is newer than perl-Net-Server-0.97-7.el6.noarch) is already installed
    file /usr/share/man/man3/Net::Server.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::Daemonize.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::Fork.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::INET.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::MultiType.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::Multiplex.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::PreFork.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::PreForkSimple.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::Proto.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::Proto::SSL.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::Proto::TCP.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::Proto::UDP.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::Proto::UNIX.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::SIG.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch
    file /usr/share/man/man3/Net::Server::Single.3pm.gz from install of perl-Net-Server-0.97-7.el6.noarch conflicts with file from package perl-Net-Server-0.99-1.el5.rf.noarch

4

Re: Amavisd not starting

executor485 wrote:

ERROR: MISSING REQUIRED BASIC MODULES:
  MIME::Head
  MIME::Entity
  MIME::Parser
  Net::Server
  Net::Server::PreFork

These 5 modules are shipped in two RPM packages (perl module): perl-MIME-Tools, perl-Net-Server. and you have them installed.

Could you please show me output of below commands?

# rpm -qi perl-MIME-Tools
# rpm -qi perl-Net-Server
# yum repolist

5

Re: Amavisd not starting

executor485 wrote:

    package perl-Net-Server-0.99-1.el5.rf.noarch (which is newer than perl-Net-Server-0.97-7.el6.noarch) is already installed

I just found this strange package: your perl-Net-Server package is built for RHEL/CentOS 5, not 6.
Both iRedMail and EPEL yum repositories provide perl-Net-Server-0.97-7.el6, and you have 0.99-1.el5. Please remove this package first, then install it with yum, then try to start Amavisd service:

# yum install perl-Net-Server

6

Re: Amavisd not starting

Removing the net server and putting the correct distro worked for the Net-Server, thanks.

This is what remains:

[root@mail ~]# /etc/init.d/amavisd start
Starting amavisd: fetch_modules: error loading required module MIME/Head.pm:
  Can't locate Mail/Header.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5) at /usr/share/perl5/MIME/Head.pm line 120.
  BEGIN failed--compilation aborted at /usr/share/perl5/MIME/Head.pm line 120.
  Compilation failed in require at /usr/sbin/amavisd line 197.
fetch_modules: error loading required module MIME/Entity.pm:
  Can't locate Mail/Internet.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5) at /usr/share/perl5/MIME/Entity.pm line 229.
  BEGIN failed--compilation aborted at /usr/share/perl5/MIME/Entity.pm line 229.
  Compilation failed in require at /usr/sbin/amavisd line 197.
fetch_modules: error loading required module MIME/Parser.pm:
  Attempt to reload MIME/Head.pm aborted.
  Compilation failed in require at /usr/share/perl5/MIME/Parser.pm line 143.
  BEGIN failed--compilation aborted at /usr/share/perl5/MIME/Parser.pm line 143.
  Compilation failed in require at /usr/sbin/amavisd line 197.
ERROR: MISSING REQUIRED BASIC MODULES:
  MIME::Head
  MIME::Entity
  MIME::Parser
BEGIN failed--compilation aborted at /usr/sbin/amavisd line 237.
                                                           [FAILED]

[root@mail ~]# rpm -qi perl-MIME-tools
Name        : perl-MIME-tools              Relocations: (not relocatable)
Version     : 5.427                             Vendor: CentOS
Release     : 4.el6                         Build Date: Fri 12 Nov 2010 08:39:13 AM EST
Install Date: Fri 11 Oct 2013 09:53:59 AM EDT      Build Host: c6b6.bsys.dev.centos.org
Group       : Development/Libraries         Source RPM: perl-MIME-tools-5.427-4.el6.src.rpm
Size        : 523017                           License: GPL+ or Artistic
Signature   : RSA/8, Sun 03 Jul 2011 12:38:19 AM EDT, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://search.cpan.org/dist/MIME-tools/
Summary     : Modules for parsing and creating MIME entities in Perl
Description :
MIME-tools is a collection of Perl5 MIME:: modules for parsing, decoding, and
generating single- or multipart (even nested multipart) MIME messages.

Yes, kids, that means you can send messages with attached GIF files.

7

Re: Amavisd not starting

Does removing perl-MIME-tools then reinstall it with "yum install perl-MIME-tools" solve this issue?