Can only access site using www (know cause but not solution)
Without the "www" I see…
It works!
This is the default web page for this server.
The web server software is running but no content has been added, yet.
I have uploaded a simple index.html file into my public_html folder and with the "www" I see file loads.
Anyone have any insight on what may be causing this?
Thank you in advance from a rookie Linode user.
Additional info…
It had been working fine for me with Drupal installed and then this issue occured. I could not figure out my issue and reinstalled my linux distrobution to see if that fixed it and I also removed my DNS settings and started fresh there as well. Neither seemed to have worked.
7 Replies
1st guess - did you check to see if both domain.com and
I followed this step by step.
Any ideas? My test emails do work.
Also I installed my LAMP server off of the Linode guide.
Thanks.
Before proceeding, make sure your /etc/hosts file has valid entries. For reference, your file should resemble the following:
File: /etc/hosts
127.0.0.1 localhost.localdomain localhost
12.34.56.78 hostname.yourdomain.com hostname
Be sure to replace "12.34.56.78" with your Linode's IP address. Replace "hostname.yourdomain.com" with your Linode's fully qualified domain name. Next, make sure your hostname is set in /etc/hostname by issuing the following commands (insert your one-word hostname in place of "hostname").
echo "hostname" > /etc/hostname
hostname -F /etc/hostname
Issue the following commands to check your setup:
hostname
hostname -f
The first command should return only the one-word hostname for your system, while the second command should return the system's FQDN.
If I add…
12.34.56.78 hostname.yourdomain.com hostname
with my server ip, domain.com domain
It is causing my issue. Any thoughts? If I remove the second line it does not.
[b]127.0.0.1 localhost.localdomain localhost [/b]
12.34.56.78 hostname.yourdomain.com hostname
I just kept the first line and did not include the second and all is well. Everything is working as it should. Any issues I may see from it?
RewriteEngine On
RewriteCond %{HTTP_HOST} ^yourdomain.com
RewriteRule (.*) http://www.yourdomain.com/$1 [R=301,L]
Thanks for the help.
I will say one thing… the extra work it took to learn how to set all of this up was well worth it. I have never had a site run this fast. Very pleased.