Error

Instance i-8D79A500 got error state. search by Google

args : tuple
('Instance i-8D79A500 got error state.',)

Traceback

  1. /usr/local/lib/python3.7/unittest/case.py in testPartExecutor (arguments )

    self : _Outcome
    <unittest.case._Outcome object at 0x7fe3fd982e10>
    test_case : InstancesGeneral
    test_run_instances_interfaces_negative (c2tests.ec2.instancesgeneral.InstancesGeneral)
    isTest : bool
    True
    1. @contextlib.contextmanager
    2. def testPartExecutor(self, test_case, isTest=False):
    3. old_success = self.success
    4. self.success = True
    5. try:
    6. yield
    7. except KeyboardInterrupt:
    8. raise
    9. except SkipTest as e:
    10. self.success = False

    Locals

    exc_info : NoneType
    None
    old_success : bool
    True

    Globals

    __unittest : bool
    True
    _subtest_msg_sentinel : object
    <object object at 0x7fe415310fc0>
    DIFF_OMITTED : str
    Diff is %s characters long. Set self.maxDiff to None to see it.
  2. /usr/local/lib/python3.7/unittest/case.py in run (arguments )

    self : InstancesGeneral
    test_run_instances_interfaces_negative (c2tests.ec2.instancesgeneral.InstancesGeneral)
    result : DiagnosticsTestResult
    <xmlrunner.extra.diagnosticstestrunner.DiagnosticsTestResult run=1 errors=0 failures=0>
    1. with outcome.testPartExecutor(self):
    2. self.setUp()
    3. if outcome.success:
    4. outcome.expecting_failure = expecting_failure
    5. with outcome.testPartExecutor(self, isTest=True):
    6. testMethod()
    7. outcome.expecting_failure = False
    8. with outcome.testPartExecutor(self):
    9. self.tearDown()

    Locals

    expecting_failure : bool
    False
    expecting_failure_class : bool
    False
    expecting_failure_method : bool
    False
    orig_result : DiagnosticsTestResult
    <xmlrunner.extra.diagnosticstestrunner.DiagnosticsTestResult run=1 errors=0 failures=0>
    outcome : _Outcome
    <unittest.case._Outcome object at 0x7fe3fd982e10>
    testMethod : method
    <bound method InstancesGeneral.test_run_instances_interfaces_negative of <c2tests.ec2.instancesgeneral.InstancesGeneral testMethod=test_run_instances_interfaces_negative>>

    Globals

    __unittest : bool
    True
    _subtest_msg_sentinel : object
    <object object at 0x7fe415310fc0>
    DIFF_OMITTED : str
    Diff is %s characters long. Set self.maxDiff to None to see it.
  3. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/ec2/instancesgeneral.py in test_run_instances_interfaces_negative (arguments )

    self : InstancesGeneral
    test_run_instances_interfaces_negative (c2tests.ec2.instancesgeneral.InstancesGeneral)
    1. template_id=template_id,
    2. network_interfaces=NetworkInterfaceCollection(
    3. NetworkInterfaceSpecification(
    4. interface1.id,
    5. device_index=0,
    6. delete_on_termination=False,
    7. ),
    8. )
    9. )

    Locals

    eni01 : NetworkInterfaceSpecification
    <boto.ec2.networkinterface.NetworkInterfaceSpecification object at 0x7fe3fd56fe90>
    eni02 : NetworkInterfaceSpecification
    <boto.ec2.networkinterface.NetworkInterfaceSpecification object at 0x7fe3fda6f490>
    interface1 : NetworkInterface
    NetworkInterface:eni-A4684080
    interface2 : NetworkInterface
    NetworkInterface:eni-C724A160
    subnet_id : str
    subnet-A75DFC00
    switch : VirtualSwitch
    VirtualSwitch:Test switch d5af8a34-f7c2-4e7f-8e69-fbb0ff4ef7d4
    template_id : str
    cmi-D1122351

    Globals

  4. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in wrap (arguments )

    *args : tuple
    (<c2tests.ec2.instancesgeneral.InstancesGeneral testMethod=test_run_instances_interfaces_negative>,)
    **kwargs : dict
    {'template_id': 'cmi-D1122351', 'network_interfaces': [<boto.ec2.networkinterface.NetworkInterfaceSpecification object at 0x7fe3fd452d10>]}
    1. @functools.wraps(func)
    2. def wrap(*args, **kwargs):
    3. retries = 0
    4. while retries <= 10:
    5. try:
    6. return func(*args, **kwargs)
    7. except EC2ResponseError as e:
    8. if e.error_code == "RequestLimitExceeded":
    9. retries += 1
    10. time.sleep(0.1 * retries)

    Locals

    retries : int
    0

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]
  5. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/__init__.py in run_instance (arguments )

    self : InstancesGeneral
    test_run_instances_interfaces_negative (c2tests.ec2.instancesgeneral.InstancesGeneral)
    update_instance : bool
    True
    **kwargs : dict
    {'template_id': 'cmi-D1122351', 'network_interfaces': [<boto.ec2.networkinterface.NetworkInterfaceSpecification object at 0x7fe3fd452d10>]}
    1. return self.run_instances(
    2. update_instance=update_instance,
    3. min_count=kwargs.pop("min_count", 1),
    4. max_count=kwargs.pop("max_count", 1),
    5. **kwargs,
    6. )[0]
    7. def run_instance_micro(self, **kwargs):
    8. """Helper for micro instance running."""

    Locals

    Globals

    gethostbyname : builtin_function_or_method
    <built-in function gethostbyname>
    UNSIGNED : UNSIGNED
    <botocore.UNSIGNED object at 0x7fe407aa0ed0>
  6. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in wrap (arguments )

    *args : tuple
    (<c2tests.ec2.instancesgeneral.InstancesGeneral testMethod=test_run_instances_interfaces_negative>,)
    **kwargs : dict
    {'update_instance': True, 'min_count': 1, 'max_count': 1, 'template_id': 'cmi-D1122351', 'network_interfaces': [<boto.ec2.networkinterface.NetworkInterfaceSpecification object at 0x7fe3fd452d10>]}
    1. @functools.wraps(func)
    2. def wrap(*args, **kwargs):
    3. retries = 0
    4. while retries <= 10:
    5. try:
    6. return func(*args, **kwargs)
    7. except EC2ResponseError as e:
    8. if e.error_code == "RequestLimitExceeded":
    9. retries += 1
    10. time.sleep(0.1 * retries)

    Locals

    retries : int
    1

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]
  7. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/__init__.py in run_instances (arguments )

    self : InstancesGeneral
    test_run_instances_interfaces_negative (c2tests.ec2.instancesgeneral.InstancesGeneral)
    update_instance : bool
    True
    conn : EC2ConnectionLegacy
    <c2tests.profile.EC2ConnectionLegacy object at 0x7fe406124a10>
    **kwargs : dict
    {'min_count': 1, 'max_count': 1, 'network_interfaces': [<boto.ec2.networkinterface.NetworkInterfaceSpecification object at 0x7fe3fd452d10>]}
    1. update_instance,
    2. template_id,
    3. kwargs,
    4. )
    5. instances = utils.run_instances(conn, template_id, **kwargs)
    6. self.log.warning("Instances: %s", common.pprint(instances))
    7. self.entities[resources.EC2_INSTANCES] += instances
    8. if update_instance:
    9. for instance in instances:

    Locals

    template_id : str
    cmi-D1122351

    Globals

    gethostbyname : builtin_function_or_method
    <built-in function gethostbyname>
    UNSIGNED : UNSIGNED
    <botocore.UNSIGNED object at 0x7fe407aa0ed0>
  8. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in run_instances (arguments )

    conn : EC2ConnectionLegacy
    <c2tests.profile.EC2ConnectionLegacy object at 0x7fe406124a10>
    template_id : str
    cmi-D1122351
    reserved : bool
    False
    wait : bool
    True
    **kwargs : dict
    {'min_count': 1, 'max_count': 1, 'network_interfaces': [<boto.ec2.networkinterface.NetworkInterfaceSpecification object at 0x7fe3fd452d10>]}
    1. [constants.INSTANCE_STATE_DELETED],
    2. check_for_errors=False)
    3. except Exception as e:
    4. LOG.error("Failed to terminate instances %s: %s.", instance_ids, e)
    5. raise exc
    6. def ssh(ip, keypath, *remote_args, user="root", **kwargs):
    7. """Run SSH client"""

    Locals

    instance_ids : list
    ['i-8D79A500']
    reservation : Reservation
    Reservation:r-8D79A500

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]
  9. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in run_instances (arguments )

    conn : EC2ConnectionLegacy
    <c2tests.profile.EC2ConnectionLegacy object at 0x7fe406124a10>
    template_id : str
    cmi-D1122351
    reserved : bool
    False
    wait : bool
    True
    **kwargs : dict
    {'min_count': 1, 'max_count': 1, 'network_interfaces': [<boto.ec2.networkinterface.NetworkInterfaceSpecification object at 0x7fe3fd452d10>]}
    1. try:
    2. reservation = conn.run_instances(template_id, **kwargs)
    3. if wait:
    4. wait_for_instance_states(
    5. conn, [instance.id for instance in reservation.instances],
    6. [constants.INSTANCE_STATE_RUNNING])
    7. return [Instance(reservation, instance) for instance in reservation.instances]
    8. except Exception as exc:
    9. if reservation is not None:
    10. instance_ids = [instance.id for instance in reservation.instances]

    Locals

    instance_ids : list
    ['i-8D79A500']
    reservation : Reservation
    Reservation:r-8D79A500

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]
  10. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in wait_for_instance_states (arguments )

    conn : EC2ConnectionLegacy
    <c2tests.profile.EC2ConnectionLegacy object at 0x7fe406124a10>
    instance_ids : list
    ['i-8D79A500']
    states : list
    ['running']
    check_for_errors : bool
    True
    1. raise Error("Instance {0} has disappeared.",
    2. set(instance_ids).difference(got_ids).pop())
    3. return True
    4. wait(10 * constants.MINUTE_SECONDS, check_state)
    5. def wait_for_extnet_attached(conn, *extnets):
    6. """Wait for External Network attached state."""

    Locals

    aws_error_states : list
    ['error', 'failed', 'crashed']
    aws_states : list
    ['running']

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]
  11. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in wait (arguments )

    timeout : int
    600
    func : function
    <function wait_for_instance_states.<locals>.check_state at 0x7fe3fd9b4050>
    *args : tuple
    ()
    **kwargs : dict
    {}
    1. def wait(timeout, func, *args, **kwargs):
    2. """Fail unless func return success within specified number of seconds"""
    3. endtime = time.time() + float(timeout)
    4. while time.time() < endtime:
    5. result = func(*args, **kwargs)
    6. if result:
    7. return result
    8. time.sleep(min(timeout, 0.1))

    Locals

    endtime : float
    1708631372.1382902
    result : bool
    False

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]
  12. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in check_state (arguments )

    1. for reservation in conn.get_all_instances(instance_ids):
    2. for instance in reservation.instances:
    3. got_ids.add(instance.id)
    4. if check_for_errors and instance.state in aws_error_states:
    5. raise Error("Instance {0} got {1} state.",
    6. instance.id, instance.state)
    7. if instance.state not in aws_states:
    8. return False
    9. if got_ids != set(instance_ids):

    Locals

    aws_error_states : list
    ['error', 'failed', 'crashed']
    aws_states : list
    ['running']
    check_for_errors : bool
    True
    conn : EC2ConnectionLegacy
    <c2tests.profile.EC2ConnectionLegacy object at 0x7fe406124a10>
    got_ids : set
    {'i-8D79A500'}
    instance : Instance
    Instance:i-8D79A500
    instance_ids : list
    ['i-8D79A500']
    reservation : Reservation
    Reservation:r-8D79A500

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]

Environment

Time of report generation
2024-02-22 22:39:53
Python version
3.7.9 (default, Sep 21 2022, 19:11:27) [GCC 4.8.5 20150623 (Red Hat 4.8.5-44)]
Path to executable
/root/c2tests/.venv/bin/python
Working directory
/root/c2tests
Arguments vector
  1. /root/c2tests/.venv/bin/c2tests
  2. run
  3. -s
  4. ec2
  5. s3
  6. vpc