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 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.

share|improve this question
    
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. –  Skyhawk 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. –  Skyhawk Jan 30 '11 at 22:43

1 Answer 1

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.

share|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

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.