Operating System - HP-UX
1834625 Members
3264 Online
110069 Solutions
New Discussion

Setting NIC's MTU permanently (viz. reboot consistent)

 
SOLVED
Go to solution
Ralph Grothe
Honored Contributor

Setting NIC's MTU permanently (viz. reboot consistent)

Hello fellow admins,

encryption gateways require frames to have a maximum transfer unit size of some 1340 Bytes (probably because they need to wrap their header around the frames)

Although it was as easy as one single "lanadmin -M ..." command to set the MTU, I now wonder if I do have to provide my own init-oneliner "script" since I cannot find a config file where this is set "reboot-proof".

# lanadmin -m 0
MTU Size = 1340

# netstat -in|awk '{print$1,$2}'
Name Mtu
lan0 1340
lo0 4136

Because lan0 is using the btlan driver

# ioscan -kfdbtlan|awk 'NR<4'
Class I H/W Path Driver S/W State H/W Type Description
========================================================================
lan 0 0/0/0/0 btlan CLAIMED INTERFACE HP PCI 10/100Base-TX Core

it seemed obvious to look for a permanent config setting here

# grep -E '^[^#]' /etc/rc.config.d/hpbtlanconf
HP_BTLAN_INTERFACE_NAME[0]=lan0
HP_BTLAN_STATION_ADDRESS[0]=
HP_BTLAN_SPEED[0]=100FD
HP_BTLAN_INIT_ARGS="HP_BTLAN_STATION_ADDRESS HP_BTLAN_SPEED"

However, because of this comment in the file

# grep HP_BTLAN_INIT_ARGS /etc/rc.config.d/hpbtlanconf
# The HP_BTLAN_INIT_ARGS are reserved by HP. They are NOT user changable.
HP_BTLAN_INIT_ARGS="HP_BTLAN_STATION_ADDRESS HP_BTLAN_SPEED"


I do not dare squeezing in my MTU setting there.

The only init scripts HP provide that contain anything related to mtu belong either to Gigabit or FDDI

# grep -il mtu /sbin/init.d/*
/sbin/init.d/hpgelan
/sbin/init.d/hpiether
/sbin/init.d/hpigelan
/sbin/init.d/hppcifddi

# grep -il mtu /etc/rc.config.d/*
/etc/rc.config.d/hpfddi4conf
/etc/rc.config.d/hpgelanconf
/etc/rc.config.d/hpietherconf
/etc/rc.config.d/hpigelanconf
/etc/rc.config.d/netconf

# grep -in mtu /etc/rc.config.d/netconf
83:# "-f", "-n" and "-p pmtu".

# sed -n 80,85p /etc/rc.config.d/netconf
#
# ROUTE_ARGS: Route command arguments and options. This variable
# may contain a combination of the following arguments:
# "-f", "-n" and "-p pmtu".
#
# For each additional route, add a set of variable assignments like the ones


No, the last match isn't the right place either.
Does this mean HP don't provide a default place for setting MTU, and that I will have to extend their /sbin/init.d/hpbtlan script?

Rgds.
Ralph

Madness, thy name is system administration
5 REPLIES 5
Sanjay Kumar Suri
Honored Contributor

Re: Setting NIC's MTU permanently (viz. reboot consistent)

Hello Ralph

The man lanadmin has following to offer:

Changes made to an interface's station address or mtu interactively with the lanadmin command will not be preserved between system reboots. A user must modify the initialization configuration files for this feature, either manually editing configuration files or through the SAM interface.

Can you check SAM?

sks
A rigid mind is very sure, but often wrong. A flexible mind is generally unsure, but often right.
Ralph Grothe
Honored Contributor

Re: Setting NIC's MTU permanently (viz. reboot consistent)

Hello Sanjai,

I almost never use SAM.
That's why I forgot to look there.
But having done so now I can only see the MTU of 1340 that I already changed manually with the lanadmin command.
But I have the creeping suspicion that this setting won't survive the next reboot.
That was why I was asking where HP hid the damned config file for MTU, or whether the admin should really be forced to modify the hpbtlan init script (which I cannot believe).
OK, this is not a feat.
But I wanted to follow the default guidelines, not to confuse some colleague, or vendor support later.
Madness, thy name is system administration
Robert-Jan Goossens
Honored Contributor
Solution

Re: Setting NIC's MTU permanently (viz. reboot consistent)

Hi Ralph,

http://www5.itrc.hp.com/service/cki/docDisplay.do?docLocale=en_US&docId=200000062910454

How to set the MTU for EISA FDDI to 1500 bytes permanently DocId: KBRC00009957


Hope this helps,
Robert-Jan
Ralph Grothe
Honored Contributor

Re: Setting NIC's MTU permanently (viz. reboot consistent)

Hi Robert,

so it looks as if non standard MTUs is a not so common requirement, and the knowledge base article suggests what I would have done anyway.
Nevermind, instead of creating an extra init script I will modify the hpbtlan script that ifconfig-s the NICs.
Thanks for pointing me to the Knowledge Kase (KB) article.
Your query of KB must have been better than mine, which didn't reveal this article.
Madness, thy name is system administration
rick jones
Honored Contributor

Re: Setting NIC's MTU permanently (viz. reboot consistent)

It is good that you have a way out of the problem of persistent MTU setttings, but I have to ask, doesn't the encryption gateway support Path MTU discovery?
there is no rest for the wicked yet the virtuous have no pillows