Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I have edited my apache vhost file in /etc/apache2/sites-enabled to add the following:

<VirtualHost *:80>
ServerName www.mysite.cn
ServerAlias mysite.cn *.mysite.cn
DocumentRoot /home/user/static/mysite/cn
</VirtualHost>

It still points to the default site on the server when i browse to mysite.cn but when i enter anything along the lines of ww3.mysite.cn it point to the new correct document root any clues of what the problem could be as i am lost.

share|improve this question
    
Please provide output to the following command: grep ^[^#] "location of httpd.conf" –  Vick Vega Apr 11 '12 at 1:49
    
The location of httpd.conf is /etc/apache2/ nothing is served out this file.All vhost setting are stored in /etc/apache2/sites-enabled/ –  Paperghost Apr 11 '12 at 1:59
    
Are you sure mysite.cn and ww3.mysite.cn all resolve to IP addresses assigned to this server? –  David Schwartz Apr 11 '12 at 7:09
    
@DavidSchwartz its pointing to the correct ip for this server, dns records are all correct and this server only has ip assigned to it. –  Paperghost Apr 11 '12 at 8:25

1 Answer 1

up vote 0 down vote accepted

The wrong page is cached somewhere; depending on the somewhere try these things:

  • Apache: sudo apache2ctl restart
  • Your web browser: close and restart, perhaps delete cached files, or try another browser
  • Your local computer DNS settings: flush your DNS cache (first Google link)

For obvious performance reasons, both your web browser and your apache server are very dedicated to caching things.

share|improve this answer
    
Thanks for that ,forgot to run apache2ctl restart –  Paperghost Apr 11 '12 at 10:37

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.