Postfix
無法在 Debian Squeeze 上安裝 postfix
我有這個奇怪的問題:apt-get 或 aptitude 無法安裝 postfix。每次我收到此錯誤時:
# apt-get install postfix Reading package lists... Done Building dependency tree Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation: The following packages have unmet dependencies: postfix : Depends: libsasl2-2 but it is not going to be installed E: Broken packages
和
# aptitude install postfix The following NEW packages will be installed: postfix ssl-cert{a} 0 packages upgraded, 2 newly installed, 0 to remove and 0 not upgraded. Need to get 1,417 kB of archives. After unpacking 3,535 kB will be used. The following packages have unmet dependencies: exim4-config: Conflicts: postfix but 2.7.1-1+squeeze1 is to be installed. libsasl2-2: Breaks: postfix (<= 2.8.3-1) but 2.7.1-1+squeeze1 is to be installed. The following actions will resolve these dependencies: Keep the following packages at their current version: 1) postfix [Not Installed] Accept this solution? [Y/n/q/?] y No packages will be installed, upgraded, or removed. 0 packages upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Need to get 0 B of archives. After unpacking 0 B will be used.
/etc/apt/sources.list:
# deb http://ftp.de.debian.org/debian/ squeeze main deb http://ftp.de.debian.org/debian/ squeeze main deb-src http://ftp.de.debian.org/debian/ squeeze main deb http://security.debian.org/ squeeze/updates main deb-src http://security.debian.org/ squeeze/updates main # squeeze-updates, previously known as 'volatile' deb http://ftp.de.debian.org/debian/ squeeze-updates main deb-src http://ftp.de.debian.org/debian/ squeeze-updates main deb http://packages.dotdeb.org squeeze all deb-src http://packages.dotdeb.org squeeze all # MariaDB 10.0 repository list - created 2013-10-11 09:14 UTC # http://mariadb.org/mariadb/repositories/ deb http://mirror.netcologne.de/mariadb/repo/10.0/debian squeeze main deb-src http://mirror.netcologne.de/mariadb/repo/10.0/debian squeeze main
我試圖 –purge 刪除 potfix 和 exim5,然後重新安裝,但問題仍然存在。感謝您的提示。
在 Debian 上,大量軟體包需要 MTA。嘗試清除 exim 或任何其他 MTA 將導致安裝替代方案。替代方案的順序是,刪除 exim 將導致安裝 exim 的替代版本或另一個 MTA。這些要求、備選方案和衝突使更改已安裝的 MTA 有點棘手。由於簡單地清除 MTA 並不容易,而且如果您確實嘗試清除 MTA,您還必須安裝幾乎所有可以使用 MTA 的東西。
為了處理這種 MTA 怪異,我的解決方案是安裝 SSMTP。
SSMTP 包,它是一個輕量級的無守護程序僅傳出 MTA,將滿足 MTA 要求,並且不會與其他 MTA 衝突。因此,您可以與標準儲存庫中的所有其他 MTA 同時安裝 SSMTP。安裝後,您可以清除 exim 或其他 MTA,並根據您的喜好進行更改。SSMTP 將滿足 MTA 要求,並且不會導致 APT 做出令人困惑的事情來嘗試確保您安裝了 MTA。