LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 09-14-2010, 09:45 AM   #1
Ubunoob001
Member
 
Registered: Feb 2010
Location: New Orleans, LA
Distribution: Mint 16 RC, Elementary OS Luna, Crunchbang
Posts: 166

Rep: Reputation: 17
Smile How To Add Slackware to Grub?


HI all, Please go slow, I am new to linux, and have virtually no experience, yet, with text file editing.

Situation: So because I was having problems with LILO (upon installing Slackware 13.1 next to my Ubuntu/Vista), I reinstalled GRUB2 using my Ubuntu LIVECD. Grub did not auto-detect Slackware 13.1 upon install.

Question: I would like to add Slackware 13.1 to GRUB so I can also boot it. (Right now my only options in Grub are Ubuntu and Vista- along with memtest etc)

note: /sda5 is Slackware and /sda8 is Ubuntu
fdisk -l
Code:
Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x68bbdcaa

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1        7279    58461113    7  HPFS/NTFS
/dev/sda2            7449       19166    94116803+   5  Extended
/dev/sda5            7450        9909    19759950   83  Linux
/dev/sda6            9910       10065     1247348   83  Linux
/dev/sda7           18331       19166     6715138+  82  Linux swap / Solaris
/dev/sda8           10065       17988    63640576   83  Linux
/dev/sda9           17988       18330     2751488   82  Linux swap / Solaris
/etc/default/grub
Code:
# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.

GRUB_DEFAULT=0
#GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=10
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""

# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_LINUX_RECOVERY="true"

# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"
/boot/grub/grub.cfg
Code:
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
  load_env
fi
set default="0"
if [ ${prev_saved_entry} ]; then
  set saved_entry=${prev_saved_entry}
  save_env saved_entry
  set prev_saved_entry=
  save_env prev_saved_entry
  set boot_once=true
fi

function savedefault {
  if [ -z ${boot_once} ]; then
    saved_entry=${chosen}
    save_env saved_entry
  fi
}

function recordfail {
  set recordfail=1
  if [ -n ${have_grubenv} ]; then if [ -z ${boot_once} ]; then save_env recordfail; fi; fi
}
insmod ext2
set root='(hd0,8)'
search --no-floppy --fs-uuid --set 5e37b2ed-3973-4225-802b-2fe2a24e9370
if loadfont /usr/share/grub/unicode.pf2 ; then
  set gfxmode=640x480
  insmod gfxterm
  insmod vbe
  if terminal_output gfxterm ; then true ; else
    # For backward compatibility with versions of terminal.mod that don't
    # understand terminal_output
    terminal gfxterm
  fi
fi
insmod ext2
set root='(hd0,8)'
search --no-floppy --fs-uuid --set 5e37b2ed-3973-4225-802b-2fe2a24e9370
set locale_dir=($root)/boot/grub/locale
set lang=en
insmod gettext
if [ ${recordfail} = 1 ]; then
  set timeout=-1
else
  set timeout=10
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=white/black
set menu_color_highlight=black/light-gray
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry 'Ubuntu, with Linux 2.6.32-21-generic' --class ubuntu --class gnu-linux --class gnu --class os {
    recordfail
    insmod ext2
    set root='(hd0,8)'
    search --no-floppy --fs-uuid --set 5e37b2ed-3973-4225-802b-2fe2a24e9370
    linux    /boot/vmlinuz-2.6.32-21-generic root=UUID=5e37b2ed-3973-4225-802b-2fe2a24e9370 ro   quiet splash
    initrd    /boot/initrd.img-2.6.32-21-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-21-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
    recordfail
    insmod ext2
    set root='(hd0,8)'
    search --no-floppy --fs-uuid --set 5e37b2ed-3973-4225-802b-2fe2a24e9370
    echo    'Loading Linux 2.6.32-21-generic ...'
    linux    /boot/vmlinuz-2.6.32-21-generic root=UUID=5e37b2ed-3973-4225-802b-2fe2a24e9370 ro single
    echo    'Loading initial ramdisk ...'
    initrd    /boot/initrd.img-2.6.32-21-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
    insmod ext2
    set root='(hd0,8)'
    search --no-floppy --fs-uuid --set 5e37b2ed-3973-4225-802b-2fe2a24e9370
    linux16    /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
    insmod ext2
    set root='(hd0,8)'
    search --no-floppy --fs-uuid --set 5e37b2ed-3973-4225-802b-2fe2a24e9370
    linux16    /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows Vista (loader) (on /dev/sda1)" {
    insmod ntfs
    set root='(hd0,1)'
    search --no-floppy --fs-uuid --set 20c2aaa3c2aa7d22
    chainloader +1
}
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###
hope this is enough info...thanks!

Last edited by Ubunoob001; 09-14-2010 at 09:55 AM.
 
Old 09-14-2010, 10:06 AM   #2
Ubunoob001
Member
 
Registered: Feb 2010
Location: New Orleans, LA
Distribution: Mint 16 RC, Elementary OS Luna, Crunchbang
Posts: 166

Original Poster
Rep: Reputation: 17
Smile solution

Okay so all I needed to do was run
Code:
sudo os-prober
followed by
Code:
sudo update-grub
. Should have figured this out prior to posting. Thanks All!
 
1 members found this post helpful.
  


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
How to edit GRUB to add Slackware in it? david08 Slackware 8 01-02-2010 01:47 PM
[SOLVED] How to add slackware in grub boot loader? cola Slackware 14 09-15-2009 04:55 AM
How Do I Add Slackware to Fedora's Grub.conf raziel23x Slackware 18 10-25-2007 12:38 PM
how do i add Slackware to GRUB ?? phyre-x Slackware 9 05-23-2006 01:11 AM
Can't chroot to slackware to 'mkinitrd' to add to grub menu surfbass Linux - General 1 05-02-2006 02:22 PM

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

All times are GMT -5. The time now is 02:16 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