Gigabyte P27G v2

This page describes how to install Gentoo Linux with Gnome 3 on a Gigabyte P27G v2 laptop.

Preliminary assumptions

 * In this page, we assume we are using rEFInd as a bootmanager. rEFInd is able to detect kernels with EFI stub support. Please refer to the Managing EFI Boot Loaders for Linux:Using rEFInd page, to learn more about how to install rEFInd on your laptop,
 * The installation is done from a terminal into the OpenSuse distribution (easy to install with EFI) or from a live CD of any distribution EFI bootable(e.g. Ubuntu),
 * The necessary partitions have already been created with a tool like gparted (in our case /dev/sda8 for /, /dev/sda9 for /home, /dev/sda12 for swap),
 * The ESP partition is already existing on the disk (/dev/sda2 ) and is FAT32.

Disable Secure Boot
Press F2 to enter the BIOS. Go to the Security tab. It is not possible to act upon the SecureBoot line [ENABLED]. Go to the Boot Control line instead and disable it. Then go to the Exit tab → Saves Changes and reset

Hardware
Here is the output of lspci:

First of all open a terminal and switch user to root with the 'su' command.

Installation files
Follow the Installing the Gentoo Installation files page and at the point on defining the MAKEOPTS variable enter:

Installing the Gentoo Base System
Follow the Installing the Gentoo base system page. The only exception is to not run mirrorselect as it is specific to Gentoo.

At the time of choosing the profile, please choose the default/linux/amd64/13.0/desktop/gnome/systemd profile, then update the system

Preparation
Do not emerge genkernel here but genkernel-next instead.

Then emerge lvm

Don't forget to set the MAKEOPTS variable in as genkernel ignore the value in

Next, edit the file so that the line containing  as second field has the first field pointing to the right device. . This would make the entry in the file look like so:

Creating an initramfs
We create an initramfs with genkernel to be embedded into the EFI stub. To do so run:

In order to boot directly from UEFI, the kernel needs to have CONFIG_EFI_STUB support enabled.

UEFI does not pass kernel parameters to the kernel during normal boot, so you need to hardcode them via CONFIG_CMDLINE. Example for the root partition on :

Compiling the kernel
To embed the initramfs in the kernel stub set it up in the General setup menu:

Completing the fstab File
Now complete the /etc/fstab file

Continue with the Configuring the System page. Then the Installing System Tools page contains optional tools to be installed.

You can skip the Configuring the bootloader page as there is no need of it.

Rebooting the system
Exit the chrooted environment and unmount all mounted partitions. Then type in that one magical command that initiates the final, true test:.

Finalizing
Continue with the Finalizing page.

Installing the X server
At first we install Gentoo using only the Integrated GPU.

Kernel configuration
{{Note|Please refer to the Xorg/Guide page for more details.

Installing Gnome
To launch gdm at startup enter this command:

Kernel
The laptop is provided with a Realteck RTL8732BE PCIe Wireless Network Adapter.

Don't forget to emerge the firmware.

Detection and Connection
In order to detect wireless networks and connect to them you can use wpa_supplicant:

Add this in the file:

and this in the file:

Alternative for Detection and Connection
If, like me, you experience some trouble using wpa_supplicant you can use wicd which offer a nice and efficient way to detect and to connect to wlan.

Here is my file:

Be sure to disable the "dhcpcd" service at startup

and to enable the "wicd" service

You should be able to connect via both wired and wireless interface launching the Wicd Network Manager from the Gnome menu.