iredmail 更新迁移, bug,ssl证书等

发布于 2021-06-02 17:46:31

1. iredmail下载地址

下载地址

2. 迁移到高版本的iredmail

https://docs.iredmail.org/migrate.to.new.iredmail.server.html

3. 如何备份,如何恢复

https://docs.iredmail.org/backup.restore.html

4. 如何修改客户端,网页附件大小

参考链接

1) 修改php配置文件

vi /etc/php/7.0/fpm/php.ini
memory_limit = 200M;
post_max_size = 100M;
upload_max_filesize = 100M;
重启服务
sudo service php7.0-fpm restart

2) Roundcube附件大小

vi /opt/www/roundcubemail/.htaccess
php_value   upload_max_filesize   100M
php_value   post_max_size         100M
php_value   memory_limit          200M

对于roundcube 1.6.1 版本,php 8.1 版本:
修改配置文件 /opt/www/roundcubemail-1.6.1/config/config.inc.php

......
$config['max_message_size'] = '100M'; //此值会按照相关大小缩小显示
......

image.png

3) 修改对应的nginx配置,比如改成100M

vi /etc/nginx/conf-enabled/client_max_body_size.conf
client_max_body_size 100m;
重启服务
sudo service nginx restart

4) 限制 SOGo 上传文件大小

vi /etc/sogo/sogo.conf
WOMaxUploadSize = 102400;
重启服务
sudo service sogo restart

5. 如何修改DNS和spf正确解析正常收发邮件:

1) 首先生成配置文件
可用参考iRedMail-0.9.8/samples/amavisd/amavisd.conf,注意默认域名需要正确配置,如有多个,请添加

# Add dkim_key here.
dkim_key('cwbiotech.com.cn', 'dkim', '/var/lib/dkim/cwbiotech.com.cn.pem');
dkim_key('genewill.cn', 'dkim', '/var/lib/dkim/genewill.cn.pem');

@dkim_signature_options_bysender_maps = ({
    # 'd' defaults to a domain of an author/sender address,
    # 's' defaults to whatever selector is offered by a matching key

    # Per-domain dkim key
    #"domain.com"  => { d => "domain.com", a => 'rsa-sha256', ttl => 10*24*3600 },

    # catch-all (one dkim key for all domains)
     '.' => {d => 'cwbiotech.com.cn',
            a => 'rsa-sha256',
            c => 'relaxed/simple',
            ttl => 30*24*3600 },
     '.' => {d => 'genewill.cn',
            a => 'rsa-sha256',
            c => 'relaxed/simple',
            ttl => 30*24*3600 },
});

2) 拷贝配置文件到/etc/amavis/conf.d/50-user目录覆盖源文件

3) 生成对应的配置pem文件

amavisd-new -c /etc/amavis/conf.d/50-user genrsa /var/lib/dkim/cwbiotech.com.cn.pem
amavisd-new -c /etc/amavis/conf.d/50-user genrsa /var/lib/dkim/genewill.cn.pem

4) 重启服务

#amavisd-new reload
#amavisd-new showkeys

5) 如果出现对应的域名,说明配置成功, 接着配置DNS解析,比如genewill.cn
image.png
注意txt至需要去掉“号

配置完成检查:

#amavisd-new testkeys
TESTING#1 cwbiotech.com.cn: dkim._domainkey.cwbiotech.com.cn => pass
TESTING#2 genewill.cn: dkim._domainkey.genewill.cn => pass
3 条评论

发布
问题