• Introducing WebPros Cloud - a fully managed infrastructure platform purpose-built to simplify the deployment of WebPros products !  WebPros Cloud enables you to easily deliver WebPros solutions — without the complexity of managing the infrastructure.
    Join the pilot program today!
  • Support for BIND DNS has been removed from Plesk for Windows due to security and maintenance risks.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS.

mass importing domains

D

dgiff

Guest
I am trying to import a couple hundred thousand domains into some of my Plesk servers using the Plesk API to provision the domains. The scripts work alright but goes very slow and seems to get slower the more domains there are on the server.

I am trying to figure out where the bottle-necks may lie. Does plesk restart or reload any of the services e.g. apache, named, psa, etc every time a domain is added? If so is there a way to stop these from restarting during the provisioning. It only took about 7 sec. to add each domain when I first started. Now after I have added about 4,000 domains the server takes about 30 sec. to add each domain. It has taken me almost 36hrs to reach 4,000 domains and I haven't even started moving the +1TB of files over! I have about 300,000 domains to add to multiple plesk servers so any input would be appreciated.

Thanks.
 
I got this to work by following the steps at...

http://kb.swsoft.com/en/260

Then removing some of the includes from httpd.conf...

#Include conf.d/*

If you want to keep existing services up then manually include any of the files except zz010_psa_httpd.conf

Include conf.d/welcome.conf
Include conf.d/python.conf
Include conf.d/mailman.conf
Include conf.d/ssl.conf
Include conf.d/perl.conf
Include conf.d/php.conf
# etc...

Make a copy of zz010_psa_httpd.conf and make sure there aren't too many httpd.include files included.

After everything is moved revert the changes in the httpd.conf and delete the copy of zz010_psa_httpd.conf.

Restart psa first then httpd and it works.

It seems that plesk does restart apache every time a domain is added and the more domains you add the longer apache will take to restart. I'm unsure about named being reloaded each time as it seemed to work just fine making these changes. I was able to import about 10 domains a minute, although it did crash every thousand or so domains and I had to add a watchdog script to restart psa first, then restart httpd whenever apache went dead.
 
Back
Top