How to change TTL value for SOA records on all domains in Plesk

Follow

Comments

6 comments

  • Avatar
    Seb

    I think it would be a good idea to also update the serial field, otherwise slave DNS servers will not update!

  • Avatar
    Bulat Tsydenov

    @Seb, Sounds like a good feature! Please, provide this suggestion on our Plesk User Voice https://plesk.uservoice.com/forums/184549-feature-suggestions .

  • Avatar
    Maghreb Services SARL

    Wouldn't it be safer and more consistent to use the Plesk Linux CLI commands to achieve this?

    So for Plesk Onyx running on Ubuntu Linux you could use:

    sudo plesk bin domain --list | xargs -I {} sudo plesk bin dns  --update-soa {} -soa-ttl 1D -soa-refresh 3H -soa-retry 1H -soa-expire 7D -soa-minimum 3H

    to reset all domains to the (current) SOA defaults.

  • Avatar
    Alexander Tsmokalyuk

    @Maghreb  Updated the article, thank you!

  • Avatar
    Bob B

    I'm about to migrate from an old Plesk 11 install, to a current version, on new hardware, with a new server provider.  I'd like to know methods for updating all TTLs on Plesk 11 (CentOS), in preparation for the migration.  Then how to switch the TTLs back to defaults, once running on the new server, with the new Plesk version.

    What, if any, modifications to the steps on the page would be required under Plesk 11 (CentOS)?

  • Avatar
    Vladimir Chernikov

    Hello @Bob B,

    >> What, if any, modifications to the steps on the page would be required under Plesk 11 (CentOS)?

    The current article is applicable for Plesk 12.5 version and higher. Plesk 11 has reached the end-of-life and is not supported anymore so I can not guarantee these steps will work in Plesk 11 version.

    Please try to use solution from this article and if it does not help, consider upgrade from Plesk 11 to Plesk 12.5. Then apply the solution from this article and then migrate data to the new server.

    >> Then how to switch the TTLs back to defaults, once running on the new server, with the new Plesk version.

    The steps are the same. You minimize the DNS propagation time before migration by changing the TTL to 1H/3600 seconds (or another value):
    # sudo plesk bin domain --list | xargs -I {} sudo plesk bin dns --update-soa {} -soa-ttl 1H

    After migration you can change back to the default TTL value 1D /86400 seconds using the same command:
    # sudo plesk bin domain --list | xargs -I {} sudo plesk bin dns --update-soa {} -soa-ttl 1D

Please sign in to leave a comment.

Have more questions? Submit a request