main website redirecting to virtual host's website?

November 6, 2019 507 views
Apache WordPress Ubuntu 16.04

Hello Team,

I have an issue regarding redirection of websites. I have two website on one IP address.Initially main website was which was working fine if we hit the website by typing either or Website was working fine. But now I have created the virtual host for my another website which is website is also working fine either by typing or But now main problem is if I run the main website by it is redirecting to second one website( Will you please help me may be I have done something wrong while configuration. root path of my file is
-main websites file(

1 comment
  • I have performed the same (creation of virtual host) on another IP but I am not facing this issue. This issue appeared when ever I enable lets encrypt SSL certificate for new created website(on virtual host).

1 Answer

I have resolved this issue.I have also created new conf file for the main website( ) having path /etc/apache2/sites-available/ and after that websites start to work.

Have another answer? Share your knowledge.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!