@@ -209,6 +209,22 @@ def set_gateway_cfg(self):
209209 if self .create_mtls_secrets :
210210 self .write_mtls_config (gateway_ips )
211211 log .info ("[nvmeof]: executed set_gateway_cfg successfully!" )
212+
213+ def teardown (self ):
214+ log .info ("[nvmeof] Removing nvmeof service" )
215+ _shell (self .ctx , self .cluster_name , self .remote , [
216+ 'ceph' , 'orch' , 'host' , 'ls'
217+ ])
218+ for i in range (self .groups_count ):
219+ group_name = self .groups_prefix + str (i )
220+ service_name = f"nvmeof.{ self .poolname } .{ group_name } "
221+ _shell (self .ctx , self .cluster_name , self .remote , [
222+ 'ceph' , 'orch' , 'rm' , service_name
223+ ])
224+ _shell (self .ctx , self .cluster_name , self .remote , [
225+ 'ceph' , 'orch' , 'host' , 'ls'
226+ ])
227+ log .info ("[nvmeof] Nvmeof teardown completed!" )
212228
213229
214230class NvmeofThrasher (Thrasher , Greenlet ):
@@ -542,6 +558,9 @@ def end(self):
542558 self .thrasher .join ()
543559 log .info ('done joining' )
544560
561+ def teardown (self ):
562+ log .info ('tearing down nvmeof thrasher...' )
563+
545564
546565task = Nvmeof
547566thrash = ThrashTest
0 commit comments