Page 1 of 4 123 ... LastLast
Results 1 to 10 of 60

Thread: [SOLVED] Zimbra+Mailman Howto

Hybrid View

  1. #1
    Join Date
    Jan 2006
    Posts
    19
    Rep Power
    9

    Smile [SOLVED] Zimbra+Mailman Howto

    This How-To will explain how to get mailman mailing list working with Zimbra. I have tried this on a Fedora Core 4. You may need to adjust certain things for other OSes.

    Requirements:
    This ONLY works if Zimbra's postfix is able to deliver mail locally. One thing you should note is ALL the domains added to Zimbra are by default 'virtual_mailbox_domains', so if your hostname is set to be one of the virtual mailbox domains, Mailman will NOT work for you.
    Zimbra's default install sets following in /opt/zimbra/postfix/conf/main.cf
    Code:
    $mydestination = localhost localhost.localdomain
    You may need to change it to get the local delivery working.
    I shall leave it to you to figure out how to achieve that. The variations in this regard are so many that covering all possiblities is impossible and I'm not a 'Postfix Expert' by a long shot.

    Limitations:
    List names must be unique across all virtual domains. For example, you can not have funlist@domain1.com and funlist@domain2.com.


    OK so lets get going.

    First download the latest mailman sources. You can find them here.

    I followed instruction on mailman documentation page.

    Now, ungzip-tar, configure and install. We are going to install mailman under default location, /usr/local/mailman, user mailman and group mailman.

    Code:
    # As root
    groupadd mailman
    useradd -c''GNU Mailman'' -s /sbin/nologin -d /no/home -g mailman mailman
    cd /usr/local
    mkdir mailman
    chgrp mailman mailman
    chmod a+rx,g+ws mailman
    If you want to use Zimbra's httpd running on port 7780, you need the –with-cgi-gid option. If you have another web server running, use the group id of that web server here.
    Code:
    # As normal user
    tar xvfz mailman-2.1.7.tgz
    cd mailman-2.1.7
    ./configure –with-cgi-gid=zimbra
    Now compile and install.
    Code:
    # As root
    make install
    # following is required only if you are using Zimbra's httpd
    cd /usr/local/mailman/archives
    chown zimbra private
    chmod o-x private
    # Check your installation
    /usr/local/mailman/bin/check_perms -f
    Now setup the web server. Add following lines at the end of /opt/zimbra/conf/httpd.conf

    Code:
    #
    #  httpd configuration settings for use with mailman.
    #
    
    ScriptAlias /mailman/ /usr/local/mailman/cgi-bin/
    <Directory /usr/local/mailman/cgi-bin/>
        AllowOverride None
        Options ExecCGI
        Order allow,deny
        Allow from all
    </Directory>
    
    Alias /pipermail/ /usr/local/mailman/archives/public/
    <Directory /usr/local/mailman/archives/public>
        Options Indexes MultiViews FollowSymLinks
        AllowOverride None
        Order allow,deny
        Allow from all
        # Only if you have internationalized archives
        AddDefaultCharset Off
    </Directory>
    
    # Uncomment the following line, replacing www.example.com with your server's
    # name, to redirect queries to /mailman to the listinfo page (recommended).
    # RedirectMatch ^/mailman[/]*$ http://www.example.com/mailman/listinfo
    Now copy mailman icons and then restart apache.
    Code:
    # As User 'zimbra'
    cd /opt/zimbra/httpd/htdocs
    mkdir mmimages
    cp /usr/local/mailman/icons/* mmimages/
    zmapachectl stop
    zmapachectl start
    Now change postfix configuration.
    Add/Modify /opt/zimbra/postfix/conf/main.cf so that following varibles are set as shown.
    Code:
    virtual_alias_maps = ldap:/opt/zimbra/conf/ldap-vam.cf,hash:/usr/local/mailman/data/virtual-mailman
    alias_maps = hash:/etc/aliases,hash:/usr/local/mailman/data/aliases
    Add following lines at the end of /usr/local/mailman/Mailman/mm_cfg.py file.
    Code:
    MTA = 'Postfix'
    POSTFIX_ALIAS_CMD = '/opt/zimbra/postfix/sbin/postalias'
    POSTFIX_MAP_CMD = '/opt/zimbra/postfix/sbin/postmap'
    IMAGE_LOGOS = '/mmimages/'
    DEFAULT_URL_PATTERN = 'http://%s:7780/mailman/'
    POSTFIX_STYLE_VIRTUAL_DOMAINS = [ 'virtual-domain1.com', 'virtual-domain2.com' ]
    In the last variable, you need to list all your virtual mailbox domains for which you want to add mailing lists. Remember you should ONLY list your virtual domains here, not your local domain for which postfix delivers mail locally.

    Now add your first list on virtual domain.
    Code:
    # As root
    # first add a sitewide list called mailman, this is mandatory
    cd /usr/local/mailman
    bin/newlist mailman 
    bin/config_list -i data/sitelist.cfg mailman
    
    bin/newlist --emailhost=virtual-domain1.com --urlhost=<your zimbra host> <listname> <admin-email-address> <admin-password>
    
    # This is just to make sure that aliases and virtual-mailman files get generated. Until you add a virtual-domain based list, virtual-mailman won't be generated.
    
    /usr/local/mailman/bin/genaliases
    # aliases and virtual-mailman must be owned by mailman.
    
    chown mailman:mailman /usr/local/mailman/data/aliases*
    chown mailman:mailman /usr/local/mailman/data/virtual-mailman*
    
    # setup mailman cron
    cd /usr/local/mailman/cron
    crontab -u mailman crontab.in
    
    # setup daemon
    cp /usr/local/mailman/scripts/mailman /etc/init.d
    chkconfig --add mailman
    Now your should be able to visit http://<zimbra host>:7780/mailman/listinfo and browse/create new lists etc. And of course you can always use mailman's command line utilities for list maintainance.

    Hope this helps.

  2. #2
    Join Date
    May 2006
    Posts
    6
    Rep Power
    9

    Default CGI error

    Thank you so much for the step by step instructions.

    I have faced 2 problems with my installation

    1) When I add a mailing list on the command line, I get
    "Hit Enter to notify the mailing list administrator"

    However on checking the email of the mailing list owner, no email is received. I have tried this with an external email as well as email which is hosted on the server too.

    2) On accessing http://myhostname.mydomainname.com:7780/mailman/listinfo

    Mailman CGI error!!!
    The Mailman CGI wrapper encountered a fatal error. This entry is being stored in your syslog:
    Group mismatch error. Mailman expected the CGI
    wrapper script to be executed as group "nobody", but
    the system's web server executed the CGI script as
    group "zimbra". Try tweaking the web server to run the
    script as group "nobody", or re-run configure,
    providing the command line option `--with-cgi-gid=zimbra'.


    Can you help me out with this?

  3. #3
    Join Date
    Oct 2006
    Posts
    2
    Rep Power
    9

    Default

    My problem is with
    virtual_alias_maps = ldap:/opt/zimbra/conf/ldap-vam.cf,hash:/usr/local/mailman/data/virtual-mailman
    alias_maps = hash:/etc/aliases,hash:/usr/local/mailman/data/aliases

    i change with zmlocalconfig but zimbra don't take new alias, so it is impossibile to post on the mailman list... how can I do to check if zimbra create the list alias?

  4. #4
    phoenix is offline Zimbra Consultant & Moderator
    Join Date
    Sep 2005
    Location
    Vannes, France
    Posts
    23,587
    Rep Power
    58

    Default

    Quote Originally Posted by ios77
    My problem is with
    virtual_alias_maps = ldap:/opt/zimbra/conf/ldap-vam.cf,hash:/usr/local/mailman/data/virtual-mailman
    alias_maps = hash:/etc/aliases,hash:/usr/local/mailman/data/aliases

    i change with zmlocalconfig but zimbra don't take new alias, so it is impossibile to post on the mailman list... how can I do to check if zimbra create the list alias?
    Please don't post the same message in multiple threads, it gets confusing trying to follow what's happened. In future start a new thread or just tag it onto one that's on-subject.
    Last edited by phoenix; 10-20-2008 at 08:08 AM.
    Regards


    Bill


    Acompli: A new adventure for Co-Founder KevinH.

  5. #5
    Join Date
    Feb 2006
    Location
    Manchester, UK
    Posts
    88
    Rep Power
    9

    Default

    Thanks for this. I've got a bit of tweaking to do, but the procedure worked great.

    On RHEL, I needed to install the python-devel package along with gcc (without python-devel I got an error about a korean module not existing).

  6. #6
    Join Date
    Nov 2005
    Location
    London, ON
    Posts
    255
    Rep Power
    10

    Default

    RHEL has an RPM for mailman, then you don't need to install a compiler.

  7. #7
    Join Date
    Aug 2007
    Location
    New York
    Posts
    59
    Rep Power
    8

    Default

    using zmlocalconfig is correct, but you need to alter postfix_virtual_alias_maps and postfix_alias_maps instead of virtual_alias_maps and alias_maps. At least in version 4.5.9
    Jeffrey Turmelle
    International Research Institute for Climate and Society
    Earth Institute at Columbia University


    Release 7.2.7_GA_2942.RHEL5_64_20140314190109 RHEL5_64 NETWORK edition.

  8. #8
    Join Date
    Nov 2007
    Posts
    6
    Rep Power
    8

    Default mydestination reset when restart zimbra

    Hello, I make the instruction and the zimbra run correctly, but when I restart the zimbra the variable mydestination of postconf reset to "localhost".

    I execute the follow as user zimbra:

    # postconf -e mydestination='<myhostname.com>'
    # postfix reload
    # postconf -e mydestination='<myhostname.com>'

    when I restart zimbra, the configuration is be for default.

    What is de problem?

    Thank`s

  9. #9
    Join Date
    Nov 2007
    Posts
    6
    Rep Power
    8

    Default I not found the value of zimbraMtaMyDestination

    I edit de file zmmta.cf, but I don't know the line where I need edit.

    Help me! please!

    Thank's.

  10. #10
    Join Date
    Dec 2005
    Location
    Veracruz, México
    Posts
    11
    Rep Power
    9

    Thumbs up

    Quote Originally Posted by montievv View Post
    Thank you so much for the step by step instructions.

    2) On accessing http://myhostname.mydomainname.com:7780/mailman/listinfo

    Mailman CGI error!!!
    The Mailman CGI wrapper encountered a fatal error. This entry is being stored in your syslog:

    ...

    providing the command line option `--with-cgi-gid=zimbra'.

    Can you help me out with this?
    Considers to use this:

    Code:
    # ./configure --with-cgi-gid=zimbra
    instead of this (It happens an error if you copy and paste from the HowTo):

    Code:
    # ./configure with-cgi-gid=zimbra

Similar Threads

  1. Replies: 26
    Last Post: 04-19-2011, 10:24 AM
  2. Can't start Zimbra!
    By zibra in forum Administrators
    Replies: 5
    Last Post: 03-22-2007, 12:34 PM
  3. zimbra-core missing
    By kinaole in forum Developers
    Replies: 1
    Last Post: 10-02-2006, 12:59 PM
  4. port 7071 not listening OS X install
    By leeimber in forum Installation
    Replies: 7
    Last Post: 03-21-2006, 10:47 AM
  5. Monitoring : Data not yet avalaible
    By s3nz3x in forum Installation
    Replies: 7
    Last Post: 11-30-2005, 07:18 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •