This is an old revision of the document!
There are two types of network configuration supported by the Analog Devices Kuiper Linux Distribution:
Updating the networking configuration will require a serial connection (UART), existing network connection, or having a physical keyboard/mouse/monitor connected. In all cases, to find out what your Ethernet port IP address is within ADI Kuiper Linux all you need to do is type the following:
ifconfig
By default, the Ethernet port of your host platform is configured for DHCP when using the ADI Kuiper Linux Distribution. Typically the Ethernet port is named eth 0, but if a platform has multiple Ethernet ports than those ports get enumerated (For example - Port 1 will be named eth 0 and Port 2 will be named eth 1)
If you require a new IP address for some reason (Perhaps your internet isn't working or there are multiple devices using the same address) use the following instructions.
sudo dhclient -r eth0
sudo dhclient eth0
ifconfig
If you are returning from a static IP configuration, and require to have a new DHCP IP address assigned to the host platform, follow these steps:
enable_dhcp.sh
ifconfig
Some versions of Kuiper have an incompatible configuration script for enabling static addresses. If you receive the error “can't read /etc/NetworkManager/NetworkManager.conf: No such file or directory”, you will need to do the following.
sudo cat > /usr/local/bin/enable_dhcp.sh #!/bin/bash # # Re-enable the default DHCP-based NetworkManager support. Use to revert the # static IP configuration performed by the enable_static_ip.sh script. # # Example usage: # enable_dhcp.sh # # WARNING: Do not use this script if there is a custom network configuration # set up in /etc/network/interfaces as it will be overwritten. set -e if [[ ${UID} -ne 0 ]]; then echo "This script must be run as root!" exit 1 fi if grep -qi kuiper "/etc/os-release"; then cat <<-EOF > /etc/dhcpcd.conf hostname EOF systemctl daemon-reload systemctl restart dhcpcd.service else echo "Re-enabling DHCP via NetworkManager for all network interfaces" cat <<-EOF > /etc/network/interfaces # interfaces(5) file used by ifup(8) and ifdown(8) # Include files from /etc/network/interfaces.d: source-directory /etc/network/interfaces.d EOF # enable DHCP via NetworkManager (assumes the config file hasn't been touched much) sed -i 's/^managed=true/managed=false/' /etc/NetworkManager/NetworkManager.conf service network-manager restart fi #<Then Press "Ctrl + D" to save> sudo chmod +x /usr/local/bin/enable_dhcp.sh
If you desire to directly connect the Ethernet port of your host platform to the Ethernet port of another host, such as a PC (without the use of a network or router) a static configuration is required.
In order to change the default settings of ADI Kuiper Linux please use the following steps.
enable_static_ip.sh <ip address> eth0
Where <ip address> is a usable and unique value such as 192.168.255.1
ifconfig
Some versions of Kuiper have an incompatible configuration script for enabling static addresses. If you receive the error “can't read /etc/NetworkManager/NetworkManager.conf: No such file or directory”, you will need to do the following.
sudo cat > /usr/local/bin/enable_static_ip.sh #!/bin/bash # # Enable a static IP for eth0 (or another interface) on Ubuntu-based setups. # Note that the wanted IP address should be specified as the first argument; # otherwise, it defaults to 192.168.0.101. Also, the interface can be specified # as the second argument if the default (eth0) isn't wanted. # # Example usage: # enable_static_ip.sh [10.66.99.101] [eth1] # # WARNING: Do not use this script if there is a custom network configuration # set up in /etc/network/interfaces as it will be overwritten. set -e IP_ADDR=${1:-192.168.0.101} ETH_DEV=${2:-eth0} if [[ ${UID} -ne 0 ]]; then echo "This script must be run as root!" exit 1 fi echo "Enabling the static IP address ${IP_ADDR} on ${ETH_DEV}" if grep -qi kuiper "/etc/os-release"; then cat <<-EOF > /etc/dhcpcd.conf interface ${ETH_DEV} static ip_address=${IP_ADDR}/24 EOF systemctl daemon-reload systemctl restart dhcpcd.service else # disable NetworkManager (assumes the config file hasn't been touched much) sed -i 's/^managed=false/managed=true/' /etc/NetworkManager/NetworkManager.conf # set up loopback and add static IP config for ${ETH_DEV} (defaults to eth0) cat <<-EOF > /etc/network/interfaces auto lo iface lo inet loopback auto ${ETH_DEV} iface ${ETH_DEV} inet static address ${IP_ADDR} netmask 255.255.255.0 EOF service network-manager restart fi #<Then Press "Ctrl + D" to save> sudo chmod +x /usr/local/bin/enable_static_ip.sh
Once complete, you will need to change the networking configuration of your PC. I am going to use a Windows 10 PC as an example, but similar procedures can be done with MAC OS and Linux based Machines.
Windows Procedure:
Now you will be ready to directly connect your ADI Kuiper Linux host directly to your PC using the Ethernet port of both devices.
Remember once you are done to come back into the setting on your PC to change the Ethernet port back to the Obtain an IP address automatically radio button. Otherwise anything connected to your PC using the Ethernet port will likely not work.
End of Document