Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
I am already hating grub 2...
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
curmudgeon
Veteran
Veteran


Joined: 08 Aug 2003
Posts: 1740

PostPosted: Sat Oct 26, 2013 10:54 am    Post subject: I am already hating grub 2... Reply with quote

and I haven't even used it yet.

It looks like yet another case of taking something simple that worked reasonably well, and turning it into something that the average user will no longer be able to understand.

I am already expecting a huge number of problems.

For now though, let me move the griping to a couple of concrete items.

First up, I use softlevels extensively on the laptops I administer (I don't really need them, but they are great for less technical users). It doesn't seem that these were covered in any of the gentoo documentation for grub 2 that I read. How do I keep those?

Right behind that (but at least as important if not more so), is setting up the video mode for the framebuffer (including rotation). That was painful enough to learn the first time, and I don't want to repeat the time and effort involved in getting it working acceptably the first time. Since grub.cfg begins with "# DO NOT EDIT THIS FILE", how do I pass those parameters to the kernel?
Back to top
View user's profile Send private message
Maitreya
Guru
Guru


Joined: 11 Jan 2006
Posts: 441

PostPosted: Sat Oct 26, 2013 11:42 am    Post subject: Reply with quote

You are not supposed to directly edit the config in /boot anymore.
The scriptfiles that generate "bootlines + options" in that /boot config are in /etc/grub.d/ with grub:2

(Make those you want to run, executable with chmod +x)

Gentoo also has /etc/defaults/grub in which you can set default options for save or default kernels. For example graphical options.

After mounting boot and running "grub2-mkconfig -o /boot/grub/grub.cfg" it will generate that config with the settings in above files.

I was quite skeptical at first (why change a winning team) but after trying grub:2 I'm convinced.
It gives me an ideal flow for rebuilding my kernel and correctly deploying (never a typo, as the lines are generated from the scripts)
Also found that my graphic cards behave more nicely. When building a kernel now with almost all graphical modules it seems to play nicer in switching to the correct one for the framebuffer. But if someone with more knowledge wants to chime in on that one, please do.

I can really recommend to try at least in a virtual machine.
Back to top
View user's profile Send private message
TheLexx
Tux's lil' helper
Tux's lil' helper


Joined: 04 Dec 2005
Posts: 137
Location: Austin Tx

PostPosted: Sat Oct 26, 2013 1:13 pm    Post subject: Reply with quote

Yeah, it is quite a shame. The grub2 language itself is quite nice. If has all the features of a true computing language. The problem I see with the grub2 system is that is suppose to be complete automated so that the package manager will generate the all the grub scripts. The code looks yucky and I did not find out how the power users could manually set kernel options.

My solution was to just install the grub2 master boot thingie (forgot the technical name) and use a separate boot partition with my own config written from scratch. Grub2 config files have the ability to "source" other files.

Because of this, I have one file that just defines variables example file: grub-gtoo-kern.cfg contains "gentookern=kern_name gentookern_new=kern_name gentookern_bac=kern_name". In My main script I have a menuentry for desktop, server testbed. In a submenu I have entries for "desktop new kernel" and "desktop backup kernel". Every new kernel built gets a unique name. After making a new kernel, I edit the grub-gtoo-kern.cfg file. I do not touch the main grub.cfg file.
Back to top
View user's profile Send private message
666threesixes666
Veteran
Veteran


Joined: 31 May 2011
Posts: 1248
Location: 42.68n 85.41w

PostPosted: Sat Oct 26, 2013 1:46 pm    Post subject: Reply with quote

hi, i beat on the wiki regularly, and grub2 was the first thing i was beating on.

/etc/default/grub is where your manual kernel flags and stuff are set. ie frame buffer config lines

i switched to lilo on the desktop because i was having problems with grub 2 not liking my dual drive setup with boot and root on sdb. laptop i was strong armed into lilo from windows xp starting @ sector 63....

grub 2 makes old kernel config entries, and automatically boots the latest kernel configuration, with no need to tweek files.

i wrote a script to automatically generate everything and install everything and check that /boot is mounted etc....

Code:

#!/bin/bash
#make sure boot is mounted to load the kernel
mount | grep "/boot" /proc/self/mounts > /dev/null
if [ $? -ne 0 ]; then
mount /boot
fi
#dynamically assign the drive to install grub2 to
DRIVE=$(cat /proc/self/mounts | grep boot | awk '{print $1}' | sed 's/[0-9]*//g')
echo "installing grub2 to $DRIVE"
/usr/sbin/grub2-mkconfig -o /boot/grub/grub.cfg
/usr/sbin/grub2-install $DRIVE


on my system located @ /usr/sbin/update-grub2 && chmod +x /usr/sbin/update-grub2 && update-grub2

i've been told repeatedly that im not supposed to touch the gears of gnu, so drop the script in your $HOME instead & run everything as root.

on your system located @ $HOME/update-grub2 && chmod +x $HOME/update-grub2 && $HOME/update-grub2 & from then on its just $HOME/update-grub2 as root

edit:

as of today sys-boot/grub-2.00_p5107-r2 works like a charm with my dual drive setup.

any lines i want to append to the root entries to my kernels are added to

GRUB_CMDLINE_LINUX_DEFAULT="ro quiet"
Back to top
View user's profile Send private message
creaker
l33t
l33t


Joined: 14 Jul 2012
Posts: 651

PostPosted: Sat Oct 26, 2013 2:40 pm    Post subject: Re: I am already hating grub 2... Reply with quote

curmudgeon wrote:
Since grub.cfg begins with "# DO NOT EDIT THIS FILE", how do I pass those parameters to the kernel?


I never paid attention to this kind of messages. If I need to update grub menu I do it by hand. Just copying first menuentry as template and editing it to get him matching new entry partition, kernel, command line options. And my menu looks much more cleaner and neater than default menu shown by .cfg with tons of crap that I never will be use, e.g. Advanced options, failsafe mode, bunch of old kernels and so on.
In other words, I replaced grub-mkconfig with kate.
Back to top
View user's profile Send private message
Maitreya
Guru
Guru


Joined: 11 Jan 2006
Posts: 441

PostPosted: Sat Oct 26, 2013 3:07 pm    Post subject: Re: I am already hating grub 2... Reply with quote

creaker wrote:
curmudgeon wrote:
Since grub.cfg begins with "# DO NOT EDIT THIS FILE", how do I pass those parameters to the kernel?


I never paid attention to this kind of messages. If I need to update grub menu I do it by hand. Just copying first menuentry as template and editing it to get him matching new entry partition, kernel, command line options. And my menu looks much more cleaner and neater than default menu shown by .cfg with tons of crap that I never will be use, e.g. Advanced options, failsafe mode, bunch of old kernels and so on.
In other words, I replaced grub-mkconfig with kate.


You could add a script in /etc/grub.d/ that does this for you.
Back to top
View user's profile Send private message
creaker
l33t
l33t


Joined: 14 Jul 2012
Posts: 651

PostPosted: Sat Oct 26, 2013 3:33 pm    Post subject: Re: I am already hating grub 2... Reply with quote

Maitreya wrote:
creaker wrote:
curmudgeon wrote:
Since grub.cfg begins with "# DO NOT EDIT THIS FILE", how do I pass those parameters to the kernel?


I never paid attention to this kind of messages. If I need to update grub menu I do it by hand. Just copying first menuentry as template and editing it to get him matching new entry partition, kernel, command line options. And my menu looks much more cleaner and neater than default menu shown by .cfg with tons of crap that I never will be use, e.g. Advanced options, failsafe mode, bunch of old kernels and so on.
In other words, I replaced grub-mkconfig with kate.


You could add a script in /etc/grub.d/ that does this for you.

Last time I used grub-mkconfig I tried to add custom menuentry by adding script. Grub-mkconfig created menuentry that doesn't boot and duplicated this entry. So I decided to edit it by hand much more easy than deal with scripts and solve grub's issues.
Back to top
View user's profile Send private message
xaviermiller
Bodhisattva
Bodhisattva


Joined: 23 Jul 2004
Posts: 8704
Location: ~Brussels - Belgique

PostPosted: Sat Oct 26, 2013 4:06 pm    Post subject: Reply with quote

I switched to syslinux, and it keeps simple :)
_________________
Kind regards,
Xavier Miller
Back to top
View user's profile Send private message
TheLexx
Tux's lil' helper
Tux's lil' helper


Joined: 04 Dec 2005
Posts: 137
Location: Austin Tx

PostPosted: Sat Oct 26, 2013 9:43 pm    Post subject: Re: I am already hating grub 2... Reply with quote

creaker wrote:
curmudgeon wrote:
Since grub.cfg begins with "# DO NOT EDIT THIS FILE", how do I pass those parameters to the kernel?


I never paid attention to this kind of messages. If I need to update grub menu I do it by hand. Just copying first menuentry as template and editing it to get him matching new entry partition, kernel, command line options. And my menu looks much more cleaner and neater than default menu shown by .cfg with tons of crap that I never will be use, e.g. Advanced options, failsafe mode, bunch of old kernels and so on.
In other words, I replaced grub-mkconfig with kate.


My sentiments exactly. that is why I have such a simple easy to read grub.cfg file.

Code:

set default='Merganser'
set timeout=90

root=(hd0,1)

source /grub2/grub-hardware.cfg

## Menues
menuentry "Merganser" --hotkey="m" {
          set parmroot="root=/dev/sda6"
          source /grub2/grub-gtoo-kern.cfg
          set kernel=$gentoo_kernel
          #set hard=""
          linux $kernel $hard $parmroot
}

menuentry "Server testbed smallfont" --hotkey="s" {
          source /grub2/grub-gtoo-kern.cfg
          set gfxpayload="800x600"
          set parmroot="root=/dev/sda7"
          set kernel=$gentoo_kernel
          #set hard=""
          linux $kernel $hard $parmroot
}

