Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > General

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Thread Tools Display Modes
Old 6th October 2012, 02:16
alleks alleks is offline
Senior Member
Join Date: Nov 2010
Posts: 157
Thanks: 9
Thanked 9 Times in 9 Posts
Default Redirecting unexisting subdomains to error page

I'm really having an issue with unexisting subdomains. For example, I have created the example.com domain with www. as auto-subdomain, but the problem is that if I go to 1029ur0pa.example.com it'll still open, just as www.example.com

So, how can I fix that? Any body had this issue before?
Reply With Quote
Sponsored Links
Old 6th October 2012, 11:55
till till is offline
Super Moderator
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 37,015
Thanks: 840
Thanked 5,652 Times in 4,461 Posts

The recommended way is to fix the dns record, remove the wildcard record and replace it eith records for subdomains that exist. Wildcard records are bad for search engine ranks anyway.

Then ensure tht you did not select * as auto subdomain in the site settings for the same reason.

If you dont want to alter the dns in the first strp, then create a catchall vhost.
Till Brehm
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
Old 8th October 2012, 17:30
alleks alleks is offline
Senior Member
Join Date: Nov 2010
Posts: 157
Thanks: 9
Thanked 9 Times in 9 Posts

Oh, I see! I just learned something new, and that you for that Till!

I decided to go for the DNS solution, but I will investigate the vhost catchall solution later.

Thank again
Reply With Quote
Old 9th October 2012, 17:46
cfoe cfoe is offline
ISPConfig Developer
Join Date: Oct 2011
Location: NRW, Germany
Posts: 233
Thanks: 27
Thanked 57 Times in 32 Posts
Send a message via Skype™ to cfoe

If you use the "*." auto-subdomain on the site you can set a htaccess file with a rewrite for all requests other than www.example.com and example.com to reply with a 404.
Christian Foellmann

OpenSource-Projects - GitHub-Projects - SVN-Mirrors on GitHub - Foe Services
Reply With Quote


Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
all subdomains work except www jasondavis87 Installation/Configuration 4 12th July 2011 14:34
Redirecting subdomains to external websites wikidd General 5 21st August 2010 16:39
Redirecting all Subdomains maweki Installation/Configuration 3 19th August 2009 14:31
SSL for multiple subdomains chillifire Installation/Configuration 12 16th April 2008 12:01
domains, subdomains, webspace, bandwidth.. TheRudy General 17 19th February 2007 19:31

All times are GMT +2. The time now is 16:39.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.