LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-20-2013, 01:52 PM   #1
masuch
Member
 
Registered: Sep 2011
Location: /dev/null
Distribution: ubuntu 64bits
Posts: 135

Rep: Reputation: 1
Question what is difference between /etc/modules and /etc/initramfs-tools/modules ?


Hi,

Could please somebody explain me or put some URL here what is the difference between /etc/modules and /etc/initramfs-tools/modules in Ubuntu | Debian (like debian distribution) ?
In which booting time within the booting process is which applied ?

thank you,
kind regards,
M.
 
Old 05-22-2013, 12:47 AM   #2
fortran
Member
 
Registered: Nov 2011
Location: Cairo, Egypt
Distribution: CentOS, RHEL, Fedora
Posts: 300
Blog Entries: 2

Rep: Reputation: 51
/etc/modules : kernel modules to load at boot time
This file is used - if new hardware is added after installation and the hardware requires a kernel module, the system must be configured to load the proper kernel module for the new hardware.

/etc/initramfs-tools/modules : List of modules that you want to include in your initramfs.
But when you include, you should run following command to make sure changes take effect.
Code:
sudo update-initramfs
Read this for initramfs.
http://www.linuxfromscratch.org/blfs...initramfs.html
 
Old 05-24-2013, 09:16 AM   #3
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,622

Rep: Reputation: 7964Reputation: 7964Reputation: 7964Reputation: 7964Reputation: 7964Reputation: 7964Reputation: 7964Reputation: 7964Reputation: 7964Reputation: 7964Reputation: 7964
Quote:
Originally Posted by fortran View Post
/etc/modules : kernel modules to load at boot time
This file is used - if new hardware is added after installation and the hardware requires a kernel module, the system must be configured to load the proper kernel module for the new hardware.
Sorry, that's misleading. If new hardware is installed, most modern systems use udev to AUTOMATICALLY load kernel modules to accommodate the new hardware. In certain cases, you would want to use /etc/modules to define aliases or set certain device-specific options for a device. The man pages for Debian are pretty clear about such things:
http://wiki.debian.org/Modules
Quote:
/etc/initramfs-tools/modules : List of modules that you want to include in your initramfs.
But when you include, you should run following command to make sure changes take effect.
Code:
sudo update-initramfs
Read this for initramfs.
http://www.linuxfromscratch.org/blfs...initramfs.html
...and that link is for Linux from scratch, which is NOT what the OP asked about (Debian/Ubuntu). Again, the Debian wiki has lots:
http://wiki.debian.org/initramfs

And just running "update-initramfs" could cause problems, because that utility manages ALL the initramfs images, not just one. You need to specify if you want to update, etc. The man page can tell you about that command:
http://man.flashnux.com/en/debian/6/...itramfs.8.html
 
1 members found this post helpful.
Old 05-25-2013, 12:55 AM   #4
bloodstreetboy
Member
 
Registered: May 2012
Posts: 201
Blog Entries: 3

Rep: Reputation: 37
Quote:
Originally Posted by masuch View Post
Could please somebody explain me or put some URL here what is the difference between /etc/modules and /etc/initramfs-tools/modules in Ubuntu | Debian (like debian distribution) ?
If you read the commented lines in the files, you did not need to post this question here.
See what do the both files say.
I have taken these lines from ubuntu 13.04 the latest distribution
file /etc/modules says
Code:
# /etc/modules: kernel modules to load at boot time.
#
# This file contains the names of kernel modules that should be loaded
# at boot time, one per line. Lines beginning with "#" are ignored.
file /etc/initrams-tools/modules says
Code:
# List of modules that you want to include in your initramfs.
# They will be loaded at boot time in the order below.
#
# Syntax:  module_name [args ...]
#
# You must run update-initramfs(8) to effect this change.
#
# Examples:
#
# raid1
# sd_mod
That is clear enough to define their meaning and working.
 
1 members found this post helpful.
Old 05-29-2013, 05:50 AM   #5
masuch
Member
 
Registered: Sep 2011
Location: /dev/null
Distribution: ubuntu 64bits
Posts: 135

Original Poster
Rep: Reputation: 1
Thumbs up

Quote:
Originally Posted by TB0ne View Post
Sorry, that's misleading. If new hardware is installed, most modern systems use udev to AUTOMATICALLY load kernel modules to accommodate the new hardware. In certain cases, you would want to use /etc/modules to define aliases or set certain device-specific options for a device. The man pages for Debian are pretty clear about such things:
http://wiki.debian.org/Modules

...and that link is for Linux from scratch, which is NOT what the OP asked about (Debian/Ubuntu). Again, the Debian wiki has lots:
http://wiki.debian.org/initramfs

And just running "update-initramfs" could cause problems, because that utility manages ALL the initramfs images, not just one. You need to specify if you want to update, etc. The man page can tell you about that command:
http://man.flashnux.com/en/debian/6/...itramfs.8.html

Thanks for URLs - helped me a lot.
 
  


Reply

Tags
boot, modules



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
initramfs not finding /lib/modules/2.6.32 dman777 Red Hat 1 09-15-2011 05:52 AM
Difference between /etc/modules and /etc/modules.conf ? Biased turkey Debian 4 08-21-2005 10:46 AM
Kernel Modules: efficiency difference? Manish Linux - General 1 02-23-2002 08:24 PM
Re: modprobe: Note: /etc/modules.conf is more recent than lib/modules/2.4.9/modules.d Andy.M Linux - General 1 01-24-2002 01:50 AM
Re: modprobe: Note: /etc/modules.conf is more recent than lib/modules/2.4.9/modules.d Andy.M Linux - Newbie 2 01-24-2002 01:40 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:58 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration