This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
app-notes:set-up-lxc [2024/11/22 15:18] – gray | app-notes:set-up-lxc [2025/01/23 13:32] (current) – [2. Test LXC installation and set up further] gray | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Set up and use an LXC container | + | ====== Set up and use an LXC container |
+ | |||
+ | ===== Goal ===== | ||
+ | |||
+ | Installing an LXC container. Images for the routers are available from the Jenkins website. | ||
+ | |||
+ | ===== Prerequisites ===== | ||
+ | |||
+ | * NetModule Wireless Router with wireless connection | ||
+ | * NetModule Software [[https:// | ||
+ | * A license is required for the LXC container | ||
+ | * Not available for legacy products NB1600, NB2700, NB3700, NB3710 | ||
+ | |||
+ | ===== - Set up the LXC Contianer ===== | ||
+ | |||
+ | Activate the LXC container on the router | ||
+ | |||
+ | {{: | ||
+ | |||
+ | In the second step the image of the LXC container in this case Debian. | ||
+ | |||
+ | {{: | ||
+ | |||
+ | The easiest way to do this is to install the whole thing over the Internet. However, the router requires a mobile connection to the Internet. | ||
+ | |||
+ | From a Jenkins server you get the current image for the container | ||
+ | |||
+ | * Jenkins Server Page image-debian / [[https:// | ||
+ | |||
+ | The "'' | ||
+ | |||
+ | Here you can get a Debina image for '' | ||
+ | |||
+ | {{: | ||
+ | |||
+ | If you click on the circle with the green rakes, you will be taken to the software. What else is important is that the circle and rakes must be green. | ||
+ | |||
+ | {{: | ||
+ | |||
+ | The image is the "'' | ||
+ | |||
+ | It would be structured like this: | ||
+ | |||
+ | '' | ||
+ | |||
+ | When the " | ||
+ | |||
+ | ===== Other LXC container images ===== | ||
+ | |||
+ | Two more LXC images are currently being offered on the Jenkins server. | ||
+ | You can use an Alpine or Ubuntu image for the container. | ||
+ | |||
+ | * Jenkins Server Page image-alpine / [[https:// | ||
+ | |||
+ | * Jenkins Server Page image-ubuntu / [[https:// | ||
+ | |||
+ | |||
+ | ===== - Test LXC installation and set up further ===== | ||
+ | |||
+ | Under the console you can first check whether the installation has been carried out. | ||
+ | |||
+ | < | ||
+ | ~ $ cd / | ||
+ | / | ||
+ | bin dev home | ||
+ | boot | ||
+ | / | ||
+ | </ | ||
+ | |||
+ | This file must be available under this directory structur | ||
+ | |||
+ | < | ||
+ | ~ $ lxc-info guest0 | ||
+ | Name: | ||
+ | State: | ||
+ | PID: 20493 | ||
+ | CPU use: 1.49 seconds | ||
+ | BlkIO use: 20.00 KiB | ||
+ | Memory use: 7.22 MiB | ||
+ | KMem use: 1.20 MiB | ||
+ | ~ $ | ||
+ | |||
+ | </ | ||
+ | |||
+ | The LXC container is set up and already started. | ||
+ | |||
+ | Set up the LXC container further. A network interface is enabled here. | ||
+ | |||
+ | {{: | ||
+ | |||
+ | The container has now also been assigned an IP address. | ||
+ | |||
+ | < | ||
+ | ~ $ lxc-info guest0 | ||
+ | Name: | ||
+ | State: | ||
+ | PID: 2255 | ||
+ | IP: | ||
+ | CPU use: 1.57 seconds | ||
+ | BlkIO use: 4.00 KiB | ||
+ | Memory use: 6.29 MiB | ||
+ | KMem use: 1.18 MiB | ||
+ | Link: | ||
+ | TX bytes: | ||
+ | RX bytes: | ||
+ | Total bytes: | ||
+ | ~ $ | ||
+ | </ | ||
+ | |||
+ | Always assign a fixed IP address for the LXC container via the DHCP server. | ||
+ | |||
+ | {{: | ||
+ | |||
+ | Log in to the LXC container and test whether it can access the Internet. | ||
+ | |||
+ | < | ||
+ | ~ $ lxc-attach guest0 | ||
+ | root@LXCNAME: | ||
+ | PING heise.de (193.99.144.80) 56(84) bytes of data. | ||
+ | 64 bytes from redirector.heise.de (193.99.144.80): | ||
+ | 64 bytes from redirector.heise.de (193.99.144.80): | ||
+ | 64 bytes from redirector.heise.de (193.99.144.80): | ||
+ | --- heise.de ping statistics --- | ||
+ | 3 packets transmitted, | ||
+ | rtt min/ | ||
+ | root@LXCNAME: | ||
+ | </ | ||
+ | |||
+ | The container is installed and set up. Now you can set up further tools on the container. | ||
+ | |||
+ | ---- | ||
+ | |||
+ | === Use this link to return to the SNMP setup === | ||
+ | |||
+ | * Back to SNMP setup / [[app-notes: |