@@ -61,10 +61,9 @@ var _ = SIGDescribe(feature.GPUDevicePlugin, framework.WithSerial(), "Sanity tes
61
61
podClient = e2epod .NewPodClient (f )
62
62
})
63
63
64
- f .It ("should run nvidia-smi cli " , func (ctx context.Context ) {
64
+ f .It ("should run nvidia-smi and cuda-demo-suite " , func (ctx context.Context ) {
65
65
SetupEnvironmentAndSkipIfNeeded (ctx , f , f .ClientSet )
66
66
pod := testNvidiaCLIPod ()
67
- pod .Spec .Containers [0 ].Command = []string {"nvidia-smi" }
68
67
69
68
ginkgo .By ("Creating a pod that runs nvidia-smi" )
70
69
createAndValidatePod (ctx , f , podClient , pod )
@@ -103,6 +102,8 @@ var _ = SIGDescribe(feature.GPUDevicePlugin, framework.WithSerial(), "Test using
103
102
framework .ExpectNoError (err )
104
103
105
104
ginkgo .By ("Checking output from nvidia-smi" )
105
+ framework .Logf ("Got container logs for %s:\n %v" , pod .Spec .Containers [0 ].Name , log )
106
+
106
107
gomega .Expect (log ).To (gomega .ContainSubstring ("TensorFlow version" ))
107
108
gomega .Expect (log ).To (gomega .ContainSubstring ("Matrix multiplication result:" ))
108
109
gomega .Expect (log ).To (gomega .ContainSubstring ("Time taken for 5000x5000 matrix multiplication" ))
@@ -178,7 +179,20 @@ func testNvidiaCLIPod() *v1.Pod {
178
179
Containers : []v1.Container {
179
180
{
180
181
Name : "nvidia-smi" ,
181
- Image : "nvidia/cuda:12.3.2-runtime-ubuntu22.04" ,
182
+ Image : "nvidia/cuda:12.5.0-devel-ubuntu22.04" ,
183
+ Command : []string {
184
+ "bash" ,
185
+ "-c" ,
186
+ `
187
+ nvidia-smi
188
+ apt-get update -y && \
189
+ DEBIAN_FRONTEND=noninteractive apt-get install -y --allow-unauthenticated cuda-demo-suite-12-5
190
+ /usr/local/cuda/extras/demo_suite/deviceQuery
191
+ /usr/local/cuda/extras/demo_suite/vectorAdd
192
+ /usr/local/cuda/extras/demo_suite/bandwidthTest --device=all --csv
193
+ /usr/local/cuda/extras/demo_suite/busGrind -a
194
+ ` ,
195
+ },
182
196
Resources : v1.ResourceRequirements {
183
197
Limits : v1.ResourceList {
184
198
"nvidia.com/gpu" : resource .MustParse ("1" ),
0 commit comments