Skip to content

Instantly share code, notes, and snippets.

@riskiwah
Last active July 28, 2023 07:35
Show Gist options
  • Save riskiwah/b18aa1dfcaa56c2d632b4e20503f000d to your computer and use it in GitHub Desktop.
Save riskiwah/b18aa1dfcaa56c2d632b4e20503f000d to your computer and use it in GitHub Desktop.
Arch Linux - T14 Gen 3

Arch Linux - T14 Gen 3

Bios

  • Make sure to disable Secure boot
  • Make sure to disable TPM 2

Partition

Device Size Type
/dev/nvme0n1p1 384M EFI System (ESP)
/dev/nvme0n1p2 475.6G Ext4

Installation Notes

This will using archinstall tools

  1. Connect wifi with iwctl can refer in here.
  2. Update archinstall package first w/ pacman -Sy archinstall to make sure get the newest.
  3. Then setup partition disk, you can using any tools like cfdisk, fdisk etc.
# Enter fdisk partition prompt
fdisk /dev/nvme0n1

# Create new GPT partition
g

# Create new partition for number 1
n

# Enter the size for first partition which is for EFi/ESP
+384M

# Create new partition for number 2
n

# Just hit `enter` and `enter` because we will use all the rest

# Then dont forget to write it
w
  1. After setup partition disk, let's enter archinstall.

    • Setup each basic needs like mirrors, hostname, root password, and user account.
      • Audio = pipewire
      • Boot option = GRUB
      • Kernel = linux
      • Profile = Xorg for intel
    • For partition disk, we already setup the partition table, however we need things like:
      • Wipe all disk (for clean up purpose)
      • Setup flag for each partition eg: /boot for EFI and / as the second partition.
      • After all make sure to check again before save it.
    • How about with swap partition? I don't enabled it because want to try ZRAM swap mode.
  2. Bump install it.

    • (this will take around ~10-15 minutes, let's grab snacks and coffee)
  3. At the last installation will prompt about do you want chroot blablalba and just ignore it with NO.

  4. Reboot and Unplug your USB :)

Entering fresh Arch linux

TL;DR this will install i3 refer to package.txt file.

  1. Login with your user account or root.
  2. Check the connection.
  3. Install the packages.
  4. Make sure better start with login manager.

Notes

Special notes regarding T14 needs

Intel sound

Suddenly got the errors that can't output the sound when try to play some song from YT/Spotify.

Then check with sudo dmesg -w to see what happen.

> Refer this repository if something bad happen: https://github.com/thesofproject/sof-bin

install these packages

   sudo pacman -Sy alsa-firmware
   sudo pacman -Sy sof-firmware alsa-ucm-conf

Intel Graphics

To able using intel driver and safe your eyes from screen tearing, if having more issue please read carefully this docs -> https://wiki.archlinux.org/title/Intel_graphics

Make sure your already install `xf86-video-intel` package then add this config:

➜ cat /etc/X11/xorg.conf.d/20-intel.conf
Section "Device"
  Identifier "Intel Graphics"
  Driver "intel"
  Option "TearFree" "true"
  Option "NoAccel" "True"
  Option "DRI" "False"
EndSection

Touchpad

➜ cat /etc/X11/xorg.conf.d/90-touchpad.conf
Section "InputClass"
        Identifier "touchpad"
        MatchIsTouchpad "on"
        Driver "libinput"
        Option "Tapping" "on"
        Option "TappingButtonMap" "lrm"
        Option "NaturalScrolling" "on"
        Option "ScrollMethod" "twofinger"
        Option "AccelerationNumerator" "2"
        Option "AccelerationDenominator" "1"
        Option "AccelerationThreshold" "4"
EndSection

Power, throttling etc

Install TLP

sudo pacman -S tlp tlp-rdw acpi_call

#refer here
https://linrunner.de/tlp/installation/arch.html#thinkpads-only-external-kernel-modules

Install throttled

sudo pacman -S throttled
sudo systemctl enable --now throttled.service

Install thermald

sudo pacman -S thermald

Install powertop

sudo pacman -S powertop

Currently install all of them, and was using combine of TLP, thermald and powertop --auto-tune. Basically throttled and thermald is having same function. So make sure or switch on/off between them. for config refer to my dotfiles.

Chromium/google-chrome

