LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-24-2007, 10:38 AM   #1
mwecomputers
LQ Newbie
 
Registered: Jul 2007
Location: North Augusta, SC USA
Distribution: CentOS, RHEL, Scyld, Slackware, Solaris, SuSE, SLED, OpenSUSE
Posts: 20

Rep: Reputation: 0
Subdomain pass through


Recently we migrated an entire development/internal domain to fully qualified external domain name. We have already updated the DNS for both the old site to point to our redirect server and new site domain location. The problem we have now is that we cannot redirect from the old subdomain.domain.com name to the new subdomain.newdomain.com one.

We are running Apache 1.3.37 with mod_alias and mod_rewrite modules enabled.

This is what is needed to happen: ourcity.domain.com --> ourcity.newdomain.com

I wrote the following out as per our virthosts-redirect.conf file on the redirect server:

<VirtualHost redirect.ourdomain.com>
ServerName domain.com
ServerAlias www.domain.com
ServerAlias *.domain.com
CustomLog /dev/null common
ErrorLog /dev/null

RewriteEngine On
RewriteCond %{HTTP_HOST} ^([^.]+)\.domain\.com$ [NC]
RewriteRule ^(.*)$ http://%1.newdomain.com [L]
</VirtualHost>

Is there a way to divert all subdomain names from the old site and pass it on the the new site keeping the subdomain intact?

-- Michael
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Subdomain->IP? johndmann Linux - Networking 5 04-03-2006 04:09 AM
questions on GCC-3.4.3 - Pass 2 and Binutils-2.15.94.0.2.2 - Pass 2 satimis Linux From Scratch 7 12-26-2005 09:23 PM
Planning to change root pass and oracle system pass sathyguy Red Hat 1 12-20-2005 09:53 PM
Subdomain help DoobyWho Linux - General 3 04-14-2003 06:51 PM
subdomain deepak Linux - Networking 2 03-01-2001 09:50 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:17 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration