DNS settings:Can you spot what I might have entered wrongly?

Hi everyone,

I would greatly appreciate it if someone could help point out what I might have done wrong in trying to map a folder on our server i.e mywebsite.com/abc to a similarly named subdomain i.e abc.mywebsite.com.

Here's what our Linode DNS entries look like:

–-----------------------------------------------------

DNS Manager » abc.mywebsite.coom

SOA Record

Primary DNS Email Default TTL Refresh Rate Retry Rate Expire Time Options

ns1.linode.com me@myemail.com Default Default Default Default Settings

NS Records

Name Server Subdomain TTL Options

ns1.linode.com abc.mywebsite.com Default Edit | Remove

ns2.linode.com abc.mywebsite.com Default Edit | Remove

ns3.linode.com abc.mywebsite.com Default Edit | Remove

ns4.linode.com abc.mywebsite.com Default Edit | Remove

ns5.linode.com abc.mywebsite.com Default Edit | Remove

Add a new NS record

MX Records

Mail Server Preference Subdomain TTL Options

mail.mywebsite.com 10 Default Edit | Remove

Add a new MX record

A/AAAA Records

Hostname IP Address TTL Options

12.34.56.78 Default Edit | Remove

mail 12.34.56.79 Default Edit | Remove

Add a new A record

CNAME Records

Hostname Aliases to TTL Options

www abc.mywebsite.com Default Edit | Remove

Add a new CNAME record

TXT Records

Name Value TTL Options

Add a new TXT record

SRV Records

Service Domain Priority Weight Port Target TTL Options


..and here's what the virtual hosts section of Apache config file looks like:

ServerAdmin webmaster@mywebsite.com

DocumentRoot /var/www/vhosts/mywebsite.com/httpdocs/

ServerName mywebsite.com

ServerAlias http://www.mywebsite.com

AllowOverride all

Alias /webmail "/var/www/html/webmail/"

Alias /postfixadmin "/var/www/html/postfixadmin"

ErrorLog logs/mywebsite.com-error_log

CustomLog logs/mywebsite.com-access_log common

ServerAdmin webmaster@mywebsite.com

DocumentRoot /var/www/vhosts/mywebsite.com/httpdocs/

ServerName mywebsite.com

ServerAlias http://www.mywebsite.com

AllowOverride all

Alias /webmail "/var/www/html/webmail/"

Alias /postfixadmin "/var/www/html/postfixadmin"

ErrorLog logs/mywebsite.com-error_log

CustomLog logs/mywebsite.com-access_log common

SSLEngine on

SSLCertificateFile /etc/pki/tls/certs/mywebsite.crt

SSLCertificateKeyFile /etc/pki/tls/private/mywebsite.key

SSLCACertificateFile /etc/pki/tls/certs/ssl123.crt

ServerAdmin webmaster@mywebsite.com

DocumentRoot /var/www/vhosts/mywebsite.com/httpdocs/

ServerName abc.mywebsite.com

ServerAlias abc.mywebsite.com

AllowOverride all

Alias /webmail "/var/www/html/webmail/"

Alias /postfixadmin "/var/www/html/postfixadmin"

ErrorLog logs/mywebsite.com.com-error_log

CustomLog logs/mywebsite.com-access_log common

SSLEngine on

SSLCertificateFile /etc/pki/tls/certs/mywebsite.crt

SSLCertificateKeyFile /etc/pki/tls/private/mywebsite.key

SSLCACertificateFile /etc/pki/tls/certs/ssl123.crt


I copied the 3rd section of the virtual host section of our Apache config from the second section and made modifications to it.

Thanks.

5 Replies

The site just started resolving…but abc.mywebsite.com its resolving to mywebsite.com.

I'm now thinking that there must be an issue with the Apache config file..

Can anyone help spot it?

Check your DocumentRoot for abc.

Hi Nibbler,

Thanks for your response.

I have changed document root to

/var/www/vhosts/mywebsite.com/httpdocs/abc 

and/or

/var/www/vhosts/mywebsite.com/httpdocs/abc/ 

and restarted the server a number of times.

abc.mywebsite.com still resolves to mywebsite.com.

Could there be other factors that could be responsible?

e.g my DNS entries for creating this subdomain. Here's what my DNS entries look like:

DNS Manager » abc.mywebsite.coom

SOA Record
Primary DNS    Email   Default TTL Refresh Rate    Retry Rate  Expire Time Options
ns1.linode.com    me@myemail.com   Default     Default     Default     Default    Settings

NS Records
Name Server    Subdomain   TTL Options
ns1.linode.com    abc.mywebsite.com    Default    Edit | Remove
ns2.linode.com    abc.mywebsite.com    Default    Edit | Remove
ns3.linode.com    abc.mywebsite.com    Default    Edit | Remove
ns4.linode.com    abc.mywebsite.com    Default    Edit | Remove
ns5.linode.com    abc.mywebsite.com    Default    Edit | Remove
Add a new NS record

MX Records
Mail Server    Preference  Subdomain   TTL Options
mail.mywebsite.com    10   Default    Edit | Remove
Add a new MX record

A/AAAA Records
Hostname    IP Address  TTL Options
12.34.56.78     Default    Edit | Remove
mail    12.34.56.79  Default    Edit | Remove
Add a new A record

CNAME Records
Hostname    Aliases to  TTL Options
www    abc.mywebsite.com    Default    Edit | Remove
Add a new CNAME record

TXT Records
Name    Value   TTL Options
Add a new TXT record

SRV Records
Service    Domain  Priority    Weight  Port    Target  TTL Options

Are you able to spot anything I might have entered wrongly?

Thanks.

RH19,

I don't see a vhosts config for 12.34.56.78:80 for abc.mywebsite.com. Have you tried accessing it via https to see if the :443 config is working for abc.mywebsite.com ?

MSJ

Maybe you could obscure the PUBLIC DNS settings and the PUBLIC IP numbers even more to make it even harder to guess what's going on with your PUBLIC website.

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