menuentry "Server testbed largefont" --hotkey="S" {
          source /grub2/grub-gtoo-kern.cfg
          set parmroot="root=/dev/sda7"
          set kernel=$gentoo_kernel
          #set hard=""
          linux $kernel $hard $parmroot
}

submenu   "More Options" --hotkey=tab {

           menuentry "Merganser new Kernel" {
                     set parmroot="root=/dev/sda6"
                     source /grub2/grub-gtoo-kern.cfg
                     set kernel=$new_gentoo_kernel
                     #set hard=""
                     linux $kernel $hard $parmroot
           }

           menuentry "Merganser old Kernel" {
                     set parmroot="root=/dev/sda6"
                     source /grub2/grub-gtoo-kern.cfg
                     set kernel=$old_gentoo_kernel
                     #set hard=""
                     linux $kernel $hard $parmroot
           }

           menuentry "Mini testbed smallfont" {
                     source /grub2/grub-gtoo-kern.cfg
                     set gfxpayload="800x600"
                     set parmroot="root=/dev/sda8"
                     set kernel=$gentoo_kernel
                     #set hard=""
                     linux $kernel $hard $parmroot
           }

           menuentry "Expermental Configfile" {
                     configfile /grub2/grub-expermnt.cfg
           }

           menuentry "Memtest"{
                     linux16 /memtest.bin
           }
}

It looks more like a grub1 config file.
Back to top
View user's profile Send private message
curmudgeon
Veteran
Veteran


Joined: 08 Aug 2003
Posts: 1740

PostPosted: Sun Oct 27, 2013 8:40 am    Post subject: Reply with quote

I have already had to blow away /boot and reformat it (for eighteen years I have been creating small boot partitions with only 256 inodes, because I could never imagine that a boot partition would need more than that - SURPRISE, grub2 requires more than 300 - side note, I wish there were some way of only installing relevant modules, but that is likely to be the least of my worries).

Maitreya wrote:
You are not supposed to directly edit the config in /boot anymore.
The scriptfiles that generate "bootlines + options" in that /boot config are in /etc/grub.d/ with grub:2


This is one of my main gripes - pushing users farther and farther away from what is happening.

Maitreya wrote:
Gentoo also has /etc/defaults/grub in which you can set default options for save or default kernels. For example graphical options.


How about providing me with an actual example?

I have a machine where the grub one line ends with "fbcon=rotate:3 vga=775" (how do I get that into grub 2?).

Likewise, where do I add "softlevel=ethernet" or "softlevel=wireless" so that gentoo with boot into the correct runlevel (I need grub entries for each one, plus the default, which is to boot with networking disabled)?

