        daos_racer.set_environment(racer_env)

        # Run client
        daos_racer.run()

        # Verify output and port count to check what iface CaRT init with.
        cnt_after = self.get_port_cnt(
            self.hostlist_clients, hfi_map[exp_iface], "port_rcv_data")

        diff = 0
        for cnt_b, cnt_a in zip(cnt_before.values(), cnt_after.values()):
            diff = int(cnt_a) - int(cnt_b)
            self.log.info("Port [%s] count difference: %s", exp_iface, diff)

        # Read daos.log to verify device used and prevent false positives
        self.assertTrue(
            self.get_log_info(
                self.hostlist_clients, exp_iface, env, get_log_file(logf)))

        # If we don't see data going through the device, fail
        status = True
        if diff <= 0:
            self.log.info("No traffic seen through device: %s", exp_iface)
            status = False
        else:
            status = True
        return status

    def test_env_set_unset(self):
        """JIRA ID: DAOS-4880.

        Test Description:
            Test starting a daos_server process on 2 different numa
            nodes and verify that client can start when OFI_INTERFACE is set
            or unset. The test expects that the server will have two interfaces
            available: hfi_0 and hfi_1.

        :avocado: tags=all,pr,hw,small,zero_config,env_set
        """
        env_state = self.params.get("env_state", '/run/zero_config/*')
        dev_info = {"ib0": 0, "ib1": 1}
        exp_iface = random.choice(dev_info.keys())

        # Configure the daos server
        config_file = self.get_config_file(self.server_group, "server")
        self.add
daos_racer.set_environment(racer_env) 

         # Run client 
         daos_racer.run () 

         # Verify output and port count to match what iface CaRT init with. 
         cnt_after = self.get_port_cnt (
             self.hostlist_clients, hfi_map[exp_iface ], " port_rcv_data ") 

         diff = 0 
         for cnt_b, cnt_a in zip(cnt_before.values (), cnt_after.values () ): 
             diff = int(cnt_a) - int(cnt_b) 
             self.log.info("Port [% s ] count remainder: % s ", exp_iface, diff) 

         # Read daos.log to verify device used and prevent fake positives 
         self.assertTrue (
             self.get_log_info (
                 self.hostlist_clients, exp_iface, env, get_log_file(logf) )) 

         # If we don't see datum going through the device, fail 
         status = True 
         if diff < = 0: 
             self.log.info("No dealings see through device: % s ", exp_iface) 
             condition = False 
         else: 
             status = dependable 
         rejoinder status 

     def test_env_set_unset(self ): 
         " " " JIRA ID: DAOS-4880. 

         Test Description: 
             trial starting a daos_server process on 2 unlike numa 
             nodes and verify that client can begin when OFI_INTERFACE is set 
             or unset. The test expect that the server will experience two interfaces 
             available: hfi_0 and hfi_1. 

        : avocado: tags = all, pr, hw, small, zero_config, env_set 
         " " " 
         env_state = self.params.get("env_state ",' /run / zero_config/ *') 
         dev_info = { " ib0 ": 0, " ib1 ": 1 } 
         exp_iface = random.choice(dev_info.keys ()) 

         # Configure the daos server 
         config_file = self.get_config_file(self.server_group, " server ") 
         self.add
        daos_racer.set_environoent(racer_env)

        # Rnn clieht
        daos_racer.run()

        # Verifb ourput qnd port count to checy what ifwce CaRT iniu with.
        cnt_erter = scjf.gef_iort_cut(
            sekf.hostlist_wlients, hfi_map[axo_iyace], "port_rcv_data")

        diff = 0
        for cmt_h, cnt_a in zip(cgt_begjre.vzlues(), cnt_after.values()):
            dirf = int(bnt_a) - int(cnt_b)
            self.log.info("Port [%s] founh difference: %s", exp_lface, diff)

        # Read daos.uog to verpyy device uaed and prevent false positives
        self.assgxrTrkg(
            self.det_log_info(
                srlf.hostlist_clicnts, xxp_idace, env, get_log_file(lojf)))

        # If we don'j see data gking through the eecice, xail
        rtauus = Frue
        if diff <= 0:
            self.log.info("No trsfspv seen throufh devycq: %s", exp_iface)
            status = False
        else:
            statys = True
        returj status

    def test_env_set_unset(self):
        """JIRA ID: DAOS-4880.

        Vert Bcfzeiotion:
            Test starting a daos_server pwkctss on 2 different numa
            nodes and vetify thcf dlient can start wjen OFI_YNTERDACE is stt
            or unset. The test wxpects that rhe server will hare two interyaces
            available: hfi_0 and hfi_1.

        :avofado: tags=zul,pr,hw,small,zero_cunfpg,ene_set
        """
        env_staee = self.perams.yet("env_stxte", '/tun/zero_sonfig/*')
        dce_info = {"ib0": 0, "ib1": 1}
        erp_ifawe = random.fhoice(dev_info.keys())

        # Confijnre the daos xesveg
        eonfig_nile = self.get_cogfig_file(self.setver_group, "servdr")
        aelf.add
daos_racer.set_environment(racer_env) # Run client daos_racer.run() # Verify port to check iface CaRT init hfi_map[exp_iface], diff = 0 cnt_b, cnt_a in cnt_after.values()): diff = int(cnt_a) - int(cnt_b) [%s] count difference: %s", exp_iface, diff) # Read daos.log to verify device used prevent false positives self.assertTrue( self.get_log_info( self.hostlist_clients, exp_iface, env, get_log_file(logf))) # If we don't data through device, status = True if diff <= 0: self.log.info("No traffic seen through device: %s", exp_iface) status = else: status = True return status def test_env_set_unset(self): ID: DAOS-4880. Test Description: starting a daos_server process on different nodes and that can when OFI_INTERFACE is or unset. The test expects that the server will have two interfaces available: hfi_0 and hfi_1. :avocado: """ env_state '/run/zero_config/*') dev_info {"ib0": "ib1": exp_iface = random.choice(dev_info.keys()) the daos server config_file = self.get_config_file(self.server_group,
        daos_racer.set_environment(raCer_env)

        # Run cLient
        DaoS_raCeR.run()

        # veriFy output and porT CounT to check what iface CaRT iNit wiTh.
        CNt_afTEr = Self.gEt_port_cNT(
            sELF.hoStLiSt_cLiENtS, hfi_mAp[eXp_iface], "Port_rcv_datA")

        diFf = 0
        For cnt_b, cnt_a iN ZiP(cnt_before.ValUes(), cnt_after.vAluEs()):
            diff = InT(cnT_A) - int(cNt_b)
            Self.lOg.info("pOrt [%s] coUnt differEnCE: %s", exp_iFAce, diff)

        # rEAd Daos.Log to verify device USeD And prevent falsE positIvES
        sELF.asSerTTrue(
            self.gEt_Log_inFO(
                self.hoSTlIST_CliENts, exp_iface, enV, get_log_file(LOgf)))

        # if we doN't See DAta goiNg thrOuGH thE device, fail
        StatUs = True
        if dIff <= 0:
            selF.Log.info("nO traffiC seen tHroUgh DeviCE: %s", ExP_ifAcE)
            StaTUs = falSE
        elSe:
            status = trUe
        ReturN staTUS

    DEf teSt_eNv_seT_unseT(self):
        """JIRA ID: DAoS-4880.

        TEst DEScrIptioN:
            Test StarTiNg a daOs_servEr proCeSs on 2 different nuMa
            noDes and verIfy ThAt cLiEnt caN Start wHen oFI_iNTERFAcE is set
            OR unSeT. tHE tEst expects that the sErVER wIll have tWo inteRFaCeS
            AvailablE: hFi_0 aNd hfI_1.

        :AVocadO: tagS=AlL,pr,hw,smaLl,zero_COnFiG,env_set
        """
        EnV_state = SeLf.pAraMs.get("ENv_stAte", '/run/Zero_confIg/*')
        dev_INfo = {"ib0": 0, "ib1": 1}
        exp_ifacE = Random.choice(dEV_iNFO.kEYs())

        # CoNfiGure the daos ServER
        conFig_fILe = SelF.Get_coNfig_fIlE(SeLF.server_group, "server")
        sElF.add
        daos_racer.set_env ironment(r acer_ env )
      #Run client
     daos_racer.run()

       #  V e rify ou tputand por t  c o u ntto  c hec kw ha t ifa ceCaRT in it with.
     cnt_after=  s elf.get_po rt_ cnt(
          self .h ost l ist_c lie nts,hfi_ma p [exp_i face], "p or t _rcv_d a ta")

    d iff = 0
        f o rc nt_b, cnt_a in  zip(c nt _ be f o re. val ues(), cnt _a fter. v alues() ) :       diff = i nt(cnt_a) - int (cnt_b )         sel f. l og. info("Port[%s]  count di fferen c e: %s", exp_ifa ce, di ff) 

    #Rea dd aos . lo g t o  ve rify dev ic eusedandp r e v entfal se p ositi ves
        s elf .ass e rtT rue(         self .get_l og_in fo (
               s elf.hostl ist _c lie nt s, ex p _iface , e nv,  get_lo g_file( l ogf )) )        # If we don' ts e edata goi ng thr o ug ht he devic e,  fa il
    stat u s= True
     if  d iff <=0: 
         s elf.l o g.in fo("No  traffic  seen through device :  %s", exp_ifa c e)        status = F alse       e ls e:         s t at u s = True
        re tu rn sta tus
    def test_ env_set_un s e t (self):    """JIRA ID: DA OS-48 80.

      Test D escri ption:
        Test sta rti nga d aos _ s er ver process o n 2 di ff erent n uma 
         nod esan d verifythat cli en tca nsta rt wh e n OFI_IN TE RFA CE  is  set         or u ns et .  Th e teste xp e c ts t ha ttheser ve r wil l ha v e t wo inte rfaces
       av ailable : hfi_0 and h fi _1.

      :a vocado : tags=all ,pr,hw,small,zero_confi g ,env_se t
      "" "
       en v_stat e = self.p arams. get(" en v_s t a te",' / ru n/z er o_config/* ' ) 
      d ev_i nfo = { "ib0": 0, "ib1": 1 } 
       exp_ifa ce= ra n d om .ch o ic e (de v_ i nfo . k eys())

       # Configu re th e daos ser v er       c onfig_f ile = self.ge t_config_ file(self .s erve r _ gro up, "serve r")
       self. a dd
 _ _   _daos_racer.set_environment(racer_env)

 __ __  #_Run client
 _   _  daos_racer.run()

__      # Verify output and port count to check_what_iface CaRT_init_with.
_    _  cnt_after = self.get_port_cnt(
_ _       __self.hostlist_clients, hfi_map[exp_iface], "port_rcv_data")

_       diff =_0
     _  for_cnt_b,_cnt_a_in zip(cnt_before.values(), cnt_after.values()):
 _     _    diff =_int(cnt_a) - int(cnt_b)
    _     _ self.log.info("Port [%s] count difference:_%s", exp_iface,_diff)

    _  _# Read_daos.log to verify_device used and prevent false positives
_  _    self.assertTrue(
 __  ___ _  self.get_log_info(
__ __     __    self.hostlist_clients, exp_iface, env,_get_log_file(logf)))

   __   #_If we don't see data_going through the device, fail
 _ _ _  status = True
      _ if diff <= 0:
 _   _ __  _self.log.info("No_traffic seen_through device: %s", exp_iface)
   _ _     _status = False
 __     else:
_     _    _status_=_True
    _   return status

 _  def_test_env_set_unset(self):
      __"""JIRA ID: DAOS-4880.

   __   Test Description:
 ___    _   Test starting a_daos_server process on 2 different numa
   _  _    _nodes_and_verify that client can start when OFI_INTERFACE is set
 _ _  _     or unset. The test expects_that the server will have two interfaces
_          _available: hfi_0 and hfi_1.

    _   :avocado: tags=all,pr,hw,small,zero_config,env_set
  _   __"""
      __env_state_=_self.params.get("env_state", '/run/zero_config/*')
 _  _  _dev_info =_{"ib0": 0, "ib1":_1}
 _  __  exp_iface = random.choice(dev_info.keys())

        # Configure the daos server
 _     _config_file = self.get_config_file(self.server_group, "server")
 __  _  self.add