-
Notifications
You must be signed in to change notification settings - Fork 0
/
gentoo install
133 lines (67 loc) · 2.59 KB
/
gentoo install
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
hdparm --user-master u --security-erase PasSWorD /dev/sda
blkdiscard /dev/sdX
mkfs.ext4 -E stride=128,stripe-width=128 /dev/sda1
tune2fs -o discard /dev/sdXY
mkdir /mnt/gentoo
mount /dev/sda1 /mnt/gentoo
cd /mnt/gentoo
links https://www.gentoo.org/downloads/mirrors/
tar xpvf stage3-*.tar.bz2 --xattrs-include='*.*' --numeric-owner
nano -w /mnt/gentoo/etc/portage/make.conf
CFLAGS="-O2 -march=native -pipe"
CHOST="x86_64-pc-linux-gnu"
ABI_X86="32 64"
ACCEPT_KEYWORDS="~amd64"
ACCEPT_LICENSE="*"
MAKEOPTS="-j4"
VIDEO_CARDS="amdgpu radeonsi"
USE="X aqua gles2 opengl egl wayland d3d9 gtk alsa user-session"
blkid
nano -w /mnt/gentoo/etc/fstab
UUID=6bb55d0a-19ca-49d8-85d2-263d9e8997bf / ext4 rw,relatime,stripe=128 0 1
mirrorselect -i -o >> /mnt/gentoo/etc/portage/make.conf
mkdir --parents /mnt/gentoo/etc/portage/repos.conf
cp /mnt/gentoo/usr/share/portage/config/repos.conf /mnt/gentoo/etc/portage/repos.conf/gentoo.conf
cp --dereference /etc/resolv.conf /mnt/gentoo/etc/
mount to chroot
mount --types proc /proc /mnt/gentoo/proc
mount --rbind /sys /mnt/gentoo/sys
mount --make-rslave /mnt/gentoo/sys
mount --rbind /dev /mnt/gentoo/dev
mount --make-rslave /mnt/gentoo/dev
chroot /mnt/gentoo /bin/bash
source /etc/profile
export PS1="(chroot) ${PS1}"
emerge-webrsync
emerge --sync
emerge --ask --update --deep --newuse @world
emerge --ask sys-kernel/linux-firmware
emerge --ask sys-kernel/gentoo-kernel-bin
emerge --ask media-sound/alsa-utils media-plugins/alsa-plugins media-libs/a52dec media-video/ffmpeg media-sound/pavucontrol media-video/mpv media-video/dvdauthor app-cdr/dvd+rw-tools x11-misc/xclip net-misc/youtube-dl media-sound/pulseaudio app-admin/sudo dev-vcs/git app-portage/repoman app-misc/bijiben net-misc/dhcpcd sys-libs/gpm www-client/links app-misc/screen
passwd
emerge --ask sys-boot/grub:2
nano -w /etc/default/grub
# Append parameters to the linux kernel command line
GRUB_CMDLINE_LINUX="init=/lib/systemd/systemd"
grub-install /dev/sda
grub-mkconfig -o /boot/grub/grub.cfg
exit
cd
umount -l /mnt/gentoo/dev{/shm,/pts,}
umount -R /mnt/gentoo
reboot
systemctl start dhcpcd
systemctl start gpm
useradd -m -G users,wheel,audio -s /bin/bash lopov
passwd lopov
rm /stage3-*.tar.*
localectl set-locale LANG=en_CA.UTF-8
emerge --ask --depclean --verbose net-misc/dhcpcd sys-libs/gpm app-misc/screen
emerge --ask x11-base/xorg-x11
emerge --ask gnome
emerge --ask www-client/google-chrome
systemctl enable NetworkManager
systemctl enable gdm.service
nano -w /etc/portage/make.conf
nano -w /var/log/Xorg.0.log
CHOST="x86_64-pc-linux-gnu"ACCEPT_KEYWORDS="~amd64"