Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 03-25-2011, 03:12 AM   #1
Registered: Jul 2008
Location: Chennai, India
Distribution: RHEL5, Ubuntu
Posts: 191

Rep: Reputation: 37
An Apache related query

I have a query related to GET requests:

Main site name: (for example).

subdomain sites:,,, etc.

Web server: Apache.

All the above-said sites run in the same server via virtual hosting.

My question is as follows:

Suppose I disable the site Now, when someone access the site, it will go to the default site (by means of the alphabetical order priority). Also, if the user types, there will be a log in /var/log/httpd/c.rf.com_access.log will have this entry and as well as the corresponding app's log will also be filled with this error.

Is there a way (without changing the DocumentRoot of to point to some index.html with "site is disabled" information), in which I can configure's virtual host that if a page is not relavent then not go to the app's log, but provide a suitable message...?

Please let me know in case I am not clear to you.


Old 03-25-2011, 03:23 AM   #2
Registered: Jul 2008
Location: Chennai, India
Distribution: RHEL5, Ubuntu
Posts: 191

Original Poster
Rep: Reputation: 37

I think what I need is something like this:

A RewriteRule that will compare the sitename (ServerName) with the incoming request sitename and if both are same then allow it, else go to an index page, saying "not found", so that it wont go to the app and fill it will log entries.



Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Xterm related query mr.blacklisted Linux - Server 1 11-17-2010 10:36 AM
Query related to syslog? your_shadow03 Linux - Newbie 5 05-15-2009 11:32 AM
A Query related to Git? your_shadow03 Linux - Newbie 10 04-24-2009 12:35 AM
Query related to sudo? your_shadow03 Linux - Newbie 2 04-22-2009 01:21 AM
shell related query !!!!!!!!!!! iacharyya Linux - General 10 06-09-2008 07:39 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:42 PM.

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