Enable web gpu

➜ cat ~/.config/chromium-flags.conf
--ignore-gpu-blocklist
--enable-gpu-rasterization
--enable-zero-copy
--disable-gpu-driver-bug-workarounds

Enable webrtc pipewire

# open chrom* and enabled it
chrome://flags/#enable-webrtc-pipewire-capturer

Virtualbox

This one will be related with daily dev using vagrant and packer, this issue happen related with permission and kernel parameters caused by new intel generation 11++

# grant group
sudo gpasswd -a $USER vboxusers

# add `ibt=off` to your grub kernel param

# sources:
- https://wiki.archlinux.org/title/VirtualBox#Freeze_during_virtual_machine_startup_with_11th_generation_Intel_CPU_and_later
- https://weepingdogel.github.io/posts/problem_of_virtualbox_appeding_starting_vm/

Sources

Cheatsheet day to day Arch Linux

  • Reflector
reflector --verbose --latest 5 --sort rate --protocol https --country Singapore,Indonesia --save /etc/pacman.d/mirrorlist
  • fwupdmgr
fwupdmgr get-devices
fwupdmgr refresh
fwupdmgr get-updates

# Update:
sudo fwupdmgr update
gesture swipe left 3 xdotool key super+shift+Tab
gesture swipe right 3 xdotool key super+Tab
gesture swipe up 3 xdotool key super+f
gesture swipe down 3 xdotool key super+f
# swipe_threshold 78
# timeout 0.1%
# Generated with pacman -Qqe
alacritty
alsa-firmware
ansible
arandr
base
base-devel
bash-completion
brightnessctl
chromium
dmenu
dunst
efibootmgr
feh
firefox
freerdp
fwupd
git
gnome-screenshot
gnu-netcat
google-chrome
gpicview
grub
gst-plugin-pipewire
htop
hugo
i3-wm
i3blocks
i3lock
i3status
intel-media-driver
intel-ucode
iwd
libpulse
libva-intel-driver
linux
linux-firmware
man-db
neofetch
neovim
noto-fonts-cjk
noto-fonts-emoji
noto-fonts-extra
packer
pacman-contrib
picom
pipewire
pipewire-alsa
pipewire-jack
pipewire-pulse
powerline-fonts
remmina
rofi
sof-firmware
spotify-launcher
terraform
thunar
thunar-archive-plugin
thunar-volman
tmux
ttf-dejavu
ttf-fira-code
ttf-font-awesome
udisks2
unzip
vagrant
vim
virtualbox
visual-studio-code-bin
vulkan-intel
wget
wireplumber
xbindkeys
xclip
xorg-bdftopcf
xorg-iceauth
xorg-mkfontscale
xorg-server
xorg-sessreg
xorg-smproxy
xorg-x11perf
xorg-xbacklight
xorg-xcmsdb
xorg-xcursorgen
xorg-xdpyinfo
xorg-xdriinfo
xorg-xev
xorg-xgamma
xorg-xhost
xorg-xinit
xorg-xinput
xorg-xkbevd
xorg-xkbprint
xorg-xkbutils
xorg-xkill
xorg-xlsatoms
xorg-xlsclients
xorg-xpr
xorg-xprop
xorg-xrandr
xorg-xrefresh
xorg-xset
xorg-xsetroot
xorg-xvinfo
xorg-xwd
xorg-xwininfo
xorg-xwud
xsel
xterm
yay-bin
zoom
zram-generator
zsh
sensors:
- hwmon: /sys/devices/platform/thinkpad_hwmon/hwmon
indices: [1, 3, 4, 5, 6, 7]
- hwmon: /sys/devices/platform/coretemp.0/hwmon
indices: [1, 2, 3, 4, 5, 6, 7, 8, 10, 11]
- tpacpi: /proc/acpi/ibm/thermal
indices: [1, 2, 3, 4]
max_errors: 10
fans:
- tpacpi: /proc/acpi/ibm/fan
max_errors: 10
levels:
- [0, 0, 45]
- [1, 39, 52]
- [2, 51, 55]
- [3, 54, 58]
- [4, 56, 66]
- [5, 64, 70]
- [6, 68, 80]
- [7, 79, 86]
- ["level auto", 54, 75]
- ["level disengaged", 70, 255]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment