8,367
edits
Changes
→Use the nmcli command to set a static IP address
<ol style="list-style-type: lower-alpha;">
<li><p>'''orangepi''' is the name of the WIFI network interface (the names are not necessarily the same)</p></li>
<li><p>'''Wired connection 1''' is the name of the Ethernet interface</p></li>{| class="wikitable" style="width:800px;"|-|orangepi@orangepi:~$ '''nmcli con show'''<br><span style="margin-right: 180px;">NAME</span><span style="margin-right: 260px;">UUID </span><span style="margin-right: 45px;">TYPE </span><span style="margin-right: 50px;">DEVICE</span><br><span style="margin-right: 125px;">'''orangepi'''</span><span style="margin-right: 70px;">cfc4f922-ae48-46f1-84e1-2f19e9ec5e2a</span><span style="margin-right: 50px;">wifi </span><span style="margin-right: 50px;">wlan0</span><br><span style="margin-right: 50px;">'''Wired connection 1'''</span><span style="margin-right: 50px;">9db058b7-7701-37b8-9411-efc2ae8bfa30</span><span style="margin-right: 30px;">ethernet </span><span style="margin-right: 50px;">eth0</span><br>|}</ol>
</li></ol>
orangepi@orangepi:~$ '''nmcli con mod "Wired connection 1" \'''
'''ipv4.method "manual"'''
|}</ol>
<ol start="4" style="list-style-type: decimal;">
<li>Then restart the Linux system</li></ol>{| class="wikitable" style="width:800px;" |-|
orangepi@orangepi:~$ '''sudo reboot'''
|}</ol>
<ol start="5" style="list-style-type: decimal;">
<li>Then re-enter the Linux system and use the '''ip addr show eth0'''command to see that the IP address has been set to the desired value</li></ol>{| class="wikitable" style="width:800px;" |-|
orangepi@orangepi:~$ '''ip addr show eth0'''
3: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
:link/ether 5e:ae:14:a5:91:b3 brd ff:ff:ff:ff:ff:ff inet '''192.168.1.110'''/32 brd 192.168.1.110 scope global noprefixroute eth0
::valid_lft forever preferred_lft forever
|}
</ol>
<span id="ssh-remote-login-development-board"></span>