• Debian 11 is approaching its end-of-life (vendor EOL date - August 31, 2026). Plesk Obsidian 18.0.80 will be the last release to support it.
    If you are running Plesk Obsidian on Debian 11, we recommend you upgrade those servers to Debian 12 using our dist-upgrade tool.
  • We plan to deprecate and remove the support for XML RPC protocol versions earlier than 1.6.9.1 in Plesk Obsidian 18.0.82. We strongly recommend that you update all existing integrations using earlier versions of the XML RPC protocol to comply with the version 1.6.9.1 specification.

DNS Zone - Serial prbl -> solutions ?

R

romino

Guest
As you know, Plesk 8 doesn't create a correct serial number for zone files, wich can be a problem for .fr and .de tld's.

Plesk sent me a code that could resolve the problem.
What is your opinion on it? I didn't test it .... not wanting to have problem with my current sites ...

Here is the code:

----
#!/bin/sh
#Change directory to named's root/var
cd `awk '/^NAMED_RUN_ROOT_D/{print $2}' /etc/psa/psa.conf`/var

#Get active DNS zones (echo...|mysql...)
#Change all zone files inline (|xargs -r perl...-i)
echo 'SELECT `Z`.`name` FROM `domains` `D`, `dns_zone` `Z` WHERE\
`D`.`dns_zone_id`=`Z`.`id` AND `Z`.`type`="master" AND `D`.`status`=0;'\
| mysql -Nb -uadmin -p`cat /etc/psa/.psa.shadow` psa\
| xargs -r perl -pe '$_ =~ s~^(\s+)([^2]\d+)(\s+;\s+Serial.*)$~$1.(@a=localtime $2, sprintf("%04d%02d%02d%02d", $a[5]+1900, $a[4]+1, $a[3], ($a[2]*60+$a[1])/96)).$3~e;' -i

#Force named to reload its configuration and zones
/usr/sbin/rndc reload

#End of script
----
 
Back
Top