Загрузка...

How do you set a static IP address on Arch Linux?

How do you set a static IP address on Arch Linux?

To set a static IP address on Arch Linux, the most common and robust approach involves `systemd-networkd`. Begin by identifying your network interface name, typically `enpXsY`, using `ip a`. Next, create a configuration file, for example, `/etc/systemd/network/20-static.network`. Within this file, define a `[Match]` section specifying your interface (e.g., `Name=enp0s3`). Then, in a `[Network]` section, configure your desired static IP address and CIDR (e.g., `Address=192.168.1.10/24`), the network gateway (`Gateway=192.168.1.1`), and your preferred DNS servers (`DNS=8.8.8.8`). Save the file. Finally, enable and start the `systemd-networkd` service with `sudo systemctl enable --now systemd-networkd` to apply the static IP configuration. If `NetworkManager` was previously active, it's prudent to disable it first (`sudo systemctl disable --now NetworkManager`) to avoid potential conflicts.

--------------

Video link: https://youtu.be/JYo431hdJRM
Channel link: https://www.youtube.com/@HeyInsights

Have questions or thoughts? Leave a comment below. Thank you! 😃

Видео How do you set a static IP address on Arch Linux? канала Hey Insights
Яндекс.Метрика
Все заметки Новая заметка Страницу в заметки
Страницу в закладки Мои закладки
На информационно-развлекательном портале SALDA.WS применяются cookie-файлы. Нажимая кнопку Принять, вы подтверждаете свое согласие на их использование.
О CookiesНапомнить позжеПринять