LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
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 11-29-2015, 08:50 PM   #1
WLD
LQ Newbie
 
Registered: Nov 2015
Location: UK
Distribution: Slack64-current, Slack64-14.1, Slack-13.37, RISC OS
Posts: 16

Rep: Reputation: Disabled
Question Anyone else on UEFI ditched ELILO for GRUB2 + GPT?


Just wondering if anybody else who moved to Slackware64 on UEFI decided to ditch ELILO and manually setup GRUB2 with GPT?

For the longest while on Slackware32 I've been using LILO on BIOS and having simple and stress-free booting but I think ELILO is just a bit of a mess and was causing lots of stressful and avoidable problems. It also gave me no end of issues when trying to use KMS for my Intel chipset.

I think ELILO is just clinging to the past a little bit, one hack at a time. With UEFI the new de-facto standard I really think it's time to look for a better boot solution that's fully-featured and mature, and I don't think ELILO is it.

My GRUB2 is purely functional and not pretty (not that is matters for about 2 whole seconds before Linux boots) but if anybody has setup theirs up to be a bit fancy I'd love to see your config, please share!

WLD
 
Old 11-29-2015, 09:21 PM   #2
Nille_kungen
Member
 
Registered: Jul 2005
Distribution: Slackware64-current
Posts: 587

Rep: Reputation: 201Reputation: 201Reputation: 201
I used elilo for a while but switched to grub2.
Since i'm not that used to grub it was a bit of a headache to set up but that was mostly my inexperience.
Actually grub2 was pretty easy to set up, i followed the archwiki and even set up my windows install in grub but i haven't used it more then testing that it worked.
 
Old 11-29-2015, 09:23 PM   #3
worsel
Member
 
Registered: Feb 2008
Location: Washington State, USA
Distribution: Slackware 14.2, Slackware-from-Scratch
Posts: 241

Rep: Reputation: 45
I've been using grub2 since about 1.91. My present computer is 64 bit with GPT.
Nothing fancy. I just installed the Slackware package and away it went.

I do set the grub.d files 10_linux, 20_linux_zen, 30_osprober permissions to 644
and list bootable partitions in 40_custom. Gives a very plain menu.

Worsel
 
Old 11-29-2015, 10:29 PM   #4
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,062

Rep: Reputation: Disabled
It's just a matter of situation and use case, as explained by Rod Smith. This being said, whilst grub is of more broader usage, shipped with elilo comes efibootmgr, that has still no equivalent that I know of to configure your firmware's boot menu (instead of setting a boot menu on a hard disk, as do grub). This has the advantage that your machine will continue to boot if you replace the hard disk where grub could else have installed a boot loader. This make use or a specific UEFI feature, that is the ability to set the firmware's menu from the OS. This being said, there are plenty of other tools that one could consider, see the aforementioned article that gives a practical overview of the landscape.

Just use what fits your needs and taste, there is no absolute answer to "which is better".
 
Old 11-29-2015, 10:35 PM   #5
Richard Cranium
Senior Member
 
Registered: Apr 2009
Location: McKinney, Texas
Distribution: Slackware64 15.0
Posts: 3,858

Rep: Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225
I've been using this rather shameless ripoff of grub2's /etc/grub.d/10_linux script for a while. I call it /etc/grub.d/09_slackware_linux
Code:
#! /bin/sh
set -e
# grub-mkconfig helper script.
# Copyright (C) 2006,2007,2008,2009,2010  Free Software Foundation, Inc.
#
# GRUB is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# GRUB is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GRUB.  If not, see <http://www.gnu.org/licenses/>.

prefix="/usr"
exec_prefix="${prefix}"
datarootdir="${prefix}/share"

. "${datarootdir}/grub/grub-mkconfig_lib"

export TEXTDOMAIN=grub
export TEXTDOMAINDIR="${datarootdir}/locale"

CLASS="--class gnu-linux --class gnu --class os"

if [ "x${GRUB_DISTRIBUTOR}" = "x" ] ; then
  OS=GNU/Linux
else
  OS="${GRUB_DISTRIBUTOR} GNU/Linux"
  CLASS="--class $(echo ${GRUB_DISTRIBUTOR} | tr '[A-Z]' '[a-z]') ${CLASS}"
fi

# loop-AES arranges things so that /dev/loop/X can be our root device, but
# the initrds that Linux uses don't like that.
case ${GRUB_DEVICE} in
  /dev/loop/*|/dev/loop[0-9])
    GRUB_DEVICE=`losetup ${GRUB_DEVICE} | sed -e "s/^[^(]*(\([^)]\+\)).*/\1/"`
  ;;
esac

if [ "x${GRUB_DEVICE_UUID}" = "x" ] || [ "x${GRUB_DISABLE_LINUX_UUID}" = "xtrue" ] \
    || ! test -e "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" ; then
  LINUX_ROOT_DEVICE=${GRUB_DEVICE}
else
  LINUX_ROOT_DEVICE=UUID=${GRUB_DEVICE_UUID}
fi

linux_entry ()
{
  os="$1"
  tag="$2"
  version="$3"
  recovery="$4"
  args="$5"
  if ${recovery} ; then
    title="$(gettext "s, with Linux %s [%s] (recovery mode)")"
  else
    title="$(gettext "%s, with Linux %s [%s]")"
  fi
  printf "menuentry \"${title}\" ${CLASS} {\n" "${os}" "${version}" "${tag}"
  save_default_entry | sed -e "s/^/\t/"

  # Use ELILO's generic "efifb" when it's known to be available.
  # FIXME: We need an interface to select vesafb in case efifb can't be used.
  if [ "x$GRUB_GFXPAYLOAD_LINUX" = x ]; then
      if grep -qx "CONFIG_FB_EFI=y" /boot/config-${version} 2> /dev/null \
	  && grep -qx "CONFIG_VT_HW_CONSOLE_BINDING=y" /boot/config-${version} 2> /dev/null; then
	  cat << EOF
	set gfxpayload=keep
EOF
      fi
  else
	  cat << EOF
	set gfxpayload=$GRUB_GFXPAYLOAD_LINUX
EOF
  fi

  if [ -z "${prepare_boot_cache}" ]; then
    prepare_boot_cache="$(prepare_grub_to_access_device ${GRUB_DEVICE_BOOT} | sed -e "s/^/\t/")"
  fi
  printf '%s\n' "${prepare_boot_cache}"
  cat << EOF
	echo	$(printf "$(gettext "Loading Linux %s ...")" ${version})
	linux	${rel_dirname}/${basename} root=${linux_root_device_thisversion} ro ${args}
EOF
  if test -n "${initrd}" ; then
    cat << EOF
	echo	$(gettext "Loading initial ramdisk ...")
	initrd	${rel_dirname}/${initrd}
EOF
  fi
  cat << EOF
}
EOF
}


process_list ()
{
    mylist="$1"
    tag="$2"
    initrd_allowed="$3"
    while [ "x$mylist" != "x" ] ; do
	linux=`version_find_latest $mylist`
	echo "Found linux image: $linux" >&2
	basename=`basename $linux`
	dirname=`dirname $linux`
	rel_dirname=`make_system_path_relative_to_its_root $dirname`
	version=`echo $basename | sed -e "s,^[^0-9]*-,,g"`
	alt_version=`echo $version | sed -e "s,\.old$,,g"`
	linux_root_device_thisversion="${LINUX_ROOT_DEVICE}"
        initrd=
	if [ "x${initrd_allowed}" = "xtrue" ]; then
	    for i in "initrd-${version}.gz" "initrd.gz" \
		"initrd.img-${version}" "initrd-${version}.img" \
		"initrd-${version}" "initrd.img-${alt_version}" \
		"initrd-${alt_version}.img" "initrd-${alt_version}"; do
		if test -e "${dirname}/${i}" ; then
		    initrd="$i"
		    break
		fi
	    done
	    if test -n "${initrd}" ; then
		echo "Found initrd image: ${dirname}/${initrd}" >&2
	    else
                # "UUID=" magic is parsed by initrds.  Since there's no initrd, it can't work here.
		linux_root_device_thisversion=${GRUB_DEVICE}
	    fi
	else
            # "UUID=" magic is parsed by initrds.  Since there's no initrd, it can't work here.
	    linux_root_device_thisversion=${GRUB_DEVICE}
	fi

	linux_entry "${OS}" "${tag}" "${version}" false \
	    "${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT}"
	if [ "x${GRUB_DISABLE_LINUX_RECOVERY}" != "xtrue" ]; then
	    linux_entry "${OS}" "${tag}" "${version}" true \
		"single ${GRUB_CMDLINE_LINUX}"
	fi

	mylist=`echo $mylist | tr ' ' '\n' | grep -vx $linux | tr '\n' ' '`
    done
}

prepare_boot_cache=

list=`for i in /boot/vmlinu[xz]-generic-* /vmlinu[xz]-generic-* ; do
        if grub_file_is_not_garbage "$i" ; then echo -n "$i " ; fi
      done`

process_list "${list}" "generic" "true"

list=`for i in /boot/vmlinu[xz]-huge-* /vmlinu[xz]-huge-* ; do
        if grub_file_is_not_garbage "$i" ; then echo -n "$i " ; fi
      done`
process_list "${list}" "huge" "false"
I run the 64 bit version of slackware; the above script will probably require a minor edit to work for 32 bit slackware.

Last edited by Richard Cranium; 11-29-2015 at 10:36 PM. Reason: Left something out.
 
Old 11-30-2015, 05:23 AM   #6
Tonus
Senior Member
 
Registered: Jan 2007
Location: Paris, France
Distribution: Slackware-15.0
Posts: 1,407
Blog Entries: 3

Rep: Reputation: 514Reputation: 514Reputation: 514Reputation: 514Reputation: 514Reputation: 514
Anyone else on UEFI ditched ELILO for GRUB2 + GPT?

I just reused a grub2 from previous debian install but haven't managed to theme it nor set up any background for now.

Since I don't reboot often it isn't very annoying... And doesn't let me test a lot.
 
Old 11-30-2015, 06:27 AM   #7
slalik
Member
 
Registered: Nov 2014
Location: Moscow
Distribution: Slackware
Posts: 233

Rep: Reputation: 203Reputation: 203Reputation: 203
I use grub on a server with bios but with gpt disks in raid10. Lilo didn't work and difficult to debug since this is a remote headless server. In grub I don't use the grub-mkconfig script, instead I use a very simple and clear file /boot/grub/grub.cfg:
Code:
set default=0
set timeout=0

search --set=root --label BOOT

menuentry "Linux" {
  linux /vmlinuz root=LABEL=ROOT ro nomodeset ipv6.disable=1 quiet
  initrd /ucode.cpio /initrd.gz
}
(Here BOOT and ROOT are labels of the partitions /boot and /, /boot/ucode.cpio is the Intel microcode.)
 
Old 11-30-2015, 07:39 AM   #8
chrisVV
Member
 
Registered: Aug 2010
Posts: 548

Rep: Reputation: 370Reputation: 370Reputation: 370Reputation: 370
Quote:
Originally Posted by WLD View Post
Just wondering if anybody else who moved to Slackware64 on UEFI decided to ditch ELILO and manually setup GRUB2 with GPT?
I have used slackware64's grub-2.00 with UEFI boot, and it works OK (it will also dual boot windows with the right recipe, although windows auto-detection doesn't work), but I much prefer rEFInd. It is considerably nicer than grub with UEFI in my view.
 
Old 11-30-2015, 08:42 AM   #9
dugan
LQ Guru
 
Registered: Nov 2003
Location: Canada
Distribution: distro hopper
Posts: 11,237

Rep: Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321
On my MacBook Pro I use no bootloader other than rEFind. No elilo, no syslinux, no grub2. I just have the kernel on the hard disk and rEFind finds it and is able to boot into it.

I think this is the best setup.
 
Old 11-30-2015, 07:45 PM   #10
ReaperX7
LQ Guru
 
Registered: Jul 2011
Location: California
Distribution: Slackware64-15.0 Multilib
Posts: 6,558
Blog Entries: 15

Rep: Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097
Does rEFind work on BtrFS-as-root systems with an EFI partition and separated /boot?
 
Old 11-30-2015, 10:41 PM   #11
dugan
LQ Guru
 
Registered: Nov 2003
Location: Canada
Distribution: distro hopper
Posts: 11,237

Rep: Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321Reputation: 5321
Quote:
Originally Posted by ReaperX7 View Post
Does rEFind work on BtrFS-as-root systems with an EFI partition and separated /boot?
That's awfully specific. I don't see why it wouldn't, but I don't know the answer.
 
Old 12-01-2015, 04:50 AM   #12
brobr
Member
 
Registered: Oct 2003
Location: uk
Distribution: Slackware
Posts: 974

Rep: Reputation: 239Reputation: 239Reputation: 239
google btrfs + refind and you get loads of info.

eg
http://sourceforge.net/p/refind/disc...read/c046733b/
https://wiki.archlinux.org/index.php/REFInd
refind_btrfs_driver_not_finding_arch/


Refind is very useful; allows you to boot from external drives as it scans all attached filesystems for its pointers to bootable kernels.
 
  


Reply

Tags
booting, elilo, gpt, grub2, uefi



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
[SOLVED] Cant boot in EFI mode: elilo doesnt load from the UEFI menu in a Asus motherboard. Linux-at-last Slackware 5 04-03-2014 04:23 PM
Problem with elilo and uefi on Asus rampage 4 damgar Slackware 3 10-20-2012 08:47 PM
lilo x elilo x grup2 x UEFI afreitascs Slackware 5 09-09-2012 10:55 AM
Elilo gpt slackware 13.37 64 -current -Fay- Linux - Software 2 03-09-2012 08:22 AM
UEFI PXE server elilo.conf configuration miszum Linux - Networking 2 08-05-2011 11:31 AM

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

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