Skip to content

Conversation

@zeeshanlakhani
Copy link
Collaborator

@zeeshanlakhani zeeshanlakhani commented Aug 22, 2024

This is related to the ongoing work in plumbing instance/guest metrics through to an oximeter producer in propolis.

Includes:

  • Rewriting the comment for trait Target in Oximeter to not being prepped for deprecation, as it does come in handy for custom needs
  • The main differentiating field among instance network information here is interface_id, which is exposed to propolis via the client's NetworkInterfaceRequest. We currently match the nic.slot to the port.slot to pass which of the requested nics interface_id uuids are part of the request.

Dependencies

zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 23, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

It depends on https://code.illumos.org/c/illumos-gate/+/3630.

Includes:

* An update to `NetworkInterfaceRequest` to include an interface_id, which
  is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping
  nic UUIDs => `minor` number of viona device instance.
  - The number of the device instance matches the kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which
    is passed through from Machine initialization to vm objects
    (and vm objects shared), the latter to which we can use it as part
    of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on
    vnics per instance, updating the `interface_id` appropriately, which is
    tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking
  for other stats tests
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 23, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

It depends on https://code.illumos.org/c/illumos-gate/+/3630.

Includes:

* An update to `NetworkInterfaceRequest` to include an interface_id, which
  is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping
  nic UUIDs => `minor` number of viona device instance.
  - The number of the device instance matches the kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which
    is passed through from Machine initialization to vm objects
    (and vm objects shared), the latter to which we can use it as part
    of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on
    vnics per instance, updating the `interface_id` appropriately, which is
    tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking
  for other stats tests

Dependencies
------------

- [ ] oxidecomputer/omicron#6414
- [ ] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 23, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [ ] oxidecomputer/omicron#6414
- [ ] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 23, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [ ] oxidecomputer/omicron#6414
- [ ] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 23, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [ ] oxidecomputer/omicron#6414
- [ ] https://code.illumos.org/c/illumos-gate/+/3630
Copy link
Collaborator

@bnaecker bnaecker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks for renaming this. I think there's still a pretty big open question on the sled identifiers, see my comment. It applies to this and a few other schema too, so we should settle on something before the next release. Not necessarily this PR, if we want to put something on the board and drop it later.

@zeeshanlakhani zeeshanlakhani force-pushed the zl/instance-network-interface branch from efe2ba7 to 90dd028 Compare August 25, 2024 15:49
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 26, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [ ] oxidecomputer/omicron#6414
- [ ] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 26, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [ ] oxidecomputer/omicron#6414
- [ ] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 26, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [ ] oxidecomputer/omicron#6414
- [ ] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 26, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [ ] oxidecomputer/omicron#6414
- [ ] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 26, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [ ] oxidecomputer/omicron#6414
- [ ] https://code.illumos.org/c/illumos-gate/+/3630
@zeeshanlakhani
Copy link
Collaborator Author

@bnaecker Updated to remove those sled fields.

Copy link
Collaborator

@bnaecker bnaecker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Thanks for your patience while we sort out the sled-identifier issue!

zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 27, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [ ] oxidecomputer/omicron#6414
- [ ] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 27, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [X] oxidecomputer/omicron#6414
- [X] https://code.illumos.org/c/illumos-gate/+/3630
@zeeshanlakhani zeeshanlakhani force-pushed the zl/instance-network-interface branch 2 times, most recently from 5d31963 to 66afcaf Compare August 28, 2024 16:03
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 28, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [X] oxidecomputer/omicron#6414
- [X] https://code.illumos.org/c/illumos-gate/+/3630
@zeeshanlakhani zeeshanlakhani force-pushed the zl/instance-network-interface branch from 66afcaf to 07bb3d1 Compare August 28, 2024 16:12
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 28, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [X] oxidecomputer/omicron#6414
- [X] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 28, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [X] oxidecomputer/omicron#6414
- [X] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 28, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [X] oxidecomputer/omicron#6414
- [X] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 28, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [X] oxidecomputer/omicron#6414
- [X] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 29, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [X] oxidecomputer/omicron#6414
- [X] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Aug 29, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona.
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `InterfaceIdentifiers`, which is passed through from Machine initialization to VM objects (and VM objects shared), the latter of which we can use as part of registering the oximeter producer.
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which is tracked in `interface_ids`.
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests

