LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 08-29-2009, 04:02 AM   #1
mlpa
Member
 
Registered: May 2008
Location: Aveiro
Distribution: Slackware
Posts: 542

Rep: Reputation: 50
mkinitrd


Hi, I use slackware-current, and I want to use a generic kernel, to do that I need a initrd, I use ext4 in my root filesystem, how can i make a initrd, what modules do i need?
 
Old 08-29-2009, 04:12 AM   #2
brianL
LQ 5k Club
 
Registered: Jan 2006
Location: Oldham, Lancs, England
Distribution: Slackware64 15; SlackwareARM-current (aarch64); Debian 12
Posts: 8,302
Blog Entries: 61

Rep: Reputation: Disabled
Get this script, and run it as root, it will tell you the command to run to make an initrd:

http://www.slackware.com/~alien/tool...d_generator.sh

Then edit /etc/lilo.conf, and run lilo.
If you need any more details, just ask.
 
Old 08-29-2009, 04:14 AM   #3
pwc101
Senior Member
 
Registered: Oct 2005
Location: UK
Distribution: Slackware
Posts: 1,847

Rep: Reputation: 128Reputation: 128
Quote:
Originally Posted by brianL View Post
Get this script, and run it as root, it will tell you the command to run to make an initrd:

http://www.slackware.com/~alien/tool...d_generator.sh

Then edit /etc/lilo.conf, and run lilo.
If you need any more details, just ask.
If you're running -current, the script is already included in /usr/share/mkinitrd/mkinitrd_command_generator.sh.

What's more, I've found the new version of mkinitrd pulls in all the modules it needs for ext4 automagically, so you need only provide a line as follows:
Code:
mkinitrd -c -k 2.6.29.6-smp -m ext4 -f ext4 -r /dev/hda1
In the mkinitrd output, you'll see it grabs a series of other modules automatically.

Last edited by pwc101; 08-29-2009 at 04:17 AM. Reason: more info
 
Old 08-29-2009, 04:18 AM   #4
mlpa
Member
 
Registered: May 2008
Location: Aveiro
Distribution: Slackware
Posts: 542

Original Poster
Rep: Reputation: 50
But for a system that with ext4 for root filesystem, what modules do I need?
Running mkinitrd without parameters work?
 
Old 08-29-2009, 04:20 AM   #5
brianL
LQ 5k Club
 
Registered: Jan 2006
Location: Oldham, Lancs, England
Distribution: Slackware64 15; SlackwareARM-current (aarch64); Debian 12
Posts: 8,302
Blog Entries: 61

Rep: Reputation: Disabled
Quote:
Originally Posted by pwc101 View Post
If you're running -current, the script is already included in /usr/share/mkinitrd/mkinitrd_command_generator.sh.

What's more, I've found the new version of mkinitrd pulls in all the modules it needs for ext4 automagically, so you need only provide a line as follows:
Code:
mkinitrd -c -k 2.6.29.6-smp -m ext4 -f ext4 -r /dev/hda1
In the mkinitrd output, you'll see it grabs a series of other modules automatically.
Aha! Something else I never noticed.
 
Old 08-29-2009, 04:47 AM   #6
acummings
Member
 
Registered: Jul 2004
Distribution: Slackware
Posts: 615

Rep: Reputation: 50
All ext4 modules (it auto gets them as needed) with the -m ext4 part of it as was listed.

if you've a common hardware controller then you likely don't need module for (a specific hardware), say, Adaptec Ultra 320 scsi controller, for exxample.

