This adds the node state when the GET /v1/introspection/<node uuid or
name> API is performed.
Change-Id: I81c6834933f789cb644a854313aacaf49a4856a7
Closes-Bug: #1665664
Add a tool which generates dot diagram from inspector state machine
using atomaton pydot convertor.
Also add generated svg diagram to docs.
Change-Id: I021812288f1833a6ebad2f90cbe862d40bd8d503
InfiniBand is computer-networking communications standard
used in high-performance computing, features very high
throughput and very low latency.
This patch allow ironic-inspector to add the client_id
to ironic port extra. The client_id option allow pxe boot
from InfiniBand interface.
Closes-Bug: #1532534
Depends-On: Ifad453977e5d3be64b34e544f269835a72b4d73f
Change-Id: I479d54c29bcacb6bd5c1ab20033ae6e428b0e744
This adds a plugin to process the raw LLDP TLVs stored in Swift for
the Basic Mgmt, 802.1, and 802.3 data sets and store the parsed data
back in Swift. It implements the TLV processing as described in the
specification:
http://specs.openstack.org/openstack/ironic-inspector-specs/specs/lldp-reporting.html
Change-Id: I854826787ff045ffb2807970deaba8b77cbe277d
Closes-Bug: 1647515
Related-Bug: 1626253
* Add a link to ironic-inspector-client documentation
* Remove the link to blueprints, we no longer use them
* Update the link to Ironic inspection documentation
Change-Id: Ia0ec933e8fe213ffea4a8ac389b6d2028ea7e9ec
There is a demand to use introspection on diskless nodes to figure out
what is possible to figure out.
We might need more changes to properly support diskless nodes, this
change is just to allow people to play with it.
The property ``local_gb == 0`` for a diskless node.
Change-Id: I21b2f2c069fdbf767367ec3d1fbf77bab6292b25
Partial-Bug: #1554243
This feature is dangerous, barely maintained and not covered by any CI.
As it was hidden behind a configuration option, we can remove it without
breaking our API contract too much. This change deprecates the option,
and create an API version with this feature already de-activated.
Change-Id: I9e05c36b8c1194f4eeeb80c1f811e808854974c4
Partial-Bug: #1654318
This patch adds a note on how to allow inspector to work on a virtual
box guest. This can be helpful for devs with limited access to test
environments.
Change-Id: I3c23594ad8a66861598057879018e37327999e60
This patch introduces an API endpoint to list introspection statuses. The
endpoint supports pagination with an uuid-marker and a limit query string
fields. Due to the pagination, this change introduces a new configuration
option: ``api_max_limit``.
APIImpact
Change-Id: I74d02698801d5290619161b2d8d7181ab51a0a5e
Partial-Bug: #1525238
When we use devstack to start ironic-inspector service, it starts
sucessfully because we have a tty in devstack screen. But when we try
to use service command to start it, we should add '!requiretty'in the
suoders config, or it will fail.
Change-Id: I1f9f539c8eafea726ca7015ef86773e26a5a5641
Enhance the introspection status with the fields:
* uuid
* started_at
* finished_at
Change-Id: I36caa7d954a9bfb029d3f849fdf5e73f06f3da74
Partial-Bug: #1525238
Adds a new plugin to distinguish PCI devices returned by Ironic
Python Agent. Recognized PCI devices are then registered in node
capabilities and later can be used by nova flavors.
Change-Id: I6565b8c4aa76de240a6c4d795635300ff2d0c30b
Partial-Bug: #1580893
For Ironic multi-tenant networking support, we need to be able to
discover the nodes local connectivity. To do this IPA can try to pull
LLDP packets for every NIC.
This patch adds a processing hook to handle the data from these packets
in ironic-inspector so that we can populate the correct fields fields in
Ironic. The generic lldp hook only handles the mandatory fields port id
and chassis id, set on port_id and switch_id in local_link_connection.
Further LLDP fields should be handled by additional vendor specific LLDP
processing hooks, that populate the switch_info field in a non-generic
way.
Change-Id: I884eaaa9cc54cd08c21147da438b1dabc10d3a40
Related-Bug: #1526403
Depends-On: Ie655fd59b06de7b84fba3b438d5e4c2ecd8075c3
Depends-On: Idae9b1ede1797029da1bd521501b121957ca1f1a
This change introduces new return code (201 instead of 200) for
POST /v1/rules endpoint on success rule creation.
API less 1.6 continues returning 200.
Default API version was changed from minimum to maximum
which Inspector can support.
Change-Id: I911c7c241d16b9948ee4b6db92b127c7f8f374ae
* Update configuration options to reflect switch to keystoneauth
* Add iPXE and UEFI configuration
* Mention puppet-ironic and bifrost
* Make ordering more logical now that we only have 1 ramdisk
* Various small fixes
Change-Id: I8c4a64b260db801622bd30d6c4f2c93b41580af0
Closes-Bug: #1416371
From now on only rely on the IPA inventory and 2 additional fields:
boot_interface and root_device.
Also updated unit tests to use one inventory example.
Also removed duplicating unit tests and checks in test_process.
Also removed devstack support for the old ramdisk.
Change-Id: Ib382328295fc2c1b9143171b1047304febadcaca
Nodes now accept names in addition to UUIDs, so this
updates the docs accordingly.
Change-Id: Ifdd3cea73f7c19a8cacdd662e44898300b43f5cf
Closes-Bug: #1584116
Current documentation uses python syntax to explain the structure of the
introspection rules, this is misleading as we're actually expecting JSON
input on the rules API. This patch converts all rule examples to use
JSON syntax to prevent confusion.
Change-Id: If442fe5db8484900a5bd688e02d77d5bed69b326
Closes-Bug: #1564238
This change drops check on UUID validness from our API.
It also has a subtle effect of doing Ironic node fetching in
the introspection status and data fetch calls, which might make them
slightly longer (but only when name is used).
A new helper common.ironic.get_node is created to unify how we fetch nodes
from Ironic. It also provides nicer exceptions.
Change-Id: I20cf65e57910568b70a62c3f9269a962e78a07e2
Closes-Bug: #1523902
As requested in the related bug, this pull request allows to run the
introspection again on previously stored data. This should make it simple
to correct mistakes in the introspection rules.
For this purpose, new API entry point was introduced:
/v1/introspection/<UUID>/data/unprocessed that supports an empty POST
method to trigger the introspection over stored data. New function
`reapply` was introduced that takes care about the entry point and carries
out the introspection. The `process` function was modified to allow
reusing common parts in the new reapply function. The storage access
methods were updated to allow saving the "raw" memdisk data besides the
processed introspection data.
Following preconditions are checked the reapply function having been
triggered:
* no data is being sent along with the request
* Swift store is configured and enabled and the stored data is present
for the node UUID
* node_info object is cached for the UUID and it is possible to lock the
object
Should the preconditions fail, an immediate response is given to the user:
* 400 if the request contained data or in case Swift store is not enabled
in configuration
* 409 if it wasn't possible to acquire lock for the node_info object
* 404 in case Ironic didn't keep track of related BM node
If the preconditions are met, a background task is executed to carry out
the processing and a 202 Accepted response is returned to the endpoint
user.
As requested, these steps are performed in the background task:
* preprocessing hooks
* post processing hooks, storing result in Swift
* introspection rules
These steps are avoided, based on the RFE:
* not_found_hook is skipped
* power operations
Limitations:
* IMPI credentials are not updated --- ramdisk not running
* there's no way to update the raw data atm.
* the raw data is never cleaned from the store
* check for stored data presence is performed in background;
missing data situation still results in a 202 response
Change-Id: Ic027c9d15f7f5475fcc3f599d081d1e8d5e244d4
Closes-Bug: #1525237
This was designed to clean up action effects, but proved too confusing.
We should recommend using explicit clean up action instead.
Change-Id: Ia414979956cc0cbd5ed040831c49dba18671f86d
Introspection naturally happens in large bulks, after which it's inactive.
Small pool for DHCP addresses means that we'll have conflicts due to how
dnsmasq distributes them by default - using hashing. This option tells dnsmasq
to allocate IP addresses sequentially instead to avoid these conflicts.
See https://bugzilla.redhat.com/show_bug.cgi?id=1301659 for detailed analysis.
The drawback of this option is that long-running clients may switch IP
addresses if their lease expires. This is not a concern for short introspection
process.
This change may obsolete the need in the delay between 2 introspections.
Change-Id: Id277f3d31902bee16d3b048dbde5c34af905f0bc
Add new node_not_found_hook - enroll_node_not_found hook,
which allows to enroll unknown nodes to Ironic automatically.
Change-Id: If1528688504e4be4b2369b985bc576544d96868d
Related-Bug: #1524753