# virtual hosting howto document, PLEASE HELP

## wizy

(ive gotta get this server up today)

After starting this, I am at the part in code listing 2.2

```

 Code listing 2.2: /etc/postfix/main.cf

myhostname = $host.domain.name

mydomain = $domain.name

inet_interfaces = all

mydestination = $myhostname, localhost.$mydomain $mydomain

mynetworks = my.ip.net.work/24, 127.0.0.0/8

home_mailbox = .maildir/

local_destination_concurrency_limit = 2

default_destination_concurrency_limit = 10 

```

After doing that and the other things I got to the part to do the aliases and I get this:

server /root # /usr/bin/newaliases 

newaliases: warning: valid_hostname: misplaced delimiter: .domain.name

newaliases: fatal: file /etc/postfix/main.cf: parameter myhostname: bad parameter value: .domain.name

I did exactly what it showed, anyone know the problem?Last edited by wizy on Tue Sep 23, 2003 9:18 pm; edited 1 time in total

----------

## Earthwings

haven't done this myself, but I think the author wants you to replace $domain.name with your domain name and so on...

----------

## wizy

I thought that but all the other code listings were word for word what they should be, so I figured it should be what he put in there.

----------

## pjp

Moved from Installing Gentoo.

----------

## wizy

Im having trouble.  I put the domain name and email address in the database.  But it is denying the email to the address saying relaying isnt allowed.  Whats the problem?

Since postfix wont put mail in the right place, and is bouncing it, it isnt creating the directories for the users when they get their first email:

Sep 24 00:18:16 [imapd] Connection, ip=[127.0.0.1]

Sep 24 00:18:16 [imapd] LOGIN, user=jeremy@wizy.ev6.net, ip=[127.0.0.1]

Sep 24 00:18:16 [imapd] chdir /home/vmail/wizy.ev6.net/jeremy/.maildir/: No such file or directory

But that shows that imap and squirrelmail are working fine.  Just need to get postfix accepting email from the domain.

EDIT:

When I add wizy.ev6.net to the mydestination in main.cf it actually tries to accept it now.  But then it gets to this:

Sep 24 00:46:43 [postfix/smtpd] > sc.am[63.208.193.192]: 250 Ok: queued as 7F1E73E0195

Sep 24 00:46:43 [postfix/local] 7F1E73E0195: to=<jeremy@wizy.ev6.net>, relay=local, delay=0, status=bounced (unknown user: "jeremy")

Sep 24 00:46:43 [postfix/cleanup] 948763E0196: message-id=<20030924054643.948763E0196@paradiesanalytics.com>

Sep 24 00:46:43 [postfix/qmgr] 948763E0196: from=<>, size=2547, nrcpt=1 (queue active)

It does that even though it finds this:

Sep 24 00:46:43 [postfix/smtpd] maps_find: virtual_alias_maps: @wizy.ev6.net: not found

Sep 24 00:46:43 [postfix/smtpd] mail_addr_find: jeremy@wizy.ev6.net -> (not found)

Sep 24 00:46:43 [postfix/smtpd] dict_mysql_lookup using sql query: select destination from alias where alias = 'jeremy@wizy.ev6.net' 

Sep 24 00:46:43 [postfix/smtpd] dict_mysql: attempting to connect to host unix:/var/run/mysqld/mysqld.sock

Sep 24 00:46:43 [postfix/smtpd] dict_mysql: successful connection to host unix:/var/run/mysqld/mysqld.sock

Sep 24 00:46:43 [postfix/smtpd] dict_mysql: successful query from host unix:/var/run/mysqld/mysqld.sock

Sep 24 00:46:43 [postfix/smtpd] dict_mysql_lookup: retrieved 0 rows

Sep 24 00:46:43 [postfix/smtpd] dict_mysql_lookup using sql query: select maildir from users where email = 'jeremy@wizy.ev6.net' and postfix = 'y'

Sep 24 00:46:43 [postfix/smtpd] dict_mysql: attempting to connect to host unix:/var/run/mysqld/mysqld.sock

Sep 24 00:46:43 [postfix/smtpd] dict_mysql: successful connection to host unix:/var/run/mysqld/mysqld.sock

Sep 24 00:46:43 [postfix/smtpd] dict_mysql: successful query from host unix:/var/run/mysqld/mysqld.sock

Sep 24 00:46:43 [postfix/smtpd] dict_mysql_lookup: retrieved 1 rows

Sep 24 00:46:43 [postfix/smtpd] maps_find: local_recipient_maps: mysql:/etc/postfix/mysql-virtual-maps.cf: jeremy@wizy.ev6.net = /home/vmail/wizy.ev6.net/jeremy/.maildir/

Sep 24 00:46:43 [postfix/smtpd] mail_addr_find: jeremy@wizy.ev6.net -> /home/vmail/wizy.ev6.net/jeremy/.maildir/

So it figured out where to deliver it, but it didnt deliver it?

----------

## wizy

fixed it. thanks everyone

----------

## R0Bzombie

 *wizy wrote:*   

> (ive gotta get this server up today)
> 
> After starting this, I am at the part in code listing 2.2
> 
> ```
> ...

 

I have the exact same problem so if wizy could tell me what he've done I'll be more than happy.

----------

## einstein14

exactly the same probleme too could you explain the way to fix it?

thanks a  lot

----------

## å×ÒÅÊ

 *wizy wrote:*   

> fixed it. thanks everyone

  can you tell us how you fixed it. 

----------

## wizy

If I had gotten one of these replies back then when I actually fixed it I could help.  But it has been a long time and I have since moved to a new method for all my servers.

----------

