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

Thread: [SOLVED] Zimbra+Mailman Howto

  1. #1
    amitbapat is offline Intermediate Member
    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
    montievv is offline Junior Member
    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
    ios77 is offline Starter Member
    Join Date
    Oct 2006
    Posts
    2
    Rep Power
    8

    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,470
    Rep Power
    56

    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 07:08 AM.
    Regards


    Bill


    Acompli: A new adventure for Co-Founder KevinH.

  5. #5
    iain is offline Loyal Member
    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
    rsharpe is offline Elite Member & Volunteer
    Join Date
    Nov 2005
    Location
    London, ON
    Posts
    255
    Rep Power
    9

    Default

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

  7. #7
    iain is offline Loyal Member
    Join Date
    Feb 2006
    Location
    Manchester, UK
    Posts
    88
    Rep Power
    9

    Default

    I didn't try that.

    I considered it but thought it wouldn't have the --with-cgi-gid setting correct for Zimbra and getting it right might be more hassle than it was worth.

  8. #8
    rsharpe is offline Elite Member & Volunteer
    Join Date
    Nov 2005
    Location
    London, ON
    Posts
    255
    Rep Power
    9

    Default

    I'm using it and I didn't have a single problem.

  9. #9
    Chris_H is offline Intermediate Member
    Join Date
    Sep 2006
    Posts
    16
    Rep Power
    8

    Default

    Quote Originally Posted by rsharpe
    I'm using it and I didn't have a single problem.
    Can you elaborate on your setup? I'm trying to integrate the mailman rpm with Zimbra and I can't get list creation to work correctly...I keep getting a permissions error in the httpd log (using the non-Zimbra httpd) when it tries to run /opt/zimbra/postfix/sbin/postalias. Any pointers would be appreciated...

    -chris

  10. #10
    chenthil is offline Active Member
    Join Date
    Oct 2006
    Location
    India
    Posts
    49
    Rep Power
    8

    Default

    Quote Originally Posted by Chris_H View Post
    Can you elaborate on your setup? I'm trying to integrate the mailman rpm with Zimbra and I can't get list creation to work correctly...I keep getting a permissions error in the httpd log (using the non-Zimbra httpd) when it tries to run /opt/zimbra/postfix/sbin/postalias. Any pointers would be appreciated...

    -chris
    After restarting of zimbra or postfix service , After restart /opt/zimbra/postfix/conf/main.cf
    gets appended ...

    vi /opt/zimbra/postfix/conf/main.cf

    add this at the bottom

    $mydestination = localhost localhost.localdomain


    please add few parameter as given below in the line ( virtual_alias_maps , alias_maps )

    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
    Attached Files Attached Files

Page 1 of 6 123 ... LastLast

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 26
    Last Post: 04-19-2011, 09:24 AM
  2. Can't start Zimbra!
    By zibra in forum Administrators
    Replies: 5
    Last Post: 03-22-2007, 11:34 AM
  3. zimbra-core missing
    By kinaole in forum Developers
    Replies: 1
    Last Post: 10-02-2006, 11:59 AM
  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
  •