From eeab3dd078a3431c203352a9ecd91735f601e74f Mon Sep 17 00:00:00 2001 From: baogen shang Date: Fri, 17 Jan 2025 10:40:03 +0800 Subject: [PATCH] fix vgpu testing issue 1.fix vgpu driver installed fail issue. 2.fix timeout issue and sleep too short issue. Signed-off-by: baogen shang --- tests/compatible/vgpu/test_vgpu.sh | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/tests/compatible/vgpu/test_vgpu.sh b/tests/compatible/vgpu/test_vgpu.sh index 4d5c383..485fa9f 100644 --- a/tests/compatible/vgpu/test_vgpu.sh +++ b/tests/compatible/vgpu/test_vgpu.sh @@ -41,7 +41,7 @@ function create_vm() { sed -i "s#test_uuid#${uuid}#" /opt/${vmfile} virsh define /opt/${vmfile} virsh start openEulerVM - sleep 60 + sleep 90 return 0 } @@ -101,6 +101,13 @@ function test_vgpu_client() { return 1 fi + echo "Remove the nouveau module." + testcmd="modprobe -r nouveau" + sshcmd $vm_ip $passwd "${testcmd}" + if [[ $? -ne 0 ]]; then + return 1 + fi + echo "Start to install driver." install_cmd="bash ${vm_driver} --disable-nouveau --ui=none --no-questions" sshcmd $vm_ip $passwd "${install_cmd}" @@ -175,7 +182,7 @@ function sshcmd() { ip=$1 passwd=$2 cmd=$3 - timeout=600 + timeout=1200 expect <<-SSHEOF set timeout $timeout spawn ssh -o "ConnectTimeout=${timeout}" root@${ip} "${cmd}" -- Gitee