]> cvs.zerfleddert.de Git - m1-debian/blob - files/quickstart.txt
93b1d76818a45b3774eeb18c4bc36f79a0b938a1
[m1-debian] / files / quickstart.txt
1 # grow the root partition
2 sgdisk -n 0:0
3
4 # grow root filesystem
5 lsblk
6 resize2fs /dev/nvme0n1pX
7
8 # Ethernet
9 ip l s
10 dhclient <device>
11
12 # Wifi
13 rmmod brcmfmac
14 rmmod brcmutil
15 mount /dev/sda1 /mnt
16 tar -C /lib/firmware/ -xf /mnt/linux-firmware.tar
17 umount /mnt
18 modprobe brcmfmac
19 vim /etc/wpa_supplicant/wpa_supplicant.conf
20 wpa_supplicant -i wlan0 -c /etc/wpa_supplicant/wpa_supplicant.conf
21 dhclient wlan0
22
23 # Time
24 ntpdate pool.ntp.org
25 date --set 2022-01-25
26 date --set 14:21
27
28 # Configure timezone
29 dpkg-reconfigure tzdata
30
31 # Fix grub
32 # We deinstall grub-efi-arm64-signed- because it creates a file fbaa64.efi
33 # which makes u-boot hang.
34 apt-get install grub-efi grub-efi-arm64-signed-
35 grub-install --target=arm64-efi --efi-directory=/boot/efi --removable
36 update-grub
37 # Set removable media to yes and nvram to no to make later grub updates work
38 dpkg-reconfigure grub-efi-arm64
39
40 See also: https://github.com/AsahiLinux/docs/wiki/U-Boot
41
42 # xorg
43
44 # Keyboard use capslock as additional ctrl
45 cat > /etc/X11/xorg.conf.d/00-keyboard.conf <<'EOF'
46 Section "InputClass"
47 Identifier "system-keyboard"
48 MatchIsKeyboard "on"
49 Option "XkbLayout" "us"
50 Option "XkbModel" "pc105"
51 Option "XkbVariant" "de_se_fi"
52 Option "XkbOptions" "ctrl:nocaps"
53 EndSection
54 EOF
55
56 # Swap command and option (windows and alt like on a pc keyboard)
57 echo 1 > /sys/module/hid_apple/parameters/swap_opt_cmd
58
59 # Configure the touchpad
60 cat > /etc/X11/xorg.conf.d/30-input.conf <<'EOF'
61 Section "InputClass"
62 Identifier "libinput touchpad catchall"
63 MatchIsTouchpad "on"
64 MatchDevicePath "/dev/input/event*"
65 Option "Tapping" "False"
66 Option "TappingDrag" "False"
67 Option "DisableWhileTyping" "True"
68 Option "AccelProfile" "adaptive"
69 Option "AccelSpeed" "0.3"
70 Option "AccelerationNumerator" "2"
71 Option "AccelerationDenominator" "1"
72 Option "AccelerationThreshold" "4"
73 Option "AdaptiveDeceleration" "2"
74 Option "NaturalScrolling" "0"
75 Option "TappingButtonMap" "lmr"
76 Option "ClickMethod" "clickfinger"
77 Driver "libinput"
78 EndSection
79 EOF
80
81 # Create a user
82 useradd -m -c 'firstname lastname' -s /bin/bash username
83 passwd username
84
85 # Lightweight desktop
86 apt-get install lightdm blackbox xterm firefox-esr
87
88 # Install gnome
89 apt-get install gnome
90 /etc/init.d/gdm3 start
91
92 # If you need to install the kernel on a bootstrapped system or one that needs recovery
93 wget https://tg.st/u/k.deb
94 dpkg -i k.deb
95
96 # asahi does not handle sleep well at the moment
97 sudo systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target
98
99 - You can also use the live system to install Debian on the m1, the rough outline is:
100
101 - Create two paritions:
102
103 - One 1 GB vfat
104 - Rest with ext4
105
106 - Use debootstrap to bootstrap debian
107
108 - Install the kernel
109
110 - Install grub
111
112 - reboot
113
114 Repack live
115 ===========
116 You might want to save the state of your live system to the usb stick. In order
117 to do so, run the following commands:
118
119 apt update
120 apt-get install -y cpio pigz
121 rm /etc/rc.local
122 # remove '#' before allow-hotplug
123 vi /etc/network/interfaces
124 mount /dev/sda1 /mnt
125 mv /mnt/initrd.gz /mnt/initrd.old
126 cd /
127 find . -xdev | cpio --quiet -H newc -o | pigz -9 > /mnt/initrd.gz
128 umount /mnt
Impressum, Datenschutz