diff --git a/xCAT-test/autotest/bundle/rhels_ppc_daily.bundle b/xCAT-test/autotest/bundle/rhels_ppc_daily.bundle index 0d9eed54a..92129c212 100644 --- a/xCAT-test/autotest/bundle/rhels_ppc_daily.bundle +++ b/xCAT-test/autotest/bundle/rhels_ppc_daily.bundle @@ -3,6 +3,7 @@ tabdump_servicenode reg_linux_diskless_installation_hierarchy tabdump_servicenode reg_linux_diskfull_installation_hierarchy +makentp_extntpserver_value tabdump_servicenode updatenode_P_script1 updatenode_P_script1_script2 diff --git a/xCAT-test/autotest/bundle/rhels_ppcle_daily.bundle b/xCAT-test/autotest/bundle/rhels_ppcle_daily.bundle index 0e45189e3..f8b4cb4ad 100644 --- a/xCAT-test/autotest/bundle/rhels_ppcle_daily.bundle +++ b/xCAT-test/autotest/bundle/rhels_ppcle_daily.bundle @@ -2,6 +2,7 @@ SN_setup_case reg_linux_diskless_installation_hierarchy reg_linux_diskless_installation_hierarchy_squashfs reg_linux_diskfull_installation_hierarchy +makentp_extntpserver_value compare_postscripts updatenode_P_script1 updatenode_P_script1_script2 diff --git a/xCAT-test/autotest/bundle/rhels_x86_daily.bundle b/xCAT-test/autotest/bundle/rhels_x86_daily.bundle index 29bda82ab..b5f2fadc0 100644 --- a/xCAT-test/autotest/bundle/rhels_x86_daily.bundle +++ b/xCAT-test/autotest/bundle/rhels_x86_daily.bundle @@ -2,6 +2,7 @@ SN_setup_case reg_linux_diskless_installation_hierarchy reg_linux_diskless_installation_hierarchy_squashfs reg_linux_diskfull_installation_hierarchy +makentp_extntpserver_value compare_postscripts updatenode_P_script1 updatenode_P_script1_script2 diff --git a/xCAT-test/autotest/bundle/sles_ppcle_daily.bundle b/xCAT-test/autotest/bundle/sles_ppcle_daily.bundle index 63dfc7e00..3a0443bda 100644 --- a/xCAT-test/autotest/bundle/sles_ppcle_daily.bundle +++ b/xCAT-test/autotest/bundle/sles_ppcle_daily.bundle @@ -2,6 +2,7 @@ SN_setup_case reg_linux_diskless_installation_hierarchy reg_linux_diskless_installation_hierarchy_squashfs reg_linux_diskfull_installation_hierarchy +makentp_extntpserver_value compare_postscripts assign_certain_command_permission bmcdiscover_help diff --git a/xCAT-test/autotest/bundle/sles_x86_daily.bundle b/xCAT-test/autotest/bundle/sles_x86_daily.bundle index 7aaf23dc5..0b1d3e307 100644 --- a/xCAT-test/autotest/bundle/sles_x86_daily.bundle +++ b/xCAT-test/autotest/bundle/sles_x86_daily.bundle @@ -2,6 +2,7 @@ SN_setup_case reg_linux_diskless_installation_hierarchy reg_linux_diskless_installation_hierarchy_squashfs reg_linux_diskfull_installation_hierarchy +makentp_extntpserver_value compare_postscripts assign_certain_command_permission bmcdiscover_help diff --git a/xCAT-test/autotest/bundle/ubuntu_ppcle_daily.bundle b/xCAT-test/autotest/bundle/ubuntu_ppcle_daily.bundle index 983d59527..753958701 100644 --- a/xCAT-test/autotest/bundle/ubuntu_ppcle_daily.bundle +++ b/xCAT-test/autotest/bundle/ubuntu_ppcle_daily.bundle @@ -1,6 +1,7 @@ reg_linux_diskless_installation_flat reg_linux_diskless_installation_flat_squashfs reg_linux_diskfull_installation_flat +makentp_extntpserver_value compare_postscripts assign_certain_command_permission bmcdiscover_help diff --git a/xCAT-test/autotest/bundle/ubuntu_x86_daily.bundle b/xCAT-test/autotest/bundle/ubuntu_x86_daily.bundle index 84f8f6968..83ba17e6a 100644 --- a/xCAT-test/autotest/bundle/ubuntu_x86_daily.bundle +++ b/xCAT-test/autotest/bundle/ubuntu_x86_daily.bundle @@ -1,6 +1,7 @@ reg_linux_diskless_installation_flat reg_linux_diskless_installation_flat_squashfs reg_linux_diskfull_installation_flat +makentp_extntpserver_value compare_postscripts assign_certain_command_permission bmcdiscover_help diff --git a/xCAT-test/autotest/testcase/makentp/cases0 b/xCAT-test/autotest/testcase/makentp/cases0 index 28eef1e18..b807e4893 100644 --- a/xCAT-test/autotest/testcase/makentp/cases0 +++ b/xCAT-test/autotest/testcase/makentp/cases0 @@ -46,6 +46,8 @@ cmd:lsdef -t site -o clustersite -i extntpservers -c >/tmp/extntpserver check:rc==0 cmd:chtab key=extntpservers site.value="$$extntpserversip" check:rc==0 +cmd:date | awk '{print $6}' > /tmp/currentyear +check:rc==0 cmd:date -s 20000101 check:rc==0 cmd:if [[ "__GETNODEATTR($$CN,os)__" =~ "rhel" ]];then clock -w;else hwclock -w ; fi @@ -56,20 +58,20 @@ check:output=~configuring management node: $$MN cmd:makentp -V check:rc==0 check:output=~configuring management node: $$MN -check:output=~checking if nptd is installed -check:output=~backing up the ntp configuration file /etc/ntp.conf -check:output=~ntp servers are: $$extntpserversip -check:output=~stopping ntpserver -check:output=~starting ntpserver -check:output=~enabling ntpserver -cmd:date -check:output=~$$DATE -cmd:if [[ "__GETNODEATTR($$CN,os)__" =~ "rhel" ]];then clock ;else hwclock ; fi +check:output=~Calling ... /install/postscripts/setupntp +check:output=~Daemon chronyd configured +cmd:curryear=`cat /tmp/currentyear`;date | grep $curryear check:rc==0 -check:output=~$$DATE +check:output=~\d +cmd:curryear=`cat /tmp/currentyear`;if [[ "__GETNODEATTR($$CN,os)__" =~ "rhel" ]];then clock | grep $curryear;else hwclock | grep $curryear ; fi +check:rc==0 +check:output=~\d cmd:extntpserver=`cat /tmp/extntpserver | awk -F = '{print \$2}'`;chtab key=extntpservers site.value=$extntpserver check:rc==0 cmd:rm -rf /tmp/extntpserver +check:rc==0 +cmd:rm -f /tmp/currentyear +check:rc==0 end start:updatenode_computenode_P_setupntp