Support » Fixing WordPress » Site only loading if www included

  • Resolved saganaki

    (@saganaki)


    Hi, I’m setting up a wordpress site at http://www.learningtoflourish.co.uk.

    Problem is only the www link works:
    http://www.learningtoflourish.co.uk ==> works
    learningtoflourish.co.uk ==> Server not found

    I’m pretty sure my zone file set up is correct:

    learningtoflourish.co.uk 900 IN A 66.147.244.219
    www 900 IN CNAME learningtoflourish.co.uk

    Much appreciate some help!

    (Tried changing Settings:WordPress url which failed and had to use phpmyadmin to fix the database and restore the site)

Viewing 5 replies - 1 through 5 (of 5 total)
  • Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    It’s your DNS records that’s currently broken for me.

    $ dig www.learningtoflourish.co.uk
    
    ;; QUESTION SECTION:
    ;www.learningtoflourish.co.uk.	IN	A
    
    ;; ANSWER SECTION:
    www.learningtoflourish.co.uk. 877 IN	CNAME	learningtoflourish.co.uk.learningtoflourish.co.uk.
    learningtoflourish.co.uk.learningtoflourish.co.uk. 900 IN A 66.147.244.219

    The www points to a CNAME “learningtoflourish.co.uk.learningtoflourish.co.uk.
    learningtoflourish.co.uk.learningtoflourish.co.uk” which is probably not exactly what you wanted.

    The DNS A record learningtoflourish.co.uk doesn’t exist.

    Good thing you’re using a small TTL of 900 seconds for your records. It’ll be useful when you fix it. 😉

    Thread Starter saganaki

    (@saganaki)

    Thanks! How can I fix this? When I open my zone file for editing, everything looks ok?:

    @ 28800 IN MX 3 ALT1.ASPMX.L.GOOGLE.COM.
    shortlinks 10800 IN CNAME ghs.google.com.
    mail 900 IN CNAME ghs.google.com.
    calendar 900 IN CNAME ghs.google.com.
    @ 28800 IN MX 3 ALT2.ASPMX.L.GOOGLE.COM.
    @ 28800 IN MX 5 ASPMX2.GOOGLEMAIL.COM.
    start 10800 IN CNAME ghs.google.com.
    @ 28800 IN MX 1 ASPMX.L.GOOGLE.COM.
    docs 900 IN CNAME ghs.google.com.
    www 900 IN CNAME learningtoflourish.co.uk
    learningtoflourish.co.uk 900 IN A 66.147.244.219
    @ 28800 IN MX 5 ASPMX5.GOOGLEMAIL.COM.
    @ 28800 IN MX 5 ASPMX4.GOOGLEMAIL.COM.
    @ 28800 IN MX 5 ASPMX3.GOOGLEMAIL.COM.

    Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    Make a backup copy of your zone in case my advice is horrible. 😉

    It’s these lines.

    www 900 IN CNAME learningtoflourish.co.uk
    learningtoflourish.co.uk 900 IN A 66.147.244.219

    Try changing it to read

    www 900 IN CNAME learningtoflourish.co.uk.
    learningtoflourish.co.uk. 900 IN A 66.147.244.219

    See the “.” affter the .co.uk? That makes the two records explicit, meaning don’t append the domain at the end.

    Don’t forget to increment the zone serial number too.

    Thread Starter saganaki

    (@saganaki)

    Thanks Jan! Devil in the details…

    Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    You’re welcome.

    A misplaced “.” can ruin your day. Keeping the DNS record TTL low like that is a good safety precaution and let’s you fix mistakes in… 900 seconds. 😉

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Site only loading if www included’ is closed to new replies.