mirror of
https://github.com/xcat2/xcat-core.git
synced 2025-08-21 02:30:21 +00:00
Add new testcase to verify site table timezone and compute timezone match
This commit is contained in:
18
xCAT-test/autotest/testcase/installation/verify_timezone
Normal file
18
xCAT-test/autotest/testcase/installation/verify_timezone
Normal file
@@ -0,0 +1,18 @@
|
||||
start:verify_timezone
|
||||
os:Linux
|
||||
label:timezone
|
||||
#stop:yes
|
||||
|
||||
# Check site table timezone
|
||||
cmd:lsdef -t site -i timezone | awk -F= '{print $2}'
|
||||
check:rc==0
|
||||
|
||||
# Check compute node timezone
|
||||
cmd:xdsh $$CN "timedatectl | grep 'Time zone'" | awk -F: '{print $3}' | awk '{print $1}'
|
||||
check:rc==0
|
||||
|
||||
# Verify the compute node timezone matches the site table timezone
|
||||
cmd:sitetz=`lsdef -t site -i timezone | awk -F= '{print $2}'`;nodetz=`xdsh $$CN "timedatectl | grep 'Time zone'" | awk -F: '{print $3}' | awk '{print $1}'`; test $sitetz = $nodetz
|
||||
check:rc==0
|
||||
|
||||
end
|
Reference in New Issue
Block a user