From 3b114aa3538e199eb4f0c3ee2f37a5357fc266cf Mon Sep 17 00:00:00 2001 From: "litingt@cn.ibm.com" Date: Thu, 20 Apr 2017 02:59:20 -0400 Subject: [PATCH] This case is to verify bug 2521 to test when there is mgtifname is defined as remote networks, makedhcp could work correctly and create entrys in dhcp lease file --- xCAT-test/autotest/testcase/makedhcp/cases0 | 28 +++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/xCAT-test/autotest/testcase/makedhcp/cases0 b/xCAT-test/autotest/testcase/makedhcp/cases0 index 64f87a839..40b772526 100644 --- a/xCAT-test/autotest/testcase/makedhcp/cases0 +++ b/xCAT-test/autotest/testcase/makedhcp/cases0 @@ -176,3 +176,31 @@ check:output!~$$CN cmd:makedhcp -a end +start:makedhcp_remote_network_bug2521 +descriptiion:This case is to verify bug 2521 to test when there is mgtifname='!remote!', makedhcp could work correctly and create entrys in dhcp lease file. +cmd:mkdef -t network -o testnetwork net=100.100.100.0 mask=255.255.255.0 mgtifname='!remote!eth0' gateway=100.100.100.1 +check:rc==0 +cmd:lsdef -t network +check:rc==0 +check:output=~testnetwork +check:rc==0 +cmd:mkdef -t node -o testnode ip=100.100.100.2 groups=all mac=42:3d:0a:05:27:0b +check:rc==0 +cmd: cp -f /etc/hosts /etc/hosts.bak +cmd:echo "100.100.100.2 testnode" >> /etc/hosts +check:rc==0 +cmd:makedhcp testnode +check:rc==0 +cmd:makdhcp -q testnode +check:rc==0 +check:output=~testnode: ip-address = 100.100.100.2 +cmd:makdhcp -d testnode +check:rc==0 +cmd:makedhcp -n +check:rc==0 +cmd:noderm testnode +check:rc==0 +cmd:chtab -d netname=testnetwork networks +check:rc==0 +cmd:cp -f /etc/hosts.bak /etc/hosts +end