Question about multiple domains on VPS account

Jan Wojtasinski

New Member
I am relatively new to VPS and have a question about hosting 2 (or 3) domains from my account. Currently i have my first domain setup with my primary IP. To access the site i need to browse to XXX.XXX.XXX.XXX/accountfolder. Is there a recommended process for directing my domain name to this folder. Should I use Virtual Hosts to accomplish this?

When the time comes to add my second domain, should i simply setup another account in WHM and direct traffic to the appropriate folder using httpd.conf? The second domain is not related to the first domain, is it OK to use the primary domains DNS server's?

Am I missing a step with assigning anything in DNS? Is there a better way to accomplish multiple domains on 1 IP address?

Thanks,

Jan
 
I will try to help if I understand your questions correctly.
I am relatively new to VPS and have a question about hosting 2 (or 3) domains from my account. Currently i have my first domain setup with my primary IP. To access the site i need to browse to XXX.XXX.XXX.XXX/accountfolder. Is there a recommended process for directing my domain name to this folder. Should I use Virtual Hosts to accomplish this?
Have you setup your name servers in your WHM? if so all you need do is go to where you have registered your domain name and point it to your ns1.your domain.com and ns2.your domain.com your cPanel/WHM will do the rest.

When the time comes to add my second domain, should i simply setup another account in WHM and direct traffic to the appropriate folder using httpd.conf? The second domain is not related to the first domain, is it OK to use the primary domains DNS server's?
Just create a new account in your cPanel/WHM and do the same as above.

Have you created any packages to assign to your accounts yet?
This may also help:
http://forums.knownhost.com/threads/creating-accounts-domains.1345/
http://forums.knownhost.com/forums/cpanel-howtos-and-tutorials.9/
 
Last edited:
Dave,

Thanks for the reply. My account was migrated from another server and CPanel account. Nameservers are all set, and when I am done testing i will officially change DNS records through the registrar. If i understand you correctly there is no need for me to setup any redirects to have my domain correctly link to the home folder of the site at xxx.xxx.xxx.xxx/~username. CPanel will automatically handle this?

To clarify what I want done:

Site 1:

www.site1.com -> 111.111.111.111/~site1

Site 2:

www.site2.com -> 111.111.111.111/~site2

I have yet to create any packages as it was not necessary for the migration. When i create a new account from scratch i will use a package.

Thanks
 
Dave,

Thanks for the reply. My account was migrated from another server and CPanel account. Nameservers are all set, and when I am done testing i will officially change DNS records through the registrar. If i understand you correctly there is no need for me to setup any redirects to have my domain correctly link to the home folder of the site at xxx.xxx.xxx.xxx/~username. CPanel will automatically handle this?

To clarify what I want done:

Site 1:

www.site1.com -> 111.111.111.111/~site1

Site 2:

www.site2.com -> 111.111.111.111/~site2

I have yet to create any packages as it was not necessary for the migration. When i create a new account from scratch i will use a package.

Thanks
Jan

Yes you have it correct as long as you have your home page index.xxx file in your [root]> public_html folder when you change/update the nameserver at your registrar things will start working in a few hours as this change will need to be updated all over the internet to put it simply.
IP/~username is generally only used in testing to make sure the site is working.

And by the way Welcome to KH I think you will be happy here, may I ask where you moved from, maybe HG?
 
Dave,

Thanks again. As i mentioned i'm new to the whole VPS thing. My Joomla site is setup in the IP/~username folder so it should be good to go. Will i need to further configure my URL rewriting rules? As of now to utilize url rewriting I have had to add the /~username base to my .htaccess. Since IP/~username is just used to access the site during testing I take it I should not have to include the ~username in the rewrite base to have the feature work after after the DNS has been transfered?
 
Jan
mod_rewrite doesn't like the IP/~username thing what I normally do is turn off the nice URL setting in the Joomla control panel, test a few pages, turn the nice URL back on. I do this on one or two sites and figure the rest will work :).
So yes you should put your .htaccess back as it was and point away.

Sorry for the delayed replies I am in the middle of pickling and canning beets!!!
 
Top