Difference between revisions of "Radxa-configuration"
(Created page with "{{Languages|radxa-configuration}} = Introduction of Radxa Configuration = This document describes Radxa configuration.") |
|||
| (3 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
{{Languages|radxa-configuration}} | {{Languages|radxa-configuration}} | ||
| − | = Introduction of Radxa Configuration = | + | = Introduction of Radxa Ubuntu/Debian Configuration = |
| − | This document describes Radxa configuration. | + | This document describes Radxa Ubuntu/Debian configuration. |
| + | |||
| + | Radxa Ubuntu/Debian: https://github.com/radxa/debos-radxa/releases | ||
| + | |||
| + | == Radxa Board Information == | ||
| + | |||
| + | * Devide Model: | ||
| + | * Serial Number: | ||
| + | |||
| + | |||
| + | == radxa-config == | ||
| + | |||
| + | == The Kernel Command Line == | ||
| + | |||
| + | The Linux Kernel accepts a command line of parameters during boot. | ||
| + | Radxa official Ubuntu/Debian provide one file '''uEnv.txt''' in the boot partition to for user to add the needed kernel parameters. | ||
| + | uEnv.txt is a simple text file that can be edited using any text editor, e.g. nano, vim, etc. | ||
| + | |||
| + | We need to add all the parameters to the line | ||
| + | |||
| + | <pre style="color: red">extraargs=</pre>. | ||
| + | |||
| + | === Command Line Options === | ||
| + | |||
| + | ==== max_loop: set the number of loop device ==== | ||
| + | |||
| + | extraargs='''max_loop=8''' | ||
| + | |||
| + | ==== mem: set memory ==== | ||
| + | |||
| + | extraargs='''mem=512MB''' max_loop=8 | ||
| + | |||
| + | == Configuring Networking == | ||
| + | |||
| + | === netplan.io: Network configuration in YAML === | ||
| + | |||
| + | Here is one example for setting Ethernet and WiFi static IP address on ROCK Pi S. | ||
| + | |||
| + | ==== Setting Ethernet Static IP Address ==== | ||
| + | |||
| + | Install package netplan.io | ||
| + | |||
| + | root@rockpis:~# apt-get install -y netplan.io | ||
| + | |||
| + | Create file, /etc/netplan/01-ethernet.yaml. If there is no /etc/netplan folder, create it. | ||
| + | |||
| + | root@rockpis:~# touch /etc/netplan/01-ethernet.yaml | ||
| + | |||
| + | Add the following contents to the file, /etc/netplan/01-ethernet.yaml and save it. | ||
| + | |||
| + | <pre> | ||
| + | root@rockpis:~# cat /etc/netplan/01-ethernet.yaml | ||
| + | network: | ||
| + | version: 2 | ||
| + | renderer: networkd | ||
| + | ethernets: | ||
| + | eth0: | ||
| + | addresses: | ||
| + | - 192.168.1.200/24 | ||
| + | gateway4: 192.168.1.1 | ||
| + | nameservers: | ||
| + | addresses: | ||
| + | - "192.168.1.1" | ||
| + | - "8.8.8.8" | ||
| + | </pre> | ||
| + | |||
| + | Run the commands below to apply our changes. | ||
| + | |||
| + | root@rockpis:~# netplan apply | ||
| + | |||
| + | To validate that our changes are applied, run the commands below to view the IP address configuration detals. | ||
| + | |||
| + | root@rockpis:~# ip addr show dev eth0 | ||
| + | |||
| + | It should display similar lines like the one below: | ||
| + | |||
| + | <pre> | ||
| + | root@rockpis:~# ip addr show dev eth0 | ||
| + | 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN group default qlen 1000 | ||
| + | link/ether c2:68:e0:7c:9b:09 brd ff:ff:ff:ff:ff:ff | ||
| + | inet 192.168.1.200/24 brd 192.168.1.255 scope global eth0 | ||
| + | valid_lft forever preferred_lft forever | ||
| + | inet6 fe80::c068:e0ff:fe7c:9b09/64 scope link | ||
| + | valid_lft forever preferred_lft forever | ||
| + | </pre> | ||
| + | |||
| + | ==== Setting Wi-Fi Static IP Address ==== | ||
| + | |||
| + | <pre> | ||
| + | root@rockpis:~# cat /etc/netplan/02-wireless.yaml | ||
| + | network: | ||
| + | version: 2 | ||
| + | renderer: networkd | ||
| + | wifis: | ||
| + | wlan0: | ||
| + | dhcp4: no | ||
| + | dhcp6: no | ||
| + | addresses: [192.168.1.220/24] | ||
| + | gateway4: 192.168.1.1 | ||
| + | nameservers: | ||
| + | addresses: [192.168.1.1, 8.8.8.8] | ||
| + | access-points: | ||
| + | "rockpi-2.4g": | ||
| + | password: "rockpistar" | ||
| + | </pre> | ||
| + | |||
| + | Run the commands below to apply the changes. | ||
| + | |||
| + | root@rockpis:~# netplan apply | ||
| + | |||
| + | Validate that our changes are applied. | ||
| + | |||
| + | <pre> | ||
| + | root@rockpis:~# ip addr show dev wlan0 | ||
| + | 3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 | ||
| + | link/ether 4a:33:14:54:4a:03 brd ff:ff:ff:ff:ff:ff | ||
| + | inet 192.168.1.220/24 brd 192.168.1.255 scope global wlan0 | ||
| + | valid_lft forever preferred_lft forever | ||
| + | </pre> | ||
Latest revision as of 07:16, 3 March 2022
Contents
Introduction of Radxa Ubuntu/Debian Configuration
This document describes Radxa Ubuntu/Debian configuration.
Radxa Ubuntu/Debian: https://github.com/radxa/debos-radxa/releases
Radxa Board Information
- Devide Model:
- Serial Number:
radxa-config
The Kernel Command Line
The Linux Kernel accepts a command line of parameters during boot. Radxa official Ubuntu/Debian provide one file uEnv.txt in the boot partition to for user to add the needed kernel parameters. uEnv.txt is a simple text file that can be edited using any text editor, e.g. nano, vim, etc.
We need to add all the parameters to the line
extraargs=.
Command Line Options
max_loop: set the number of loop device
extraargs=max_loop=8
mem: set memory
extraargs=mem=512MB max_loop=8
Configuring Networking
netplan.io: Network configuration in YAML
Here is one example for setting Ethernet and WiFi static IP address on ROCK Pi S.
Setting Ethernet Static IP Address
Install package netplan.io
root@rockpis:~# apt-get install -y netplan.io
Create file, /etc/netplan/01-ethernet.yaml. If there is no /etc/netplan folder, create it.
root@rockpis:~# touch /etc/netplan/01-ethernet.yaml
Add the following contents to the file, /etc/netplan/01-ethernet.yaml and save it.
root@rockpis:~# cat /etc/netplan/01-ethernet.yaml
network:
version: 2
renderer: networkd
ethernets:
eth0:
addresses:
- 192.168.1.200/24
gateway4: 192.168.1.1
nameservers:
addresses:
- "192.168.1.1"
- "8.8.8.8"
Run the commands below to apply our changes.
root@rockpis:~# netplan apply
To validate that our changes are applied, run the commands below to view the IP address configuration detals.
root@rockpis:~# ip addr show dev eth0
It should display similar lines like the one below:
root@rockpis:~# ip addr show dev eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN group default qlen 1000
link/ether c2:68:e0:7c:9b:09 brd ff:ff:ff:ff:ff:ff
inet 192.168.1.200/24 brd 192.168.1.255 scope global eth0
valid_lft forever preferred_lft forever
inet6 fe80::c068:e0ff:fe7c:9b09/64 scope link
valid_lft forever preferred_lft forever
Setting Wi-Fi Static IP Address
root@rockpis:~# cat /etc/netplan/02-wireless.yaml
network:
version: 2
renderer: networkd
wifis:
wlan0:
dhcp4: no
dhcp6: no
addresses: [192.168.1.220/24]
gateway4: 192.168.1.1
nameservers:
addresses: [192.168.1.1, 8.8.8.8]
access-points:
"rockpi-2.4g":
password: "rockpistar"
Run the commands below to apply the changes.
root@rockpis:~# netplan apply
Validate that our changes are applied.
root@rockpis:~# ip addr show dev wlan0
3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether 4a:33:14:54:4a:03 brd ff:ff:ff:ff:ff:ff
inet 192.168.1.220/24 brd 192.168.1.255 scope global wlan0
valid_lft forever preferred_lft forever