TheLexx wrote:
My solution was to just install the grub2 master boot thingie (forgot the technical name) and use a separate boot partition with my own config written from scratch. Grub2 config files have the ability to "source" other files.


I am fine with manually editing files. I am not a fan of sourcing other files, simply because that makes it less transparent as to what is happening.

So far, any edits I have made to /etc/default/grub have been completely ignored (I got the exact same grub.cfg file as before when uncommenting GRUB_DISABLE_LINUX_UUID=true - is there something that needs to be run after updating this file and before running grub2-mkconfig?).

6threesixes666 wrote:
i switched to lilo on the desktop...


Probably the best solution of all.

creaker wrote:
And my menu looks much more cleaner and neater than default menu shown by .cfg with tons of crap that I never will be use, e.g. Advanced options, failsafe mode, bunch of old kernels and so on.
In other words, I replaced grub-mkconfig with kate.


I would probably use vim, but I like the sentiment. :) WTF do I need " --class gentoo --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" for? Are any of the modules actually required (I know I don't need video_bochs and video_cirrus)? Also, I thought insmod was deprecated in favor of modprobe (never mind - it looks like they are both symlinks to /bin/kmod now).

TheLexx wrote:
My sentiments exactly. that is why I have such a simple easy to read grub.cfg file.


How about posting the files that you sourced in grub.cfg?
Back to top
View user's profile Send private message
creaker
l33t
l33t


Joined: 14 Jul 2012
Posts: 651

PostPosted: Sun Oct 27, 2013 12:07 pm    Post subject: Reply with quote

Quote:
I have a machine where the grub one line ends with "fbcon=rotate:3 vga=775" (how do I get that into grub 2?).

probably you have to add it to kernel options. At least I have similar vga option set.

Quote:
WTF do I need " --class gentoo --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'" for? Are any of the modules actually required (I know I don't need video_bochs and video_cirrus)? Also, I thought insmod was deprecated in favor of modprobe (never mind - it looks like they are both symlinks to /bin/kmod now).



I think it was done to confuse the user and make it look complex and unclear, so that the user does not have a desire to do something himself. I have no all these crap in my menu, but nevertheless it boots fine:

Code:
menuentry 'Gentoo kernel-3.8.13'{
   set root='hd0,msdos2'
   search --no-floppy --fs-uuid --set=root cad32add-44df-40de-a842-08380537613c
   linux   /boot/kernel-3.8.13-gentoo root=/dev/sda2 ro vga=795 init=/sbin/e4rat-preload
}


This bunch of strings was removed:
Code:
insmod ext2
load_video   
insmod part_msdos   
insmod gzio
if [ x$feature_platform_search_hint = xy ]; then
     search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2  cad32add-44df-40de-a842-08380537613c
   else
     search --no-floppy --fs-uuid --set=root cad32add-44df-40de-a842-08380537613c
fi
echo   'Loading Linux 3.8.13-gentoo'
Back to top
View user's profile Send private message
_______0
Guru
Guru


Joined: 15 Oct 2012
Posts: 521

PostPosted: Sun Oct 27, 2013 12:34 pm    Post subject: Reply with quote

XavierMiller wrote:
I switched to syslinux, and it keeps simple :)


w00t, isn't this for liveCDs??

The most brutally simple way of booting is straight off uefi. No bootloader required, period.
Back to top
View user's profile Send private message
TheLexx
Tux's lil' helper
Tux's lil' helper


Joined: 04 Dec 2005
Posts: 137
Location: Austin Tx

PostPosted: Sun Oct 27, 2013 3:51 pm    Post subject: Reply with quote

curmudgeon wrote:
TheLexx wrote:
My sentiments exactly. that is why I have such a simple easy to read grub.cfg file.
How about posting the files that you sourced in grub.cfg?


grub-gtoo-kern.cfg
Code:
## Set Default Kernels

old_gentoo_kernel=/kmh-bzImage-3.4.41-2
gentoo_kernel=/kmh-bzImage-3.4.48-1
new_gentoo_kernel=/kmh-bzImage-3.4.48-1


grub-hardware.cfg
Code:
set hard_kestrel   = ""
set hard_merganser = ""
set hard_harrier   = "acpi_enforce_resources=lax"
set hard_goshawk   = ""

set hard=$hard_merganser
Back to top
View user's profile Send private message
miket
Guru
Guru


Joined: 28 Apr 2007
Posts: 483
Location: Gainesville, FL, USA

PostPosted: Tue Oct 29, 2013 4:00 am    Post subject: Reply with quote

_______0 wrote:
XavierMiller wrote:
I switched to syslinux, and it keeps simple :)


w00t, isn't this for liveCDs??

The most brutally simple way of booting is straight off uefi. No bootloader required, period.

Well, the UEFI method's all right if 1) you've got a BIOS that will do UEFI (or are willing to use the odd Tianocore shim), and 2) you never need to change your baked-in kernel command line.

I've quite happily moved into syslinux (specifically extlinux) for new installs. It's not just for CD's! The configuration is straightforward.

While I was at it, I even got a system to do all of these things:
1. An ext3 boot partition that contains the extlinux binaries and its configuration file (yes, just one file!). There is no need to set aside phantom unallocated space for mysterious stage 2.5 bootloaders.
2. Early userspace that does not require decompression: the kernel, busybox, scripts, and LVM binaries are all there not bundled in a shar file but easy to examine and edit.
3. This early userspace starts the LVM device mapper and allows boots root from an LVM volume, and does it all quickly. It runs very happily with OpenRC. (Drivers are compiled in-kernel, and eth0, by God, is eth0.)
4. By selecting a different menu option, I get a busybox-based rescue system.

I was planning to do a writeup of all of this, but unfortunately, in the midst of working to get a smooth, reproducable procedure that I wanted to try in various setups, I got too busy at work. The project's not ready to mention too much, but I did want to make this point: syslinux is worth a look for frustrated grub2 people.
Back to top
View user's profile Send private message
mreff555
Apprentice
Apprentice


Joined: 10 Mar 2011
Posts: 231
Location: Philadelphia

PostPosted: Tue Oct 29, 2013 8:16 pm    Post subject: Reply with quote

I couldn't agree more. Which is why I use LILO

Code:

boot=/dev/sda                   
prompt                           
timeout=00                   
default=Gentoo
lba32
image=/boot/kernel-3.11.1-gentoo-r00
  label=Gentoo
  read-only
  root=/dev/sda4


Instead of a bunch of obscure files, I just have one tiny config file that I can write from memory.
Back to top
View user's profile Send private message
xaviermiller
Bodhisattva
Bodhisattva


Joined: 23 Jul 2004
Posts: 8704
Location: ~Brussels - Belgique

PostPosted: Tue Oct 29, 2013 8:20 pm    Post subject: Reply with quote

_______0 wrote:
XavierMiller wrote:
I switched to syslinux, and it keeps simple :)


w00t, isn't this for liveCDs??

The most brutally simple way of booting is straight off uefi. No bootloader required, period.


Hello,

extlinux can be run on hard disks, and is as simple and configurable as syslinux.

But indeed, if you have UEFI, don't use any bootloader but EFI.
_________________
Kind regards,
Xavier Miller
Back to top
View user's profile Send private message
hujuice
Guru
Guru


Joined: 16 Oct 2007
Posts: 318
Location: Rome, Italy

PostPosted: Sun Nov 03, 2013 11:56 am    Post subject: Reply with quote

XavierMiller wrote:
I switched to syslinux, and it keeps simple :)

Same here.
Grub 2 has the hateful feature that for a normal management you need a working system to edit its configuration. Exactly what you DON'T have when you experiment a problem/mistake/try. In such situations, you need to chroot in or perform a sort of "hacking" (ok, we're not afraid because the «# DO NOT EDIT THIS FILE» warning).

The syslinux family, instead, is very powerful and elegant. Its most remarkable lack is the documentation, complete but not well organized for my point of view. But it has a very good learning curve.
It is a very good choice and maybe more powerful than grub 1/2. Let's see why.

syslinux is a family:
    SYSLINUX, able to boot from FAT
    EXTLINUX, able to boot from ext2/3/4 and btrfs
    ISOLINUX, able to boot from CDROM/USB
    PXELINUX, able to boot from network

So, you can manage a centralized bootloader for your network, if you want, or you can easily change your mind about your partition layout or have more ideas.
For example, I've a centralized SystemRescueCD via PXE for all my network.
Grub 2 can do the same, but in a more complex and strict ways.
Most important, you can directly write to the syslinux configuration file.
Also, syslinux can manage GPT and UEFI scenarios.
Last, you can check powerful configuration examples in many live distros.

XavierMiller and me are not alone in this idea. A lot of people agree with us. Note that Arch propose syslinux and Grub 2 as equal alternatives in the official guide.

You can start from here: https://wiki.gentoo.org/wiki/Syslinux
It's very easy. And then you can learn more about all its wide landscape of options.

Hurrah for {sys|ext|iso|pxe}linux!
http://www.syslinux.org/wiki/index.php/The_Syslinux_Project

HUjuice
_________________
Who hasn't a spine, should have a method.
Chi non ha carattere, deve pur avere un metodo.
Back to top
View user's profile Send private message
mv
Watchman
Watchman


Joined: 20 Apr 2005
Posts: 6747

PostPosted: Sun Nov 03, 2013 2:04 pm    Post subject: Reply with quote

hujuice wrote:
Grub 2 has the hateful feature that for a normal management you need a working system to edit its configuration.

This is plain wrong. Exactly the opposite was true already for legacy grub, and it is true even more for grub2.
You only need a working system if you want to use the tools to automatically generate an example grub.cfg adapted to your system.
Quote:
Most important, you can directly write to the syslinux configuration file.

So what is better than for grub where you can directly write to the grub configuration file?
The disadvantage of this is identical in both cases: you need a running system (with an editor). In grub you can just change the configuration on the fly on booting without needing any other tool. Only to make the change permanent you have to edit the file eventually.
Back to top
View user's profile Send private message
hujuice
Guru
Guru


Joined: 16 Oct 2007
Posts: 318
Location: Rome, Italy

PostPosted: Mon Nov 04, 2013 9:41 am    Post subject: Reply with quote

mv wrote:
So what is better than for grub where you can directly write to the grub configuration file?

mv, you have reason, my tone was too categorical. We can do everything with both. Having more opportunities is always good.

But what I mean is that everything is the relationship between our knowledge and time effort and the results.
syslinux has the classical layout of an application with a configuration text file, where the KISS principle works fine and where a handful of hand written (via an editor, not telepathy, of course) lines can boot a machine. This is true for Grub legacy too.
The Grub2 layout is application/application-to-write-the-configuration-text-file/complex-text-file. Why? This is not KISS.
In case of problem we need a working system *with Grub2* (while a typical live CD boots with ISOLINUX, do they have Grub2?) or maybe directly edit a configuration built not to be edited. In such situation, we need extra knowledge for no extra benefits, from my point of view.

I completely agree if you say that Grub2 is a compete and well working application. You can have a scenario where Grub2 is better than syslinux and you can simply prefer it. Also, SystemRescueCD has Grub2 and SystemRescueCD is "my" live system. I was too assertive and manichean in the previous post.

But actually I cannot see the benefits of the Grub2 approach, while I see the simple power of syslinux.

Regards,
HUjuice
_________________
Who hasn't a spine, should have a method.
Chi non ha carattere, deve pur avere un metodo.
Back to top
View user's profile Send private message
mv
Watchman
Watchman


Joined: 20 Apr 2005
Posts: 6747

PostPosted: Mon Nov 04, 2013 11:44 am    Post subject: Reply with quote

hujuice wrote:
The Grub2 layout is application/application-to-write-the-configuration-text-file/complex-text-file. Why? This is not KISS.

You can just ignore that misconception and use your grub.cfg. Users who do not want to read the documentation or have no time/ability to write a grub.cfg will still be happy about the possibility that frequent use-cases can be configured out-of-the-box from a running system without any preknowledge.
Quote:
In such situation, we need extra knowledge for no extra benefits, from my point of view.

You do need the knowledge in both cases (either about syslinux config or grub.cfg). With the non-KISS scripts users can get around this knowledge in simple cases when they have no (or only trivial) special needs.
Quote:
But actually I cannot see the benefits of the Grub2 approach

You practically have a primitive rescue system built-in which you can start at every boot (unless the disk is so much damaged that even grub does not boot, but in this case you need a rescue disk in all cases).
Back to top
View user's profile Send private message
shazeal
Apprentice
Apprentice


