* [gentoo-user] Question about genkernel's default kernel config @ 2016-08-14 11:45 Raymond Jennings 2016-08-14 12:49 ` Alan McKinnon 2016-08-15 7:27 ` [gentoo-user] " Azamat Hackimov 0 siblings, 2 replies; 29+ messages in thread From: Raymond Jennings @ 2016-08-14 11:45 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 347 bytes --] Hey, just curious about something: How is genkernel's "default" kernel config maintained? Is it fixed, or is it maintained as a diff against upstream, or what? I'm curious because I'm considering if I should just go straight to the kernel's own built in defaults. I know a lot of it sets up most things as modules instead of builtin/disabled. [-- Attachment #2: Type: text/html, Size: 451 bytes --] ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Question about genkernel's default kernel config 2016-08-14 11:45 [gentoo-user] Question about genkernel's default kernel config Raymond Jennings @ 2016-08-14 12:49 ` Alan McKinnon 2016-08-14 18:48 ` [gentoo-user] " Ian Zimmerman 2016-08-15 7:27 ` [gentoo-user] " Azamat Hackimov 1 sibling, 1 reply; 29+ messages in thread From: Alan McKinnon @ 2016-08-14 12:49 UTC (permalink / raw To: gentoo-user On 14/08/2016 13:45, Raymond Jennings wrote: > Hey, just curious about something: > > How is genkernel's "default" kernel config maintained? Is it fixed, or > is it maintained as a diff against upstream, or what? it's mysterious magic > > I'm curious because I'm considering if I should just go straight to the > kernel's own built in defaults. do this. build code for the hardware you have, not for hardware you don't have > > I know a lot of it sets up most things as modules instead of > builtin/disabled. genkernel builds a kernel like for a binary distro or a LiveCD - works everywhere (by enabling everything). You can customized it with a config somehwow (I forget the details). But this is gentoo: cd /usr/src/<kernel-ver> make menuconfig -- Alan McKinnon alan.mckinnon@gmail.com ^ permalink raw reply [flat|nested] 29+ messages in thread
* [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-14 12:49 ` Alan McKinnon @ 2016-08-14 18:48 ` Ian Zimmerman 2016-08-14 18:55 ` Neil Bothwick 2016-08-15 12:27 ` Todd Goodman 0 siblings, 2 replies; 29+ messages in thread From: Ian Zimmerman @ 2016-08-14 18:48 UTC (permalink / raw To: gentoo-user On 2016-08-14 14:49 +0200, Alan McKinnon wrote: > genkernel builds a kernel like for a binary distro or a LiveCD - works > everywhere (by enabling everything). You can customized it with a config > somehwow (I forget the details). But this is gentoo: > > cd /usr/src/<kernel-ver> > make menuconfig Don't you still need genkernel if you want to build an initramfs? The handbook (amd64) seems to imply you do, and I don't know of an easy way to build an initramfs just with the bare kernel source. -- Please *no* private Cc: on mailing lists and newsgroups Why does the arrow on Hillary signs point to the right? ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-14 18:48 ` [gentoo-user] " Ian Zimmerman @ 2016-08-14 18:55 ` Neil Bothwick 2016-08-14 20:29 ` J. Roeleveld 2016-08-15 12:27 ` Todd Goodman 1 sibling, 1 reply; 29+ messages in thread From: Neil Bothwick @ 2016-08-14 18:55 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 395 bytes --] On Sun, 14 Aug 2016 11:48:08 -0700, Ian Zimmerman wrote: > Don't you still need genkernel if you want to build an initramfs? No, dracut. > The handbook (amd64) seems to imply you do, and I don't know of an easy > way to build an initramfs just with the bare kernel source. Dracut. -- Neil Bothwick Remember that the Titanic was built by experts, and the Ark by a newbie [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 181 bytes --] ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-14 18:55 ` Neil Bothwick @ 2016-08-14 20:29 ` J. Roeleveld 2016-08-15 0:38 ` Mike Gilbert 0 siblings, 1 reply; 29+ messages in thread From: J. Roeleveld @ 2016-08-14 20:29 UTC (permalink / raw To: gentoo-user On August 14, 2016 8:55:32 PM GMT+02:00, Neil Bothwick <neil@digimed.co.uk> wrote: >On Sun, 14 Aug 2016 11:48:08 -0700, Ian Zimmerman wrote: > >> Don't you still need genkernel if you want to build an initramfs? > >No, dracut. > >> The handbook (amd64) seems to imply you do, and I don't know of an >easy >> way to build an initramfs just with the bare kernel source. > >Dracut. Dracut if you just want something quick and easy. If you want something small and reliable, build your own. -- Joost -- Sent from my Android device with K-9 Mail. Please excuse my brevity. ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-14 20:29 ` J. Roeleveld @ 2016-08-15 0:38 ` Mike Gilbert 2016-08-15 0:45 ` Rich Freeman 2016-08-15 8:10 ` J. Roeleveld 0 siblings, 2 replies; 29+ messages in thread From: Mike Gilbert @ 2016-08-15 0:38 UTC (permalink / raw To: gentoo-user On Sun, Aug 14, 2016 at 4:29 PM, J. Roeleveld <joost@antarean.org> wrote: > On August 14, 2016 8:55:32 PM GMT+02:00, Neil Bothwick <neil@digimed.co.uk> wrote: >>On Sun, 14 Aug 2016 11:48:08 -0700, Ian Zimmerman wrote: >> >>> Don't you still need genkernel if you want to build an initramfs? >> >>No, dracut. >> >>> The handbook (amd64) seems to imply you do, and I don't know of an >>easy >>> way to build an initramfs just with the bare kernel source. >> >>Dracut. > > Dracut if you just want something quick and easy. > If you want something small and reliable, build your own. A homegrown initramfs created by a novice is going to be more reliable than one created by dracut or genkernel? Seems unlikely. ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 0:38 ` Mike Gilbert @ 2016-08-15 0:45 ` Rich Freeman 2016-08-15 7:48 ` Jeroen Mathon 2016-08-15 8:10 ` J. Roeleveld 1 sibling, 1 reply; 29+ messages in thread From: Rich Freeman @ 2016-08-15 0:45 UTC (permalink / raw To: gentoo-user On Sun, Aug 14, 2016 at 7:38 PM, Mike Gilbert <floppym@gentoo.org> wrote: > On Sun, Aug 14, 2016 at 4:29 PM, J. Roeleveld <joost@antarean.org> wrote: >> On August 14, 2016 8:55:32 PM GMT+02:00, Neil Bothwick <neil@digimed.co.uk> wrote: >>>On Sun, 14 Aug 2016 11:48:08 -0700, Ian Zimmerman wrote: >>> >>>> Don't you still need genkernel if you want to build an initramfs? >>> >>>No, dracut. >>> >>>> The handbook (amd64) seems to imply you do, and I don't know of an >>>easy >>>> way to build an initramfs just with the bare kernel source. >>> >>>Dracut. >> >> Dracut if you just want something quick and easy. >> If you want something small and reliable, build your own. > > A homegrown initramfs created by a novice is going to be more reliable > than one created by dracut or genkernel? Seems unlikely. > This is a silly argument. Everybody knows that anybody who wants something reliable just writes their own kernel in the first place. -- Rich ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 0:45 ` Rich Freeman @ 2016-08-15 7:48 ` Jeroen Mathon 2016-08-15 8:12 ` J. Roeleveld 0 siblings, 1 reply; 29+ messages in thread From: Jeroen Mathon @ 2016-08-15 7:48 UTC (permalink / raw To: gentoo-user I have used genkernel for my initramfs. The dracut one seems to hang on a kernel panic(Implying that it did not load the correct modules for luks and lvm). Besides the size of your initramfs should not matter since its only used to mount the partitions and do the pre-kernel loading. The only thing that you will win by making your own initramfs would be size and boot speed. Correct me if im wrong btw. On 15-08-16 02:45, Rich Freeman wrote: > On Sun, Aug 14, 2016 at 7:38 PM, Mike Gilbert <floppym@gentoo.org> wrote: >> On Sun, Aug 14, 2016 at 4:29 PM, J. Roeleveld <joost@antarean.org> wrote: >>> On August 14, 2016 8:55:32 PM GMT+02:00, Neil Bothwick <neil@digimed.co.uk> wrote: >>>> On Sun, 14 Aug 2016 11:48:08 -0700, Ian Zimmerman wrote: >>>> >>>>> Don't you still need genkernel if you want to build an initramfs? >>>> No, dracut. >>>> >>>>> The handbook (amd64) seems to imply you do, and I don't know of an >>>> easy >>>>> way to build an initramfs just with the bare kernel source. >>>> Dracut. >>> Dracut if you just want something quick and easy. >>> If you want something small and reliable, build your own. >> A homegrown initramfs created by a novice is going to be more reliable >> than one created by dracut or genkernel? Seems unlikely. >> > This is a silly argument. Everybody knows that anybody who wants > something reliable just writes their own kernel in the first place. > ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 7:48 ` Jeroen Mathon @ 2016-08-15 8:12 ` J. Roeleveld 0 siblings, 0 replies; 29+ messages in thread From: J. Roeleveld @ 2016-08-15 8:12 UTC (permalink / raw To: gentoo-user On Monday, August 15, 2016 09:48:14 AM Jeroen Mathon wrote: > I have used genkernel for my initramfs. > > The dracut one seems to hang on a kernel panic(Implying that it did not > load the correct modules for luks and lvm). In my experience, normal for both... > Besides the size of your initramfs should not matter since its only used > to mount the partitions and do the pre-kernel loading. Agreed, except for the next part: > The only thing that you will win by making your own initramfs would be > size and boot speed. If done sanely, the reduced complexity makes debugging and maintenance a lot easier. > Correct me if im wrong btw. > > On 15-08-16 02:45, Rich Freeman wrote: > > On Sun, Aug 14, 2016 at 7:38 PM, Mike Gilbert <floppym@gentoo.org> wrote: > >> On Sun, Aug 14, 2016 at 4:29 PM, J. Roeleveld <joost@antarean.org> wrote: > >>> On August 14, 2016 8:55:32 PM GMT+02:00, Neil Bothwick <neil@digimed.co.uk> wrote: > >>>> On Sun, 14 Aug 2016 11:48:08 -0700, Ian Zimmerman wrote: > >>>>> Don't you still need genkernel if you want to build an initramfs? > >>>> > >>>> No, dracut. > >>>> > >>>>> The handbook (amd64) seems to imply you do, and I don't know of an > >>>> > >>>> easy > >>>> > >>>>> way to build an initramfs just with the bare kernel source. > >>>> > >>>> Dracut. > >>> > >>> Dracut if you just want something quick and easy. > >>> If you want something small and reliable, build your own. > >> > >> A homegrown initramfs created by a novice is going to be more reliable > >> than one created by dracut or genkernel? Seems unlikely. > > > > This is a silly argument. Everybody knows that anybody who wants > > something reliable just writes their own kernel in the first place. ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 0:38 ` Mike Gilbert 2016-08-15 0:45 ` Rich Freeman @ 2016-08-15 8:10 ` J. Roeleveld 2016-08-15 8:32 ` Rich Freeman 2016-08-15 8:40 ` Neil Bothwick 1 sibling, 2 replies; 29+ messages in thread From: J. Roeleveld @ 2016-08-15 8:10 UTC (permalink / raw To: gentoo-user On Sunday, August 14, 2016 08:38:42 PM Mike Gilbert wrote: > On Sun, Aug 14, 2016 at 4:29 PM, J. Roeleveld <joost@antarean.org> wrote: > > On August 14, 2016 8:55:32 PM GMT+02:00, Neil Bothwick <neil@digimed.co.uk> wrote: > >>On Sun, 14 Aug 2016 11:48:08 -0700, Ian Zimmerman wrote: > >>> Don't you still need genkernel if you want to build an initramfs? > >> > >>No, dracut. > >> > >>> The handbook (amd64) seems to imply you do, and I don't know of an > >> > >>easy > >> > >>> way to build an initramfs just with the bare kernel source. > >> > >>Dracut. > >> > > Dracut if you just want something quick and easy. > > If you want something small and reliable, build your own. > > A homegrown initramfs created by a novice is going to be more reliable > than one created by dracut or genkernel? Seems unlikely. The ones created by genkernel or dracut always need a few iterations before they work semi-reliably and are not flexible enough. I have 2 disks in my laptop. Both are encrypted using LUKS and the same passphrase. Neither genkernel nor dracut have the intelligence to ask me once and try the key on both, only asking for a 2nd key when the provided one doesn't work for both. I ended up writing my own, which has proven more reliable and stable. The reduced size also makes maintenance less of an issue. -- Joost ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 8:10 ` J. Roeleveld @ 2016-08-15 8:32 ` Rich Freeman 2016-08-15 9:06 ` J. Roeleveld 2016-08-18 22:41 ` Raymond Jennings 2016-08-15 8:40 ` Neil Bothwick 1 sibling, 2 replies; 29+ messages in thread From: Rich Freeman @ 2016-08-15 8:32 UTC (permalink / raw To: gentoo-user On Mon, Aug 15, 2016 at 4:10 AM, J. Roeleveld <joost@antarean.org> wrote: > > The ones created by genkernel or dracut always need a few iterations before > they work semi-reliably and are not flexible enough. > I have 2 disks in my laptop. Both are encrypted using LUKS and the same > passphrase. Neither genkernel nor dracut have the intelligence to ask me once > and try the key on both, only asking for a 2nd key when the provided one > doesn't work for both. > > I ended up writing my own, which has proven more reliable and stable. The > reduced size also makes maintenance less of an issue. > Nothing wrong with this if you know what you're doing. Dracut is designed to be one-size-fits-all with a lot of logic to figure out what your system needs to boot. It is also somewhat dependent on a correct fstab. Don't take that for granted: the kernel doesn't look at fstab at all when mounting root, and neither do most of the other tools, so if your root partition isn't correctly defined in fstab you might never know it and dracut will get confused. If nothing else once it does have it correctly mounted it will read fstab and then mess it up when it re-mounts root per "your" instructions. If you just need to tweak dracut behavior you may be better off with a dracut module. They're just shell scripts and pretty simple to write. That lets you tweak something at some point during boot without having to build the entire thing yourself. And since it uses udev it is fairly robust against things like adding a drive and now the kernel re-letters everything. If you tweak it to use the same password for all drives I wouldn't be surprised if upstream accepts the patch... -- Rich ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 8:32 ` Rich Freeman @ 2016-08-15 9:06 ` J. Roeleveld 2016-08-15 12:41 ` Rich Freeman 2016-08-18 22:41 ` Raymond Jennings 1 sibling, 1 reply; 29+ messages in thread From: J. Roeleveld @ 2016-08-15 9:06 UTC (permalink / raw To: gentoo-user On Monday, August 15, 2016 04:32:29 AM Rich Freeman wrote: > On Mon, Aug 15, 2016 at 4:10 AM, J. Roeleveld <joost@antarean.org> wrote: > > The ones created by genkernel or dracut always need a few iterations > > before > > they work semi-reliably and are not flexible enough. > > I have 2 disks in my laptop. Both are encrypted using LUKS and the same > > passphrase. Neither genkernel nor dracut have the intelligence to ask me > > once and try the key on both, only asking for a 2nd key when the provided > > one doesn't work for both. > > > > I ended up writing my own, which has proven more reliable and stable. The > > reduced size also makes maintenance less of an issue. > > Nothing wrong with this if you know what you're doing. Dracut is > designed to be one-size-fits-all with a lot of logic to figure out > what your system needs to boot. > > It is also somewhat dependent on a correct fstab. Don't take that for > granted: the kernel doesn't look at fstab at all when mounting root, > and neither do most of the other tools, so if your root partition > isn't correctly defined in fstab you might never know it and dracut > will get confused. If nothing else once it does have it correctly > mounted it will read fstab and then mess it up when it re-mounts root > per "your" instructions. I understand what you're saying. Except in my case, that wasn't the cause. > If you just need to tweak dracut behavior you may be better off with a > dracut module. They're just shell scripts and pretty simple to write. > That lets you tweak something at some point during boot without having > to build the entire thing yourself. This actually had (or has, not bothered to check current status) a distinct lack of usable documentation. Looking for clear howto's on creating my own (embedded into the kernel) initramfs was a lot quicker. > And since it uses udev it is fairly robust against things like adding > a drive and now the kernel re-letters everything. If I were using normal partitioning, I wouldn't need an initramfs. > If you tweak it to use the same password for all drives I wouldn't be > surprised if upstream accepts the patch... If it were properly documented where it does this, I would be willing to try. Right now, my init-script is 45 lines (including white-space) My laptop has 2 disks. Both are fully encrypted (apart from a small /boot). On top of the encrypted parts I have LVM, which contains my partitions. It asks for a password, decrypts both drives, enables LVM, checks if it needs to resume from "suspend to disk", if not, mounts the partitions and boots. If it does need to resume, it simply resumes. If it fails anywhere, it drops me into a busybox shell. I can then simply "cat" the init script to see what commands I need to run to boot, replacing anything that is no longer valid. With dracut and genkernel, the init-script is too convoluted to simply follow. Which means it is not allowed to fail. -- Joost ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 9:06 ` J. Roeleveld @ 2016-08-15 12:41 ` Rich Freeman 2016-08-16 5:39 ` J. Roeleveld 0 siblings, 1 reply; 29+ messages in thread From: Rich Freeman @ 2016-08-15 12:41 UTC (permalink / raw To: gentoo-user On Mon, Aug 15, 2016 at 5:06 AM, J. Roeleveld <joost@antarean.org> wrote: > On Monday, August 15, 2016 04:32:29 AM Rich Freeman wrote: >> >> It is also somewhat dependent on a correct fstab. Don't take that for >> granted: the kernel doesn't look at fstab at all when mounting root, >> and neither do most of the other tools, so if your root partition >> isn't correctly defined in fstab you might never know it and dracut >> will get confused. If nothing else once it does have it correctly >> mounted it will read fstab and then mess it up when it re-mounts root >> per "your" instructions. > > I understand what you're saying. Except in my case, that wasn't the cause. > Oh, I agree. I just said that in lieu of replying to every single other email in this thread. :) >> If you just need to tweak dracut behavior you may be better off with a >> dracut module. They're just shell scripts and pretty simple to write. >> That lets you tweak something at some point during boot without having >> to build the entire thing yourself. > > This actually had (or has, not bothered to check current status) a distinct > lack of usable documentation. Looking for clear howto's on creating my own > (embedded into the kernel) initramfs was a lot quicker. Yeah, I found this frustrating as well. This may or may not be helpful: https://rich0gentoo.wordpress.com/2012/01/21/a-quick-dracut-module/ In general the benefits of using dracut are the benefits of using anything that somebody else maintains. You could replace openrc with a single shell script as well, or a fair bit of systemd. That doesn't mean that this is really the optimal approach. >> And since it uses udev it is fairly robust against things like adding >> a drive and now the kernel re-letters everything. > If I were using normal partitioning, I wouldn't need an initramfs. An initramfs is beneficial even if you don't "need" one. To start with it allows you to build a more modular kernel, which is especially beneficial if you aren't customizing your kernel for every host. It also tends to be more robust when something goes wrong. You end up having a rescue shell even if root doesn't mount, more robust fsck/etc during early boot, and it is going to be a lot smarter when you add/remove a drive (since root can be identified by UUID or label). Dracut is becoming common enough that I think it is worth learning... -- Rich ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 12:41 ` Rich Freeman @ 2016-08-16 5:39 ` J. Roeleveld 0 siblings, 0 replies; 29+ messages in thread From: J. Roeleveld @ 2016-08-16 5:39 UTC (permalink / raw To: gentoo-user On Monday, August 15, 2016 08:41:31 AM Rich Freeman wrote: > On Mon, Aug 15, 2016 at 5:06 AM, J. Roeleveld <joost@antarean.org> wrote: > > On Monday, August 15, 2016 04:32:29 AM Rich Freeman wrote: > >> It is also somewhat dependent on a correct fstab. Don't take that for > >> granted: the kernel doesn't look at fstab at all when mounting root, > >> and neither do most of the other tools, so if your root partition > >> isn't correctly defined in fstab you might never know it and dracut > >> will get confused. If nothing else once it does have it correctly > >> mounted it will read fstab and then mess it up when it re-mounts root > >> per "your" instructions. > > > > I understand what you're saying. Except in my case, that wasn't the cause. > > Oh, I agree. I just said that in lieu of replying to every single > other email in this thread. :) > > >> If you just need to tweak dracut behavior you may be better off with a > >> dracut module. They're just shell scripts and pretty simple to write. > >> That lets you tweak something at some point during boot without having > >> to build the entire thing yourself. > > > > This actually had (or has, not bothered to check current status) a > > distinct > > lack of usable documentation. Looking for clear howto's on creating my own > > (embedded into the kernel) initramfs was a lot quicker. > > Yeah, I found this frustrating as well. > > This may or may not be helpful: > https://rich0gentoo.wordpress.com/2012/01/21/a-quick-dracut-module/ It shows where to find it and add custom steps. For my scenario, I'd need to first find where the code is that currently handles it. Disable that and insert my own in its place. The majority works, except for it asking for my passphrase multiple times, which, in Dracut, might actually be handled by "cryptsetup" itself. In which case I'm stuck. In my script it's handled via: ---- # Obtain key through loop device /sbin/losetup /dev/loop0 /key.iso || rescue_shell /sbin/cryptsetup -T 5 luksOpen /dev/loop0 key || rescue_shell # Unlock the root partition /sbin/cryptsetup --key-file /dev/mapper/key luksOpen --allow-discards /dev/sda2 sda2 || rescue_shell /sbin/cryptsetup --key-file /dev/mapper/key luksOpen --allow-discards /dev/sdb2 sdb2 || rescue_shell # Clean up the loop device /sbin/cryptsetup luksClose key /sbin/losetup -d /dev/loop0 ---- > In general the benefits of using dracut are the benefits of using > anything that somebody else maintains. You could replace openrc with > a single shell script as well, or a fair bit of systemd. That doesn't > mean that this is really the optimal approach. If I'd need the level of complexity Dracut allows, I'd look into it. But all I need to do is maintain a few small and simple files and the kernel-build handles all the heavy lifting. > >> And since it uses udev it is fairly robust against things like adding > >> a drive and now the kernel re-letters everything. > > > > If I were using normal partitioning, I wouldn't need an initramfs. > > An initramfs is beneficial even if you don't "need" one. To start > with it allows you to build a more modular kernel, which is especially > beneficial if you aren't customizing your kernel for every host. It > also tends to be more robust when something goes wrong. You end up > having a rescue shell even if root doesn't mount, more robust fsck/etc > during early boot, and it is going to be a lot smarter when you > add/remove a drive (since root can be identified by UUID or label). > > Dracut is becoming common enough that I think it is worth learning... For binary distributions, I tend to stick with the supplied kernel and initramfs. Those are usually for running software from big vendors like Oracle or IBM. For the rest, it's quicker to make the few changes needed to the init-script. I don't have a large serverfarm requiring that level of standardisation. -- Joost ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 8:32 ` Rich Freeman 2016-08-15 9:06 ` J. Roeleveld @ 2016-08-18 22:41 ` Raymond Jennings 2016-08-18 22:50 ` Rich Freeman 1 sibling, 1 reply; 29+ messages in thread From: Raymond Jennings @ 2016-08-18 22:41 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 300 bytes --] On Mon, Aug 15, 2016 at 1:32 AM, Rich Freeman <rich0@gentoo.org> wrote: > And since it uses udev it is fairly robust against things like adding > a drive and now the kernel re-letters everything. > Did you seriously just post that on a gentoo list? I assume you mean /dev/sd? and not A: B: C: :P [-- Attachment #2: Type: text/html, Size: 659 bytes --] ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-18 22:41 ` Raymond Jennings @ 2016-08-18 22:50 ` Rich Freeman 2016-08-21 17:04 ` Raymond Jennings 0 siblings, 1 reply; 29+ messages in thread From: Rich Freeman @ 2016-08-18 22:50 UTC (permalink / raw To: gentoo-user On Thu, Aug 18, 2016 at 6:41 PM, Raymond Jennings <shentino@gmail.com> wrote: > On Mon, Aug 15, 2016 at 1:32 AM, Rich Freeman <rich0@gentoo.org> wrote: >> >> And since it uses udev it is fairly robust against things like adding >> a drive and now the kernel re-letters everything. > > Did you seriously just post that on a gentoo list? > Yes > I assume you mean /dev/sd? and not A: B: C: > Yes. What else would you call it? -- Rich ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-18 22:50 ` Rich Freeman @ 2016-08-21 17:04 ` Raymond Jennings 0 siblings, 0 replies; 29+ messages in thread From: Raymond Jennings @ 2016-08-21 17:04 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 568 bytes --] On Thu, Aug 18, 2016 at 3:50 PM, Rich Freeman <rich0@gentoo.org> wrote: > On Thu, Aug 18, 2016 at 6:41 PM, Raymond Jennings <shentino@gmail.com> > wrote: > > On Mon, Aug 15, 2016 at 1:32 AM, Rich Freeman <rich0@gentoo.org> wrote: > >> > >> And since it uses udev it is fairly robust against things like adding > >> a drive and now the kernel re-letters everything. > > > > Did you seriously just post that on a gentoo list? > > > > Yes > > > I assume you mean /dev/sd? and not A: B: C: > > > > Yes. What else would you call it? > A bad attempt at humor on my part. [-- Attachment #2: Type: text/html, Size: 1204 bytes --] ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 8:10 ` J. Roeleveld 2016-08-15 8:32 ` Rich Freeman @ 2016-08-15 8:40 ` Neil Bothwick 1 sibling, 0 replies; 29+ messages in thread From: Neil Bothwick @ 2016-08-15 8:40 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 809 bytes --] On Mon, 15 Aug 2016 10:10:22 +0200, J. Roeleveld wrote: > > A homegrown initramfs created by a novice is going to be more reliable > > than one created by dracut or genkernel? Seems unlikely. > > The ones created by genkernel or dracut always need a few iterations > before they work semi-reliably and are not flexible enough. Yes, I usually have to rerun dracut a few times after tweaking its options, because I don't use the full-fat defaults. However, when I rolled my own initramfs, there were several more iterations after making changes. In my experience, once you have a sensible config, dracut just works - your comments about multiple LUKS partitions notwithstanding. -- Neil Bothwick Biology is the only science in which multiplication means the same thing as division. [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 181 bytes --] ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-14 18:48 ` [gentoo-user] " Ian Zimmerman 2016-08-14 18:55 ` Neil Bothwick @ 2016-08-15 12:27 ` Todd Goodman 1 sibling, 0 replies; 29+ messages in thread From: Todd Goodman @ 2016-08-15 12:27 UTC (permalink / raw To: gentoo-user * Ian Zimmerman <itz@buug.org> [160814 14:49]: > On 2016-08-14 14:49 +0200, Alan McKinnon wrote: > > > genkernel builds a kernel like for a binary distro or a LiveCD - works > > everywhere (by enabling everything). You can customized it with a config > > somehwow (I forget the details). But this is gentoo: > > > > cd /usr/src/<kernel-ver> > > make menuconfig > > Don't you still need genkernel if you want to build an initramfs? > > The handbook (amd64) seems to imply you do, and I don't know of an easy > way to build an initramfs just with the bare kernel source. No, you don't have to use genkernel to build an initramfs (though using genkernel will get you an initramfs.) You can use dracut or any other initramfs builder after building the kernel from "bare source." I do that on three servers but generally just use genkernel on my laptops and desktop machines. Todd ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Question about genkernel's default kernel config 2016-08-14 11:45 [gentoo-user] Question about genkernel's default kernel config Raymond Jennings 2016-08-14 12:49 ` Alan McKinnon @ 2016-08-15 7:27 ` Azamat Hackimov 2016-08-15 8:43 ` Neil Bothwick 2016-08-15 11:57 ` james 1 sibling, 2 replies; 29+ messages in thread From: Azamat Hackimov @ 2016-08-15 7:27 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 948 bytes --] 2016-08-14 16:45 GMT+05:00 Raymond Jennings <shentino@gmail.com>: > Hey, just curious about something: > > How is genkernel's "default" kernel config maintained? Is it fixed, or is > it maintained as a diff against upstream, or what? > > I'm curious because I'm considering if I should just go straight to the > kernel's own built in defaults. > > I know a lot of it sets up most things as modules instead of > builtin/disabled. > Default config is maintained by genkernel developers ( https://gitweb.gentoo.org/proj/genkernel.git/tree/defaults). Definitely you should build own kernel configuration, and genkernel can significantly ease this task. genkernel supports --menuconfig and --oldconfig (which placed into /etc/kernels by default) options, so you can customize and rebuild new versions of kernel based on customized config. I suggest to read https://wiki.gentoo.org/wiki/Genkernel for final enlightenment. -- From Siberia with Love! [-- Attachment #2: Type: text/html, Size: 1624 bytes --] ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Question about genkernel's default kernel config 2016-08-15 7:27 ` [gentoo-user] " Azamat Hackimov @ 2016-08-15 8:43 ` Neil Bothwick 2016-08-15 10:04 ` Azamat Hackimov 2016-08-15 11:57 ` james 1 sibling, 1 reply; 29+ messages in thread From: Neil Bothwick @ 2016-08-15 8:43 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 517 bytes --] On Mon, 15 Aug 2016 12:27:43 +0500, Azamat Hackimov wrote: > Definitely you should build own kernel configuration, and genkernel can > significantly ease this task. > genkernel supports --menuconfig and --oldconfig (which placed into > /etc/kernels by default) options, so you can customize and rebuild new > versions of kernel based on customized config. How is that "significantly easier" than typing make oldconfig? -- Neil Bothwick Drive not ready: (R)etry (G)o to Impulse (C)all Engineering [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 181 bytes --] ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Question about genkernel's default kernel config 2016-08-15 8:43 ` Neil Bothwick @ 2016-08-15 10:04 ` Azamat Hackimov 2016-08-15 14:54 ` [gentoo-user] " Ian Zimmerman 2016-08-25 9:33 ` [gentoo-user] " thegeezer 0 siblings, 2 replies; 29+ messages in thread From: Azamat Hackimov @ 2016-08-15 10:04 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 881 bytes --] 2016-08-15 13:43 GMT+05:00 Neil Bothwick <neil@digimed.co.uk>: > On Mon, 15 Aug 2016 12:27:43 +0500, Azamat Hackimov wrote: > > > Definitely you should build own kernel configuration, and genkernel can > > significantly ease this task. > > genkernel supports --menuconfig and --oldconfig (which placed into > > /etc/kernels by default) options, so you can customize and rebuild new > > versions of kernel based on customized config. > > How is that "significantly easier" than typing make oldconfig? > > > -- > Neil Bothwick > > Drive not ready: (R)etry (G)o to Impulse (C)all Engineering > Well, at least for me it's much easier just type genkernel --oldconfig=/etc/kernels/<someconfig> than cp <path-to-oldconfig> config make oldconfig make make modules make install <some quirk command to make initramfs> grub2-mkconfig -o /boot/grub/grub.cfg -- From Siberia with Love! [-- Attachment #2: Type: text/html, Size: 1846 bytes --] ^ permalink raw reply [flat|nested] 29+ messages in thread
* [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 10:04 ` Azamat Hackimov @ 2016-08-15 14:54 ` Ian Zimmerman 2016-08-15 18:42 ` Rich Freeman 2016-08-25 9:33 ` [gentoo-user] " thegeezer 1 sibling, 1 reply; 29+ messages in thread From: Ian Zimmerman @ 2016-08-15 14:54 UTC (permalink / raw To: gentoo-user On 2016-08-15 15:04 +0500, Azamat Hackimov wrote: > Well, at least for me it's much easier just type > > genkernel --oldconfig=/etc/kernels/<someconfig> > > than > > cp <path-to-oldconfig> config > make oldconfig > make > make modules > make install > <some quirk command to make initramfs> > grub2-mkconfig -o /boot/grub/grub.cfg One reason why I might prefer the second alternative is that I don't have to be root except for the install and grub steps. I actually wrote my own shell based tool to simplify these tasks, with a "subcommand" structure, ie. "genbuild config", "sudo genbuild installkernel" etc. It does call on genkernel to build the initramfs because I didn't know about dracut at the time. Now I'm considering redoing it. So, can anyone explain why dracut is better than genkernel for _that_ particular subtask? -- Please *no* private Cc: on mailing lists and newsgroups Why does the arrow on Hillary signs point to the right? ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 14:54 ` [gentoo-user] " Ian Zimmerman @ 2016-08-15 18:42 ` Rich Freeman 2016-08-15 19:50 ` Ian Zimmerman 2016-08-15 21:57 ` Neil Bothwick 0 siblings, 2 replies; 29+ messages in thread From: Rich Freeman @ 2016-08-15 18:42 UTC (permalink / raw To: gentoo-user On Mon, Aug 15, 2016 at 10:54 AM, Ian Zimmerman <itz@buug.org> wrote: > > So, can anyone explain why dracut is better than genkernel for _that_ > particular subtask? > Focusing purely on dracut vs genkernel: The main advantage of dracut is that it is a cross-distro tool that gets a lot more attention in general (being used by multiple distros I believe). I know it does things like copy your mdadm.conf and fstab to the initramfs and tries to use existing configurations like these. It probably supports a larger number of targets as well (like various network-based roots). It is also more modular. While it was rightly said that the documentation is more reference-level than howto-level it is straightforward to drop in your own modules if you need them. If you include all the modules in most cases it can figure out what to do on its own. However, ultimately both tools just boot the system and then go away, so if your system is booting, it isn't like it will boot "better" with one tool than the other. There are a few nice-to-haves with dracut (and perhaps also with genkernel), but I don't think they're going to sway somebody. Something I like about dracut is that when I'm shutting down systemd actually pivots back to the initramfs and it unmounts root, which I think is more elegant than mounting ro, but in practice the latter works. For me the main driver is using something fairly standard vs something Gentoo-specific. -- Rich ^ permalink raw reply [flat|nested] 29+ messages in thread
* [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 18:42 ` Rich Freeman @ 2016-08-15 19:50 ` Ian Zimmerman 2016-08-15 21:57 ` Neil Bothwick 1 sibling, 0 replies; 29+ messages in thread From: Ian Zimmerman @ 2016-08-15 19:50 UTC (permalink / raw To: gentoo-user On 2016-08-15 14:42 -0400, Rich Freeman wrote: > For me the main driver is using something fairly standard vs something > Gentoo-specific. I sort of expected that answer. But, I don't think it's enough for me to switch right now. It's good to know there's an alternative, though. -- Please *no* private Cc: on mailing lists and newsgroups Why does the arrow on Hillary signs point to the right? ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Re: Question about genkernel's default kernel config 2016-08-15 18:42 ` Rich Freeman 2016-08-15 19:50 ` Ian Zimmerman @ 2016-08-15 21:57 ` Neil Bothwick 1 sibling, 0 replies; 29+ messages in thread From: Neil Bothwick @ 2016-08-15 21:57 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 596 bytes --] On Mon, 15 Aug 2016 14:42:17 -0400, Rich Freeman wrote: > Something I like about dracut is that when I'm > shutting down systemd actually pivots back to the initramfs and it > unmounts root, which I think is more elegant than mounting ro, but in > practice the latter works. Another nice thing about dracut, if your using systemd, is that it starts logging while the initramfs is loaded, flushing the data to disk once /var is mounted rw, so you get information from far earlier in the boot in the journal. -- Neil Bothwick Know thyself. If you need help, call the C.I.A. [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 181 bytes --] ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Question about genkernel's default kernel config 2016-08-15 10:04 ` Azamat Hackimov 2016-08-15 14:54 ` [gentoo-user] " Ian Zimmerman @ 2016-08-25 9:33 ` thegeezer 1 sibling, 0 replies; 29+ messages in thread From: thegeezer @ 2016-08-25 9:33 UTC (permalink / raw To: gentoo-user On 2016-08-15 11:04, Azamat Hackimov wrote: > Well, at least for me it's much easier just type > > genkernel --oldconfig=/etc/kernels/<someconfig> been a bit silent on this list for the last year or so with personal life, come back and immediately find a nugget of info i had been doing make oldconfig and /then/ genkernel initramfs thanks for the shortcut! ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Question about genkernel's default kernel config 2016-08-15 7:27 ` [gentoo-user] " Azamat Hackimov 2016-08-15 8:43 ` Neil Bothwick @ 2016-08-15 11:57 ` james 2016-08-15 21:53 ` Neil Bothwick 1 sibling, 1 reply; 29+ messages in thread From: james @ 2016-08-15 11:57 UTC (permalink / raw To: gentoo-user On 08/15/2016 03:27 AM, Azamat Hackimov wrote: > I suggest to read https://wiki.gentoo.org/wiki/Genkernel for final > enlightenment. > From Siberia with Love! As well as:: https://wiki.gentoo.org/wiki/Initramfs/Guide hth, James ^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [gentoo-user] Question about genkernel's default kernel config 2016-08-15 11:57 ` james @ 2016-08-15 21:53 ` Neil Bothwick 0 siblings, 0 replies; 29+ messages in thread From: Neil Bothwick @ 2016-08-15 21:53 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 421 bytes --] On Mon, 15 Aug 2016 07:57:02 -0400, james wrote: > > I suggest to read https://wiki.gentoo.org/wiki/Genkernel for final > > enlightenment. > > As well as:: > > > https://wiki.gentoo.org/wiki/Initramfs/Guide If you want to look at rolling your own, see /usr/src/linux/Documentation/filesystems/ramfs-rootfs-initramfs.txt -- Neil Bothwick WindowError:01B Illegal error. Do NOT get this error. [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 181 bytes --] ^ permalink raw reply [flat|nested] 29+ messages in thread
end of thread, other threads:[~2016-08-25 9:34 UTC | newest] Thread overview: 29+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2016-08-14 11:45 [gentoo-user] Question about genkernel's default kernel config Raymond Jennings 2016-08-14 12:49 ` Alan McKinnon 2016-08-14 18:48 ` [gentoo-user] " Ian Zimmerman 2016-08-14 18:55 ` Neil Bothwick 2016-08-14 20:29 ` J. Roeleveld 2016-08-15 0:38 ` Mike Gilbert 2016-08-15 0:45 ` Rich Freeman 2016-08-15 7:48 ` Jeroen Mathon 2016-08-15 8:12 ` J. Roeleveld 2016-08-15 8:10 ` J. Roeleveld 2016-08-15 8:32 ` Rich Freeman 2016-08-15 9:06 ` J. Roeleveld 2016-08-15 12:41 ` Rich Freeman 2016-08-16 5:39 ` J. Roeleveld 2016-08-18 22:41 ` Raymond Jennings 2016-08-18 22:50 ` Rich Freeman 2016-08-21 17:04 ` Raymond Jennings 2016-08-15 8:40 ` Neil Bothwick 2016-08-15 12:27 ` Todd Goodman 2016-08-15 7:27 ` [gentoo-user] " Azamat Hackimov 2016-08-15 8:43 ` Neil Bothwick 2016-08-15 10:04 ` Azamat Hackimov 2016-08-15 14:54 ` [gentoo-user] " Ian Zimmerman 2016-08-15 18:42 ` Rich Freeman 2016-08-15 19:50 ` Ian Zimmerman 2016-08-15 21:57 ` Neil Bothwick 2016-08-25 9:33 ` [gentoo-user] " thegeezer 2016-08-15 11:57 ` james 2016-08-15 21:53 ` Neil Bothwick
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox