Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Install queries (UEFI, FS, Kernel compile etc)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
Twenty_Four
n00b
n00b


Joined: 10 Apr 2015
Posts: 9

PostPosted: Fri Apr 10, 2015 8:33 pm    Post subject: Install queries (UEFI, FS, Kernel compile etc) Reply with quote

Hi

Next week sometime I’m going to be performing a new install on a new laptop, and I have some questions to how the install process has changed since 2010 when I last done it (mainly between BIOS and UEFI, and one or two other things). note: I’m only installing Gentoo and have zero interest in dual booting or anything, which I understand will make things considerably easier.

Installation on a device with UEFI:

I’ve read Sakaki’s guide on the wiki and numerous other pages, and from what I understand a UEFI device has secure boot enabled for win8 and my options for installing other operating systems are:

- Disable secure boot and enable ‘legacy mode’ or something along those lines (providing the device has the capability) and boot via grub/grub2 as per normal procedure.

- Install Gentoo with UEFI and secure boot enabled, booting via grub/grub2.

- Install Gentoo with UEFI stub support and secure boot enabled, self-booting under UEFI with no external boot loader required (I’ve read this is the easier option, and results in faster booting vs booting with grub/grub2 - any truth in this at all?).

BTRFS:

Anyone have btrfs as their fs of choice on their Gentoo box? any problems with it thus far etc?

I’ve read that you can assign stuff like /var/ etc (that we previously may have created separate partitions for) as sub-volumes instead in btrfs? What’s the general rule of thumb here etc - any limitations with doing such a thing? or should I stick with ext4?

Many thanks in advance and I’ll most likely add some more questions as and when they enter my head.


Last edited by Twenty_Four on Thu Apr 16, 2015 9:10 pm; edited 1 time in total
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43221
Location: 56N 3W

PostPosted: Fri Apr 10, 2015 8:59 pm    Post subject: Reply with quote

Twenty_Four,

Welcome to the Forums .. I guess you have another account?

Secure boot and UEFI are not linked.
Disable secure boot and install using legacy BIOS and the boot loader of your choice, UEFI and a bootloader or UEFI and making the kernel a UEFI compliant program.
When the kernel is a UEFI compliant program, no bootloader is required.

If you want to use your laptop and not just do btrfs develorment, use a mainstream filesystem, like ext4.
You can always have a second throw away install on btrfs. I'm sure others will tell you that btrfs is perfectly usabale.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Twenty_Four
n00b
n00b


Joined: 10 Apr 2015
Posts: 9

PostPosted: Fri Apr 10, 2015 9:14 pm    Post subject: Reply with quote

NeddySeagoon wrote:
Twenty_Four,

Welcome to the Forums .. I guess you have another account?

Secure boot and UEFI are not linked.
Disable secure boot and install using legacy BIOS and the boot loader of your choice, UEFI and a bootloader or UEFI and making the kernel a UEFI compliant program.
When the kernel is a UEFI compliant program, no bootloader is required.

If you want to use your laptop and not just do btrfs develorment, use a mainstream filesystem, like ext4.
You can always have a second throw away install on btrfs. I'm sure others will tell you that btrfs is perfectly usabale.


Thanks for the quick reply - I may have one but I can't for the life of me remember the username, or which email address that I registered under (if I did).

I seem to remember reading somewhere that using legacy BIOS had some effect on the integrated Intel HD graphics stuff, is there any truth in this or is it bs?

What are the pros and cons of each method? I've read that making the kernel UEFI compliant and not using a boot loader makes your life easier, but I don't know if that's just biased opinion?

re: secure boot, I seemed to get the understanding from Sakaki's guide that this is enabled by signing the kernel with our own key - is this part of making the kernel UEFI compliant or separate?

re: btrfs Yeah that's what I was thinking. Though for every few people who said they'd had problems with btrfs, there were the usual "I've used it for X time with no problems" which puts the thought back in your head, lol.

Thanks again, sounds like plenty of trial and error in store for me next week.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43221
Location: 56N 3W

PostPosted: Fri Apr 10, 2015 9:23 pm    Post subject: Reply with quote

Twenty_Four,

To use secure boot with your own key, you have to get the other haly of the key pair into the machine firmware.
That means you need to pay Microsoft a lot of money or find a secure boot boot loader shim. I know one was in the works but I don't know how far it has got.
Someone will need to get Microsoft to sign it ...

I would be surprised if using legacy BIOS had any effect on anything once the kernel was in control.

If you don't use a boot loader, the kernel command line has to be embedded in the kernel, so if you get it wrong, its a kernel rebuild.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Twenty_Four
n00b
n00b


Joined: 10 Apr 2015
Posts: 9

PostPosted: Fri Apr 10, 2015 10:04 pm    Post subject: Reply with quote

NeddySeagoon wrote:
Twenty_Four,

To use secure boot with your own key, you have to get the other haly of the key pair into the machine firmware.
That means you need to pay Microsoft a lot of money or find a secure boot boot loader shim. I know one was in the works but I don't know how far it has got.
Someone will need to get Microsoft to sign it ...

I would be surprised if using legacy BIOS had any effect on anything once the kernel was in control.

If you don't use a boot loader, the kernel command line has to be embedded in the kernel, so if you get it wrong, its a kernel rebuild.


From reading Sakaki's guide here https://wiki.gentoo.org/wiki/Sakaki%27s_EFI_Install_Guide/Configuring_Secure_Boot we're able to use our own keys for the signed kernel stub? the laptop I've bought has win8 installed by default so will have it's own keys anyhow.

That's what I thought. I've never used anything with UEFI though so just figured I'd clear it up before hand.

thanks again!
Back to top
View user's profile Send private message
Twenty_Four
n00b
n00b


Joined: 10 Apr 2015
Posts: 9

PostPosted: Fri Apr 10, 2015 10:31 pm    Post subject: Reply with quote

another thing I forgot to include in the main post: what's the general consensus on 'systemd'? is that the accepted initialisation method nowadays? has it completely replaced the previously used method?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43221
Location: 56N 3W

PostPosted: Sat Apr 11, 2015 8:04 am    Post subject: Reply with quote

Twenty_Four,

Thats like asking about vi and emacs :)

I will let my package.mask speak for itself
/etc/portage/package.mask:
# an over my dead body hard mask
# dump GNOME and anything else that has this as a hard dependency at any version
sys-apps/systemd


As to the why, systemd is badly conceived, badly implemented and brings all the bad things about Windows to Linux.
If it ever becomes the standard on Linux, it might be the best thing that happened to BSD as eveyone moves to BSD from the remains of Linux.
Anyway - thats my opinion - you can't have it. Feel free to share it though.
In the interests of impartiality, unless you use Gnome, which depends on systemd, you can use any init system you like on Gentoo and in some cases, switch between them.
Try a few and find one you like. Thats the Gentoo way.

Other posters - state you opinion if you wish but do not debate the merits (or otherwise) of systemd in this thread.
We have lots of other already locked threads for that.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
yngwin
Retired Dev
Retired Dev


Joined: 19 Dec 2002
Posts: 4572
Location: Suzhou, China

PostPosted: Sat Apr 11, 2015 9:50 am    Post subject: Reply with quote

Twenty_Four wrote:
another thing I forgot to include in the main post: what's the general consensus on 'systemd'? is that the accepted initialisation method nowadays? has it completely replaced the previously used method?

OpenRC is the default on Gentoo. systemd is offered as an option for those users who wish to use that, but OpenRC still gets the most support on Gentoo.
_________________
"Those who deny freedom to others deserve it not for themselves." - Abraham Lincoln
Free Culture | Defective by Design | EFF
Back to top
View user's profile Send private message
Twenty_Four
n00b
n00b


Joined: 10 Apr 2015
Posts: 9

PostPosted: Sat Apr 11, 2015 10:27 am    Post subject: Reply with quote

Thanks for replying all.

Just wanting to confirm now - https://wiki.gentoo.org/wiki/Sakaki%27s_EFI_Install_Guide/Configuring_Secure_Boot this means we are able to have our own keys for the signed kernel stub, for use in secure boot?
Back to top
View user's profile Send private message
324874
Apprentice
Apprentice


Joined: 26 Jul 2014
Posts: 168

PostPosted: Sat Apr 11, 2015 12:13 pm    Post subject: Reply with quote

Hi everybody,

I've read this thread and I don't understand the message of NeddySeagoon.

NeddySeagoon wrote:

[...]

If you don't use a boot loader, the kernel command line has to be embedded in the kernel, so if you get it wrong, its a kernel rebuild.


What is the kernel command line ? and what it's goal ?

Could anyone answer me ?

Best regards

Neoptslap
Back to top
View user's profile Send private message
dr_vic
n00b
n00b


Joined: 04 Apr 2014
Posts: 14

PostPosted: Sat Apr 11, 2015 12:21 pm    Post subject: Reply with quote

neoptslap wrote:
...What is the kernel command line ? and what it's goal ?...

Hope this helps.
Back to top
View user's profile Send private message
324874
Apprentice
Apprentice


Joined: 26 Jul 2014
Posts: 168

PostPosted: Sat Apr 11, 2015 1:00 pm    Post subject: Reply with quote

Thanks.

I forgot this and my OS doesn't want boot. Maybe, i will arrive to boot it :lol:

Can we do the same thing using the genkernel utility ?

[url]https://wiki.gentoo.org/wiki/Genkernel#Using_Genkernel_to_change_the_kernel [/url]

/etc/genkernel.conf:

# ==== MIS BOOT CONFIGURATION ====
#
# Specify a default for real_root=
#REAL_ROOT="/dev/one/two/gentoo"
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43221
Location: 56N 3W

PostPosted: Sat Apr 11, 2015 2:05 pm    Post subject: Reply with quote

neoptslap,

The boot process is a little like black magic as it seems to be problem that involves infinite recursion on several levels.

Simply stated the problem is to read an operating system from disk without using an operating system that can read the disk because the operating system that can read the dik is stored on the disk and its not yet loaded. Thats a circular problem, to solve it we must break the circle.

Step 1 is that the BIOS can read one disk block - logical block address 0 and jump to the start address of the code.
Step 2 is that the code here can read more disk blocks and jump to it.
Step 3 is that the code loaded in step 3 can read exactly one filesystem type to load the grub stage2 file.

The grub stage2 file displays the grub menu and after you make your choice, loads the kernel and initrd files. It jumps to the kernel.

At this point, grub has done its thing and the kernel and initrd are in memory on their own.
The kernel looks around for the root filesystem but as root is not yet mounted, it can't read /etc/fstab to find it. Hence when the kernel loads it needs to be told where root is.
Thats what root= or real_root= is for. Its the last step in breaking all the circles to get your system to boot.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
davidm
Guru
Guru


Joined: 26 Apr 2009
Posts: 557
Location: US

PostPosted: Wed Apr 15, 2015 11:35 pm    Post subject: Reply with quote

I've been using btrfs for about two years (4 months on Gentoo). It's been usable and I appreciate the extra features (I have a four disk RAID1 array) but it's not as solid as ext4. Sometimes you do get to deal with little papercuts which you can usually work around without any lost data by reading the mailing list and being smart. That said personally I don't recommend it to anyone not running some type of raid with non-btrfs backups. Since you are using a laptop that means you are probably stuck with one disk.

One other thing about btrfs I will mention just so more people know about it (and it increases the chances of it getting fixed sooner!) is that the multi-disk reading code is not optimal. It does not maximize reading by performance and instead determines which copy from which disk is read based merely on the PID of the requesting process. So it's basically random performance on multi-disk raid setups. This means if you have one disk which is much slower than the other you will take a random performance hit in read operations depending on the PID of the requesting process.
Back to top
View user's profile Send private message
Twenty_Four
n00b
n00b


Joined: 10 Apr 2015
Posts: 9

PostPosted: Thu Apr 16, 2015 6:43 pm    Post subject: Reply with quote

All

Thanks for the replies - got the laptop and started the install earlier today. And have a few more questions!

Has anyone installed Gentoo on hardware with one of the new Intel bay trail cpu's (specifically pentium n3540)? I'm getting ready to build the kernel once I get home later and was wondering which processor family I should choose. Traditionally bay trail was Intel Atom but those were used in the smaller netbooks with not much cpu power. The newer ones are much more powerful and are no longer marketed under the Atom family, which leaves me a little unsure.

edit: some cpu info

Quote:
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 4
Online-line CPU(s) list: 0-3
Thread(s) per core: 1
Core(s) per socket: 4
Socket(s): 1
NUMA node(s): 1
Vendor ID: Genuine Intel
CPU family: 6
Model: 55
Model name: Intel (R) Pentium (R) CPU N3540 @ 2.16GHz
Stepping: 8
CPU MHz: 499.826
CPU max MHz: 2665.6000
CPU min MHz: 499.8000
BogoMIPS: 4326.40
Virtualization: VT-x
L1d cache: 24k
L1i cache: 32k
L2 cache: 1024k
NUMA node0 CPU(s): 0-3


Last edited by Twenty_Four on Thu Apr 16, 2015 7:31 pm; edited 1 time in total
Back to top
View user's profile Send private message
Biker
Apprentice
Apprentice


Joined: 11 Jun 2003
Posts: 165
Location: A very dark, cold and moisty place...

PostPosted: Thu Apr 16, 2015 7:18 pm    Post subject: Reply with quote

Twenty_Four wrote:
...this [Secure_Boot ] means we are able to have our own keys for the signed kernel stub, for use in secure boot?


Doesn't that make booting with for instance GParted from a USB key to resize the root partition a pretty complicated thing to achieve?

And what about a system rescue when I have fsck'd up my system?

Biker
_________________
The Internet never forgets.
Where 'never' points in the direction of a moment in the very, very far future.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43221
Location: 56N 3W

PostPosted: Thu Apr 16, 2015 8:16 pm    Post subject: Reply with quote

Biker,

You need to sign the rescue/USB stuff and test that it boots before you actually need it.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing 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