Last modified: 2023-03-29
GRUB config
Configuration for GRUB, located at /etc/default/grub
.
Edit /etc/default/grub
and add network configuration into GRUB_CMDLINE_LINUX_DEFAULT
attribute.
Most of the information is from ArchLinux wiki.
There are multiple ways to configure this, however my favorite is to use IP address assigned by DHCP server, essentially:
ip=dhcp
I also like to add netconf_timeout
, especially on laptop, otherwise the device will hand and indefinitely wait for IP address from DHCP.
netconf_timeout=10
Example with UUID
GRUB_CMDLINE_LINUX_DEFAULT="loglevel=3 cryptdevice=UUID=3c8e3563-6394-46d0-88cc-e068387f1e1c:ark_system_luks:allow-discards ip=dhcp netconf_timeout=10 l1tf=full,force mds=full,nosmt mitigations=auto,nosmt nosmt=force usbhid.quirks=0x0463:0xffff:0x08"
It is also possible to use multiple configurations. You can add a specific network configuration into GRUB menu as additional entry. That way, you can pick on boot whether you wish to use DHCP or hard-coded IP address.