[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Netconsole scripts for Debian



Pavel Odintsov <pavel.odintsov@gmail.com> writes:

> Hello!
>
> At now I configure netconsole dynamically and got network
> configuration from ip route command. For getting netconsole server MAC
> address I use arping to it.
>
> But I can generate modprobe configuration file with current
> configuration and integrate it to initrd.
>
> You can check my approach here:
> 1) On first netconsole script start I can get netconsole collector IP
> and MAC address (of destination server or gateway for current server)

The MAC address is optional and should be so in your package too.

> 2) I create /etc/modprobe.d/netconsole.conf configuration with fixed
> MAC, PORT and IP of netconsole server

Why?  You have to load the module from a script anyway, so you could just
set the options there.

> 3) I add netconsole to initramfs configuration file
> (/etc/initramfs-tools/modules) with fixed IP/MAC configuration
> 4) I rebuild initramfs for current kernel: update-initramfs -v -u -k
> `uname -r` -t
> 5) On every system run I will check if MAC/IP of destination server
> was changes I will reconfigure netconsole modprobe.conf file and
> rebuilt initrd.

There is already "netconsole=" cmdline support in initramfs-tools.
Whatever you add should integrate nicely with this IMHO.



Bjørn


Reply to: