Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

How to reset all domains to package defaults using Shell?

Discussion in 'General Discussion' started by nat, Feb 24, 2008.

  1. nat

    nat Well-Known Member

    Jan 16, 2003
    Likes Received:
    Trophy Points:
    How to reset all domains to package defaults using Shell?

    Let's say I have 100 packages on 50 servers.

    I want to upgrade all domains that use all 100 packages on all 50 servers.

    I edited the packages on one server and copied them to /var/cpanel/packages on all servers. So now all servers have my new packages. But the domains that use those packages still do not have the features of the new packages.

    Right now in order to get the domains to use the new setting of the new packages, I have to Login to WebHost Manager on each server, click Edit Packages, select the Package, click Edit, click Edit again. 50 X 100 = 5000 times.

    It would be nice to run....


    Then type in the package name(s)

    Hit enter.

    #1 nat, Feb 24, 2008
    Last edited: Feb 24, 2008
  2. cPanelDavidG

    cPanelDavidG Technical Product Specialist

    Nov 29, 2006
    Likes Received:
    Trophy Points:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    One solution you may want to pursue is to use the XML-API to create a central means by which you can edit packages on all servers. One can easily create a shell script that updates the packages on all servers. Using the XML-API will also act as if you modified the parameters via WHM so, like WHM, any modifications to the package should propagate automatically to all accounts using that package.

    XML-API documentation is available at:

    editpkg XML-API call information available at:

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice