notebook/IT/linux/index.md

58 lines
1.4 KiB
Markdown
Raw Normal View History

2021-04-20 21:13:14 +00:00
# Linux
2021-01-24 16:52:22 +00:00
![linux](../img/linux.png)
2021-04-20 21:13:14 +00:00
2020-11-26 17:38:25 +00:00
## retrouvé date t'instalation
2021-04-20 21:13:14 +00:00
2020-11-26 17:38:25 +00:00
`ls -lct /etc | tail -1 | awk '{print $6, $7, $8}'`
2021-04-20 21:13:14 +00:00
## enable Wayland support
2020-11-26 17:38:25 +00:00
- execute `ln -s /dev/null /etc/udev/rules.d/61-gdm.rules` to avoid that gnome test your nvidia Driver
- add `nvidia-drm.modeset=1` to GRUB_CMDLINE_LINUX_DEFAULT in*/etc/default/grub*
- update grub config `grub-mkconfig -o /boot/grub/grub.cfg` in root
- add nvidia module to mkinitcpio.cong:
`MODULES=(nvidia nvidia_modeset nvidia_uvm nvidia_drm)`
- create pacman hook:
2021-04-20 21:13:14 +00:00
```ini
2020-11-26 17:38:25 +00:00
[Trigger]
Operation=Install
Operation=Upgrade
Operation=Remove
Type=Package
Target=nvidia
Target=linux
# Change the linux part above and in the Exec line if a different kernel is used
[Action]
Description=Update Nvidia module in initcpio
Depends=mkinitcpio
When=PostTransaction
NeedsTargets
Exec=/bin/sh -c 'while read -r trg; do case $trg in linux) exit 0; esac; done; /usr/bin/mkinitcpio -P'
```
2021-04-20 21:13:14 +00:00
## see if you run on wayland
2020-11-26 17:38:25 +00:00
`loginctl show-session $(loginctl G $USERNAME|awk '{print $1}') -p Type`
## boot in emergency target
1. (Re)boot the machine
2. Wait for the grub menu to appear, then hit “e”,
3. scroll down to the “linux16” line then press the end key
4. type the following:
systemd.unit=emergency.target
5. press ctrl+x
6. put root writable with `mount -o rw,remount /`
2022-02-12 10:16:10 +00:00
## disable IPV6
`sysctl -b net.ipv6.conf.all.disable_ipv6=1`