Joined: 03 May 2006
Posts: 206
Location: New Zealand

PostPosted: Mon Nov 04, 2013 6:23 pm    Post subject: Reply with quote

XavierMiller wrote:
I switched to syslinux, and it keeps simple :)


I love you! This is so much better than Grub1/2/Lilo! It did stump me a bit until I realised it needs /boot on a separate partition. But my config...

Code:
UI menu.c32
PROMPT 0

MENU TITLE Boot Menu
TIMEOUT 100
DEFAULT Gentoo Linux

LABEL Gentoo Linux
  MENU LABEL Gentoo Linux
  KERNEL /vmlinuz-3.10.17
  APPEND root=/dev/sda2

LABEL Debian Linux
  MENU LABEL Debian Linux
  KERNEL /vmlinuz-3.11.6-ck1
  APPEND root=/dev/sda3
  INITRD /initrd.img-3.11.6-ck1


So simple!
_________________
CFLAGS="-OmgWTFR1CE --fun-lol-loops --march=asmx86go"
Back to top
View user's profile Send private message
frostschutz
Advocate
Advocate


Joined: 22 Feb 2005
Posts: 2977
Location: Germany

PostPosted: Mon Nov 04, 2013 6:59 pm    Post subject: Reply with quote

I actually like Grub 2, but I keep the config custom nevertheless. I don't understand the generated stuff with all the insmods and whatnots, which you don't seem to actually need if you write it yourself...

currently looks like this: http://bpaste.net/show/146707/
Back to top
View user's profile Send private message
mv
Watchman
Watchman


Joined: 20 Apr 2005
Posts: 6747

PostPosted: Mon Nov 04, 2013 7:21 pm    Post subject: Reply with quote

frostschutz wrote:
I actually like Grub 2, but I keep the config custom nevertheless. I don't understand the generated stuff with all the insmods and whatnots, which you don't seem to actually need if you write it yourself...

Well, you need those modules which you neeed (e.g. for the filesystem, for graphical eyecandy if you want it, for lvm if you use it, ...). Some modules are perhaps autoloaded. Unfortuantely, documentation concerning the modules is practically non-existent.
You need the first part of the autogenerated grub.cfg if you want that e.g. kdm is able to select a certain entry only for the next booting etc.
You might want to have a look at this sample grub.cfg with a function library
Quote:
currently looks like this: http://bpaste.net/show/146707/

I would suggest to add search commands with UUIDs so that you have no problems if you add/remove a harddisk.
Back to top
View user's profile Send private message
frostschutz
Advocate
Advocate


Joined: 22 Feb 2005
Posts: 2977
Location: Germany

PostPosted: Tue Nov 05, 2013 11:12 am    Post subject: Reply with quote

That's the thing about modules, it autoloads them all for me. So all the insmod lines are just bloat as far as I am concerned. As for UUID, it's not necessary in my case. The main reason my config looks complicated is because of all the live CDs. The minimal example would really be just the first 7 lines. My point is, if you like a simple configuration, you can have it even with Grub 2. It's just that the generated configs are completely bonkers. Which is fine if you don't care as long as it works either way, not so fine if you like to fine tune things yourself.
Back to top
View user's profile Send private message
monicajae
Guru
Guru


Joined: 03 Sep 2003
Posts: 363
Location: Dorset, VT

PostPosted: Wed Nov 13, 2013 2:19 am    Post subject: Re: I am already hating grub 2... Reply with quote

curmudgeon wrote:
and I haven't even used it yet.

It looks like yet another case of taking something simple that worked reasonably well, and turning it into something that the average user will no longer be able to understand.

I am already expecting a huge number of problems.

For now though, let me move the griping to a couple of concrete items.

First up, I use softlevels extensively on the laptops I administer (I don't really need them, but they are great for less technical users). It doesn't seem that these were covered in any of the gentoo documentation for grub 2 that I read. How do I keep those?

Right behind that (but at least as important if not more so), is setting up the video mode for the framebuffer (including rotation). That was painful enough to learn the first time, and I don't want to repeat the time and effort involved in getting it working acceptably the first time. Since grub.cfg begins with "# DO NOT EDIT THIS FILE", how do I pass those parameters to the kernel?


I AM SO FEELING THIS!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum