Optimizing httpd.conf fpr parked domains

  • camperjohn
  • Guru
  • Guru
  • User avatar
  • Posts: 1127
  • Loc: San Diego

Post 3+ Months Ago

I have about 4000 domains parked on my server. I notice my httpd.conf is like this:

Is there a way to optimize this? With 4000 domains, I worry my httpd.conf file is getting to large and slowing down the system. Is it possible to do this: ServerAlias *.com

Code: [ Select ]

<VirtualHost 99.99.99.99>

ServerName XYZ.MYSITE.COM
  ServerAlias 401krealestatefunds.com www.401krealestatefunds.com
  ServerAlias 401kmutualfundinvestments.com www.401kmutualfundinvestments.com
  ServerAlias 401kbondfunds.com www.401kbondfunds.com
  ServerAlias 2tdy.com www.2tdy.com
  ServerAlias 2dtimearound.com www.2dtimearound.com
  ServerAlias 2dmedopinion.com www.2dmedopinion.com
  ServerAlias 2dmedicalopinion.com www.2dmedicalopinion.com
  ServerAlias 1111dates.com www.1111dates.com
  ServerAlias 411onamerica.com www.411onamerica.com
  etc...
  etc...
  etc...
  etc...


</VirtualHost>
  1. <VirtualHost 99.99.99.99>
  2. ServerName XYZ.MYSITE.COM
  3.   ServerAlias 401krealestatefunds.com www.401krealestatefunds.com
  4.   ServerAlias 401kmutualfundinvestments.com www.401kmutualfundinvestments.com
  5.   ServerAlias 401kbondfunds.com www.401kbondfunds.com
  6.   ServerAlias 2tdy.com www.2tdy.com
  7.   ServerAlias 2dtimearound.com www.2dtimearound.com
  8.   ServerAlias 2dmedopinion.com www.2dmedopinion.com
  9.   ServerAlias 2dmedicalopinion.com www.2dmedicalopinion.com
  10.   ServerAlias 1111dates.com www.1111dates.com
  11.   ServerAlias 411onamerica.com www.411onamerica.com
  12.   etc...
  13.   etc...
  14.   etc...
  15.   etc...
  16. </VirtualHost>
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • camperjohn
  • Guru
  • Guru
  • User avatar
  • Posts: 1127
  • Loc: San Diego

Post 3+ Months Ago

This is an extension of the above problem of my httpd.conf being too large. I notice my named.conf is also really large and wonder how I can optimize the parked domains.

My httpd.conf file is 280K, my named.conf file is 362K. If there was a way I could reduce these with pattens or something I think this would help my server load. Can I put at the end of the file, zone "*.com" goes to the parent for parking?

Code: [ Select ]
named.conf

zone "cityonlinelinks.com" {
    type master;
    file "/var/named/cityonlinelinks.com.db";
};
zone "citypimps.com" {
    type master;
    file "/var/named/citypimps.com.db";
};
zone "claimings.com" {
    type master;
    file "/var/named/claimings.com.db";
};
etc..etc..etc..4000 more domains
  1. named.conf
  2. zone "cityonlinelinks.com" {
  3.     type master;
  4.     file "/var/named/cityonlinelinks.com.db";
  5. };
  6. zone "citypimps.com" {
  7.     type master;
  8.     file "/var/named/citypimps.com.db";
  9. };
  10. zone "claimings.com" {
  11.     type master;
  12.     file "/var/named/claimings.com.db";
  13. };
  14. etc..etc..etc..4000 more domains
  • SpooF
  • ٩๏̯͡๏۶
  • Bronze Member
  • User avatar
  • Posts: 3422
  • Loc: Richland, WA

Post 3+ Months Ago

I know you can do ServerAlias *.domain.com so I see no reason you couldn't just drop the domain.
  • camperjohn
  • Guru
  • Guru
  • User avatar
  • Posts: 1127
  • Loc: San Diego

Post 3+ Months Ago

SpooF wrote:
I know you can do ServerAlias *.domain.com so I see no reason you couldn't just drop the domain.


hmm I am going to test that. I will put all my regular domains first, then all the others under it. This will allow regular sites to host properly, then see if anything else goes to the parking page.

I will return with results.

Continued: hosting-forum/dns-wildcards-for-named-conf-and-apache-are-working-almost-t101917.html
Moderator Remark: added continuation

Post Information

  • Total Posts in this topic: 4 posts
  • Users browsing this forum: No registered users and 22 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.