def METHOD_NAME(arch):
    """
    Use gdb to check core dump file
    """
    arch_map = {'x86_64': 'X86_64', 'ppc64le': 'ppc64-le'}
    arch_name = arch_map.get(arch)
    arch = arch_name if arch_name else arch
    command = ('echo -e "source %s\nset height 0\ndump-guest-memory'
               ' %s %s\nbt\nquit" > %s' % (dump_guest_memory_file,
                                           vmcore_file, arch,
                                           gdb_command_file))
    process.run(command, shell=True)
    status, output = process.getstatusoutput(gdb_command, timeout=360)
    os.remove(gdb_command_file)
    os.remove(core_file)
    test.log.debug(output)
    if status != 0:
        test.fail("gdb command execute failed")
    elif "<class 'gdb.MemoryError'>" in output:
        if dump_guest_core == "on":
            test.fail("Cannot access memory")