Dependencies
------------

- [X] oxidecomputer/omicron#6414
- [X] https://code.illumos.org/c/illumos-gate/+/3630
zeeshanlakhani added a commit to oxidecomputer/crucible that referenced this pull request Aug 29, 2024
Prep to update lock to account for changes in omicron:

- [ ] oxidecomputer/omicron#6414
- [ ] and used in oxidecomputer/propolis#747
This is related to the ongoing work in [plumbing instance/guest
metrics](oxidecomputer/propolis#742) through to an
oximeter producer in propolis.

Includes:
- Rewriting the comment for `trait Target` in Oximeter to not being prepped for deprecation,
  as it does come in handy for custom needs
- The main differentiating field among instance network information here is `interface_id`, which is
  exposed to propolis via the client's `NetworkInterfaceRequest`. We currently match the `nic.slot` to the `port.slot` to pass which of the
  requested nics `interface_id` uuids are part of the request.
@zeeshanlakhani zeeshanlakhani force-pushed the zl/instance-network-interface branch from 500212c to 9bac9ba Compare August 29, 2024 21:59
@zeeshanlakhani
Copy link
Collaborator Author

@bnaecker @leftwo deps are properly aligned now (with oxidecomputer/crucible#1438 and oxidecomputer/propolis#747).

@zeeshanlakhani zeeshanlakhani requested a review from leftwo August 29, 2024 22:51
Copy link
Contributor

@leftwo leftwo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like you got the dance steps figured out here on how to get these changes
rolled across the three repos.

@zeeshanlakhani zeeshanlakhani merged commit 5bf5f09 into main Sep 3, 2024
@zeeshanlakhani zeeshanlakhani deleted the zl/instance-network-interface branch September 3, 2024 13:03
zeeshanlakhani added a commit to oxidecomputer/crucible that referenced this pull request Sep 3, 2024
Prep to update lock to account for changes in omicron:

- [x] oxidecomputer/omicron#6414
- [x] and used in oxidecomputer/propolis#747
zeeshanlakhani added a commit to oxidecomputer/propolis that referenced this pull request Sep 3, 2024
Overview
========

This is related to the ongoing work in [plumbing instance/guest
metrics](#742) through to an
oximeter producer in propolis.

Includes:
* An update to `NetworkInterfaceRequest` to include an interface_id, which is part of the request on the [sled instance in Omicron](oxidecomputer/omicron#6414).
* Within initialization, with concrete types, we create interface_ids mapping nic UUIDs => `minor` number of the device instance of viona. This is done as a Vec because it is limited in size (typically the MAX networks interfaces per VM). 
  - The device instance number matches the Kstat we'll look for.
  - We track this mapping via a type alias `NetworkInterfaceIds` which is then passed to a `track_network_interfaces_kstats` function which is part of `initialize_network_devices` and adds the target to the kstat sampler. 
* A new stats module for collecting network_interface metrics.
  - In `to_samples` we generate multiple network interface targets based on vnics per instance, appropriately updating the `interface_id`, which comes from the network interface identifiers updated in network device initialization. 
* Move kstat_types out of virtual machine-specific stats and use its mocking for other stats tests
* move stats.rs to stats/mod.rs

Dependencies
------------

- [X] oxidecomputer/omicron#6414
- [X] https://code.illumos.org/c/illumos-gate/+/3630

Thanks to @pfmooney for exposing kstats directly through the viona (VirtIO-Net) driver as part of https://code.illumos.org/c/illumos-gate/+/3630. This work would be nothing without his!
@iliana
Copy link
Contributor

iliana commented Sep 3, 2024

Heads up — this merged PR updated the commits for Crucible and Propolis to commits that are on branches. We've had issues with that before, particularly since merged branches are squashed and then deleted in other repos.

@zeeshanlakhani
Copy link
Collaborator Author

zeeshanlakhani commented Sep 3, 2024

@iliana Yep. I have a new PR now setting up everything off commits from main branches: #6453. With the bidirectional dependencies between propolis and omicron for this change (affecting crucible in the middle), it would have broken otherwise. But, with 6453 going green, everything will point to revs off main. I discussed this with @bnaecker and @leftwo. Sadly, there's not a great way to handle these bidirectional deps.

@iliana
Copy link
Contributor

iliana commented Sep 3, 2024

Ah I see. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants