4

How can I create a backup of all the driver modules (especially those that are not part of the original kernel yet) from an installation of GNU/Linux OS?

The original source of the proprietary drivers has gone offline and I need to do a clean install of another Gnu/Linux OS.

rinfinity
  • 325

1 Answers1

1

Kernel modules are usually located in /lib/modules. You can create a backup by executing tar -c -f backup.tar /lib/modules/$(uname -r). This will create(-c) a backup of the modules of your current kernel(uname -a) in the file(-f) backup.tar. Note that kernel modules for one kernel version do not necessarily work with another kernel version.

A few modules come with firmware typically located in /lib/firmware. You can find out with modinfo name_of_module. You should see something like "firmware: xyz-123.ucode".

If you need to pass any options to the modules in /etc/modprobe.d, you have to backup that file as well. You can find out with grep -r name_of_module /etc/modprobe.d.

tastytea
  • 262