Google Apps & Contact Form: Emails Don't Get Sent to G-A

I recently switched over to Google Apps to handle emails for my domains. I can successfully send and receive emails from these Google Apps emails using Mozilla Thunderbird or the standard google interface.

I'm running Wordpress v3 with cforms contact form on my sites. I've set up the contact form to send the submissions to my domain@domain.com running google apps and my yahoo & gmail addresses. I receive any contact form submissions at my yahoo & gmail email accounts, but not at my google apps email inbox. Before Google Apps, I would receive contact form submissions at my domain@domain inbox, now I do not.

If I go into Webmin > Servers > Read User Mail and then click the domain name with the contact form, all the submissions are found there.

My MX:

> ASPMX2.GOOGLEMAIL.COM 30 3600 (1 hour)

ALT2.ASPMX.L.GOOGLE.COM 20 3600 (1 hour)

ALT1.ASPMX.L.GOOGLE.COM 20 3600 (1 hour)

ASPMX.L.GOOGLE.COM 10 3600 (1 hour)

ASPMX3.GOOGLEMAIL.COM 30 3600 (1 hour)

ASPMX4.GOOGLEMAIL.COM 30 3600 (1 hour)

ASPMX5.GOOGLEMAIL.COM 30 3600 (1 hour)

My SPF:

> v=spf1 include:_spf.google.com ~all

Some PostFix settings:

> What domain to use in outbound mail: Use domainname

What domains to receive mail for: Whole domain

Send outgoing mail via host: Deliver directly

I'm running Ubuntu 8.04.3 LTS, Virtualmin v3.80, Google Apps, Dovecot and Postfix. I am not running msmtprc.

11 Replies

So postfix is sending the emails for wordpress correct? If so you need to change your spf to

v=spf1 a include:_spf.google.com ~all

Thank you for the response.

I've adjusted the TXT record to:

> v=spf1 a include:_spf.google.com ~all

I set the TTL to 3600 (1 Hour).

But contact form is still not sending to the google apps inbox, yet sends to my yahoo & gmail inbox. The contact form submissions are still found in Webmin > Servers > Read User Mail.

Ah wait sorry I missed the part where you said it was being retrieved locally.

You need to set the "mydestination" line of your /etc/postfix/main.cf to mydestination = localhost, localhost.$mydomain, localhost

then restart postfix

Edit: oh also keep the spf record with the additional 'a' you'll need it when you start sending from your server.

Should I have myorigin be:

> myorigin = $mydomain

or should I have it be:

> myorigin = /etc/mailname

or something else?

````
/etc/mailname

Here's the bottom portion of mine

myhostname = mail.domain.com
aliasmaps = hash:/etc/aliases aliasdatabase = hash:/etc/aliases
myorigin = /etc/mailname
mydestination = localhost, localhost.$mydomain, localhost
relayhost =
mynetworks = 127.0.0.0/8
mailboxsizelimit = 0
recipientdelimiter = + inetinterfaces = all

````

Restarted Postfix but still not sending the submissions to my google apps inbox (yet successfully sends to my yahoo/gmail inboxes).

Here's my /etc/postfix/main.cf:

> # See /usr/share/postfix/main.cf.dist for a commented, more complete version

Debian specific: Specifying a file name will cause the first

line of that file to be used as the name. The Debian default

is /etc/mailname.

myorigin = /etc/mailname

smtpdbanner = $myhostname ESMTP $mailname (Ubuntu)

biff = no

appending .domain is the MUA's job.

appenddotmydomain = no

Uncomment the next line to generate "delayed mail" warnings

delaywarningtime = 4h

readme_directory = no

TLS parameters

smtpdtlscert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem

smtpdtlskey_file=/etc/ssl/private/ssl-cert-snakeoil.key

smtpdusetls=yes

smtpdtlssessioncachedatabase = btree:${datadirectory}/smtpdscache

smtptlssessioncachedatabase = btree:${datadirectory}/smtpscache

See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for

information on enabling SSL in the smtp client.

alias_maps = hash:/etc/aliases

alias_database = hash:/etc/aliases

mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128

mailboxsizelimit = 0

recipient_delimiter = +

virtualaliasmaps = hash:/etc/postfix/virtual

senderbccmaps = hash:/etc/postfix/bcc

mailbox_command = /usr/bin/procmail-wrapper -o -a $DOMAIN -d $LOGNAME

