使用rpm文件手動安裝CentOS authlib軟件
CentOS authlib軟件已被廣泛應(yīng)用但是也在不斷的更新,這里介紹CentOS authlib軟件安裝設(shè)置使用,幫助大家安裝更新CentOS authlib軟件系統(tǒng)。下面介紹使用rpm安裝CentOS authlib軟件步驟操作。
A、CentOS authlib軟件安裝依懶的包
[root@localhost ~]# yum -y install postgresql-devel expect libtool-ltdl-devel
[root@localhost ~]# wget http://prdownloads.sourceforge.net/courier/courier-authlib-0.61.0.tar.bz2
[root@localhost ~]# tar xjf courier-authlib-0.61.0.tar.bz2
[root@localhost ~]# cd courier-authlib-0.61.0
[root@localhost courier-authlib-0.61.0]# cp courier-authlib.spec $SPEC
[root@localhost courier-authlib-0.61.0]# cd ..
[root@localhost ~]# cp courier-authlib-0.61.0.tar.bz2 $SOURCE
[root@localhost ~]# cd $SPEC
[root@localhost SPECS]# rpmbuild -bb courier-authlib.spec (創(chuàng)建rpm文件)
B、安裝生成的rpm
[root@localhost SPECS]# cd $RPMS/i386
[root@localhost i386]# rpm -ivh courier-authlib-0.61.0-1.i386.rpm
[root@localhost i386]# rpm -ivh courier-authlib-devel-0.61.0-1.i386.rpm
[root@localhost i386]# rpm -ivh courier-authlib-mysql-0.61.0-1.i386.rpm
C、CentOS authlib軟件配置daemon
[root@localhost i386]# cd /etc/authlib/
[root@localhost authlib]# mv authdaemonrc authdaemonrc.bak
[root@localhost authlib]# vim authdaemonrc
輸入下面的內(nèi)容:
authmodulelist="authmysql"
authmodulelistorig="authmysql"
daemons=10
authdaemonvar=/var/spool/authdaemon
DEBUG_LOGIN=2
DEFAULTOPTIONS="wbnodsn=1"
LOGGEROPTS=""
D、CentOS authlib軟件配置authmysqlrc
[root@localhost authlib]# mv authmysqlrc authmysqlrc.bak
[root@localhost authlib]# vim authmysqlrc
輸入下面的內(nèi)容:
MYSQL_SERVER localhost
MYSQL_USERNAME extmail
MYSQL_PASSWORD extmail
MYSQL_PORT 0
MYSQL_SOCKET /var/lib/mysql/mysql.sock
MYSQL_OPT 0
MYSQL_DATABASE extmail
MYSQL_SELECT_CLAUSE SELECT username,password,"",uidnumber,gidnumber,
CONCAT('/home/data/domains/',homedir),
CONCAT('/home/data/domains/',maildir),
quota,
name
FROM mailbox
WHERE username = '$(local_part)@$(domain)'
E、啟動CentOS authlib軟件
[root@localhost ~]# service courier-authlib start
Starting Courier authentication services: authdaemond
[root@localhost ~]# chmod 777 /var/spool/authdaemon
以上講解手動使用rpm系統(tǒng)安裝CentOS authlib軟件。
【編輯推薦】