Semi-OT: Ipmitool Or Ipmicfg: Set BMC To Use NIC 2

Home » CentOS » Semi-OT: Ipmitool Or Ipmicfg: Set BMC To Use NIC 2
CentOS 9 Comments

The man page isn’t helping, nor have I been able to find examples that work.

For example, the man page claims I can do ipmitool lan get active, and I
try, and it says, “invaling lan command, get”.

Do I set the MAC address for the lan to NIC 2? Anyone have a clue – I do
*not* want martians on the real network.

mark

9 thoughts on - Semi-OT: Ipmitool Or Ipmicfg: Set BMC To Use NIC 2

  • Michael C. Tiernan wrote:

    Description: CentOS Linux release 7.5.1804 (Core)
    Release: 7.5.1804

    ipmitool -I open lan get 1
    Invalid LAN command: get

    I’m saying that the get command with lan DOES NOT WORK. ipmitool doesn’t understand it….


    mark

  • get isn’t a recognized subcommand under lan in the ipmitool I have installed.

    This will be very dependent on your motherboard and its BMC capabilities. Some can do IPMI on specific ports and not others. On the Intel S2600
    series that I use they can use port 1, 2, and a dedicated RMM port, but not ports 3 and 4. You’ll need to check your mobo suppport docs to see if it can even handle IPMI on the second port. If so, you just configure it with the IP setting you want for static, or configure the MAC shown by issuing
    ‘lan print 2’ in the ipmitool shell. Very often the MACs is sequential , so you can guess it by looking at the MACs of the normal ethernet ports and adding 1, 2 or whatever.

  • I should finish that sentence.

    … or configure the MAC (shown by issuing ‘lan print 2’ in the ipmitool shell) in your DHCP server. Though, running server management IPs in DHCP
    isn’t a great idea, because how do you access the management if the DHCP
    server is down?

  • Jon Pruente wrote:

    So you’re saying I should set the MAC address for the lan channel 1 to the MAC address of the second NIC?

    mark

  • Well, that didn’t work – Channel 2 is not a LAN channel!

    NO!!! I do not want this ever asking for an IP. There’s no management port, dunno why, but the only thing where it should be is a couple of pieces of thin, bent metal, and nothing, apparently, damaged.

    I do see one option of “defgw macaddr” – is that supposed to be a MAC
    external to the server, or can I use the MAC of eth1 (or whatever the stupid, unrememberable name is)?

    mark

  • As mentioned earlier, the BMC is a different MAC from any interface you might see from the OS side. Think of it as a separate computer that shares a physical network port (assuming it doesnt have a dedicated port).

    Imagine what would happen if you put two devices on the network with the same MAC. You don’t want to do that. defgw macaddr is for setting what it thnks the Default Gateway’s MAC address is.

    You will need to set the IP, netmask and gateway using the appropriate tool (I prefer ipmitool). keep in mind that because the device shares a port you most likely wont be able to use IPMI to talk over the LAN
    to the device from the OS on the same box.

  • Date: Wed, 27 Jun 2018 20:45:44 -0400
    From: Jonathan Billings

    It’s the end of the week, and maybe I’m being dense, but I still don’t get it: how do I tell the BMC to use eth1? Do I give it eth1’s MAC address as a gateway?

    mark

  • No, use the IP and MAC of the gateway you wish it to use, as if you were configuring another network device that’s on the same network as eth1 (assuming it’s sharing the eth1 physical network port). THe important thing to remember is: The BMC is not eth1. It just happens to share the physical port you’re plugging an ethernet cable into. It behaves like there’s another computer inside your case, with a vampire tap on the ethernet port’s cable.

    For example, if this is your eth1:

    $ ip -4 a show dev eth1
    2: eth1: mtu 1500 qdisc fq_codel state UP group default qlen 1000
    inet 10.0.0.5/24 brd 10.0.0.255 scope global dynamic
    noprefixroute eth1
    valid_lft 567262sec preferred_lft 567262sec
    $ ip -4 route default via 10.0.0.1 dev eth1 proto dhcp metric 100
    10.0.0.0/24 dev eth1 proto kernel scope link src 10.0.0.5 metric 100
    $ arp -n 10.0.0.1
    Address HWtype HWaddress Flags Mask Iface
    10.0.0.1 ether 00:00:11:11:22:22 C eth1

    Then you would pick an IP on your network (lets call it 10.0.0.6) and set the IPMI interface to use 10.0.0.6/255.255.255.0 and use 10.0.0.1
    and 00:00:11:11:22:22 as the defgw MAC.

    You won’t be able to ping the IP from the same system, but it should be reachable from other systems on the 10.0.0.0/24 network above.

  • Once upon a time, mark said:

    Choosing the NIC(s) for IPMI is not a general configuration of IPMI;
    that’s going to be a vendor/hardware specific setting (if it can be done at all). Different vendors have different methods of configuring which NIC(s) have IPMI access. You won’t be able to configure that with ipmitool; it’ll typically have to be set in the BIOS and/or BMC boot configuration menus.