C.对表的内容的一些说明.
mysql> use postfix
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> show table
+-------------------+
| Tables_in_postfix |
+-------------------+
| alias |
| domain |
| mailbox |
+-------------------+
3 rows in set (0.00 sec)
mysql> desc alia
+----------+--------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+----------+--------------+------+-----+---------+-------+
| username | varchar(255) | | PRI | | |
| goto | text | | | | |
| domain | varchar(255) | | | | |
+----------+--------------+------+-----+---------+-------+
3 rows in set (0.00 sec)
mysql> desc domai
+-------------+--------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------------+--------------+------+-----+---------+-------+
| domain | varchar(255) | | PRI | | |
| description | varchar(255) | | | | |
+-------------+--------------+------+-----+---------+-------+
2 rows in set (0.00 sec)
mysql> desc mailbox;
+--------------------+----------------------+------+-----+------------+-------+
| Field | Type | Null | Key | Default | Extra |
+--------------------+----------------------+------+-----+------------+-------+
| userid | varchar(20) binary | | | | |
| username | varchar(255) | | PRI | | |
| paword | varchar(255) | | | | |
| home | varchar(255) | | | | |
| maildir | varchar(255) | | | | |
| name | varchar(255) | | | | |
| uid | smallint(5) uigned | | | 12345 | |
| gid | smallint(5) uigned | | | 12345 | |
| quota | varchar(255) | | | | |
| domain | varchar(255) | | | | |
| create_date | date | | | 0000-00-00 | |
| create_time | time | | | 00:00:00 | |
| change_date | date | | | 0000-00-00 | |
| change_time | time | | | 00:00:00 | |
| last_acce | int(10) uigned | | | 0 | |
| pawd_lastchanged | int(10) uigned | | | 0 | |
| status | tinyint(4) | | MUL | 1 | |
+--------------------+----------------------+------+-----+------------+-------+
17 rows in set (0.00 sec)
mysql>
domain表的解释:
domain 任意的domain.
description 通常是2种 "local:" 用于本地的 or "virtual:" 用于是虚拟的.
alias表的解释:
username 是虚拟的邮箱addre@domain.tld
,将被转发到goto下的联结中.
goto 可以用简单的名字
,如果是本地用户名,如(root, postmaster, etc.), 或者是整个的邮箱名字,user@domain.tld
。
Mailbox表的内容:
Userid 使用者编码
username 可以是user.domain.tld 或 user@domain.tld
paword 在mysql中用encrypt('paword') 输入.
name 使用着的真实姓名
。 uid 虚拟用户身份uid
gid 组的gid
home "/usr/local/virtual/". Maildirs必须在此目录下。
domain 这栏可以不要,但有些软件需要他。
maildir 是整个地址,必须带”/”结尾。
Quota 邮箱的
空间或信息量的限制。
status 0 为禁止。"MY
SQL_WHERE_CLAUSE= status" .
三、pam-mysql的编译
tar pam-mysql-5.0.tar.gz
make cp pam_mysql.so /lib/security