Get your server issues fixed by our experts for a price starting at just 25 USD/Hour. Click here to register and open a ticket with us now!

Author Topic: Script to change expiration period of all domains to unlimited  (Read 1840 times)

0 Members and 1 Guest are viewing this topic.

Jithin

  • Guest
Script to change expiration period of all domains to unlimited
« on: November 29, 2013, 06:59:02 pm »
Hi Guys,

If you want to change the expiration date of all the domains in Plesk to unlimited, you can either do it from Plesk frontend and of course it will be time consuming.  So here is a script for that.

for i in `mysql -uadmin -p\`cat /etc/psa/.psa.shadow\` psa -Ns -e “select name from domains”`; do /usr/local/psa/bin/domain_pref -u $i -expiration -1;done

It will do the trick!

Give it a try!