home_mailbox = Maildir/

smtpdsaslauth_enable = yes

smtpdsaslsecurity_options = noanonymous

brokensaslauth_clients = yes

smtpdrecipientrestrictions = permitmynetworks permitsaslauthenticated rejectunauth_destination

mydestination = localhost, localhost.$mydomain, localhost

myorigin = /etc/mailname

What does your postfix mail.log say?

Thank you for the help obs.

Here's the most recent section of the mail log after I restarted Postfix and tried the contact form again. Where you see MYSERVER is where my server name goes. Where you see DOMAIN is the domain name where the contact form is. You can also see when the contact form is sending to the yahoo mail account. I have no clue what the other domain names are, like wep6, 4girls.ws, guvan.com, mailza, atlaskit - those aren't my domains:

Aug 18 21:57:23 ns1 postfix/smtp[25142]: connect to relay.mymail-in.net[217.20.163.69]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25142]: 2E7371A7A6: to=<pessobselonaf@mymail-in.net>, relay=none, delay=67306, delays=67306/0.06/0.37/0, dsn=4.4.1, status=deferred (connect to relay.mymail-in.net[217.20.16$
Aug 18 21:57:23 ns1 postfix/smtp[25148]: connect to mail.mymail-in.net[217.20.163.8]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25148]: 1F2151A86F: to=<jetarreft@mymail-in.net>, relay=none, delay=424541, delays=424541/0.1/0.36/0, dsn=4.4.1, status=deferred (connect to mail.mymail-in.net[217.20.163.8]$
Aug 18 21:57:23 ns1 postfix/smtp[25146]: connect to mail.mymail-in.net[217.20.163.8]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25146]: 544B81A890: to=<vialbomidoova@mymail-in.net>, relay=none, delay=67306, delays=67305/0.09/0.38/0, dsn=4.4.1, status=deferred (connect to mail.mymail-in.net[217.20.163$
Aug 18 21:57:23 ns1 postfix/smtp[25152]: connect to mail.mymail-in.net[217.20.163.8]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25154]: connect to mail.bdsmstorybondage.com[94.75.206.166]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25152]: D2B711A78A: to=<husoft@mymail-in.net>, relay=none, delay=285881, delays=285881/0.12/0.34/0, dsn=4.4.1, status=deferred (connect to mail.mymail-in.net[217.20.163.8]:2$
Aug 18 21:57:23 ns1 postfix/smtp[25154]: A42641A639: to=<oppolalypecon@bdsmstorybondage.com>, relay=none, delay=67467, delays=67466/0.13/0.33/0, dsn=4.4.1, status=deferred (connect to mail.bdsmstorybondage.$
Aug 18 21:57:23 ns1 postfix/smtp[25138]: connect to relay.mymail-in.net[217.20.163.69]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25138]: 014601A838: to=<unahacagigh@atlaskit.com>, relay=none, delay=424541, delays=424541/0.04/0.43/0, dsn=4.4.1, status=deferred (connect to relay.mymail-in.net[217.20.163$
Aug 18 21:57:23 ns1 postfix/smtp[25136]: connect to mail.mymail-in.net[217.20.163.8]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25133]: connect to relay.mymail-in.net[217.20.163.69]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25133]: EF9951A82C: to=<inveo@metaping.com>, relay=none, delay=243950, delays=243950/0.02/0.47/0, dsn=4.4.1, status=deferred (connect to relay.mymail-in.net[217.20.163.69]:2$
Aug 18 21:57:23 ns1 postfix/smtp[25136]: 0F3271A88D: to=<qarater@mymail-in.net>, relay=none, delay=424538, delays=424538/0.03/0.45/0, dsn=4.4.1, status=deferred (connect to mail.mymail-in.net[217.20.163.8]:$
Aug 18 21:57:23 ns1 postfix/smtp[25144]: 28BB91A7E1: to=<mavies@lipetsk.in>, relay=none, delay=386488, delays=386488/0.08/0.42/0, dsn=4.4.3, status=deferred (Host or domain name not found. Name service erro$
Aug 18 21:57:23 ns1 postfix/smtp[25150]: connect to relay.mymail-in.net[217.20.163.69]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25150]: 12E611A85C: to=<cownkilslowly@lvovs.com>, relay=none, delay=424541, delays=424541/0.11/0.44/0, dsn=4.4.1, status=deferred (connect to relay.mymail-in.net[217.20.163.$
Aug 18 21:57:23 ns1 postfix/smtp[25149]: connect to mail.anal-ne-oral.co.cc[94.75.206.166]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25149]: 1F6AB1A805: to=<varrycibpar@anal-ne-oral.co.cc>, relay=none, delay=214419, delays=214419/0.1/0.46/0, dsn=4.4.1, status=deferred (connect to mail.anal-ne-oral.co.cc[9$
Aug 18 21:57:23 ns1 postfix/smtp[25151]: connect to mail.podiebka.co.cc[94.75.206.166]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25151]: 603F21A350: to=<grearfaparcew@podiebka.co.cc>, relay=none, delay=269032, delays=269031/0.12/0.46/0, dsn=4.4.1, status=deferred (connect to mail.podiebka.co.cc[94.75.$
Aug 18 21:57:23 ns1 postfix/smtp[25140]: connect to mail.mymail-in.net[217.20.163.8]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25156]: connect to ez-email.co.cc[114.207.244.144]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25140]: connect to relay.mymail-in.net[217.20.163.69]:25: Connection refused
Aug 18 21:57:23 ns1 postfix/smtp[25140]: F09F31A7D3: to=<bdca@ua-news.net>, relay=none, delay=67353, delays=67352/0.05/0.82/0, dsn=4.4.1, status=deferred (connect to relay.mymail-in.net[217.20.163.69]:25: C$
Aug 18 21:57:23 ns1 postfix/smtp[25141]: 2D4C81A424: to=<seartynar@sevastopol.in>, relay=mail.sevastopol.in[77.120.99.7]:25, delay=394903, delays=394902/0.06/0.68/0.14, dsn=4.7.1, status=deferred (host mail$
Aug 18 21:57:23 ns1 postfix/smtp[25159]: 9A0B11A51A: to=<equinewep@sevastopol.in>, relay=mail.sevastopol.in[77.120.99.7]:25, delay=67467, delays=67466/0.16/0.66/0.14, dsn=4.7.1, status=deferred (host mail.s$
Aug 18 21:57:23 ns1 postfix/smtp[25156]: connect to ez-email.co.cc[114.207.244.145]:25: Connection refused
Aug 18 21:57:24 ns1 postfix/smtp[25147]: 10EC01A803: host relay.inmail24.com[217.198.113.91] said: 450 4.1.8 <www-data@ns1.myserver.com>: Sender address rejected: Domain not found (in reply to RCPT TO comman$
Aug 18 21:57:24 ns1 postfix/smtp[25156]: connect to ez-email.co.cc[114.207.244.143]:25: Connection refused
Aug 18 21:57:24 ns1 postfix/smtp[25156]: connect to ez-email.co.cc[114.207.244.146]:25: Connection refused
Aug 18 21:57:24 ns1 postfix/smtp[25156]: 30C821A83F: to=<reunataksteh19@ez-email.co.cc>, relay=none, delay=243910, delays=243909/0.15/1.4/0, dsn=4.4.1, status=deferred (connect to ez-email.co.cc[114.207.244$
Aug 18 21:57:24 ns1 postfix/smtp[25153]: DFF351A7FB: to=<fasouhsob@xsecurity.org>, relay=relay.mydomain-in.co.uk[72.55.168.89]:25, delay=243952, delays=243950/0.13/0.39/1.1, dsn=4.7.1, status=deferred (host$
Aug 18 21:57:25 ns1 postfix/smtp[25147]: 10EC01A803: to=<zaykomoyox@inmail24.com>, relay=relay.inmail24.com[217.198.113.80]:25, delay=67354, delays=67352/0.09/1.8/0.32, dsn=4.1.8, status=deferred (host rela$
Aug 18 21:57:27 ns1 postfix/pickup[25130]: 854721A539: uid=33 from= <www-data>Aug 18 21:57:27 ns1 postfix/cleanup[25166]: 854721A539: message-id=<722a320d91381b2d23dcc8123f04cbdb@michaelemilio.com>?
Aug 18 21:57:27 ns1 postfix/qmgr[25131]: 854721A539: from=<www-data@ns1.myserver.com>, size=2974, nrcpt=2 (queue active)
Aug 18 21:57:27 ns1 postfix/smtp[25135]: 854721A539: to=<domain@ns1.myserver.com>, orig_to=<michael@domain.com>, relay=none, delay=0.02, delays=0.01/0/0/0, dsn=5.4.4, status=bounced (Host or do$
Aug 18 21:57:28 ns1 postfix/smtp[25139]: 854721A539: to=<mike@yahoo.com>, relay=i.mx.mail.yahoo.com[74.6.140.64]:25, delay=0.76, delays=0.01/0/0.29/0.45, dsn=2.0.0, status=sent (250 ok dirdel)
Aug 18 21:57:28 ns1 postfix/cleanup[25166]: 48E6F1A56D: message-id=<20100819015728.48E6F1A56D@ns1.MYSERVER.com>
Aug 18 21:57:28 ns1 postfix/bounce[25167]: 854721A539: sender non-delivery notification: 48E6F1A56D
Aug 18 21:57:28 ns1 postfix/qmgr[25131]: 48E6F1A56D: from=<>, size=4946, nrcpt=1 (queue active)
Aug 18 21:57:28 ns1 postfix/qmgr[25131]: 854721A539: removed
Aug 18 21:57:28 ns1 postfix/smtp[25134]: 48E6F1A56D: to=<www-data@ns1.myserver.com>, relay=none, delay=0, delays=0/0/0/0, dsn=5.4.4, status=bounced (Host or domain name not found. Name service error for name$
Aug 18 21:57:28 ns1 postfix/qmgr[25131]: 48E6F1A56D: removed
Aug 18 21:57:35 ns1 postfix/smtp[25143]: 205031A39A: to=<shop@searchengineshome.org>, relay=none, delay=243921, delays=243909/0.07/12/0, dsn=4.4.3, status=deferred (Host or domain name not found. Name servi$
Aug 18 21:57:35 ns1 postfix/smtp[25158]: 93B481A84C: to=<weevehefbon@mailza.com>, relay=none, delay=67469, delays=67456/0.16/12/0, dsn=4.4.3, status=deferred (Host or domain name not found. Name service err$
Aug 18 21:57:43 ns1 postfix/smtp[25137]: connect to guvan.com[74.117.116.96]:25: Connection timed out
Aug 18 21:57:43 ns1 postfix/smtp[25137]: 0719C1A889: to=<5@guvan.com>, relay=none, delay=424534, delays=424513/0.03/21/0, dsn=4.4.1, status=deferred (connect to guvan.com[74.117.116.96]:25: Connection timed$
Aug 18 21:57:44 ns1 postfix/smtp[25145]: connect to 4girls.ws[64.70.19.33]:25: Connection timed out
Aug 18 21:57:44 ns1 postfix/smtp[25145]: 25C171A816: to=<naebi@4girls.ws>, relay=none, delay=243930, delays=243909/0.08/21/0, dsn=4.4.1, status=deferred (connect to 4girls.ws[64.70.19.33]:25: Connection tim$
Aug 18 21:57:44 ns1 postfix/smtp[25160]: connect to wep6.com[208.73.210.28]:25: Connection timed out
Aug 18 21:57:44 ns1 postfix/smtp[25160]: 9C0481A775: to=<52@wep6.com>, relay=none, delay=67480, delays=67458/0.17/21/0, dsn=4.4.1, status=deferred (connect to wep6.com[208.73.210.28]:25: Connection timed ou$
Aug 18 21:57:44 ns1 postfix/smtp[25155]: connect to minivds.ru[193.232.158.145]:25: Connection timed out
Aug 18 21:58:05 ns1 postfix/smtp[25155]: connect to minivds.ru[193.232.159.145]:25: Connection timed out
Aug 18 21:58:26 ns1 postfix/smtp[25155]: connect to minivds.ru[193.232.158.144]:25: Connection timed out</naebi@4girls.ws></weevehefbon@mailza.com></shop@searchengineshome.org></www-data@ns1.myserver.com></mike@yahoo.com></michael@domain.com></domain@ns1.myserver.com></www-data@ns1.myserver.com></www-data></zaykomoyox@inmail24.com></fasouhsob@xsecurity.org></reunataksteh19@ez-email.co.cc></www-data@ns1.myserver.com></equinewep@sevastopol.in></seartynar@sevastopol.in></bdca@ua-news.net></grearfaparcew@podiebka.co.cc></varrycibpar@anal-ne-oral.co.cc></cownkilslowly@lvovs.com></mavies@lipetsk.in></qarater@mymail-in.net></inveo@metaping.com></unahacagigh@atlaskit.com></oppolalypecon@bdsmstorybondage.com></husoft@mymail-in.net></vialbomidoova@mymail-in.net></jetarreft@mymail-in.net></pessobselonaf@mymail-in.net>

Here are my A/AAAA records:

> Host Name:

IP Address: 97.000.000.00 (my ip address)

Host Name: www

IP Address: 97.000.000.00(my ip address)

Host Name: mail

IP Address: 97.000.000.00(my ip address)

Tried the contact form again, here's another mail log section after that:

Aug 18 22:09:03 ns1 postfix/anvil[26302]: statistics: max connection rate 1/60s for (smtp:202.175.216.166) at Aug 18 22:05:40
Aug 18 22:09:03 ns1 postfix/anvil[26302]: statistics: max connection count 1 for (smtp:202.175.216.166) at Aug 18 22:05:40
Aug 18 22:09:03 ns1 postfix/anvil[26302]: statistics: max cache size 1 at Aug 18 22:05:40
Aug 18 22:10:50 ns1 postfix/pickup[25130]: 8CD781A569: uid=33 from= <www-data>Aug 18 22:10:50 ns1 postfix/cleanup[26990]: 8CD781A569: message-id=<e6a8b56b41855e95a663377b1a6224cc@domain.com>?
Aug 18 22:10:50 ns1 postfix/qmgr[25131]: 8CD781A569: from=<www-data@ns1.myserver.com>, size=2885, nrcpt=2 (queue active)
Aug 18 22:10:50 ns1 postfix/smtp[26992]: 8CD781A569: to=<domain@ns1.myserver.com>, orig_to=<michael@domain.com>, relay=none, delay=0.03, delays=0.02/0.01/0/0, dsn=5.4.4, status=bounced (Host or$
Aug 18 22:10:51 ns1 postfix/smtp[26993]: 8CD781A569: to=<mike@yahoo.com>, relay=d.mx.mail.yahoo.com[209.191.88.254]:25, delay=1.2, delays=0.02/0.02/0.4/0.77, dsn=2.0.0, status=sent (250 ok dirdel)
Aug 18 22:10:51 ns1 postfix/cleanup[26990]: BB91D1A56D: message-id=<20100819021051.BB91D1A56D@ns1.MYSERVER.com>
Aug 18 22:10:51 ns1 postfix/qmgr[25131]: BB91D1A56D: from=<>, size=4857, nrcpt=1 (queue active)
Aug 18 22:10:51 ns1 postfix/bounce[26994]: 8CD781A569: sender non-delivery notification: BB91D1A56D
Aug 18 22:10:51 ns1 postfix/qmgr[25131]: 8CD781A569: removed
Aug 18 22:10:51 ns1 postfix/smtp[26992]: BB91D1A56D: to=<www-data@ns1.myserver.com>, relay=none, delay=0, delays=0/0/0/0, dsn=5.4.4, status=bounced (Host or domain name not found. Name service error for name$
Aug 18 22:10:51 ns1 postfix/qmgr[25131]: BB91D1A56D: removed
Aug 18 22:12:22 ns1 postfix/qmgr[25131]: E61A11A83C: from=<www-data@ns1.myserver.com>, size=678, nrcpt=1 (queue active)
Aug 18 22:12:22 ns1 postfix/qmgr[25131]: 052311A8A4: from=<www-data@ns1.myserver.com>, size=589, nrcpt=1 (queue active)
Aug 18 22:12:22 ns1 postfix/qmgr[25131]: DE17E1A87C: from=<www-data@ns1.myserver.com>, size=583, nrcpt=1 (queue active)
Aug 18 22:12:22 ns1 postfix/qmgr[25131]: DD1E61A89A: from=<www-data@ns1.myserver.com>, size=595, nrcpt=1 (queue active)
Aug 18 22:12:22 ns1 postfix/qmgr[25131]: DF1011A86A: from=<www-data@ns1.myserver.com>, size=594, nrcpt=1 (queue active)
Aug 18 22:12:22 ns1 postfix/qmgr[25131]: C380A1A8A3: from=<www-data@ns1.myserver.com>, size=592, nrcpt=1 (queue active)
Aug 18 22:12:22 ns1 postfix/qmgr[25131]: 9F9761A840: from=<www-data@ns1.myserver.com>, size=691, nrcpt=1 (queue active)
Aug 18 22:12:22 ns1 postfix/smtp[27140]: connect to mail.mymail-in.net[217.20.163.8]:25: Connection refused
Aug 18 22:12:23 ns1 postfix/smtp[27140]: connect to relay.mymail-in.net[217.20.163.69]:25: Connection refused
Aug 18 22:12:23 ns1 postfix/smtp[27138]: connect to hotmail.insky.biz[62.80.127.189]:25: Connection refused</www-data@ns1.myserver.com></www-data@ns1.myserver.com></www-data@ns1.myserver.com></www-data@ns1.myserver.com></www-data@ns1.myserver.com></www-data@ns1.myserver.com></www-data@ns1.myserver.com></www-data@ns1.myserver.com></mike@yahoo.com></michael@domain.com></domain@ns1.myserver.com></www-data@ns1.myserver.com></e6a8b56b41855e95a663377b1a6224cc@domain.com></www-data>

Ok looks like you have a few issues…

1) You possibly have an open relay due to the connect messages from strange domains, you should check at http://www.abuse.net/relay.html

2) Your mail is being sent from ns1.MYSERVER.com this is probably not your desired from, I imagine it should be MYSERVER.com or mail.MYSERVER.com check your hostname and /etc/mailname

3) Once you correct number 2) your bounced messages from lines like " to=<www-data@ns1.MYSERVER.com>, relay=none, delay=0, delays=0/0/0/0, dsn=5.4.4, status=bounced (Host or domain name not found. Name service error for name$ " should reach you and you can diagnose the issue.

Thanks a ton for the help obs.

Tried abuse.net, put in my server ip address, and got a good result:

> Relay test result

All tests performed, no relays accepted.

About ns1.myserver.com… I choose that because I had read in the virtualmin documentation and forums that you need a FQDM as the hostname so I had chosen ns1.myserver.com:

http://www.virtualmin.com/node/13246

> An FQDN is typically in the form of "hostname.domain.com". That is, pick a domain name that you want to use for your server… for many folks, this is their company domain name, or perhaps a personal domain that you host. Then, add onto that an arbitrary hostname. And then you've got your FQDN! Afterwards, what you'd want to do is setup a DNS 'a' record for your FQDN. So if you setup "hostname.domain.com" as your FQDN, you'll need to set it up so that the name resolves to an IP address. If you're hosting DNS on your Virtualmin server, you can setup the 'a' record in Services -> DNS Domain.

http://www.virtualmin.com/documentation … /automated">http://www.virtualmin.com/documentation/installation/automated
> Fully qualified domain name

If your system does not have a fully qualified domain name (FQDN), the installer will stop and ask you to choose one. This is mandatory because many services rely on having a fully qualified domain name in order to function. Mail, in particular, but some Apache configurations and many of the Virtualmin-created configuration files, also require a valid fully qualified domain name to function correctly. A fully qualified domain name is one of the form "www.virtualmin.com", or simply "virtualmin.com". We recommend you choose a name that is not one for which you will be receiving mail, in order to simplify later configuration. A good choice is to use a name server designator, such as "ns1.virtualmin.com". Some customers also choose something like "host1.virtualmin.com" or "primary.virtualmin.com". Any of these would be valid and would satisfy the install script and the services that rely on this option. The install script will add this name to /etc/hosts, which will satisfy all local services. It is even better if this name resolves correctly when looked up from outside of the system–this requires the name be added to your DNS zone for the second level domain. If the Virtualmin server you are installing will be the authoritative name server for this zone, you can later use Webmin to add a record for this name to the zone.

Do I have to use something like ns1.myserver.com or can I just use myserver.com or even just myserver as my server hostname?

well it does have to be a FQDN but your emails are being sent from ns1.MYSERVER.COM and bounced back to it…but ns1.myserver.com doesn't appear to have any MX records

Aug 18 21:57:28 ns1 postfix/smtp[25134]: 48E6F1A56D: to=<www-data@ns1.MYSERVER.com>, relay=none, delay=0, delays=0/0/0/0, dsn=5.4.4, status=bounced (Host or domain name not found. Name service error for name$

which made me assume you should have set it to MYSERVER.COM

Ensure ns1.MYSERVER.COM has A and MX records set, not just MYSERVER.COM

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct