Ejemplo n.º 1
0
 def test_wait_till_segments_in_change_tracking(self):
     """
     [feature]: Wait until segments for into change tracking
     
     """
     newfault = Fault()
     rtrycnt = 0
     while( not newfault.is_changetracking()):
         tinctest.logger.info("Waiting [%s] for DB to go in CT mode" %rtrycnt)
         rtrycnt = rtrycnt + 1
Ejemplo n.º 2
0
    def test_drop_pg_dirs_on_primary(self):
        """
        [feature]: Drops primary gp0 folder 
        
        """

        newfault = Fault()
        (host, fileLoc) = newfault.get_segment_host_fileLoc()
        newfault.drop_pg_dirs_on_primary(host, fileLoc)
        rtrycnt = 0
        max_rtrycnt = 300
        while( not newfault.is_changetracking()):
            tinctest.logger.info("Waiting [%s] for DB to go into CT mode" %rtrycnt)
            rtrycnt = rtrycnt + 1
Ejemplo n.º 3
0
    def test_kill_mirror(self):
        """
        [feature]: Kills mirror gp0 segment 
        
        """

        newfault = Fault()
        hosts = newfault.get_segment_host(preferred_role='m',content=0)
        if not newfault.kill_mirror_gp0(hosts):
            self.fail("Could not the kill the mirror process, cannot proceed further!")
        rtrycnt = 0
        while( not newfault.is_changetracking()):
            tinctest.logger.info("Waiting [%s] for DB to go in CT mode" %rtrycnt)
            rtrycnt = rtrycnt + 1
Ejemplo n.º 4
0
    def test_use_gpfaultinjector_to_mark_segment_down(self):
        """
        [feature]: Use gpfaultinjector to mark a segment down in the configuration, but the 
        process is still running on the segment.
        
        """

        newfault = Fault()
        seginfo = newfault.get_seginfo(preferred_role='m', content=1)
        newfault.inject_using_gpfaultinjector(fault_name='filerep_consumer', fault_mode='async', fault_type='fault', segdbid=seginfo.getSegmentDbId())
        rtrycnt = 0
        while (not newfault.is_changetracking()):
            tinctest.logger.info("Waiting [%s] for DB to go into CT mode" % rtrycnt)
            rtrycnt += 1
Ejemplo n.º 5
0
    def test_kill_primary_group(self):
        """
        [feature]: Kill a group of primary segments
        
        """

        newfault = Fault()
        seglist = newfault.get_seginfo_for_primaries()
        seglist = seglist[:(len(seglist) + 1 ) / 2]
        for seg in seglist:
            tinctest.logger.info('Killing segment %s' % seg.getSegmentDataDirectory())
            newfault.kill_primary(seg.getSegmentHostName(), seg.getSegmentDataDirectory(), seg.getSegmentPort())
        rtrycnt = 0
        while (not newfault.is_changetracking()):
            tinctest.logger.info('Waiting [%s] for DB to go in CT mode' % rtrycnt)
            rtrycnt += 1