I've got 4 different kernels I can choose from to run. (you can keep your currently working kernel to use in case your initrd don't work the first time around) (yes, a few times I've fired it up on a non working initrd) then do another initrd).

can boot from install CD/DVD then pass a command that makes my /root file system run (yet another option in addition to my 4 different kernels I can run). So, only 1 kernel doesn't run. So. I "might get around to fixing that 1 so it runs too.

Code:
al@P5Q:~$
al@P5Q:~$ cat /etc/slackware-version
Slackware 12.2.0
al@P5Q:~$ cat /etc/lilo.conf
# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
# Append any additional kernel parameters:
append=" vt.default_utf8=0"
boot = /dev/sda

# Boot BMP Image.
# Bitmap in BMP format: 640x480x8
  bitmap = /boot/slack.bmp
# Menu colors (foreground, background, shadow, highlighted
# foreground, highlighted background, highlighted shadow):
  bmp-colors = 255,0,255,0,255,0
# Location of the option table: location x, location y, number of
# columns, lines per column (max 15), "spill" (this is how many
# entries must be in the first column before the next begins to
# be used.  We don't specify it here, as there's just one column.
  bmp-table = 60,6,1,16
# Timer location x, timer location y, foreground color,
# background color, shadow color.
  bmp-timer = 65,27,0,255

# Standard menu.
# Or, you can comment out the bitmap menu above and
# use a boot message with the standard menu:
#message = /boot/boot_message.txt

# Wait until the timeout to boot (if commented out, boot the
# first entry immediately):
prompt
# Timeout before the first entry boots.
# This is given in tenths of a second, so 600 for every minute:
timeout = 50
# Override dangerous defaults that rewrite the partition table:
change-rules
  reset
# VESA framebuffer console @ 1024x768x256
# vga = 773
# Normal VGA console
# vga = normal
# VESA framebuffer console @ 1024x768x64k
vga=791
# VESA framebuffer console @ 1024x768x32k
# vga=790
# VESA framebuffer console @ 1024x768x256
# vga=773
# VESA framebuffer console @ 800x600x64k
# vga=788
# VESA framebuffer console @ 800x600x32k
# vga=787
# VESA framebuffer console @ 800x600x256
# vga=771
# VESA framebuffer console @ 640x480x64k
# vga=785
# VESA framebuffer console @ 640x480x32k
# vga=784
# VESA framebuffer console @ 640x480x256
# vga=769
# End LILO global section
# Linux bootable partition config begins
image = /boot/vmlinuz-ac-smp-2.6.28.8
  root = /dev/sda5
  initrd = /boot/initrd-ac-288.gz
  label = ac-smp-28_8
  read-only
image = /boot/vmlinuz-ac-smp-2.6.27.15
  root = /dev/sda5
  initrd = /boot/initrd-ac.gz
  label = ac-smp-27_15
  read-only
image = /boot/vmlinuz-generic-smp-2.6.27.7-smp
  root = /dev/sda5
  initrd = /boot/initrd.gz
  label = SW12_2GenSmp
  read-only
image = /boot/vmlinuz
  root = /dev/sda5
  label = HugeSmp
  read-only
# Linux bootable partition config ends
al@P5Q:~$
--
Alan.
 
Old 08-29-2009, 07:02 AM   #7
multios
Member
 
Registered: Mar 2006
Location: Homer, Alaska USA
Distribution: OpenBSD, FreeBSD, Slackware64-current
Posts: 276

Rep: Reputation: 58
Quote:
Aha! Something else I never noticed.
Same here
I haven't been able to run 12.2 on one of my machines since the kernel upgrade.
I decided to install 13, so I quit seeding, put the cd in and rebooted. I thought I would try 12.2 one more time so used the huge.s kernel and booted my 12.2 system.
I ran mkinitrd again with all options/switches and "lo and behold" I see a list of modules that I haven't seen before while doing mkinitrd.
Now, I'm happily using 12.2 again on this particular system. 13 will now go on other machines.
 
Old 08-29-2009, 07:16 AM   #8
mlpa
Member
 
Registered: May 2008
Location: Aveiro
Distribution: Slackware
Posts: 542

Original Poster
Rep: Reputation: 50
Work for me
I run

Quote:
mkinitrd -c -k 2.6.29.6-smp -m ext4 -f ext4 -r /dev/hdb1
And create new symbolic links to vmlinuz-generic-smp; System-map-genertic-smp; config_generic-smp.
Edited lilo.conf and run lilo.

Thank you
 
  


Reply



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
mkinitrd ? anti.corp Slackware 1 11-27-2005 01:51 PM
Help with mkinitrd paddyjoy Linux - Newbie 2 07-02-2005 07:05 AM
mkinitrd beaucox Linux - Software 6 03-29-2004 09:44 AM
mkinitrd vmniza Linux - General 1 03-10-2004 02:05 AM
No Mkinitrd?????? sovietpower Linux - General 5 02-08-2004 05:10 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 05:35 AM.

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