centos8批量加IP
需求:在centos8里为eno1网卡批量加192.168.99.3到192.168.99.100的IP地址,掩码是255.255.255.0
尝试:用nmcli批量加,如 for I in $(seq 3 100); do nmcli con mod eno1 +ipv4.addresses 192.168.99.${I}/24; done
之后重载配置内容 nmcli con up eno1
需求:在centos8里为eno1网卡批量加192.168.99.3到192.168.99.100的IP地址,掩码是255.255.255.0
尝试:用nmcli批量加,如 for I in $(seq 3 100); do nmcli con mod eno1 +ipv4.addresses 192.168.99.${I}/24; done
之后重载配置内容 nmcli con up eno1
问题:centos7 里的 postfix 日志中提示兼容性信息提示。
尝试:原来是将原debian 里的 postfix 配置文件复制到 centos7 中发生的。默认 centos 不使用 chroot 环境,所以将配置文件中的 chroot 列值,从 - 修改为 n 重启 postfix 就可以了。
Nov 19 23:25:44 localhost postfix/master[865]: /etc/postfix/master.cf: line 18: using backwards-compatible default setting chroot=y
Nov 19 23:25:44 localhost postfix/master[865]: /etc/postfix/master.cf: line 26: using backwards-compatible default setting chroot=y
Nov 19 23:25:44 localhost postfix/master[865]: /etc/postfix/master.cf: line 35: using backwards-compatible default setting chroot=y
参考:
问题:/var/log/maillog 日志中,有dovecot的警告信息,如
Nov 19 23:25:22 localhost dovecot: imap(laile@s)<1100>
尝试:将dovecot配置文件中的原:
protocol imap {
mail_plugins = "autocreate"
}
plugin {
autocreate = Trash
autocreate2 = Sent
autosubscribe = Trash
autosubscribe2 = Sent
}
替换为:
namespace inbox {
inbox = yes
mailbox Trash {
auto = subscribe # autocreate and autosubscribe the Trash mailbox
special_use = \Trash
}
mailbox Sent {
auto = subscribe # autocreate and autosubscribe the Sent mailbox
special_use = \Sent
}
}
环境:CentOS7
问题:邮箱用户通过imap登录失败,/var/log/maillog 日志中有错误信息:localhost postfix/submission/smtpd[451]: error: unsupported dictionary type: mysql
尝试:yum install postfix-mysql
安装 postfix-mysql 后重启 postfix
参考:https://serverfault.com/questions/622796/postfix-error-unsupported-dictionary-type-mysql
环境:CentOS7
问题:邮箱用户通过imap登录失败,/var/log/maillog 日志中有错误信息:localhost dovecot: auth: Fatal: sql: Unknown database driver 'mysql'
尝试:yum install dovecot-mysql
安装 dovecot-mysql 后重启 dovecot
参考:https://serverfault.com/questions/334850/dovecot-auth-fatal-unknown-database-driver-pgsql