From 41772f43dfb845c6e0078f20c4d2a3474c32fa7f Mon Sep 17 00:00:00 2001 From: compile_success <980965867@qq.com> Date: Tue, 1 Mar 2022 21:27:37 +0800 Subject: [PATCH] set lmdb in main.cf (cherry picked from commit 27c29359ea6a1e43b8a49545813b0a9e140b73dc) --- ...use-lmdb-by-default-instead-of-libdb.patch | 34 +++++++++++++++++++ postfix.spec | 10 +++++- 2 files changed, 43 insertions(+), 1 deletion(-) create mode 100644 postfix-use-lmdb-by-default-instead-of-libdb.patch diff --git a/postfix-use-lmdb-by-default-instead-of-libdb.patch b/postfix-use-lmdb-by-default-instead-of-libdb.patch new file mode 100644 index 0000000..164134e --- /dev/null +++ b/postfix-use-lmdb-by-default-instead-of-libdb.patch @@ -0,0 +1,34 @@ +From 771dfac772b6d4893b6043b70336fae46e60351f Mon Sep 17 00:00:00 2001 +From: eaglegai +Date: Mon, 24 May 2021 20:11:06 +0800 +Subject: [PATCH] use lmdb by default instead of libdb + +--- + conf/main.cf | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/conf/main.cf b/conf/main.cf +index 495e346..6d7b236 100644 +--- a/conf/main.cf ++++ b/conf/main.cf +@@ -402,7 +402,7 @@ unknown_local_recipient_reject_code = 550 + # "postfix reload" to eliminate the delay. + # + #alias_maps = dbm:/etc/aliases +-alias_maps = hash:/etc/aliases ++alias_maps = lmdb:/etc/aliases + #alias_maps = hash:/etc/aliases, nis:mail.aliases + #alias_maps = netinfo:/aliases + +@@ -413,7 +413,7 @@ alias_maps = hash:/etc/aliases + # + #alias_database = dbm:/etc/aliases + #alias_database = dbm:/etc/mail/aliases +-alias_database = hash:/etc/aliases ++alias_database = lmdb:/etc/aliases + #alias_database = hash:/etc/aliases, hash:/opt/majordomo/aliases + + # ADDRESS EXTENSIONS (e.g., user+foo) +-- +1.8.3.1 + diff --git a/postfix.spec b/postfix.spec index b7b7c3b..ed06960 100644 --- a/postfix.spec +++ b/postfix.spec @@ -23,7 +23,7 @@ Name: postfix Summary: Postfix Mail Transport Agent Version: 3.3.1 -Release: 17 +Release: 18 Epoch: 2 URL: http://www.postfix.org License: (IPL-1.0 and GPLv2+) or (EPL-2.0 and GPLv2+) @@ -46,6 +46,7 @@ Patch7: fix-postfix-build-failed.patch Patch8: fix-build-error-with_glibc2.30-ftbfs.patch Patch9: fix-multiple-definition-error-with-gcc-10.patch Patch10: postfix-3.6.2-glibc-234-build-fix.patch +Patch11: postfix-use-lmdb-by-default-instead-of-libdb.patch BuildRequires: lmdb-devel perl-generators pkgconfig zlib-devel systemd-units libicu-devel libnsl2-devel gcc m4 openldap-devel BuildRequires: cyrus-sasl-devel pcre-devel mariadb-connector-c-devel postgresql-devel sqlite-devel openssl-devel procps-ng @@ -110,6 +111,7 @@ PostgreSQL maps with Postfix, you need this. %patch8 -p1 %patch9 -p1 %patch10 -p1 +%patch11 -p1 sed -i \ 's|^\(\s*#define\s\+DEF_SHLIB_DIR\s\+\)"/usr/lib/postfix"|\1"%{_libdir}/postfix"|' \ @@ -552,6 +554,12 @@ fi %{postfix_doc_dir}/README_FILES/* %changelog +* Tue Mar 01 2022 zhujunhao - 2:3.3.1-18 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:set lmdb db in main.cf + * Tue Mar 01 2022 zhouyihang - 2:3.3.1-17 - Type:bugfix - ID:NA