Skip to content

Add IPMI channels support and tool to configure lan channel#43

Merged
datdenkikniet merged 13 commits into
datdenkikniet:mainfrom
nuclearcat:add-channels
Jan 25, 2026
Merged

Add IPMI channels support and tool to configure lan channel#43
datdenkikniet merged 13 commits into
datdenkikniet:mainfrom
nuclearcat:add-channels

Conversation

@nuclearcat
Copy link
Copy Markdown
Contributor

No description provided.

@nuclearcat nuclearcat force-pushed the add-channels branch 2 times, most recently from 830a39b to 256e2d9 Compare January 14, 2026 11:53
@datdenkikniet
Copy link
Copy Markdown
Owner

Please let me know when/if this is ready for an initial review (or if you just want feedback), then I'll take a look at it.

Added GetChannelInfo command + ChannelInfo parsing, defined channel
medium/protocol/session enums with Display.

Signed-off-by: Denys Fedoryshchenko <[email protected]>
prints IPMI channel medium/protocol/session.

This is foundational work for an ipmi-lan tool; it
provide details needed to locate LAN channels before managing their configuration.

Signed-off-by: Denys Fedoryshchenko <[email protected]>
Implemented the LAN config library pieces to retrieve LAN parameters from a channel.
This is initial, raw-first API design, providing low-level access to LAN configuration data.

Signed-off-by: Denys Fedoryshchenko <[email protected]>
Added an example in ipmi-channels, displaying LAN configuration
parameters using the new Transport module.

Signed-off-by: Denys Fedoryshchenko <[email protected]>
This automation tool is self-sufficient, and expected to be highly
useful for automation script, to validate, set up IPMI lan config.
Implementing read part.

./ipmi-lan-config
{
  "channels": [
    {
      "channel_number": 2,
      "lan_config": {
        "ip_address": "10.168.110.3",
        "subnet_mask": "255.255.255.0",
        "gateway": "10.168.110.1",
        "mac_address": "90:1B:0E:XX:XX:XX",
        "ip_source": "BIOS/System software",
        "default_gateway_mac": "C4:AD:34:XX:XX:XX",
        "backup_gateway": "0.0.0.0",
        "backup_gateway_mac": "00:00:00:00:00:00"
      }
    }
  ]
}

Signed-off-by: Denys Fedoryshchenko <[email protected]>
…e library

Implementing necessary harness to write LAN configuration.

Signed-off-by: Denys Fedoryshchenko <[email protected]>
We can use same json schema we received on get - to
configure IPMI. Tested on real server.
Adding dependencies and using serde_json properly.

Signed-off-by: Denys Fedoryshchenko <[email protected]>
@nuclearcat nuclearcat marked this pull request as ready for review January 17, 2026 12:36
@nuclearcat
Copy link
Copy Markdown
Contributor Author

Ready, and tested (except tested v6 set, but can't test if it really works yet)

Copy link
Copy Markdown
Owner

@datdenkikniet datdenkikniet left a comment

Choose a reason for hiding this comment

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

Another really cool addition! Thank you.

Some minor change requests.

Would you also update the table of supported commands in the README?

Comment thread ipmi-rs-core/src/app/get_channel_access.rs Outdated
Comment thread ipmi-rs-core/src/app/get_channel_access.rs Outdated
Comment thread ipmi-rs-core/src/transport/get_lan_configuration_parameters.rs Outdated
Comment thread ipmi-rs/examples/ipmi-lan-config.rs Outdated
}

fn render_schema() -> &'static str {
r#"{
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Could you include these as .json files and include_str! them instead?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

done

Comment thread ipmi-rs/examples/ipmi-lan-config.rs Outdated
@nuclearcat
Copy link
Copy Markdown
Contributor Author

I will push as fixups and i guess will do squash after review done?

Will help sysadmins what they can set and what not.

Signed-off-by: Denys Fedoryshchenko <[email protected]>
This is one of most important additions. AFAIK ipmitool doesnt
support ipv6 at all.

Signed-off-by: Denys Fedoryshchenko <[email protected]>
This will allow to read/set IPv6 address, dynamic parameters too.

Signed-off-by: Denys Fedoryshchenko <[email protected]>
Sometimes channel might be disabled, this means even IPMI looks
configured, LAN channel wont answer. We need functions to discover
that.

Signed-off-by: Denys Fedoryshchenko <[email protected]>
@datdenkikniet
Copy link
Copy Markdown
Owner

That looks good! Thank you, once again, for being receptive to feedback and all that, and for fixing up the commits in-line.

@datdenkikniet datdenkikniet merged commit 2977cbd into datdenkikniet:main Jan 25, 2026
16 checks passed
@nuclearcat
Copy link
Copy Markdown
Contributor Author

That looks good! Thank you, once again, for being receptive to feedback and all that, and for fixing up the commits in-line.

Thank you too, you are best Rust maintainer i met.

@nuclearcat nuclearcat deleted the add-channels branch January 25, 2026 22:14
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.

2 participants