Now I made my databases but i can't login! with normal users it works but with virtual not. There is some error with a query.
I've included config file, database setup,error so you have an idea
Thanks!
main.cf
Code: Select all
queue_directory = /var/spool/postfix
command_directory = /usr/sbin
daemon_directory = /usr/lib/postfix
mail_owner = postfix
myorigin = localhost
myhostname = eddy.be
mydestination = eddy.be, localhost, localhost.Belkin, Belkin
unknown_local_recipient_reject_code = 450
mynetworks_style = subnet
mynetworks = 127.0.0.0/8 192.168.2.0/24
mailbox_command = /usr/bin/procmail
debug_peer_level = 3
debugger_command =
PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin:
xxgdb = $daemon_directory/$process_name $process_id & sleep 5
sendmail_path = /usr/sbin/sendmail
newaliases_path = /usr/bin/newaliases
mailq_path = /usr/bin/mailq
setgid_group = postdrop
manpage_directory = /usr/share/man
readme_directory = /usr/share/doc/postfix-2.1.5-r2/readme
default_destination_concurrency_limit = 2
alias_database = hash:/etc/mail/aliases
local_destination_concurrency_limit = 2
alias_maps = hash:/etc/mail/aliases
home_mailbox = .maildir/
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
smtpd_sasl_local_domain =
broken_sasl_auth_clients = yes
smtpd_client_restrictions = permit_sasl_authenticated, reject_unauth_destination
smtpd_use_tls=yes
smtpd_tls_auth_only = yes
smtpd_tls_key_file = /etc/ssl/postfix/server.key
smtpd_tls_cert_file = /etc/ssl/postfix/server.crt
smtpd_tls_CAfile = /etc/ssl/postfix/server.pem
smtpd_tls_loglevel = 3
smtpd_tls_received_header = yes
smtpd_tls_session_cache_timeout = 3600s
tls_random_source = dev:/dev/urandom
#virtual_alias_maps=mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_mailbox_maps=mysql:/etc/postfix/mysql-virtual_mailboxes.cf
#virtual_mailbox_base=/usr/local/virtual
virtual_transport = virtual
virtual_uid_maps=static:5000
virtual_gid_maps=static:5000
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
Code: Select all
user = root
password = *
hosts = localhost
dbname = postfix
table = alias
select_field = goto
where_field = address
Code: Select all
user = root
password = *
hosts = localhost
dbname = postfix
table = domain
select_field = domain
where_field = domain
mysql-virtual_mailboxes.cf
Code: Select all
user = root
password = *
hosts = localhost
dbname = postfix
table = mailbox
select_field = maildir
where_field = username
Code: Select all
+-------------------+
| Tables_in_postfix |
+-------------------+
| admin |
| alias |
| domain |
| domain_admins |
| log |
| mailbox |
| vacation |
+-------------------+
7 rows in set (0.00 sec)
Code: Select all
+----------------------+-------------------------------------------+-------------+---------------------+---------------------+--------+
| address | goto | domain | created | modified | active |
+----------------------+-------------------------------------------+-------------+---------------------+---------------------+--------+
| abuse@localhost | abuse@change-this-to-your.domain.tld | localhost | 2000-01-01 01:29:50 | 2000-01-01 01:29:50 | 1 |
| hostmaster@localhost | hostmaster@change-this-to-your.domain.tld | localhost | 2000-01-01 01:29:50 | 2000-01-01 01:29:50 | 1 |
| postmaster@localhost | postmaster@change-this-to-your.domain.tld | localhost | 2000-01-01 01:29:50 | 2000-01-01 01:29:50 | 1 |
| webmaster@localhost | webmaster@change-this-to-your.domain.tld | localhost | 2000-01-01 01:29:50 | 2000-01-01 01:29:50 | 1 |
| test@spamstop.be | test@spamstop.be | spamstop.be | 2000-01-01 01:51:05 | 2000-01-01 01:51:05 | 1 |
| test@eddy.be | test@eddy.be | eddy.be | 0000-00-00 00:00:00 | 0000-00-00 00:00:00 | 1 |
+----------------------+-------------------------------------------+-------------+---------------------+---------------------+--------+
Code: Select all
+-------------+---------------+---------+-----------+----------+-----------+----------+---------------------+---------------------+--------+
| domain | description | aliases | mailboxes | maxquota | transport | backupmx | created | modified | active |
+-------------+---------------+---------+-----------+----------+-----------+----------+---------------------+---------------------+--------+
| localhost | - | 0 | 0 | 0 | virtual | 0 | 2000-01-01 01:29:50 | 2000-01-01 01:29:50 | 1 |
| spamstop.be | spamstop test | 0 | 0 | 0 | virtual | 0 | 2000-01-01 01:50:43 | 2000-01-01 01:50:43 | 1 |
| eddy.be | | 0 | 0 | 0 | virtual | 0 | 0000-00-00 00:00:00 | 0000-00-00 00:00:00 | 1 |
+-------------+---------------+---------+-----------+----------+-----------+----------+---------------------+---------------------+--------+
3 rows in set (0.00 sec)
Code: Select all
+------------------+------------------------------------+------+---------------------------+-------+-------------+---------------------+---------------------+--------+
| username | password | name | maildir | quota | domain | created | modified | active |
+------------------+------------------------------------+------+---------------------------+-------+-------------+---------------------+---------------------+--------+
| test@spamstop.be | $1$e40dd70b$cvT4gKIrB4KbsK5RVg1WV0 | | test@spamstop.be/ | 0 | spamstop.be | 2000-01-01 01:51:05 | 2000-01-01 01:51:05 | 1 |
| test@eddy.be | test | test | /var/virtual/eddy.be/test | 0 | eddy.be | 2006-11-30 00:00:00 | 2006-11-22 00:00:00 | 1 |
+------------------+------------------------------------+------+---------------------------+-------+-------------+---------------------+---------------------+--------+
Code: Select all
Jan 1 01:26:08 eddy postfix/virtual[5748]: fatal: bad string length 0 < 1: virtual_mailbox_base =
Jan 1 01:26:09 eddy postfix/master[5357]: warning: process /usr/lib/postfix/virtual pid 5748 exit status 1
Jan 1 01:26:09 eddy postfix/master[5357]: warning: /usr/lib/postfix/virtual: bad command startup -- throttling
Jan 1 01:27:01 eddy pop3d: Connection, ip=[::ffff:192.168.2.2]
Jan 1 01:27:01 eddy pop3d: LOGIN, user=esger, ip=[::ffff:192.168.2.2]
Jan 1 01:27:01 eddy pop3d: LOGOUT, user=esger, ip=[::ffff:192.168.2.2], top=0, retr=0, time=0
Jan 1 01:27:01 eddy pop3d: Connection, ip=[::ffff:192.168.2.2]
Jan 1 01:27:01 eddy pop3d: LOGIN FAILED, user=test, ip=[::ffff:192.168.2.2]
Jan 1 01:27:06 eddy pop3d: Disconnected, ip=[::ffff:192.168.2.2]
Jan 1 01:27:09 eddy postfix/virtual[5753]: fatal: bad string length 0 < 1: virtual_mailbox_base =
Jan 1 01:27:10 eddy postfix/master[5357]: warning: process /usr/lib/postfix/virtual pid 5753 exit status 1
Jan 1 01:27:10 eddy postfix/master[5357]: warning: /usr/lib/postfix/virtual: bad command startup -- throttling

