I have a dedicated server with a bunch of stuff on it already. Basically, I am accessing it now with the free domain I got when I purchased the server (http://example.com/directory, etc).

I also have a second domain I want to use with a specific subdirectory (http://exampletwo.com/ should basically work as if I were under http://example.com/two, but it should use the exampletwo domain.

I would assume I would change the A record of the second domain to the IP of the server, but how do I make it work with a subdirectory? I have full DNS control of the second domain but it is purchased on from a different registrar than the dedicated server.

link|improve this question

60% accept rate
What OS are you using? – Jacob Jan 30 '11 at 22:33
Is this "dedicated server" a VPS that is hosted in the cloud somewhere? Are you using Windows/IIS, Linux/Apache, or something else? Ask an absurdly general question and you are likely to get an absurdly general answer. – Miles Erickson Jan 30 '11 at 22:34
@Miles I agree about needing what OS it is running, but I don't see the need for if it's a VPS or Dedicated. – Jacob Jan 30 '11 at 22:39
I also agree that we need to know which OS or at the very least which web server you're running. – Mike Brown Jan 30 '11 at 22:42
Often, a VPS will come preinstalled with management tools, e.g. Webmin/Virtualmin or WHM/Cpanel. Understanding the specific nature of the server or VPS would enable us to identify the simplest solution. – Miles Erickson Jan 30 '11 at 22:43
show 4 more comments
feedback

1 Answer

up vote 2 down vote accepted

how do I make it work with a subdirectory?

Use HTTP redirect/rewrite or virtual host.

Settings depend on the web-server.

link|improve this answer
I'm going to mark this as the answer since my original question did not assume that I had Plesk or other management software available. – Andrew M Jan 31 '11 at 1:57
feedback

Your Answer

 
or
required, but never shown

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