2022-06-30
md
OctoPrint on a Rock Pi S D4W
<-Installing an OS on the Rock Pi S
<-OctoPrint on a Raspberry Pi 3

After installing OctoPrint on a Rock Pi S model D4W in February of last year, I started writing a post on the subject which I never completed. Since then new versions of the main operating system have been released and I also wanted a more permanent solution beyond a breadboard/proof of concept phase project. Consequently I have reinstalled OctoPrint and MJPG-Streamer on the Rock Pi S and decided to finally complete the post at the same time. Unfortunately, this is a long post. The Linux images provided by Radxa are definitely not up to Raspberry Pi OS standards so a surprisingly important portion of what follows is about getting the operating system to an acceptable working state.

Before embarking on a project like this, know that it is far simpler and easier to install OctoPrint and MJPG-Streamer on a supported Rapsberry Pi using an OctoPi SD card image provided by Guy Sheffer (guysoft on GitHub). This is probably the best route for anyone starting out. Also DietPi supports the Rock Pi single-board computers. This is probably another good choice for beginners because Octoprint and MJPG-Streamer are in its optimized software collection. While I have not tested this possibility, past experience would lead me to believe that the installation of the OS and the software packages should be straightforward. Finally, there is another reason not to follow this guide. The Rock Pi S, which was very affordable ($14 back in early 2020) is now much more expensive and difficult to find.

Rock Pi S: $50+ on Aliexpress

Besides, it seems that the board is no longer in production. All mention of the Rock Pi S has disappeared from the vendor site from which I purchased it: Seeed Studio and Radxa approved vendors in North America do not carry it either. Furthermore, Radxa itself has not released an updated image of the operating system since the June 2021 release which was based on kernel 4.4 of Linux while Armbian has unsupported images based on the 5.10 and 5.13 kernels released almost at the same time.

Given these arguments I would look elsewhere if I had to buy a single-board computer to complete this project. But the Rock Pi S is available, so it might as well be put to good use.

Table of contents

  1. Hardware on a Shoe String
  2. Choice of an Operating System
  3. First Boot
  4. Initial Hardware Test
  5. Necessary Housekeeping
    1. Set the Local Time Zone
    2. Update the OS
  6. Useful Housekeeping
    1. Add a Second User
    2. Change the Default User Name
    3. Change the Host Name
    4. Less Password Protection
    5. Enable Zeronconf (avahi-daemon)
    6. Reclaim RAM
    7. Limit the Footprint of the Journal Service
  7. Configure the Network
    1. Static IP for the Ethernet Interface
    2. Enable Wi-Fi
    3. Static IP for the Wireless Interface
    4. Cleaning Up the Network Configuration
  8. Install MJPG-Streamer
  9. Python Requirements for Octoprint
  10. Install OctoPrint
  11. OctoPrint Configuration
  12. OctoPrint Usage
  13. Enable the Services

Hardware on a Shoe String toc

When starting out, I was just dipping my toe into 3D printing without being convinced that a good case for this new venture could be made. Understandably, I wanted to keep expenses to a minimum until an informed opinion could be reached. Consequently the hardware choices were strongly influenced by cost considerations. In particular, it made sense to use hardware that was on hand as much as possible. The Rock Pi S is a good fit for this task. It has Wi-Fi capability which in my case is mandatory as an Ethernet connection is not readily available. The Rock Pi S has two USB ports which is just sufficient to connect to the printer and to a WebCam. It has a GPIO header which can be used to supply power to the board and to control relays for the printer and lights, although that remains to be done.

The Rock Pi S does not have a dedicated camera connector so an old WebCam is used: the Microsof LifeCam VX-2000 (model 1381). It is acceptable for monitoring the printer in real time as I am not planning to record any videos. Both the USB cable to the printer and the webcam have USB type A connectors, but the Rock Pi S has only one port with that type of connector. Accordingly it was necessary to purchase a USB-C to Type-A adapter to go ahead of the project. Since such adapters cost more than the Rock Pi S and the WebCam together in local retail outlets (based on original prices!), I ordered the adapter from China. That usually means delivery in two to four months and even more lately. This is why I first installed OctoPrint on a Raspberry Pi 3 as described elsewhere.

Of course, the Rock Pi has to be powered. Be careful about this source of power. An Asus 5V 1.35A wall wart orignally meant for a Nexus 7 (circa 2013) has proven to be adequate.

Lastly, I added a Wi-Fi antenna: one of those printed boards meant for the 2.4 MHz band. Of course, if an Ethernet connection can be made with the Rock Pi then there is no need for an antenna. Here is a representation of the basic system.

The diagram shows the connections when OctoPrint is up and running. When installing and configuring the operating system, the desktop computer was connected by a USB cable to the Rock Pi using the latter's USB-C port and in addition a USB-Serial converter was used to connect directly with the debug serial port of the Rock Pi S. More on that latter.

Choice of an Operating System toc

There are two flavours of Linux for the Rock Pi S, Debian and Ubuntu (which is itself based on Debian), available from two sources: Radxa and Armbian. I very recently evaluated the Armbian offering (Armbian 21.08 / Ubuntu Focal 20.04 on a Rock Pi S D4W) and concluded that it was not suitable for this project. Of the two official Images on the Radxa downloads page which are actually hosted in the Radxa Rock Pi S released images GitHub repository

I have decided to use Ubuntu Focal. This is a matter of convenience as both are based on the same Linux kernel and the same U-Boot loader:

Kernel version: 4.4.143-65-rockchip-g58431d38f8f3,
U-Boot version: 2017.09-02389-gc93a0fc709.

There's no point in putting direct links to any of these image files, as they may be replaced with newer versions. Just consult the download pages.

I described in detail the installation of the previous version (January 26, 2021) versions of both Debian Buster and Ubuntu Focal in a previous post: Installing an OS on the Rock Pi S. There is not much different in the newer version.

First Boot toc

Console pinout I used Balena Etcher to write the image file to an 8 GByte SD card. This is a simple procedure which is explained in many blogs on the Web and in some posts here, so I will not go into the details again.

There are three ways to open a bash session on the Rock Pi S running Ubuntu Focal from Radxa: an Android Debugging Bridge adb over USB, a direct serial connection using a USB-serial converter, and an SSH connection over the local area network. Be aware that in the latter case, it will be necessary to connect the Rock Pi S to the LAN with an Ethernet cable. Furthermore, it will be necessary to ascertain the IP address assigned to the Rock Pi S by the DHCP server on the LAN to connect to the board because the avahi service is not enabled by default in the OS image, no matter what the Radxa documentation says.

While I prefer to use SSH, this first boot will be done with a USB-Serial connection in place. The diagram to the right shows where to connect the Rx, Tx and ground signals of a USB-Serial converter. From experience I know that the serial converter will be mapped to the ttyUSB0 or ttyUSB1 device, so that is fairly easy to ascertain. I then started a terminal connecting to that device at a baud of 1500000. I used cu, but miniterm.py, picocom, screen, etc. could be used as long as it can run at the very fast baud. The advantage of using the serial link for this initial boot is that the messages from the bootloader (U-boot) and from the Linux boot sequence will be seen.

For the initial boot:

michel@hp:~$ cu -l /dev/ttyUSB0 -s 1500000 Connected. DDR Version V1.26 REGFB: 0x00000031, 0x00000031 In 589MHz DDR3 Col=10 Bank=8 Row=15 Size=512MB msch:1 Returning to boot ROM... INFO: Preloader serial: 0 NOTICE: BL31: v1.3(release):3a579d3 NOTICE: BL31: Built : 09:09:17, Jan 29 2019 INFO: Lastlog: last=0x100000, realtime=0x102000, size=0x2000 INFO: ARM GICv2 driver initialized INFO: Using opteed sec cpu_context! INFO: boot cpu mask: 1 INFO: plat_rockchip_pmu_init: pd status 0xe b INFO: BL31: Initializing runtime services WARNING: No OPTEE provided by BL2 boot loader, Booting device without OPTEE initialization. SMC`s destined for OPTEE will return SMC_UNK ERROR: Error initializing runtime service opteed_fast INFO: BL31: Preparing for EL3 exit to normal world INFO: Entry point address = 0x600000 INFO: SPSR = 0x3c9 U-Boot 2017.09-02389-gc93a0fc709 (May 24 2021 - 01:09:26 +0000), Build: jenkins-linux-build-release-590 Model: Radxa ROCK Pi S PreSerial: 0 DRAM: 510 MiB Relocation Offset is: 1f917000 vdd_core 1044000 uV vdd-core init 1044000 uV MMC: dwmmc@ff480000: 0, dwmmc@ff490000: 1 Using default environment In: serial@ff0c0000 Out: serial@ff0c0000 Err: serial@ff0c0000 Model: Radxa ROCK Pi S Bootdev(atags): mmc 0 PartType: EFI ## Error: Can't overwrite "serial#" ## Error inserting "serial#" variable, errno=1 get part misc fail -1 boot mode: normal CLK: (sync kernel. arm: enter 816000 KHz, init 816000 KHz, kernel 0N/A) apll 816000 KHz dpll 1300000 KHz vpll0 1179647 KHz vpll1 903167 KHz aclk_bus 185714 KHz hclk_bus 100000 KHz pclk_bus 100000 KHz aclk_peri 185714 KHz hclk_peri 100000 KHz pclk_peri 100000 KHz hclk_audio 98303 KHz pclk_audio 98303 KHz Net: eth0: ethernet@ff4e0000 Hit key to stop autoboot('CTRL+C'): 0 starting USB... USB0: Core Release: 3.10a USB1: USB EHCI 1.00 scanning bus 0 for devices... 1 USB Device(s) found scanning bus 1 for devices... 1 USB Device(s) found scanning usb for storage devices... 0 Storage Device(s) found Device 0: unknown device switch to partitions #0, OK mmc0 is current device Scanning mmc 0:1... Found U-Boot script /boot.scr reading /boot.scr 2641 bytes read in 5 ms (515.6 KiB/s) ## Executing script at 00500000 Boot script loaded from mmc 0 reading /uEnv.txt 317 bytes read in 3 ms (102.5 KiB/s) reading /initrd.img-4.4.143-65-rockchip-g58431d38f8f3 8482442 bytes read in 368 ms (22 MiB/s) reading /vmlinuz-4.4.143-65-rockchip-g58431d38f8f3 10663944 bytes read in 464 ms (21.9 MiB/s) reading /dtbs/4.4.143-65-rockchip-g58431d38f8f3/rockchip/rk3308-rock-pi-s.dtb 63554 bytes read in 11 ms (5.5 MiB/s) reading /dtbs/4.4.143-65-rockchip-g58431d38f8f3/rockchip/overlay/rk3308-uart0.dtbo 382 bytes read in 15 ms (24.4 KiB/s) Applying kernel provided DT overlay rk3308-uart0.dtbo reading /dtbs/4.4.143-65-rockchip-g58431d38f8f3/rockchip/overlay/rockchip-fixup.scr 1814 bytes read in 15 ms (117.2 KiB/s) Applying kernel provided DT fixup script (rockchip-fixup.scr) ## Executing script at 05000000 initrdsize = 0x816e8a ## Flattened Device Tree blob at 01f00000 Booting using the fdt blob at 0x1f00000 reserving fdt memory region: addr=1f00000 size=75000 Loading Ramdisk to 1ecef000, end 1f505e8a ... OK Loading Device Tree to 000000001ec77000, end 000000001eceefff ... OK Adding bank: 0x00200000 - 0x20000000 (size: 0x1fe00000) Starting kernel ... WARNING: suspend_mode_handler: Not support call: 0x4 [ 0.000000] Booting Linux on physical CPU 0x0 [ 0.000000] Initializing cgroup subsys cpuset [ 0.000000] Initializing cgroup subsys cpu [ 0.000000] Initializing cgroup subsys cpuacct [ 0.000000] Linux version 4.4.143-65-rockchip-g58431d38f8f3 (root@ffe6d6b57a26) (gcc version 7.3.1 20180425 [linaro-7.3-2018.05 revision d29120a424ecfbc167ef90065c0eeb7f91977701] (Linaro GCC 7.3-2018.05) ) #1 SMP PREEMPT Sat Aug 14 09:31:07 UTC 2021 [ 0.000000] Boot CPU: AArch64 Processor [410fd042] [ 0.000000] Reserved memory: failed to reserve memory for node 'drm-logo@00000000': base 0x0000000000000000, size 0 MiB [ 0.000000] psci: probing for conduit method from DT. [ 0.000000] psci: PSCIv1.0 detected in firmware. [ 0.000000] psci: Using standard PSCI v0.2 function IDs [ 0.000000] psci: MIGRATE_INFO_TYPE not supported. [ 0.000000] PERCPU: Embedded 19 pages/cpu @ffffffc01ff56000 s40344 r8192 d29288 u77824 [ 0.000000] Detected VIPT I-cache on CPU0 [ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 128520 [ 0.000000] Kernel command line: initrd=initrd.img-4.4.143-65-rockchip-g58431d38f8f3 root=UUID=d99ac41e-e8cc-4c73-a420-e71f15e42042 rootwait rw rootfstype=ext4 console=tty1 console=ttyS0,1500000n8 panic=10 consoleblank=0 loglevel=7 [ 0.000000] PID hash table entries: 2048 (order: 2, 16384 bytes) [ 0.000000] Dentry cache hash table entries: 65536 (order: 7, 524288 bytes) [ 0.000000] Inode-cache hash table entries: 32768 (order: 6, 262144 bytes) [ 0.000000] software IO TLB [mem 0x19c77000-0x1dc77000] (64MB) mapped at [ffffffc019c77000-ffffffc01dc76fff] [ 0.000000] Memory: 426856K/522240K available (6910K kernel code, 558K rwdata, 2492K rodata, 384K init, 522K bss, 95384K reserved, 0K cma-reserved) [ 0.000000] Virtual kernel memory layout: [ 0.000000] modules : 0xffffff8000000000 - 0xffffff8008000000 ( 128 MB) [ 0.000000] vmalloc : 0xffffff8008000000 - 0xffffffbdbfff0000 ( 246 GB) [ 0.000000] .init : 0xffffff80089c0000 - 0xffffff8008a20000 ( 384 KB) [ 0.000000] .text : 0xffffff8008080000 - 0xffffff8008740000 ( 6912 KB) [ 0.000000] .rodata : 0xffffff8008740000 - 0xffffff80089c0000 ( 2560 KB) [ 0.000000] .data : 0xffffff8008a20000 - 0xffffff8008aab808 ( 559 KB) [ 0.000000] fixed : 0xffffffbffe7fd000 - 0xffffffbffec00000 ( 4108 KB) [ 0.000000] PCI I/O : 0xffffffbffee00000 - 0xffffffbfffe00000 ( 16 MB) [ 0.000000] memory : 0xffffffc000200000 - 0xffffffc020000000 ( 510 MB) [ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1 [ 0.000000] Preemptible hierarchical RCU implementation. [ 0.000000] Build-time adjustment of leaf fanout to 64. [ 0.000000] NR_IRQS:64 nr_irqs:64 0 [ 0.000000] GIC: Using split EOI/Deactivate mode [ 0.000000] Architected cp15 timer(s) running at 24.00MHz (phys). [ 0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x588fe9dc0, max_idle_ns: 440795202592 ns [ 0.000007] sched_clock: 56 bits at 24MHz, resolution 41ns, wraps every 4398046511097ns [ 0.001032] Console: colour dummy device 80x25 [ 0.002547] console [tty1] enabled [ 0.002602] Calibrating delay loop (skipped), value calculated using timer frequency.. 48.00 BogoMIPS (lpj=96000) [ 0.002682] pid_max: default: 32768 minimum: 301 [ 0.002800] Security Framework initialized [ 0.002847] AppArmor: AppArmor disabled by boot time parameter [ 0.002946] Mount-cache hash table entries: 1024 (order: 1, 8192 bytes) [ 0.002993] Mountpoint-cache hash table entries: 1024 (order: 1, 8192 bytes) [ 0.003840] Initializing cgroup subsys io [ 0.003901] Initializing cgroup subsys memory [ 0.003968] Initializing cgroup subsys devices [ 0.004015] Initializing cgroup subsys freezer [ 0.004061] Initializing cgroup subsys net_cls [ 0.004105] Initializing cgroup subsys perf_event [ 0.004151] Initializing cgroup subsys net_prio [ 0.004206] Initializing cgroup subsys hugetlb [ 0.004250] Initializing cgroup subsys pids [ 0.004619] sched-energy: CPU device node has no sched-energy-costs [ 0.004670] Invalid sched_group_energy for CPU0 [ 0.004708] CPU0: update cpu_capacity 1024 [ 0.004795] ASID allocator initialised with 65536 entries [ 0.039867] Detected VIPT I-cache on CPU1 [ 0.039927] Invalid sched_group_energy for CPU1 [ 0.039932] CPU1: update cpu_capacity 1024 [ 0.039937] CPU1: Booted secondary processor [410fd042] [ 0.051893] Detected VIPT I-cache on CPU2 [ 0.051935] Invalid sched_group_energy for CPU2 [ 0.051940] CPU2: update cpu_capacity 1024 [ 0.051945] CPU2: Booted secondary processor [410fd042] [ 0.063939] Detected VIPT I-cache on CPU3 [ 0.063977] Invalid sched_group_energy for CPU3 [ 0.063981] CPU3: update cpu_capacity 1024 [ 0.063986] CPU3: Booted secondary processor [410fd042] [ 0.064065] Brought up 4 CPUs [ 0.064511] SMP: Total of 4 processors activated. [ 0.064557] CPU: All CPU(s) started at EL2 [ 0.064742] Invalid sched_group_energy for CPU3 [ 0.064787] Invalid sched_group_energy for Cluster3 [ 0.064826] Invalid sched_group_energy for CPU2 [ 0.064864] Invalid sched_group_energy for Cluster2 [ 0.064903] Invalid sched_group_energy for CPU1 [ 0.064941] Invalid sched_group_energy for Cluster1 [ 0.064978] Invalid sched_group_energy for CPU0 [ 0.065016] Invalid sched_group_energy for Cluster0 [ 0.065685] devtmpfs: initialized [ 0.083418] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 7645041785100000 ns [ 0.083524] futex hash table entries: 1024 (order: 4, 65536 bytes) [ 0.084084] pinctrl core: initialized pinctrl subsystem [ 0.085372] NET: Registered protocol family 16 [ 0.096093] cpuidle: using governor menu [ 0.096167] Registered FIQ tty driver [ 0.096520] vdso: 2 pages (1 code @ ffffff8008746000, 1 data @ ffffff8008a24000) [ 0.096618] hw-breakpoint: found 6 breakpoint and 4 watchpoint registers. [ 0.096883] DMA: preallocated 256 KiB pool for atomic allocations [ 0.100128] console [pstore-1] enabled [ 0.100176] pstore: Registered ramoops as persistent store backend [ 0.100222] ramoops: attached 0xf0000@0x110000, ecc: 0/0 [ 0.143795] vcc_1v8: regulator get failed, ret=-517 [ 0.144746] vcc_1v8_codec: regulator get failed, ret=-517 [ 0.145602] vcc_1v8: supplied by vcc_io [ 0.145717] vcc_1v8_codec: supplied by vcc_io [ 0.148028] SCSI subsystem initialized [ 0.148708] usbcore: registered new interface driver usbfs [ 0.148825] usbcore: registered new interface driver hub [ 0.148965] usbcore: registered new device driver usb [ 0.149165] media: Linux media interface: v0.10 [ 0.149256] Linux video capture interface: v2.00 [ 0.149402] pps_core: LinuxPPS API ver. 1 registered [ 0.149447] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it> [ 0.149541] PTP clock support registered [ 0.150772] Advanced Linux Sound Architecture Driver Initialized. [ 0.151545] Bluetooth: Core ver 2.21 [ 0.151634] NET: Registered protocol family 31 [ 0.151675] Bluetooth: HCI device and connection manager initialized [ 0.151727] Bluetooth: HCI socket layer initialized [ 0.151774] Bluetooth: L2CAP socket layer initialized [ 0.151847] Bluetooth: SCO socket layer initialized [ 0.152483] NetLabel: Initializing [ 0.152534] NetLabel: domain hash size = 128 [ 0.152574] NetLabel: protocols = UNLABELED CIPSOv4 [ 0.152696] NetLabel: unlabeled traffic allowed by default [ 0.153354] rockchip-cpuinfo cpuinfo: Serial : 3671c4b04d834f48 [ 0.154073] clocksource: Switched to clocksource arch_sys_counter [ 0.166456] thermal thermal_zone1: power_allocator: sustainable_power will be estimated [ 0.166550] missing polling-delay-passive property [ 0.166592] failed to build thermal zone soc_thermal: -22 [ 0.166992] NET: Registered protocol family 2 [ 0.167789] TCP established hash table entries: 4096 (order: 3, 32768 bytes) [ 0.167911] TCP bind hash table entries: 4096 (order: 4, 65536 bytes) [ 0.168034] TCP: Hash tables configured (established 4096 bind 4096) [ 0.168165] UDP hash table entries: 256 (order: 1, 8192 bytes) [ 0.168228] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes) [ 0.168524] NET: Registered protocol family 1 [ 0.169144] Trying to unpack rootfs image as initramfs... [ 0.357916] Freeing initrd memory: 8280K [ 0.358660] hw perfevents: enabled with armv8_cortex_a53 PMU driver, 7 counters available [ 0.362641] audit: initializing netlink subsys (disabled) [ 0.362771] audit: type=2000 audit(0.360:1): initialized [ 0.363624] HugeTLB registered 2 MB page size, pre-allocated 0 pages [ 0.373155] squashfs: version 4.0 (2009/01/31) Phillip Lougher [ 0.373989] fuse init (API version 7.23) [ 0.379207] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 247) [ 0.379464] io scheduler noop registered [ 0.379518] io scheduler deadline registered (default) [ 0.379735] io scheduler cfq registered [ 0.385277] dma-pl330 ff2c0000.dma-controller: Loaded driver for PL330 DMAC-241330 [ 0.385374] dma-pl330 ff2c0000.dma-controller: DBUFF-32x8bytes Num_Chans-6 Num_Peri-12 Num_Events-12 [ 0.387848] dma-pl330 ff2d0000.dma-controller: Loaded driver for PL330 DMAC-241330 [ 0.387940] dma-pl330 ff2d0000.dma-controller: DBUFF-128x8bytes Num_Chans-8 Num_Peri-20 Num_Events-16 [ 0.388355] rockchip-pvtm ff000000.grf:pmu-pvtm: failed to get rst 0 pmu [ 0.388536] rockchip-pvtm ff00c000.syscon:pvtm: failed to get rst 0 core [ 0.390166] Serial: 8250/16550 driver, 5 ports, IRQ sharing disabled [ 0.392501] console [ttyS0] disabled [ 0.392623] ff0a0000.serial: ttyS0 at MMIO 0xff0a0000 (irq = 11, base_baud = 1500000) is a 16550A [ 0.470084] console [ttyS0] enabled [ 0.471639] ff0e0000.serial: ttyS4 at MMIO 0xff0e0000 (irq = 12, base_baud = 5078125) is a 16550A [ 0.473500] [drm] Initialized drm 1.1.0 20060810 [ 0.476501] Unable to detect cache hierarchy for CPU 0 [ 0.478262] brd: module loaded [ 0.486154] loop: module loaded [ 0.486938] SCSI Media Changer driver v0.25 [ 0.489590] rk_gmac-dwmac ff4e0000.ethernet: clock input or output? (output). [ 0.490342] rk_gmac-dwmac ff4e0000.ethernet: Can not read property: tx_delay. [ 0.491014] rk_gmac-dwmac ff4e0000.ethernet: set tx_delay to 0x30 [ 0.491593] rk_gmac-dwmac ff4e0000.ethernet: Can not read property: rx_delay. [ 0.492261] rk_gmac-dwmac ff4e0000.ethernet: set rx_delay to 0x10 [ 0.492846] rk_gmac-dwmac ff4e0000.ethernet: integrated PHY? (no). [ 0.498673] rk_gmac-dwmac ff4e0000.ethernet: init for RMII [ 0.499315] stmmac - user ID: 0x10, Synopsys ID: 0x35 [ 0.499797] Ring mode enabled [ 0.500100] DMA HW capability register supported [ 0.500513] Normal descriptors [ 0.500864] RX Checksum Offload Engine supported (type 2) [ 0.501380] TX Checksum insertion supported [ 0.501788] Wake-Up On Lan supported [ 0.502217] Enable RX Mitigation via HW Watchdog Timer [ 0.623721] brian phy in rtl8201f_probe [ 0.632458] brian phy in rtl8201f_probe [ 0.635630] libphy: stmmac: probed [ 0.635976] eth%d: PHY ID 001cc816 at 0 IRQ POLL (stmmac-0:00) active [ 0.636583] eth%d: PHY ID 001cc816 at 1 IRQ POLL (stmmac-0:01) [ 0.638364] Rockchip WiFi SYS interface (V1.00) ... [ 0.639292] ff400000.usb supply vusb_d not found, using dummy regulator [ 0.640035] ff400000.usb supply vusb_a not found, using dummy regulator [ 0.870130] dwc2 ff400000.usb: EPs: 10, dedicated fifos, 972 entries in SPRAM [ 0.871385] dwc2 ff400000.usb: DWC OTG Controller [ 0.871884] dwc2 ff400000.usb: new USB bus registered, assigned bus number 1 [ 0.872590] dwc2 ff400000.usb: irq 20, io mem 0xff400000 [ 0.873292] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002 [ 0.873935] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1 [ 0.874675] usb usb1: Product: DWC OTG Controller [ 0.875132] usb usb1: Manufacturer: Linux 4.4.143-65-rockchip-g58431d38f8f3 dwc2_hsotg [ 0.875890] usb usb1: SerialNumber: ff400000.usb [ 0.877147] hub 1-0:1.0: USB hub found [ 0.877557] hub 1-0:1.0: 1 port detected [ 1.518187] phy phy-ff008000.syscon:usb2-phy@100.0: charger = USB_FLOATING_CHARGER [ 1.518988] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver [ 1.519615] ehci-platform: EHCI generic platform driver [ 1.523948] ehci-platform ff440000.usb: EHCI Host Controller [ 1.524753] ehci-platform ff440000.usb: new USB bus registered, assigned bus number 2 [ 1.525651] ehci-platform ff440000.usb: irq 21, io mem 0xff440000 [ 1.538103] ehci-platform ff440000.usb: USB 2.0 started, EHCI 1.00 [ 1.538889] usb usb2: New USB device found, idVendor=1d6b, idProduct=0002 [ 1.539534] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1 [ 1.540231] usb usb2: Product: EHCI Host Controller [ 1.540700] usb usb2: Manufacturer: Linux 4.4.143-65-rockchip-g58431d38f8f3 ehci_hcd [ 1.541442] usb usb2: SerialNumber: ff440000.usb [ 1.542614] hub 2-0:1.0: USB hub found [ 1.543022] hub 2-0:1.0: 1 port detected [ 1.544012] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver [ 1.544631] ohci-platform: OHCI generic platform driver [ 1.545515] ohci-platform ff450000.usb: Generic Platform OHCI controller [ 1.546466] ohci-platform ff450000.usb: new USB bus registered, assigned bus number 3 [ 1.547360] ohci-platform ff450000.usb: irq 22, io mem 0xff450000 [ 1.606304] usb usb3: New USB device found, idVendor=1d6b, idProduct=0001 [ 1.606950] usb usb3: New USB device strings: Mfr=3, Product=2, SerialNumber=1 [ 1.607647] usb usb3: Product: Generic Platform OHCI controller [ 1.608209] usb usb3: Manufacturer: Linux 4.4.143-65-rockchip-g58431d38f8f3 ohci_hcd [ 1.608951] usb usb3: SerialNumber: ff450000.usb [ 1.610135] hub 3-0:1.0: USB hub found [ 1.610547] hub 3-0:1.0: 1 port detected [ 1.613036] i2c /dev entries driver [ 1.613861] usbcore: registered new interface driver uvcvideo [ 1.614463] USB Video Class driver (1.1.1) [ 1.617209] rk_tsadcv2_temp_to_code: Invalid conversion table: code=4095, temperature=2147483647 [ 1.618377] rockchip-thermal ff1f0000.tsadc: tsadc is probed successfully! [ 1.620413] device-mapper: ioctl: 4.34.0-ioctl (2015-10-28) initialised: dm-devel@redhat.com [ 1.621251] Bluetooth: Virtual HCI driver ver 1.5 [ 1.622242] cpu cpu0: leakage=6 [ 1.622845] cpu cpu0: Failed to get pvtm [ 1.624484] cpu cpu0: l=0 h=55000 hyst=5000 l_limit=1200000000 h_limit=1008000000 [ 1.626711] Synopsys Designware Multimedia Card Interface Driver [ 1.628445] dwmmc_rockchip ff480000.dwmmc: IDMAC supports 32-bit address mode. [ 1.629185] dwmmc_rockchip ff480000.dwmmc: Using internal DMA controller. [ 1.629833] dwmmc_rockchip ff480000.dwmmc: Version ID is 270a [ 1.630495] dwmmc_rockchip ff480000.dwmmc: DW MMC controller at irq 23,32 bit host data width,256 deep fifo [ 1.646192] mmc_host mmc0: Bus speed (slot 0) = 400000Hz (slot req 400000Hz, actual 400000HZ div = 0) [ 1.663274] dwmmc_rockchip ff480000.dwmmc: 1 slots initialized [ 1.666263] dwmmc_rockchip ff490000.dwmmc: IDMAC supports 32-bit address mode. [ 1.667023] dwmmc_rockchip ff490000.dwmmc: Using internal DMA controller. [ 1.668695] dwmmc_rockchip ff490000.dwmmc: Version ID is 270a [ 1.671323] dwmmc_rockchip ff490000.dwmmc: DW MMC controller at irq 24,32 bit host data width,256 deep fifo [ 1.672324] dwmmc_rockchip ff490000.dwmmc: No vmmc regulator found [ 1.672925] dwmmc_rockchip ff490000.dwmmc: No vqmmc regulator found [ 1.686178] mmc_host mmc1: Bus speed (slot 0) = 400000Hz (slot req 400000Hz, actual 400000HZ div = 0) [ 1.696387] mmc_host mmc0: Bus speed (slot 0) = 50000000Hz (slot req 50000000Hz, actual 50000000HZ div = 0) [ 1.697588] mmc0: new high speed SDHC card at address 0007 [ 1.699060] mmcblk0: mmc0:0007 SD16G 14.5 GiB [ 1.702302] dwmmc_rockchip ff490000.dwmmc: 1 slots initialized [ 1.703647] dwmmc_rockchip ff4a0000.dwmmc: num-slots property not found, assuming 1 slot is available [ 1.704693] dwmmc_rockchip ff4a0000.dwmmc: IDMAC supports 32-bit address mode. [ 1.705450] dwmmc_rockchip ff4a0000.dwmmc: Using internal DMA controller. [ 1.706950] dwmmc_rockchip ff4a0000.dwmmc: Version ID is 270a [ 1.707620] dwmmc_rockchip ff4a0000.dwmmc: DW MMC controller at irq 25,32 bit host data width,256 deep fifo [ 1.708663] dwmmc_rockchip ff4a0000.dwmmc: No vmmc regulator found [ 1.709284] dwmmc_rockchip ff4a0000.dwmmc: No vqmmc regulator found [ 1.710516] dwmmc_rockchip ff4a0000.dwmmc: allocated mmc-pwrseq [ 1.713143] mmcblk0: p1 p2 [ 1.726296] mmc_host mmc2: Bus speed (slot 0) = 400000Hz (slot req 400000Hz, actual 400000HZ div = 0) [ 1.730157] mmc_host mmc1: Bus speed (slot 0) = 300000Hz (slot req 300000Hz, actual 300000HZ div = 0) [ 1.742360] dwmmc_rockchip ff4a0000.dwmmc: 1 slots initialized [ 1.747250] hidraw: raw HID events driver (C) Jiri Kosina [ 1.748176] dwmmc_rockchip ff4a0000.dwmmc: card claims to support voltages below defined range [ 1.749300] usbcore: registered new interface driver usbhid [ 1.749860] usbhid: USB HID core driver [ 1.750581] rockchip-dmc dmc: failed to get the count of devfreq-event in /dmc node [ 1.751659] rockchip-dmc dmc: Failed to get leakage [ 1.752299] rockchip-dmc dmc: Failed to get pvtm [ 1.753140] rockchip-dmc dmc: failed to get vop bandwidth to dmc rate [ 1.753779] rockchip-dmc dmc: failed to get vop pn to msch rl [ 1.754386] rockchip-dmc dmc: don't add devfreq feature [ 1.757320] rknandc_base v1.1 2017-01-11 [ 1.757991] rksfc_base v1.1 2016-01-08 [ 1.762889] mmc_host mmc2: Bus speed (slot 0) = 50000000Hz (slot req 50000000Hz, actual 50000000HZ div = 0) [ 1.763338] dummy_codec dummy-codec: Unable to get mclk [ 1.763804] rk3308-acodec ff560000.acodec: Don't need hp-ctl gpio [ 1.763861] rk3308-acodec ff560000.acodec: Don't need spk-ctl gpio [ 1.763915] rk3308-acodec ff560000.acodec: Don't need pa-drv gpio [ 1.763923] rk3308-acodec ff560000.acodec: De-pop as much as possible [ 1.764027] The acodec version is: b [ 1.768530] mmc2: new high speed SDIO card at address 0001 [ 1.770226] mmc_host mmc1: Bus speed (slot 0) = 200000Hz (slot req 200000Hz, actual 200000HZ div = 0) [ 1.814221] mmc_host mmc1: Bus speed (slot 0) = 100000Hz (slot req 100000Hz, actual 100000HZ div = 0) [ 1.823955] rk-multicodecs acodec-sound: rk3308-hifi <-> ff320000.i2s mapping ok [ 1.826017] input: rockchip,rk3308-acodec Headphones as /devices/platform/acodec-sound/sound/card1/input0 [ 1.827947] u32 classifier [ 1.828254] Netfilter messages via NETLINK v0.30. [ 1.828795] ip_set: protocol 6 [ 1.829387] ip_tables: (C) 2000-2006 Netfilter Core Team [ 1.829923] Initializing XFRM netlink socket [ 1.831050] NET: Registered protocol family 10 [ 1.832893] ip6_tables: (C) 2000-2006 Netfilter Core Team [ 1.833443] NET: Registered protocol family 17 [ 1.833902] NET: Registered protocol family 15 [ 1.834447] bridge: automatic filtering via arp/ip/ip6tables has been deprecated. Update your scripts to load br_netfilter if you need this. [ 1.834469] rk3308-acodec ff560000.acodec: Don't need to change dac_output: 0 [ 1.837117] Bridge firewalling registered [ 1.837692] Bluetooth: RFCOMM TTY layer initialized [ 1.838209] Bluetooth: RFCOMM socket layer initialized [ 1.838730] Bluetooth: RFCOMM ver 1.11 [ 1.839116] Bluetooth: HIDP (Human Interface Emulation) ver 1.2 [ 1.839682] Bluetooth: HIDP socket layer initialized [ 1.840162] 8021q: 802.1Q VLAN Support v1.8 [ 1.840609] [WLAN_RFKILL]: Enter rfkill_wlan_init [ 1.841673] [WLAN_RFKILL]: Enter rfkill_wlan_probe [ 1.842215] [WLAN_RFKILL]: wlan_platdata_parse_dt: wifi_chip_type = rtl8723ds [ 1.842885] [WLAN_RFKILL]: wlan_platdata_parse_dt: enable wifi power control. [ 1.843551] [WLAN_RFKILL]: wlan_platdata_parse_dt: wifi power controled by gpio. [ 1.844354] [WLAN_RFKILL]: wlan_platdata_parse_dt: get property: WIFI,host_wake_irq = 0, flags = 0. [ 1.845268] [WLAN_RFKILL]: rfkill_wlan_probe: init gpio [ 1.845772] [WLAN_RFKILL]: Exit rfkill_wlan_probe [ 1.846344] [BT_RFKILL]: Enter rfkill_rk_init [ 1.847310] [BT_RFKILL]: bluetooth_platdata_parse_dt: get property: uart_rts_gpios = 135. [ 1.848122] [BT_RFKILL]: bluetooth_platdata_parse_dt: get property: BT,power_gpio = 139. [ 1.848946] [BT_RFKILL]: bluetooth_platdata_parse_dt: get property: BT,wake_host_irq = 140. [ 1.849744] [BT_RFKILL]: bluetooth_platdata_parse_dt: clk_get failed!!!. [ 1.850484] [BT_RFKILL]: Request irq for bt wakeup host [ 1.851044] [BT_RFKILL]: ** disable irq [ 1.851642] [BT_RFKILL]: bt_default device registered. [ 1.852261] Key type dns_resolver registered [ 1.853186] flash vendor_init_thread! [ 1.853560] flash vendor storage:20170308 ret = -1 [ 1.854940] registered taskstats version 1 [ 1.889172] Key type encrypted registered [ 1.890882] hctosys: unable to open rtc device (rtc0) [ 1.912690] ALSA device list: [ 1.913032] #0: Loopback 1 [ 1.913333] #1: rockchip,rk3308-acodec [ 1.915166] Freeing unused kernel memory: 384K Loading, please wait... Starting version 245.4-4ubuntu3 Begin: Loading essential drivers ... done. Begin: Running /scripts/init-premount ... done. Begin: Mounting root file system ... Begin: Running /scripts/local-top ... done. Begin: Running /scripts/local-premount ... done. Warning: fsck not present, so skipping root file system [ 2.741753] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null) done. Begin: Running /scripts/local-bottom ... done. Begin: Running /scripts/init-bottom ... done. [ 3.557218] systemd[1]: System time before build time, advancing clock. [ 3.575831] cgroup: cgroup2: unknown option "nsdelegate" [ 3.595756] systemd[1]: systemd 245.4-4ubuntu3 running in system mode. (+PAM +AUDIT +SELINUX +IMA +APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ +LZ4 +SECCOMP +BLKID +ELFUTILS +KMOD +IDN2 -IDN +PCRE2 default-hierarchy=hybrid) [ 3.599920] systemd[1]: Detected architecture arm64. Welcome to Ubuntu 20.04 LTS! [ 3.631826] systemd[1]: Set hostname to <rockpis>. [ 4.157176] systemd[1]: /lib/systemd/system/dbus.socket:5: ListenStream= references a path below legacy directory /var/run/, updating /var/run/dbus/system_bus_socket → /run/dbus/system_bus_socket; please update the unit file accordingly. [ 4.431921] random: systemd: uninitialized urandom read (16 bytes read, 46 bits of entropy available) [ 4.433109] systemd[1]: system-getty.slice: unit configures an IP firewall, but the local system does not support BPF/cgroup firewalling. [ 4.434371] systemd[1]: (This warning is only shown for the first unit using IP firewalling.) [ 4.438646] systemd[1]: Created slice system-getty.slice. [ OK ] Created slice system-getty.slice. [ 4.446489] random: systemd: uninitialized urandom read (16 bytes read, 46 bits of entropy available) [ 4.448865] systemd[1]: Created slice system-modprobe.slice. [ OK ] Created slice system-modprobe.slice. [ 4.458478] random: systemd: uninitialized urandom read (16 bytes read, 46 bits of entropy available) [ 4.460856] systemd[1]: Created slice system-serial\x2dgetty.slice. [ OK ] Created slice system-serial\x2dgetty.slice. [ 4.470458] random: systemd: uninitialized urandom read (16 bytes read, 46 bits of entropy available) [ 4.472694] systemd[1]: Created slice User and Session Slice. [ OK ] Created slice User and Session Slice. [ 4.482520] random: systemd: uninitialized urandom read (16 bytes read, 46 bits of entropy available) [ 4.483737] systemd[1]: Started Dispatch Password Requests to Console Directory Watch. [ OK ] Started Dispatch Password …ts to Console Directory Watch. [ 4.485900] random: systemd: uninitialized urandom read (16 bytes read, 47 bits of entropy available) [ 4.487195] systemd[1]: Started Forward Password Requests to Wall Directory Watch. [ OK ] Started Forward Password R…uests to Wall Directory Watch. [ 4.489810] random: systemd: uninitialized urandom read (16 bytes read, 47 bits of entropy available) [ 4.491414] systemd[1]: Set up automount Arbitrary Executable File Formats File System Automount Point. [ OK ] Set up automount Arbitrary…s File System Automount Point. [ 4.493799] random: systemd: uninitialized urandom read (16 bytes read, 47 bits of entropy available) [ 4.495115] systemd[1]: Reached target Local Encrypted Volumes. [ OK ] Reached target Local Encrypted Volumes. [ 4.502723] random: systemd: uninitialized urandom read (16 bytes read, 47 bits of entropy available) [ 4.503774] systemd[1]: Reached target Paths. [ OK ] Reached target Paths. [ 4.510557] random: systemd: uninitialized urandom read (16 bytes read, 47 bits of entropy available) [ 4.511604] systemd[1]: Reached target Remote File Systems. [ OK ] Reached target Remote File Systems. [ 4.518645] systemd[1]: Reached target Slices. [ OK ] Reached target Slices. [ 4.526747] systemd[1]: Reached target Swap. [ OK ] Reached target Swap. [ 4.535400] systemd[1]: Listening on initctl Compatibility Named Pipe. [ OK ] Listening on initctl Compatibility Named Pipe. [ 4.539505] systemd[1]: Listening on Journal Audit Socket. [ OK ] Listening on Journal Audit Socket. [ 4.547489] systemd[1]: Listening on Journal Socket (/dev/log). [ OK ] Listening on Journal Socket (/dev/log). [ 4.556094] systemd[1]: Listening on Journal Socket. [ OK ] Listening on Journal Socket. [ 4.564174] systemd[1]: Listening on udev Control Socket. [ OK ] Listening on udev Control Socket. [ 4.567545] systemd[1]: Listening on udev Kernel Socket. [ OK ] Listening on udev Kernel Socket. [ 4.579648] systemd[1]: Mounting Huge Pages File System... Mounting Huge Pages File System... [ 4.592632] systemd[1]: Mounting POSIX Message Queue File System... Mounting POSIX Message Queue File System... [ 4.604496] systemd[1]: Mounting Kernel Debug File System... Mounting Kernel Debug File System... [ 4.607618] systemd[1]: Condition check resulted in Kernel Trace File System being skipped. [ 4.619457] systemd[1]: Starting Journal Service... Starting Journal Service... [ 4.644763] systemd[1]: Starting Create list of static device nodes for the current kernel... Starting Create list of st…odes for the current kernel... [ 4.647448] systemd[1]: Condition check resulted in Load Kernel Module drm being skipped. [ 4.667427] systemd[1]: Condition check resulted in Set Up Additional Binary Formats being skipped. [ 4.688939] systemd[1]: Starting Load Kernel Modules... Starting Load Kernel Modules... [ 4.696990] systemd[1]: Starting Remount Root and Kernel File Systems... Starting Remount Root and Kernel File Systems... [ 4.705892] systemd[1]: Starting udev Coldplug all Devices... Starting udev Coldplug all Devices... [ 4.720602] systemd[1]: Mounted Huge Pages File System. [ OK ] Mounted Huge Pages File System. [ 4.727840] systemd[1]: Mounted POSIX Message Queue File System. [ OK ] Mounted POSIX Message Queue File System. [ 4.731549] systemd[1]: Mounted Kernel Debug File System. [ OK ] Mounted Kernel Debug File System. [ 4.736874] systemd[1]: Finished Create list of static device nodes for the current kernel. [ OK [ 4.738419] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null) ] Finished Create list of st… nodes for the current kernel. [ 4.746780] systemd[1]: Finished Remount Root and Kernel File Systems. [ OK ] Finished Remount Root and Kernel File Systems. [ 4.772392] systemd[1]: Condition check resulted in Rebuild Hardware Database being skipped. [ 4.777963] systemd[1]: Starting Platform Persistent Storage Archival... Starting Platform Persistent Storage Archival... [ 4.791947] systemd[1]: Starting Load/Save Random Seed... Starting Load/Save Random Seed... [ 4.804268] systemd[1]: Starting Create System Users... Starting Create System Users... [ 4.815410] systemd[1]: Started Journal Service. [ OK ] Started Journal Service. [ OK ] Finished Load Kernel Modules. Mounting FUSE Control File System... Mounting Kernel Configuration File System... [ 4.874227] vendor storage:20160801 ret = -1 Starting Flush Journal to Persistent Storage... Starting Apply Kernel Variables... [ OK ] Finished Platform Persistent Storage Archival. [ OK ] Finished Create System Users. [ 4.912441] systemd-journald[207]: Received client request to flush runtime journal. [ OK ] Mounted FUSE Control File System. [ OK ] Mounted Kernel Configuration File System. [ 4.924307] systemd-journald[207]: File /var/log/journal/399d3a6a0f6b42e1a92ca095d497da94/system.journal corrupted or uncleanly shut down, renaming and replacing. Starting Create Static Device Nodes in /dev... [ OK ] Finished Apply Kernel Variables. [ OK ] Finished udev Coldplug all Devices. [ OK ] Finished Flush Journal to Persistent Storage. [ OK ] Finished Create Static Device Nodes in /dev. [ OK ] Reached target Local File Systems (Pre). [ OK ] Set up automount boot.automount. [ OK ] Reached target Local File Systems. Starting Create Volatile Files and Directories... Starting udev Kernel Device Manager... [ OK ] Finished Create Volatile Files and Directories. Starting Network Name Resolution... Starting Network Time Synchronization... Starting Update UTMP about System Boot/Shutdown... [ OK ] Started udev Kernel Device Manager. [ OK ] Finished Update UTMP about System Boot/Shutdown. [ OK ] Reached target Sound Card. [ OK ] Found device /dev/ttyS0. [ OK ] Started Network Time Synchronization. [ OK ] Reached target System Initialization. [ OK ] Started Daily Cleanup of Temporary Directories. [ OK ] Reached target System Time Set. [ OK ] Reached target System Time Synchronized. [ OK ] Started Daily apt download activities. [ OK ] Started Daily apt upgrade and clean activities. [ OK ] Started Periodic ext4 Onli…ata Check for All Filesystems. [ OK ] Started Discard unused blocks once a week. [ OK ] Started Message of the Day. [ OK ] Reached target Timers. [ OK ] Listening on D-Bus System Message Bus Socket. [ OK ] Reached target Sockets. [ OK ] Reached target Basic System. [ OK ] Listening on Load/Save RF …itch Status /dev/rfkill Watch. Starting Bluetooth service... [ OK ] Started D-Bus System Message Bus. Starting Network Manager... Starting Remove Stale Onli…t4 Metadata Check Snapshots... Starting Install HCI UART Module... [ OK ] Started Set the CPU Frequency Scaling governor. Starting Resize root files…to fit available disk space... Starting Login Service... Starting WPA supplicant... Starting Load/Save RF Kill Switch Status... [ OK ] Finished Install HCI UART Module. [ OK ] Started Load/Save RF Kill Switch Status. [ OK ] Finished Remove Stale Onli…ext4 Metadata Check Snapshots. [ OK ] Started Network Name Resolution. [ OK ] Reached target Host and Network Name Lookups. [ OK ] Started Login Service. [ OK ] Started Bluetooth service. [ OK ] Started WPA supplicant. Starting Load RTL8723DS Bluetooth firmware... [ OK ] Started Load RTL8723DS Bluetooth firmware. [ OK ] Finished Load/Save Random Seed. Starting Hostname Service... [ OK ] Started Hostname Service. [ OK ] Started Network Manager. [ OK ] Reached target Network. Starting /etc/rc.local Compatibility... Starting Rockchip adb... Starting OpenBSD Secure Shell server... Starting Permit User Sessions... [ OK ] Started /etc/rc.local Compatibility. [ OK ] Finished Permit User Sessions. [ OK ] Started Getty on tty1. [ OK ] Started Serial Getty on ttyS0. [ OK ] Reached target Login Prompts. [ OK ] Reached target Bluetooth. Starting Network Manager Script Dispatcher Service... [ OK ] Started OpenBSD Secure Shell server. [ OK ] Started Network Manager Script Dispatcher Service. [ OK ] Started Rockchip adb. [ OK ] Reached target Multi-User System. [ OK ] Reached target Graphical Interface. Starting Update UTMP about System Runlevel Changes... [ OK ] Finished Update UTMP about System Runlevel Changes. Ubuntu 20.04 LTS rockpis ttyS0 rockpis login: [ OK ] Finished Resize root files…m to fit available disk space. rockpis login:

At this point I wanted to open an SSH session because the terminal window can be resized, but it is certainly possible to continue with the serial connection only. The assigned dynamic IP address is needed to open an SSH session and the easiest way to obtain it at this point is to log in over the serial connection.

rock Password: rock not shown on screen Welcome to Ubuntu 20.04 LTS (GNU/Linux 4.4.143-65-rockchip-g58431d38f8f3 aarch64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage The programs included with the Ubuntu system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. To run a command as administrator (user "root"), use "sudo <command>". See "man sudo_root" for details. rock@rockpis:~$ ip -4 a 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN group default qlen 1000 inet 192.168.3.140/24 brd 192.168.3.255 scope global dynamic noprefixroute eth0 valid_lft 1104sec preferred_lft 1104sec rock@rockpis:~$

The IP address was used before so the old SSH key had to be removed before I could open an SSH session.

michel@hp:~$ ssh rock@192.168.3.140 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ @ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY! Someone could be eavesdropping on you right now (man-in-the-middle attack)! It is also possible that a host key has just been changed. The fingerprint for the ECDSA key sent by the remote host is SHA256:L78C+TeI2ecHyFUx6ctz/aK5XuJ/PXgGqkpGUTf0uGg. Please contact your system administrator. Add correct host key in /home/michel/.ssh/known_hosts to get rid of this message. Offending ECDSA key in /home/michel/.ssh/known_hosts:77 remove with: ssh-keygen -f "/home/michel/.ssh/known_hosts" -R "192.168.3.140" ECDSA host key for 192.168.3.140 has changed and you have requested strict checking. Host key verification failed. michel@hp:~$ ssh-keygen -f "/home/michel/.ssh/known_hosts" -R "192.168.3.140" # Host 192.168.3.140 found: line 77 /home/michel/.ssh/known_hosts updated. Original contents retained as /home/michel/.ssh/known_hosts.old michel@hp:~$ ssh rock@192.168.3.140 The authenticity of host '192.168.3.140 (192.168.3.140)' can't be established. ECDSA key fingerprint is SHA256:L78C+TeI2ecHyFUx6ctz/aK5XuJ/PXgGqkpGUTf0uGg. Are you sure you want to continue connecting (yes/no/[fingerprint])? yes Warning: Permanently added '192.168.3.140' (ECDSA) to the list of known hosts. rock@192.168.3.140's password: Welcome to Ubuntu 20.04 LTS (GNU/Linux 4.4.143-65-rockchip-g58431d38f8f3 aarch64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage Last login: Mon Jun 20 06:15:53 2022 To run a command as administrator (user "root"), use "sudo <command>". See "man sudo_root" for details.

It is always a good idea to change the default password

rock@rockpis:~$ passwd Changing password for rock. Current password: rock not shown on screen New password: ******** not shown on screen Retype new password: ******** not shown on screen passwd: password updated successfully

I had a quick look at the main services running on the board.

rock@rockpis:~$ sudo systemctl status [sudo] password for rock: ● rockpis State: running Jobs: 0 queued Failed: 0 units Since: Thu 1970-01-01 00:00:03 UTC; 52 years 5 months ago CGroup: / ├─init.scope │ └─1 /sbin/init ├─system.slice │ ├─dbus.service │ │ └─254 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only │ ├─wpa_supplicant.service │ │ └─262 /sbin/wpa_supplicant -u -s -O /run/wpa_supplicant │ ├─rockchip-adbd.service │ │ └─332 /usr/local/bin/adbd │ ├─systemd-journald.service │ │ └─207 /lib/systemd/systemd-journald │ ├─systemd-resolved.service │ │ └─234 /lib/systemd/systemd-resolved │ ├─systemd-timesyncd.service │ │ └─235 /lib/systemd/systemd-timesyncd │ ├─ssh.service │ │ └─337 sshd: /usr/sbin/sshd -D [listener] 0 of 10-100 startups │ ├─systemd-logind.service │ │ └─261 /lib/systemd/systemd-logind │ ├─system-getty.slice │ │ └─getty@tty1.service │ │ └─304 /sbin/agetty -o -p -- \u --noclear tty1 linux │ ├─systemd-udevd.service │ │ └─233 /lib/systemd/systemd-udevd │ ├─rtl8723ds-btfw-load.service │ │ └─293 /usr/bin/rtk_hciattach -n -s 115200 /dev/ttyS4 rtk_h5 & │ ├─NetworkManager.service │ │ └─255 /usr/sbin/NetworkManager --no-daemon │ └─bluetooth.service │ └─253 /usr/lib/bluetooth/bluetoothd └─user.slice └─user-1000.slice ├─user@1000.service … │ └─init.scope │ ├─552 /lib/systemd/systemd --user │ └─553 (sd-pam) ├─session-c1.scope │ ├─307 /bin/login -p -- │ └─557 -bash └─session-c2.scope ├─565 sshd: rock [priv] ├─579 sshd: rock@pts/0 ├─580 -bash ├─585 sudo systemctl status ├─586 systemctl status └─587 pager

That confirms that adbd is started, that network management is under the perview of NetworkManager and that the avahi service is not started; actually it is not even installed. If you use vim (vi) then it will not matter, but I was a bit surprised to see that my goto editor, nano, was not available. It was simple to install it.

rock@rockpis:~$ nano -bash: nano: command not found rock@rockpis:~$ sudo apt update Get:1 http://apt.radxa.com/focal-stable focal InRelease [2359 B] ... Fetched 21.2 MB in 13s (1647 kB/s) Reading package lists... Done Building dependency tree Reading state information... Done 142 packages can be upgraded. Run 'apt list --upgradable' to see them. rock@rockpis:~$ sudo apt install nano Reading package lists... Done Building dependency tree Reading state information... Done Suggested packages: hunspell The following NEW packages will be installed: nano 0 upgraded, 1 newly installed, 0 to remove and 142 not upgraded. Need to get 261 kB of archives. After this operation, 868 kB of additional disk space will be used. Get:1 http://ports.ubuntu.com/ubuntu-ports focal/main arm64 nano arm64 4.8-1ubuntu1 [261 kB] Fetched 261 kB in 1s (310 kB/s) debconf: delaying package configuration, since apt-utils is not installed Selecting previously unselected package nano. (Reading database ... 32545 files and directories currently installed.) Preparing to unpack .../nano_4.8-1ubuntu1_arm64.deb ... Unpacking nano (4.8-1ubuntu1) ... Setting up nano (4.8-1ubuntu1) ... update-alternatives: using /bin/nano to provide /usr/bin/editor (editor) in auto mode update-alternatives: using /bin/nano to provide /usr/bin/pico (pico) in auto mode

Clearly with 142 packages that should be upgraded, I should get on with that task quickly. However, having learned my lesson with Armbian, I wanted to test that it would be possible to use the hardware before investing more time into this project.

Initial Hardware Test toc

I started to monitor the kernel messages, powered up the 3D printer and connected a USB cable between it and the Rock Pi S and saw that the serial connection over USB was set up by the system. When I connected the webcam to the USB-C connector (with an USB-A to USB-C adapter), nothing showed up.

rock@rockpis:~$ dmesg -w ... [ 778.214661] usb 3-1: new full-speed USB device number 2 using ohci-platform [ 778.419721] usb 3-1: New USB device found, idVendor=1a86, idProduct=7523 [ 778.419772] usb 3-1: New USB device strings: Mfr=0, Product=2, SerialNumber=0 [ 778.419804] usb 3-1: Product: USB Serial [ 778.464444] usbcore: registered new interface driver usbserial [ 778.464600] usbcore: registered new interface driver usbserial_generic [ 778.464738] usbserial: USB Serial support registered for generic [ 778.468207] usbcore: registered new interface driver ch341 [ 778.468451] usbserial: USB Serial support registered for ch341-uart [ 778.468648] ch341 3-1:1.0: ch341-uart converter detected [ 778.492378] usb 3-1: ch341-uart converter now attached to ttyUSB0 CtrlC ^C rock@rockpis:~$

That should not be surprising, the USB-C port is a USB-OTG port not a USB host. There is a device tree overlay that should switch that role. It was more or less easy to spot among all the overlays for the RK3308.

rock@rockpis:~$ ls /boot/dtbs/4.4.143-65-rockchip-g58431d38f8f3/rockchip/overlay/ README.rockchip-overlays rk3308-uart0.dtbo i2c1-hym8563.dtbo rk3308-uart1.dtbo rk3308-console-on-uart0.dtbo rk3308-uart2.dtbo rk3308-console-on-uart1.dtbo rk3308-usb20-host.dtbo rk3308-console-on-uart2.dtbo rk3308-w1-gpio.dtbo rk3308-i2c0.dtbo rockchip-fixup.scr rk3308-i2c1.dtbo rockpis-dmic-8ch-pdm.dtbo rk3308-i2c2.dtbo rockpis-i2s-out.dtbo rk3308-i2c3.dtbo rockpis-spdif-out.dtbo rk3308-pwm1.dtbo rockpis-v11-spi2-waveshare35b-v2.dtbo rk3308-pwm2.dtbo rockpis-v11-spi2-waveshare35c.dtbo rk3308-pwm3.dtbo rockpis-v12-spi2-waveshare35b-v2.dtbo rk3308-spi-spidev.dtbo rockpis-v12-spi2-waveshare35c.dtbo

The next step was to add that overlay in the list of overlays loaded by the bootloader. Its configuration file is in the /boot directory.

rock@rockpis:~$ sudo nano /boot/uEnv.txt

verbosity=7 fdtfile=rockchip/rk3308-rock-pi-s.dtb console=ttyS0,1500000n8 overlays=rk3308-uart0 rk3308-usb20-host rootuuid=d99ac41e-e8cc-4c73-a420-e71f15e42042 initrdsize=0x816e8a kernelversion=4.4.143-65-rockchip-g58431d38f8f3 initrdimg=initrd.img-4.4.143-65-rockchip-g58431d38f8f3 kernelimg=vmlinuz-4.4.143-65-rockchip-g58431d38f8f3

Note how the .dtbo extension is not included in the overlay name. To verify that this works, disconnect the webcam, and reboot the machine. U-Boot should send the following message at the beginning of the boot process to the debug serial port of the Rock Pi S.

... reading /dtbs/4.4.143-65-rockchip-g58431d38f8f3/rockchip/overlay/rk3308-usb20-host.dtbo 295 bytes read in 10 ms (28.3 KiB/s) Applying kernel provided DT overlay rk3308-usb20-host.dtbo

Restart the interrupted SSH session, monitor the kernel messages and then reconnect the webcam.

rock@rockpis:~$ dmesg -w ... [ 93.612859] usb 1-1: new high-speed USB device number 2 using dwc2 [ 93.886014] usb 1-1: New USB device found, idVendor=045e, idProduct=0761 [ 93.886065] usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0 [ 93.886098] usb 1-1: Product: Microsoft® LifeCam VX-2000 [ 93.886128] usb 1-1: Manufacturer: Microsoft [ 93.894661] uvcvideo: Found UVC 1.00 device Microsoft® LifeCam VX-2000 (045e:0761) [ 93.899279] input: Microsoft® LifeCam VX-2000 as /devices/platform/ff400000.usb/usb1/1-1/1-1:1.0/input/input1 [ 94.003056] usbcore: registered new interface driver snd-usb-audio CtrlC ^C rock@rockpis:~$ ls /dev/ttyUSB* /dev/vid* /dev/ttyUSB0 /dev/video0 /dev/video1

Both the 3D printer and the webcam are connected and show up as peripheral devices. However there was a error message during the start of of the Linux kernel.

[FAILED] Failed to start Rockchip adb. See 'systemctl status rockchip-adbd.service' for details. rock@rockpis:~$ systemctl status rockchip-adbd.service ● rockchip-adbd.service - Rockchip adb Loaded: loaded (/lib/systemd/system/rockchip-adbd.service; enabled; vendor preset: enabled) Active: failed (Result: exit-code) since Wed 2022-06-22 01:11:36 ADT; 5min ago Docs: https://wiki.radxa.com/Template:Rockpi_apt Process: 280 ExecStart=/etc/init.d/adbd.sh start (code=exited, status=1/FAILURE)

That makes sense. Now that the USB port mode has been changed and it is now a host it can no longer be used as a "debug" peripheral. The way to get rid of the error message is to disable the adbd service.

rock@rockpis:~$ sudo systemctl disable rockchip-adbd.service Removed /etc/systemd/system/multi-user.target.wants/rockchip-adbd.service.

It should now be possible to install the two packages that will allow for remote control and monitoring of the 3D printer. However, there is necessary and optional housekeeping that should be done before, and I also want to enable Wi-Fi.

Necessary Housekeeping toc

A couple of necessary steps when installing a new OS have already been done: changing the default password and updating the list of packages. It is time to upgrade the system. I have found that that process will sometimes be interrupted by the installation of the time zone database. Might as well do that first.

Setting the Local Time Zone toc

The Ubuntu Focal image from Radxa is light and one reason is that it does not contain the time zone database so only UTC time is used on the system without it.

rock@rockpis:~$ sudo apt install tzdata Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: tzdata 0 upgraded, 1 newly installed, 0 to remove and 142 not upgraded. Need to get 294 kB of archives. After this operation, 4029 kB of additional disk space will be used. ... Configuring tzdata ------------------ Please select the geographic area in which you live. Subsequent configuration questions will narrow this down by presenting a list of cities, representing the time zones in which they are located. 1. Africa 3. Antarctica 5. Arctic 7. Atlantic 9. Indian 11. SystemV 13. Etc 2. America 4. Australia 6. Asia 8. Europe 10. Pacific 12. US Geographic area: 2 Please select the city or region corresponding to your time zone. 1. Adak 27. Blanc-Sablon 53. Ensenada 79. Juneau 105. New_York 131. Santarem 2. Anchorage 28. Boa_Vista 54. Fort_Nelson 80. Kentucky/Louisville 106. Nipigon 132. Santiago ... 18. Aruba 44. Danmarkshavn 70. Indiana/Marengo 96. Metlakatla 122. Puerto_Rico 148. Tijuana [More] Space 19. Asuncion 45. Dawson 71. Indiana/Petersburg 97. Mexico_City 123. Punta_Arenas 149. Toronto ... 26. Belize 52. El_Salvador 78. Jamaica 104. Nassau 130. Santa_Isabel 156. Yellowknife Time zone: 65 Current default time zone: 'America/Halifax' Local time is now: Tue Jun 21 20:24:29 ADT 2022. Universal Time is now: Tue Jun 21 23:24:29 UTC 2022. Run 'dpkg-reconfigure tzdata' if you wish to change it.

Of course, the choice of a time zone should correspond to the local situation of the user.

Update the OS toc

As already stated, it is important to keep the operating system up to date. This is especially true when staring with a fresh install based on an image that is already a number of months old.

rock@rockpis:~$ sudo apt update; sudo apt upgrade -y Hit:1 http://apt.radxa.com/focal-stable focal InRelease Hit:2 http://ports.ubuntu.com/ubuntu-ports focal InRelease Get:3 http://ports.ubuntu.com/ubuntu-ports focal-security InRelease [114 kB] Get:4 http://ports.ubuntu.com/ubuntu-ports focal-updates InRelease [114 kB] Get:5 http://ports.ubuntu.com/ubuntu-ports focal-backports InRelease [108 kB] Fetched 336 kB in 3s (104 kB/s) Reading package lists... Done Building dependency tree Reading state information... Done 142 packages can be upgraded. Run 'apt list --upgradable' to see them. Reading package lists... Done Building dependency tree Reading state information... Done Calculating upgrade... Done The following packages were automatically installed and are no longer required: binutils binutils-aarch64-linux-gnu binutils-common libbinutils libctf-nobfd0 libctf0 Use 'sudo apt autoremove' to remove them. The following NEW packages will be installed: libubootenv-tool libubootenv0.1 linux-firmware-image-4.4.143-68-rockchip-g222447a97264 linux-headers-4.4.143-68-rockchip-g222447a97264 linux-image-4.4.143-68-rockchip-g222447a97264 The following packages will be upgraded: apt base-files bash binutils binutils-aarch64-linux-gnu binutils-common bluez bsdutils busybox-initramfs cpio dbus dirmngr dpkg e2fsprogs fdisk gcc-10-base gnupg gnupg-l10n gnupg-utils gnupg2 gpg gpg-agent gpg-wks-client gpg-wks-server gpgconf gpgsm gpgv gzip initramfs-tools initramfs-tools-bin initramfs-tools-core isc-dhcp-client klibc-utils kmod libapparmor1 libapt-pkg6.0 libasound2 libasound2-data libbinutils libblkid1 libbluetooth3 libbrotli1 libc-bin libc6 libcom-err2 libcryptsetup12 libctf-nobfd0 libctf0 libcurl3-gnutls libdbus-1-3 libdns-export1109 libexpat1 libext2fs2 libfdisk1 libgcc-s1 libgcc1 libgcrypt20 libglib2.0-0 libgnutls30 libgssapi-krb5-2 libhogweed5 libisc-export1105 libjson-c4 libk5crypto3 libkeyutils1 libklibc libkmod2 libkrb5-3 libkrb5support0 libldap-2.4-2 libldap-common liblz4-1 liblzma5 libmm-glib0 libmount1 libnettle7 libnm0 libp11-kit0 libpam-modules libpam-modules-bin libpam-runtime libpam-systemd libpam0g libparted2 libpcre3 libperl5.30 libpolkit-agent-1-0 libpolkit-gobject-1-0 libprocps8 libpython3.8 libpython3.8-minimal libpython3.8-stdlib libsasl2-2 libsasl2-modules-db libseccomp2 libsepol1 libsmartcols1 libsqlite3-0 libss2 libssh-4 libssl1.1 libstdc++6 libsystemd0 libtdb1 libudev1 libuuid1 libzstd1 linux-4.4-rock-pi-s-latest linux-base login logsave lz4 mount network-manager openssh-client openssh-server openssh-sftp-server parted passwd perl perl-base perl-modules-5.30 policykit-1 procps rfkill rockchip-overlay ssh sudo systemd systemd-sysv systemd-timesyncd tar u-boot-tools ubuntu-keyring udev util-linux vim vim-common vim-runtime wpasupplicant xxd zlib1g 142 upgraded, 5 newly installed, 0 to remove and 0 not upgraded. Need to get 77.8 MB of archives. After this operation, 131 MB of additional disk space will be used. Get:1 http://apt.radxa.com/focal-stable focal/main arm64 linux-image-4.4.143-68-rockchip-g222447a97264 arm64 4.4.143-68-rockchip [10.7 MB] Get:2 http://ports.ubuntu.com/ubuntu-ports focal-security/universe arm64 libgcc1 arm64 1:10.3.0-1ubuntu1~20.04 [34.5 kB] Get:3 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 gcc-10-base arm64 10.3.0-1ubuntu1~20.04 [20.2 kB] Get:4 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libgcc-s1 arm64 10.3.0-1ubuntu1~20.04 [34.6 kB] Get:5 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libstdc++6 arm64 10.3.0-1ubuntu1~20.04 [461 kB] Get:6 http://apt.radxa.com/focal-stable focal/main arm64 linux-firmware-image-4.4.143-68-rockchip-g222447a97264 arm64 4.4.143-68-rockchip [53.3 kB] Get:7 http://apt.radxa.com/focal-stable focal/main arm64 linux-headers-4.4.143-68-rockchip-g222447a97264 arm64 4.4.143-68-rockchip [10.1 MB] Get:8 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libc6 arm64 2.31-0ubuntu9.9 [2281 kB] Get:9 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 base-files arm64 11ubuntu5.5 [60.4 kB] Get:10 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 bash arm64 5.0-6ubuntu1.2 [603 kB] Get:11 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 bsdutils arm64 1:2.34-0.1ubuntu9.3 [60.1 kB] Get:12 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 tar arm64 1.30+dfsg-7ubuntu0.20.04.2 [227 kB] Get:13 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 dpkg arm64 1.19.7ubuntu3.2 [1112 kB] Get:14 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 gzip arm64 1.10-0ubuntu4.1 [92.8 kB] Get:15 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 login arm64 1:4.8.1-1ubuntu5.20.04.2 [218 kB] Get:16 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libperl5.30 arm64 5.30.0-9ubuntu0.2 [3772 kB] Get:17 http://apt.radxa.com/focal-stable focal/main arm64 linux-4.4-rock-pi-s-latest arm64 4.4.143-68-rockchip [1156 B] Get:18 http://apt.radxa.com/focal-stable focal/main arm64 rockchip-overlay all 3.0 [5072 B] Get:19 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 perl arm64 5.30.0-9ubuntu0.2 [224 kB] Get:20 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 perl-base arm64 5.30.0-9ubuntu0.2 [1392 kB] Get:21 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 perl-modules-5.30 all 5.30.0-9ubuntu0.2 [2738 kB] Get:22 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 zlib1g arm64 1:1.2.11.dfsg-2ubuntu1.3 [51.3 kB] Get:23 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libblkid1 arm64 2.34-0.1ubuntu9.3 [129 kB] Get:24 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libuuid1 arm64 2.34-0.1ubuntu9.3 [19.3 kB] Get:25 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libfdisk1 arm64 2.34-0.1ubuntu9.3 [160 kB] Get:26 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libmount1 arm64 2.34-0.1ubuntu9.3 [140 kB] Get:27 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libsmartcols1 arm64 2.34-0.1ubuntu9.3 [93.0 kB] Get:28 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 fdisk arm64 2.34-0.1ubuntu9.3 [114 kB] Get:29 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 util-linux arm64 2.34-0.1ubuntu9.3 [983 kB] Get:30 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libc-bin arm64 2.31-0ubuntu9.9 [508 kB] Get:31 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libgcrypt20 arm64 1.8.5-5ubuntu1.1 [349 kB] Get:32 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 lz4 arm64 1.9.2-2ubuntu0.20.04.1 [77.7 kB] Get:33 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 liblz4-1 arm64 1.9.2-2ubuntu0.20.04.1 [53.0 kB] Get:34 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 liblzma5 arm64 5.2.4-1ubuntu1.1 [88.1 kB] Get:35 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 bluez arm64 5.53-0ubuntu3.6 [895 kB] Get:36 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 udev arm64 245.4-4ubuntu3.17 [1321 kB] Get:37 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libudev1 arm64 245.4-4ubuntu3.17 [70.0 kB] Get:38 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libapparmor1 arm64 2.13.3-7ubuntu5.1 [32.9 kB] Get:39 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libexpat1 arm64 2.2.9-1ubuntu0.4 [62.6 kB] Get:40 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libdbus-1-3 arm64 1.12.16-2ubuntu2.2 [169 kB] Get:41 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 dbus arm64 1.12.16-2ubuntu2.2 [142 kB] Get:42 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libpcre3 arm64 2:8.39-12ubuntu0.1 [209 kB] Get:43 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libglib2.0-0 arm64 2.64.6-1~ubuntu20.04.4 [1200 kB] Get:44 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libssl1.1 arm64 1.1.1f-1ubuntu2.15 [1157 kB] Get:45 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libzstd1 arm64 1.4.4+dfsg-3ubuntu0.1 [216 kB] Get:46 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 kmod arm64 27-1ubuntu2.1 [89.7 kB] Get:47 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libkmod2 arm64 27-1ubuntu2.1 [41.9 kB] Get:48 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 systemd-sysv arm64 245.4-4ubuntu3.17 [10.3 kB] Get:49 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 systemd-timesyncd arm64 245.4-4ubuntu3.17 [26.2 kB] Get:50 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libpam0g arm64 1.3.1-5ubuntu4.3 [53.8 kB] Get:51 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libpam-modules-bin arm64 1.3.1-5ubuntu4.3 [39.8 kB] Get:52 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libpam-modules arm64 1.3.1-5ubuntu4.3 [252 kB] Get:53 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libpam-runtime all 1.3.1-5ubuntu4.3 [37.3 kB] Get:54 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libpam-systemd arm64 245.4-4ubuntu3.17 [175 kB] Get:55 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libjson-c4 arm64 0.13.1+dfsg-7ubuntu0.3 [28.3 kB] Get:56 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libcryptsetup12 arm64 2:2.2.2-3ubuntu2.4 [152 kB] Get:57 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libnettle7 arm64 3.5.1+really3.5.1-2ubuntu0.2 [124 kB] Get:58 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libhogweed5 arm64 3.5.1+really3.5.1-2ubuntu0.2 [135 kB] Get:59 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libp11-kit0 arm64 0.23.20-1ubuntu0.1 [177 kB] Get:60 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libgnutls30 arm64 3.6.13-2ubuntu1.6 [755 kB] Get:61 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libseccomp2 arm64 2.5.1-1ubuntu1~20.04.2 [41.4 kB] Get:62 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 mount arm64 2.34-0.1ubuntu9.3 [112 kB] Get:63 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 systemd arm64 245.4-4ubuntu3.17 [3495 kB] Get:64 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libsystemd0 arm64 245.4-4ubuntu3.17 [247 kB] Get:65 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libapt-pkg6.0 arm64 2.0.9 [763 kB] Get:66 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gpg-wks-client arm64 2.2.19-3ubuntu2.1 [89.3 kB] Get:67 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 dirmngr arm64 2.2.19-3ubuntu2.1 [310 kB] Get:68 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gnupg-utils arm64 2.2.19-3ubuntu2.1 [443 kB] Get:69 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gpg-wks-server arm64 2.2.19-3ubuntu2.1 [83.0 kB] Get:70 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gpg-agent arm64 2.2.19-3ubuntu2.1 [216 kB] Get:71 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gpg arm64 2.2.19-3ubuntu2.1 [442 kB] Get:72 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gpgconf arm64 2.2.19-3ubuntu2.1 [117 kB] Get:73 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gnupg-l10n all 2.2.19-3ubuntu2.1 [51.7 kB] Get:74 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gnupg all 2.2.19-3ubuntu2.1 [259 kB] Get:75 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gpgsm arm64 2.2.19-3ubuntu2.1 [199 kB] Get:76 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libsqlite3-0 arm64 3.31.1-4ubuntu0.3 [506 kB] Get:77 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libsasl2-modules-db arm64 2.1.27+dfsg-2ubuntu0.1 [14.9 kB] Get:78 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libsasl2-2 arm64 2.1.27+dfsg-2ubuntu0.1 [48.4 kB] Get:79 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libldap-common all 2.4.49+dfsg-2ubuntu1.9 [16.6 kB] Get:80 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libldap-2.4-2 arm64 2.4.49+dfsg-2ubuntu1.9 [145 kB] Get:81 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gpgv arm64 2.2.19-3ubuntu2.1 [184 kB] Get:82 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 ubuntu-keyring all 2020.02.11.4 [22.1 kB] Get:83 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 apt arm64 2.0.9 [1243 kB] Get:84 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 logsave arm64 1.45.5-2ubuntu1.1 [10.1 kB] Get:85 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 klibc-utils arm64 2.0.7-1ubuntu5.1 [98.8 kB] Get:86 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 initramfs-tools all 0.136ubuntu6.7 [9248 B] Get:87 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 initramfs-tools-core all 0.136ubuntu6.7 [47.8 kB] Get:88 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libext2fs2 arm64 1.45.5-2ubuntu1.1 [177 kB] Get:89 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 e2fsprogs arm64 1.45.5-2ubuntu1.1 [505 kB] Get:90 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libklibc arm64 2.0.7-1ubuntu5.1 [45.3 kB] Get:91 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 linux-base all 4.5ubuntu3.7 [17.6 kB] Get:92 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 busybox-initramfs arm64 1:1.30.1-4ubuntu6.4 [158 kB] Get:93 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 initramfs-tools-bin arm64 0.136ubuntu6.7 [10.7 kB] Get:94 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 cpio arm64 2.13+dfsg-2ubuntu0.3 [80.3 kB] Get:95 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 openssh-sftp-server arm64 1:8.2p1-4ubuntu0.5 [48.3 kB] Get:96 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libprocps8 arm64 2:3.3.16-1ubuntu2.3 [31.5 kB] Get:97 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 procps arm64 2:3.3.16-1ubuntu2.3 [229 kB] Get:98 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libcom-err2 arm64 1.45.5-2ubuntu1.1 [9248 B] Get:99 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libgssapi-krb5-2 arm64 1.17-6ubuntu4.1 [113 kB] Get:100 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libkrb5-3 arm64 1.17-6ubuntu4.1 [312 kB] Get:101 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libkrb5support0 arm64 1.17-6ubuntu4.1 [30.4 kB] Get:102 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libk5crypto3 arm64 1.17-6ubuntu4.1 [80.4 kB] Get:103 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libkeyutils1 arm64 1.6-6ubuntu1.1 [10.1 kB] Get:104 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 openssh-server arm64 1:8.2p1-4ubuntu0.5 [354 kB] Get:105 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 passwd arm64 1:4.8.1-1ubuntu5.20.04.2 [772 kB] Get:106 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 openssh-client arm64 1:8.2p1-4ubuntu0.5 [637 kB] Get:107 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 ssh all 1:8.2p1-4ubuntu0.5 [5084 B] Get:108 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libsepol1 arm64 3.0-1ubuntu0.1 [231 kB] Get:109 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libss2 arm64 1.45.5-2ubuntu1.1 [10.8 kB] Get:110 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libisc-export1105 arm64 1:9.11.16+dfsg-3~ubuntu1 [159 kB] Get:111 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libdns-export1109 arm64 1:9.11.16+dfsg-3~ubuntu1 [683 kB] Get:112 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 isc-dhcp-client arm64 4.4.1-2.1ubuntu5.20.04.2 [232 kB] Get:113 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libpython3.8 arm64 3.8.10-0ubuntu1~20.04.4 [1491 kB] Get:114 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libpython3.8-minimal arm64 3.8.10-0ubuntu1~20.04.4 [714 kB] Get:115 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libpython3.8-stdlib arm64 3.8.10-0ubuntu1~20.04.4 [1648 kB] Get:116 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 sudo arm64 1.8.31-1ubuntu1.2 [473 kB] Get:117 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 xxd arm64 2:8.1.2269-1ubuntu5.7 [49.5 kB] Get:118 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 vim arm64 2:8.1.2269-1ubuntu5.7 [1135 kB] Get:119 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 vim-runtime all 2:8.1.2269-1ubuntu5.7 [5872 kB] Get:120 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 vim-common all 2:8.1.2269-1ubuntu5.7 [85.0 kB] Get:121 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 parted arm64 3.3-4ubuntu0.20.04.1 [40.9 kB] Get:122 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libparted2 arm64 3.3-4ubuntu0.20.04.1 [149 kB] Get:123 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 policykit-1 arm64 0.105-26ubuntu1.3 [79.4 kB] Get:124 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libpolkit-agent-1-0 arm64 0.105-26ubuntu1.3 [14.2 kB] Get:125 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libpolkit-gobject-1-0 arm64 0.105-26ubuntu1.3 [37.4 kB] Get:126 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libctf0 arm64 2.34-6ubuntu1.3 [43.2 kB] Get:127 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 binutils-aarch64-linux-gnu arm64 2.34-6ubuntu1.3 [1987 kB] Get:128 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libbinutils arm64 2.34-6ubuntu1.3 [475 kB] Get:129 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 binutils arm64 2.34-6ubuntu1.3 [3356 B] Get:130 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 binutils-common arm64 2.34-6ubuntu1.3 [207 kB] Get:131 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libctf-nobfd0 arm64 2.34-6ubuntu1.3 [44.0 kB] Get:132 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libasound2 arm64 1.2.2-2.1ubuntu2.5 [304 kB] Get:133 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libasound2-data all 1.2.2-2.1ubuntu2.5 [20.1 kB] Get:134 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libbluetooth3 arm64 5.53-0ubuntu3.6 [59.4 kB] Get:135 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libbrotli1 arm64 1.0.7-6ubuntu0.1 [257 kB] Get:136 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libssh-4 arm64 0.9.3-2ubuntu2.2 [159 kB] Get:137 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libcurl3-gnutls arm64 7.68.0-1ubuntu2.11 [213 kB] Get:138 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libmm-glib0 arm64 1.16.6-2~20.04.1 [179 kB] Get:139 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 wpasupplicant arm64 2:2.9-1ubuntu4.3 [1090 kB] Get:140 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 network-manager arm64 1.22.10-1ubuntu2.3 [1689 kB] Get:141 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libnm0 arm64 1.22.10-1ubuntu2.3 [342 kB] Get:142 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 libtdb1 arm64 1.4.3-0ubuntu0.20.04.1 [43.2 kB] Get:143 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 u-boot-tools arm64 2021.01+dfsg-3ubuntu0~20.04.4 [156 kB] Get:144 http://ports.ubuntu.com/ubuntu-ports focal/universe arm64 libubootenv0.1 arm64 0.2-1 [9516 B] Get:145 http://ports.ubuntu.com/ubuntu-ports focal/universe arm64 libubootenv-tool arm64 0.2-1 [5360 B] Get:146 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 rfkill arm64 2.34-0.1ubuntu9.3 [22.0 kB] Get:147 http://ports.ubuntu.com/ubuntu-ports focal-updates/universe arm64 gnupg2 all 2.2.19-3ubuntu2.1 [4584 B] Fetched 77.8 MB in 10s (8192 kB/s) debconf: delaying package configuration, since apt-utils is not installed (Reading database ... 34527 files and directories currently installed.) Preparing to unpack .../libgcc1_1%3a10.3.0-1ubuntu1~20.04_arm64.deb ... Unpacking libgcc1 (1:10.3.0-1ubuntu1~20.04) over (1:10-20200411-0ubuntu1) ... Preparing to unpack .../gcc-10-base_10.3.0-1ubuntu1~20.04_arm64.deb ... Unpacking gcc-10-base:arm64 (10.3.0-1ubuntu1~20.04) over (10-20200411-0ubuntu1) ... Setting up gcc-10-base:arm64 (10.3.0-1ubuntu1~20.04) ... (Reading database ... 34527 files and directories currently installed.) Preparing to unpack .../libgcc-s1_10.3.0-1ubuntu1~20.04_arm64.deb ... Unpacking libgcc-s1:arm64 (10.3.0-1ubuntu1~20.04) over (10-20200411-0ubuntu1) ... Setting up libgcc-s1:arm64 (10.3.0-1ubuntu1~20.04) ... (Reading database ... 34527 files and directories currently installed.) Preparing to unpack .../libstdc++6_10.3.0-1ubuntu1~20.04_arm64.deb ... Unpacking libstdc++6:arm64 (10.3.0-1ubuntu1~20.04) over (10-20200411-0ubuntu1) ... Setting up libstdc++6:arm64 (10.3.0-1ubuntu1~20.04) ... (Reading database ... 34527 files and directories currently installed.) Preparing to unpack .../libc6_2.31-0ubuntu9.9_arm64.deb ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based fronte nd cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline Unpacking libc6:arm64 (2.31-0ubuntu9.9) over (2.31-0ubuntu9) ... Setting up libc6:arm64 (2.31-0ubuntu9.9) ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based fronte nd cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline (Reading database ... 34527 files and directories currently installed.) Preparing to unpack .../base-files_11ubuntu5.5_arm64.deb ... Warning: Stopping motd-news.service, but it can still be activated by: motd-news.timer Unpacking base-files (11ubuntu5.5) over (11ubuntu5) ... Setting up base-files (11ubuntu5.5) ... Installing new version of config file /etc/issue ... Installing new version of config file /etc/issue.net ... Installing new version of config file /etc/lsb-release ... Installing new version of config file /etc/update-motd.d/50-motd-news ... motd-news.service is a disabled or a static unit, not starting it. Removing obsolete conffile /etc/default/motd-news ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../bash_5.0-6ubuntu1.2_arm64.deb ... Unpacking bash (5.0-6ubuntu1.2) over (5.0-6ubuntu1) ... Setting up bash (5.0-6ubuntu1.2) ... update-alternatives: using /usr/share/man/man7/bash-builtins.7.gz to provide /us r/share/man/man7/builtins.7.gz (builtins.7.gz) in auto mode (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../bsdutils_1%3a2.34-0.1ubuntu9.3_arm64.deb ... Unpacking bsdutils (1:2.34-0.1ubuntu9.3) over (1:2.34-0.1ubuntu9) ... Setting up bsdutils (1:2.34-0.1ubuntu9.3) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../tar_1.30+dfsg-7ubuntu0.20.04.2_arm64.deb ... Unpacking tar (1.30+dfsg-7ubuntu0.20.04.2) over (1.30+dfsg-7) ... Setting up tar (1.30+dfsg-7ubuntu0.20.04.2) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../dpkg_1.19.7ubuntu3.2_arm64.deb ... Unpacking dpkg (1.19.7ubuntu3.2) over (1.19.7ubuntu3) ... Setting up dpkg (1.19.7ubuntu3.2) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../gzip_1.10-0ubuntu4.1_arm64.deb ... Unpacking gzip (1.10-0ubuntu4.1) over (1.10-0ubuntu4) ... Setting up gzip (1.10-0ubuntu4.1) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../login_1%3a4.8.1-1ubuntu5.20.04.2_arm64.deb ... Unpacking login (1:4.8.1-1ubuntu5.20.04.2) over (1:4.8.1-1ubuntu5) ... Setting up login (1:4.8.1-1ubuntu5.20.04.2) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../libperl5.30_5.30.0-9ubuntu0.2_arm64.deb ... Unpacking libperl5.30:arm64 (5.30.0-9ubuntu0.2) over (5.30.0-9build1) ... Preparing to unpack .../perl_5.30.0-9ubuntu0.2_arm64.deb ... Unpacking perl (5.30.0-9ubuntu0.2) over (5.30.0-9build1) ... Preparing to unpack .../perl-base_5.30.0-9ubuntu0.2_arm64.deb ... Unpacking perl-base (5.30.0-9ubuntu0.2) over (5.30.0-9build1) ... Setting up perl-base (5.30.0-9ubuntu0.2) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../perl-modules-5.30_5.30.0-9ubuntu0.2_all.deb ... Unpacking perl-modules-5.30 (5.30.0-9ubuntu0.2) over (5.30.0-9build1) ... Preparing to unpack .../zlib1g_1%3a1.2.11.dfsg-2ubuntu1.3_arm64.deb ... Unpacking zlib1g:arm64 (1:1.2.11.dfsg-2ubuntu1.3) over (1:1.2.11.dfsg-2ubuntu1) ... Setting up zlib1g:arm64 (1:1.2.11.dfsg-2ubuntu1.3) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../libblkid1_2.34-0.1ubuntu9.3_arm64.deb ... Unpacking libblkid1:arm64 (2.34-0.1ubuntu9.3) over (2.34-0.1ubuntu9) ... Setting up libblkid1:arm64 (2.34-0.1ubuntu9.3) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../libuuid1_2.34-0.1ubuntu9.3_arm64.deb ... Unpacking libuuid1:arm64 (2.34-0.1ubuntu9.3) over (2.34-0.1ubuntu9) ... Setting up libuuid1:arm64 (2.34-0.1ubuntu9.3) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../libfdisk1_2.34-0.1ubuntu9.3_arm64.deb ... Unpacking libfdisk1:arm64 (2.34-0.1ubuntu9.3) over (2.34-0.1ubuntu9) ... Preparing to unpack .../libmount1_2.34-0.1ubuntu9.3_arm64.deb ... Unpacking libmount1:arm64 (2.34-0.1ubuntu9.3) over (2.34-0.1ubuntu9) ... Setting up libmount1:arm64 (2.34-0.1ubuntu9.3) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../libsmartcols1_2.34-0.1ubuntu9.3_arm64.deb ... Unpacking libsmartcols1:arm64 (2.34-0.1ubuntu9.3) over (2.34-0.1ubuntu9) ... Setting up libsmartcols1:arm64 (2.34-0.1ubuntu9.3) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../fdisk_2.34-0.1ubuntu9.3_arm64.deb ... Unpacking fdisk (2.34-0.1ubuntu9.3) over (2.34-0.1ubuntu9) ... Preparing to unpack .../util-linux_2.34-0.1ubuntu9.3_arm64.deb ... Unpacking util-linux (2.34-0.1ubuntu9.3) over (2.34-0.1ubuntu9) ... Setting up util-linux (2.34-0.1ubuntu9.3) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../libc-bin_2.31-0ubuntu9.9_arm64.deb ... Unpacking libc-bin (2.31-0ubuntu9.9) over (2.31-0ubuntu9) ... Setting up libc-bin (2.31-0ubuntu9.9) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../libgcrypt20_1.8.5-5ubuntu1.1_arm64.deb ... Unpacking libgcrypt20:arm64 (1.8.5-5ubuntu1.1) over (1.8.5-5ubuntu1) ... Setting up libgcrypt20:arm64 (1.8.5-5ubuntu1.1) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../lz4_1.9.2-2ubuntu0.20.04.1_arm64.deb ... Unpacking lz4 (1.9.2-2ubuntu0.20.04.1) over (1.9.2-2) ... Preparing to unpack .../liblz4-1_1.9.2-2ubuntu0.20.04.1_arm64.deb ... Unpacking liblz4-1:arm64 (1.9.2-2ubuntu0.20.04.1) over (1.9.2-2) ... Setting up liblz4-1:arm64 (1.9.2-2ubuntu0.20.04.1) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../liblzma5_5.2.4-1ubuntu1.1_arm64.deb ... Unpacking liblzma5:arm64 (5.2.4-1ubuntu1.1) over (5.2.4-1) ... Setting up liblzma5:arm64 (5.2.4-1ubuntu1.1) ... (Reading database ... 34526 files and directories currently installed.) Preparing to unpack .../bluez_5.53-0ubuntu3.6_arm64.deb ... Unpacking bluez (5.53-0ubuntu3.6) over (5.53-0ubuntu3) ... Preparing to unpack .../udev_245.4-4ubuntu3.17_arm64.deb ... Unpacking udev (245.4-4ubuntu3.17) over (245.4-4ubuntu3) ... Preparing to unpack .../libudev1_245.4-4ubuntu3.17_arm64.deb ... Unpacking libudev1:arm64 (245.4-4ubuntu3.17) over (245.4-4ubuntu3) ... Setting up libudev1:arm64 (245.4-4ubuntu3.17) ... (Reading database ... 34527 files and directories currently installed.) Preparing to unpack .../libapparmor1_2.13.3-7ubuntu5.1_arm64.deb ... Unpacking libapparmor1:arm64 (2.13.3-7ubuntu5.1) over (2.13.3-7ubuntu5) ... Preparing to unpack .../libexpat1_2.2.9-1ubuntu0.4_arm64.deb ... Unpacking libexpat1:arm64 (2.2.9-1ubuntu0.4) over (2.2.9-1build1) ... Preparing to unpack .../libdbus-1-3_1.12.16-2ubuntu2.2_arm64.deb ... Unpacking libdbus-1-3:arm64 (1.12.16-2ubuntu2.2) over (1.12.16-2ubuntu2) ... Preparing to unpack .../dbus_1.12.16-2ubuntu2.2_arm64.deb ... Unpacking dbus (1.12.16-2ubuntu2.2) over (1.12.16-2ubuntu2) ... Preparing to unpack .../libpcre3_2%3a8.39-12ubuntu0.1_arm64.deb ... Unpacking libpcre3:arm64 (2:8.39-12ubuntu0.1) over (2:8.39-12build1) ... Setting up libpcre3:arm64 (2:8.39-12ubuntu0.1) ... (Reading database ... 34527 files and directories currently installed.) Preparing to unpack .../libglib2.0-0_2.64.6-1~ubuntu20.04.4_arm64.deb ... Unpacking libglib2.0-0:arm64 (2.64.6-1~ubuntu20.04.4) over (2.64.2-1~fakesync1) ... Preparing to unpack .../libssl1.1_1.1.1f-1ubuntu2.15_arm64.deb ... Unpacking libssl1.1:arm64 (1.1.1f-1ubuntu2.15) over (1.1.1f-1ubuntu2) ... Preparing to unpack .../libzstd1_1.4.4+dfsg-3ubuntu0.1_arm64.deb ... Unpacking libzstd1:arm64 (1.4.4+dfsg-3ubuntu0.1) over (1.4.4+dfsg-3) ... Setting up libzstd1:arm64 (1.4.4+dfsg-3ubuntu0.1) ... (Reading database ... 34527 files and directories currently installed.) Preparing to unpack .../kmod_27-1ubuntu2.1_arm64.deb ... Unpacking kmod (27-1ubuntu2.1) over (27-1ubuntu2) ... Preparing to unpack .../libkmod2_27-1ubuntu2.1_arm64.deb ... Unpacking libkmod2:arm64 (27-1ubuntu2.1) over (27-1ubuntu2) ... Preparing to unpack .../systemd-sysv_245.4-4ubuntu3.17_arm64.deb ... Unpacking systemd-sysv (245.4-4ubuntu3.17) over (245.4-4ubuntu3) ... Preparing to unpack .../systemd-timesyncd_245.4-4ubuntu3.17_arm64.deb ... Unpacking systemd-timesyncd (245.4-4ubuntu3.17) over (245.4-4ubuntu3) ... Preparing to unpack .../libpam0g_1.3.1-5ubuntu4.3_arm64.deb ... Unpacking libpam0g:arm64 (1.3.1-5ubuntu4.3) over (1.3.1-5ubuntu4) ... Setting up libpam0g:arm64 (1.3.1-5ubuntu4.3) ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based fronte nd cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline (Reading database ... 34527 files and directories currently installed.) Preparing to unpack .../libpam-modules-bin_1.3.1-5ubuntu4.3_arm64.deb ... Unpacking libpam-modules-bin (1.3.1-5ubuntu4.3) over (1.3.1-5ubuntu4) ... Setting up libpam-modules-bin (1.3.1-5ubuntu4.3) ... (Reading database ... 34529 files and directories currently installed.) Preparing to unpack .../libpam-modules_1.3.1-5ubuntu4.3_arm64.deb ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based fronte nd cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline Unpacking libpam-modules:arm64 (1.3.1-5ubuntu4.3) over (1.3.1-5ubuntu4) ... Setting up libpam-modules:arm64 (1.3.1-5ubuntu4.3) ... (Reading database ... 34533 files and directories currently installed.) Preparing to unpack .../libpam-runtime_1.3.1-5ubuntu4.3_all.deb ... Unpacking libpam-runtime (1.3.1-5ubuntu4.3) over (1.3.1-5ubuntu4) ... Setting up libpam-runtime (1.3.1-5ubuntu4.3) ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based fronte nd cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline (Reading database ... 34533 files and directories currently installed.) Preparing to unpack .../libpam-systemd_245.4-4ubuntu3.17_arm64.deb ... Unpacking libpam-systemd:arm64 (245.4-4ubuntu3.17) over (245.4-4ubuntu3) ... Preparing to unpack .../libjson-c4_0.13.1+dfsg-7ubuntu0.3_arm64.deb ... Unpacking libjson-c4:arm64 (0.13.1+dfsg-7ubuntu0.3) over (0.13.1+dfsg-7) ... Preparing to unpack .../libcryptsetup12_2%3a2.2.2-3ubuntu2.4_arm64.deb ... Unpacking libcryptsetup12:arm64 (2:2.2.2-3ubuntu2.4) over (2:2.2.2-3ubuntu2) ... Preparing to unpack .../libnettle7_3.5.1+really3.5.1-2ubuntu0.2_arm64.deb ... Unpacking libnettle7:arm64 (3.5.1+really3.5.1-2ubuntu0.2) over (3.5.1+really3.5.1-2) ... Setting up libnettle7:arm64 (3.5.1+really3.5.1-2ubuntu0.2) ... (Reading database ... 34533 files and directories currently installed.) Preparing to unpack .../libhogweed5_3.5.1+really3.5.1-2ubuntu0.2_arm64.deb ... Unpacking libhogweed5:arm64 (3.5.1+really3.5.1-2ubuntu0.2) over (3.5.1+really3.5.1-2) ... Setting up libhogweed5:arm64 (3.5.1+really3.5.1-2ubuntu0.2) ... (Reading database ... 34533 files and directories currently installed.) Preparing to unpack .../libp11-kit0_0.23.20-1ubuntu0.1_arm64.deb ... Unpacking libp11-kit0:arm64 (0.23.20-1ubuntu0.1) over (0.23.20-1build1) ... Setting up libp11-kit0:arm64 (0.23.20-1ubuntu0.1) ... (Reading database ... 34533 files and directories currently installed.) Preparing to unpack .../libgnutls30_3.6.13-2ubuntu1.6_arm64.deb ... Unpacking libgnutls30:arm64 (3.6.13-2ubuntu1.6) over (3.6.13-2ubuntu1) ... Setting up libgnutls30:arm64 (3.6.13-2ubuntu1.6) ... (Reading database ... 34533 files and directories currently installed.) Preparing to unpack .../libseccomp2_2.5.1-1ubuntu1~20.04.2_arm64.deb ... Unpacking libseccomp2:arm64 (2.5.1-1ubuntu1~20.04.2) over (2.4.3-1ubuntu1) ... Setting up libseccomp2:arm64 (2.5.1-1ubuntu1~20.04.2) ... (Reading database ... 34533 files and directories currently installed.) Preparing to unpack .../mount_2.34-0.1ubuntu9.3_arm64.deb ... Unpacking mount (2.34-0.1ubuntu9.3) over (2.34-0.1ubuntu9) ... Preparing to unpack .../systemd_245.4-4ubuntu3.17_arm64.deb ... Unpacking systemd (245.4-4ubuntu3.17) over (245.4-4ubuntu3) ... Preparing to unpack .../libsystemd0_245.4-4ubuntu3.17_arm64.deb ... Unpacking libsystemd0:arm64 (245.4-4ubuntu3.17) over (245.4-4ubuntu3) ... Setting up libsystemd0:arm64 (245.4-4ubuntu3.17) ... (Reading database ... 34534 files and directories currently installed.) Preparing to unpack .../libapt-pkg6.0_2.0.9_arm64.deb ... Unpacking libapt-pkg6.0:arm64 (2.0.9) over (2.0.2) ... Setting up libapt-pkg6.0:arm64 (2.0.9) ... (Reading database ... 34534 files and directories currently installed.) Preparing to unpack .../00-gpg-wks-client_2.2.19-3ubuntu2.1_arm64.deb ... Unpacking gpg-wks-client (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Preparing to unpack .../01-dirmngr_2.2.19-3ubuntu2.1_arm64.deb ... Unpacking dirmngr (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Preparing to unpack .../02-gnupg-utils_2.2.19-3ubuntu2.1_arm64.deb ... Unpacking gnupg-utils (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Preparing to unpack .../03-gpg-wks-server_2.2.19-3ubuntu2.1_arm64.deb ... Unpacking gpg-wks-server (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Preparing to unpack .../04-gpg-agent_2.2.19-3ubuntu2.1_arm64.deb ... Unpacking gpg-agent (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Preparing to unpack .../05-gpg_2.2.19-3ubuntu2.1_arm64.deb ... Unpacking gpg (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Preparing to unpack .../06-gpgconf_2.2.19-3ubuntu2.1_arm64.deb ... Unpacking gpgconf (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Preparing to unpack .../07-gnupg-l10n_2.2.19-3ubuntu2.1_all.deb ... Unpacking gnupg-l10n (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Preparing to unpack .../08-gnupg_2.2.19-3ubuntu2.1_all.deb ... Unpacking gnupg (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Preparing to unpack .../09-gpgsm_2.2.19-3ubuntu2.1_arm64.deb ... Unpacking gpgsm (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Preparing to unpack .../10-libsqlite3-0_3.31.1-4ubuntu0.3_arm64.deb ... Unpacking libsqlite3-0:arm64 (3.31.1-4ubuntu0.3) over (3.31.1-4) ... Preparing to unpack .../11-libsasl2-modules-db_2.1.27+dfsg-2ubuntu0.1_arm64.deb ... Unpacking libsasl2-modules-db:arm64 (2.1.27+dfsg-2ubuntu0.1) over (2.1.27+dfsg-2) ... Preparing to unpack .../12-libsasl2-2_2.1.27+dfsg-2ubuntu0.1_arm64.deb ... Unpacking libsasl2-2:arm64 (2.1.27+dfsg-2ubuntu0.1) over (2.1.27+dfsg-2) ... Preparing to unpack .../13-libldap-common_2.4.49+dfsg-2ubuntu1.9_all.deb ... Unpacking libldap-common (2.4.49+dfsg-2ubuntu1.9) over (2.4.49+dfsg-2ubuntu1) ... Preparing to unpack .../14-libldap-2.4-2_2.4.49+dfsg-2ubuntu1.9_arm64.deb ... Unpacking libldap-2.4-2:arm64 (2.4.49+dfsg-2ubuntu1.9) over (2.4.49+dfsg-2ubuntu1) ... Preparing to unpack .../15-gpgv_2.2.19-3ubuntu2.1_arm64.deb ... Unpacking gpgv (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Setting up gpgv (2.2.19-3ubuntu2.1) ... (Reading database ... 34534 files and directories currently installed.) Preparing to unpack .../ubuntu-keyring_2020.02.11.4_all.deb ... Unpacking ubuntu-keyring (2020.02.11.4) over (2020.02.11.2) ... Setting up ubuntu-keyring (2020.02.11.4) ... (Reading database ... 34534 files and directories currently installed.) Preparing to unpack .../archives/apt_2.0.9_arm64.deb ... Unpacking apt (2.0.9) over (2.0.2) ... Setting up apt (2.0.9) ... Removing obsolete conffile /etc/kernel/postinst.d/apt-auto-removal ... (Reading database ... 34533 files and directories currently installed.) Preparing to unpack .../logsave_1.45.5-2ubuntu1.1_arm64.deb ... Unpacking logsave (1.45.5-2ubuntu1.1) over (1.45.5-2ubuntu1) ... Preparing to unpack .../klibc-utils_2.0.7-1ubuntu5.1_arm64.deb ... Unpacking klibc-utils (2.0.7-1ubuntu5.1) over (2.0.7-1ubuntu5) ... Preparing to unpack .../initramfs-tools_0.136ubuntu6.7_all.deb ... Unpacking initramfs-tools (0.136ubuntu6.7) over (0.136ubuntu6) ... Preparing to unpack .../initramfs-tools-core_0.136ubuntu6.7_all.deb ... Unpacking initramfs-tools-core (0.136ubuntu6.7) over (0.136ubuntu6) ... Preparing to unpack .../libext2fs2_1.45.5-2ubuntu1.1_arm64.deb ... Unpacking libext2fs2:arm64 (1.45.5-2ubuntu1.1) over (1.45.5-2ubuntu1) ... Setting up libext2fs2:arm64 (1.45.5-2ubuntu1.1) ... (Reading database ... 34533 files and directories currently installed.) Preparing to unpack .../00-e2fsprogs_1.45.5-2ubuntu1.1_arm64.deb ... Unpacking e2fsprogs (1.45.5-2ubuntu1.1) over (1.45.5-2ubuntu1) ... Preparing to unpack .../01-libklibc_2.0.7-1ubuntu5.1_arm64.deb ... Unpacking libklibc:arm64 (2.0.7-1ubuntu5.1) over (2.0.7-1ubuntu5) ... Preparing to unpack .../02-linux-base_4.5ubuntu3.7_all.deb ... Unpacking linux-base (4.5ubuntu3.7) over (4.5ubuntu3) ... Preparing to unpack .../03-busybox-initramfs_1%3a1.30.1-4ubuntu6.4_arm64.deb ... Unpacking busybox-initramfs (1:1.30.1-4ubuntu6.4) over (1:1.30.1-4ubuntu6) ... Preparing to unpack .../04-initramfs-tools-bin_0.136ubuntu6.7_arm64.deb ... Unpacking initramfs-tools-bin (0.136ubuntu6.7) over (0.136ubuntu6) ... Preparing to unpack .../05-cpio_2.13+dfsg-2ubuntu0.3_arm64.deb ... Unpacking cpio (2.13+dfsg-2ubuntu0.3) over (2.13+dfsg-2) ... Preparing to unpack .../06-openssh-sftp-server_1%3a8.2p1-4ubuntu0.5_arm64.deb ... Unpacking openssh-sftp-server (1:8.2p1-4ubuntu0.5) over (1:8.2p1-4) ... Preparing to unpack .../07-libprocps8_2%3a3.3.16-1ubuntu2.3_arm64.deb ... Unpacking libprocps8:arm64 (2:3.3.16-1ubuntu2.3) over (2:3.3.16-1ubuntu2) ... Preparing to unpack .../08-procps_2%3a3.3.16-1ubuntu2.3_arm64.deb ... Unpacking procps (2:3.3.16-1ubuntu2.3) over (2:3.3.16-1ubuntu2) ... Preparing to unpack .../09-libcom-err2_1.45.5-2ubuntu1.1_arm64.deb ... Unpacking libcom-err2:arm64 (1.45.5-2ubuntu1.1) over (1.45.5-2ubuntu1) ... Preparing to unpack .../10-libgssapi-krb5-2_1.17-6ubuntu4.1_arm64.deb ... Unpacking libgssapi-krb5-2:arm64 (1.17-6ubuntu4.1) over (1.17-6ubuntu4) ... Preparing to unpack .../11-libkrb5-3_1.17-6ubuntu4.1_arm64.deb ... Unpacking libkrb5-3:arm64 (1.17-6ubuntu4.1) over (1.17-6ubuntu4) ... Preparing to unpack .../12-libkrb5support0_1.17-6ubuntu4.1_arm64.deb ... Unpacking libkrb5support0:arm64 (1.17-6ubuntu4.1) over (1.17-6ubuntu4) ... Preparing to unpack .../13-libk5crypto3_1.17-6ubuntu4.1_arm64.deb ... Unpacking libk5crypto3:arm64 (1.17-6ubuntu4.1) over (1.17-6ubuntu4) ... Preparing to unpack .../14-libkeyutils1_1.6-6ubuntu1.1_arm64.deb ... Unpacking libkeyutils1:arm64 (1.6-6ubuntu1.1) over (1.6-6ubuntu1) ... Preparing to unpack .../15-openssh-server_1%3a8.2p1-4ubuntu0.5_arm64.deb ... Unpacking openssh-server (1:8.2p1-4ubuntu0.5) over (1:8.2p1-4) ... Preparing to unpack .../16-passwd_1%3a4.8.1-1ubuntu5.20.04.2_arm64.deb ... Unpacking passwd (1:4.8.1-1ubuntu5.20.04.2) over (1:4.8.1-1ubuntu5) ... Setting up passwd (1:4.8.1-1ubuntu5.20.04.2) ... (Reading database ... 34534 files and directories currently installed.) Preparing to unpack .../openssh-client_1%3a8.2p1-4ubuntu0.5_arm64.deb ... Unpacking openssh-client (1:8.2p1-4ubuntu0.5) over (1:8.2p1-4) ... Preparing to unpack .../ssh_1%3a8.2p1-4ubuntu0.5_all.deb ... Unpacking ssh (1:8.2p1-4ubuntu0.5) over (1:8.2p1-4) ... Preparing to unpack .../libsepol1_3.0-1ubuntu0.1_arm64.deb ... Unpacking libsepol1:arm64 (3.0-1ubuntu0.1) over (3.0-1) ... Setting up libsepol1:arm64 (3.0-1ubuntu0.1) ... (Reading database ... 34534 files and directories currently installed.) Preparing to unpack .../00-libss2_1.45.5-2ubuntu1.1_arm64.deb ... Unpacking libss2:arm64 (1.45.5-2ubuntu1.1) over (1.45.5-2ubuntu1) ... Preparing to unpack .../01-libisc-export1105_1%3a9.11.16+dfsg-3~ubuntu1_arm64.deb ... Unpacking libisc-export1105:arm64 (1:9.11.16+dfsg-3~ubuntu1) over (1:9.11.16+dfsg-3~build1) ... Preparing to unpack .../02-libdns-export1109_1%3a9.11.16+dfsg-3~ubuntu1_arm64.deb ... Unpacking libdns-export1109 (1:9.11.16+dfsg-3~ubuntu1) over (1:9.11.16+dfsg-3~build1) ... Preparing to unpack .../03-isc-dhcp-client_4.4.1-2.1ubuntu5.20.04.2_arm64.deb ... Unpacking isc-dhcp-client (4.4.1-2.1ubuntu5.20.04.2) over (4.4.1-2.1ubuntu5) ... Preparing to unpack .../04-libpython3.8_3.8.10-0ubuntu1~20.04.4_arm64.deb ... Unpacking libpython3.8:arm64 (3.8.10-0ubuntu1~20.04.4) over (3.8.2-1ubuntu1) ... Preparing to unpack .../05-libpython3.8-minimal_3.8.10-0ubuntu1~20.04.4_arm64.deb ... find: ‘/usr/lib/python3’: No such file or directory Unpacking libpython3.8-minimal:arm64 (3.8.10-0ubuntu1~20.04.4) over (3.8.2-1ubuntu1) ... Preparing to unpack .../06-libpython3.8-stdlib_3.8.10-0ubuntu1~20.04.4_arm64.deb ... find: ‘/usr/lib/python3’: No such file or directory Unpacking libpython3.8-stdlib:arm64 (3.8.10-0ubuntu1~20.04.4) over (3.8.2-1ubuntu1) ... Preparing to unpack .../07-sudo_1.8.31-1ubuntu1.2_arm64.deb ... Unpacking sudo (1.8.31-1ubuntu1.2) over (1.8.31-1ubuntu1) ... Preparing to unpack .../08-xxd_2%3a8.1.2269-1ubuntu5.7_arm64.deb ... Unpacking xxd (2:8.1.2269-1ubuntu5.7) over (2:8.1.2269-1ubuntu5) ... Preparing to unpack .../09-vim_2%3a8.1.2269-1ubuntu5.7_arm64.deb ... Unpacking vim (2:8.1.2269-1ubuntu5.7) over (2:8.1.2269-1ubuntu5) ... Preparing to unpack .../10-vim-runtime_2%3a8.1.2269-1ubuntu5.7_all.deb ... Unpacking vim-runtime (2:8.1.2269-1ubuntu5.7) over (2:8.1.2269-1ubuntu5) ... Preparing to unpack .../11-vim-common_2%3a8.1.2269-1ubuntu5.7_all.deb ... Unpacking vim-common (2:8.1.2269-1ubuntu5.7) over (2:8.1.2269-1ubuntu5) ... Preparing to unpack .../12-parted_3.3-4ubuntu0.20.04.1_arm64.deb ... Unpacking parted (3.3-4ubuntu0.20.04.1) over (3.3-4) ... Preparing to unpack .../13-libparted2_3.3-4ubuntu0.20.04.1_arm64.deb ... Unpacking libparted2:arm64 (3.3-4ubuntu0.20.04.1) over (3.3-4) ... Preparing to unpack .../14-policykit-1_0.105-26ubuntu1.3_arm64.deb ... Unpacking policykit-1 (0.105-26ubuntu1.3) over (0.105-26ubuntu1) ... Preparing to unpack .../15-libpolkit-agent-1-0_0.105-26ubuntu1.3_arm64.deb ... Unpacking libpolkit-agent-1-0:arm64 (0.105-26ubuntu1.3) over (0.105-26ubuntu1) ... Preparing to unpack .../16-libpolkit-gobject-1-0_0.105-26ubuntu1.3_arm64.deb ... Unpacking libpolkit-gobject-1-0:arm64 (0.105-26ubuntu1.3) over (0.105-26ubuntu1) ... Preparing to unpack .../17-libctf0_2.34-6ubuntu1.3_arm64.deb ... Unpacking libctf0:arm64 (2.34-6ubuntu1.3) over (2.34-6ubuntu1) ... Preparing to unpack .../18-binutils-aarch64-linux-gnu_2.34-6ubuntu1.3_arm64.deb... Unpacking binutils-aarch64-linux-gnu (2.34-6ubuntu1.3) over (2.34-6ubuntu1) ... Preparing to unpack .../19-libbinutils_2.34-6ubuntu1.3_arm64.deb ... Unpacking libbinutils:arm64 (2.34-6ubuntu1.3) over (2.34-6ubuntu1) ... Preparing to unpack .../20-binutils_2.34-6ubuntu1.3_arm64.deb ... Unpacking binutils (2.34-6ubuntu1.3) over (2.34-6ubuntu1) ... Preparing to unpack .../21-binutils-common_2.34-6ubuntu1.3_arm64.deb ... Unpacking binutils-common:arm64 (2.34-6ubuntu1.3) over (2.34-6ubuntu1) ... Preparing to unpack .../22-libctf-nobfd0_2.34-6ubuntu1.3_arm64.deb ... Unpacking libctf-nobfd0:arm64 (2.34-6ubuntu1.3) over (2.34-6ubuntu1) ... Preparing to unpack .../23-libasound2_1.2.2-2.1ubuntu2.5_arm64.deb ... Unpacking libasound2:arm64 (1.2.2-2.1ubuntu2.5) over (1.2.2-2.1) ... Preparing to unpack .../24-libasound2-data_1.2.2-2.1ubuntu2.5_all.deb ... Unpacking libasound2-data (1.2.2-2.1ubuntu2.5) over (1.2.2-2.1) ... Preparing to unpack .../25-libbluetooth3_5.53-0ubuntu3.6_arm64.deb ... Unpacking libbluetooth3:arm64 (5.53-0ubuntu3.6) over (5.53-0ubuntu3) ... Preparing to unpack .../26-libbrotli1_1.0.7-6ubuntu0.1_arm64.deb ... Unpacking libbrotli1:arm64 (1.0.7-6ubuntu0.1) over (1.0.7-6build1) ... Preparing to unpack .../27-libssh-4_0.9.3-2ubuntu2.2_arm64.deb ... Unpacking libssh-4:arm64 (0.9.3-2ubuntu2.2) over (0.9.3-2ubuntu2) ... Preparing to unpack .../28-libcurl3-gnutls_7.68.0-1ubuntu2.11_arm64.deb ... Unpacking libcurl3-gnutls:arm64 (7.68.0-1ubuntu2.11) over (7.68.0-1ubuntu2) ... Preparing to unpack .../29-libmm-glib0_1.16.6-2~20.04.1_arm64.deb ... Unpacking libmm-glib0:arm64 (1.16.6-2~20.04.1) over (1.12.8-1) ... Preparing to unpack .../30-wpasupplicant_2%3a2.9-1ubuntu4.3_arm64.deb ... Unpacking wpasupplicant (2:2.9-1ubuntu4.3) over (2:2.9-1ubuntu4) ... Preparing to unpack .../31-network-manager_1.22.10-1ubuntu2.3_arm64.deb ... Unpacking network-manager (1.22.10-1ubuntu2.3) over (1.22.10-1ubuntu1) ... Preparing to unpack .../32-libnm0_1.22.10-1ubuntu2.3_arm64.deb ... Unpacking libnm0:arm64 (1.22.10-1ubuntu2.3) over (1.22.10-1ubuntu1) ... Preparing to unpack .../33-libtdb1_1.4.3-0ubuntu0.20.04.1_arm64.deb ... Unpacking libtdb1:arm64 (1.4.3-0ubuntu0.20.04.1) over (1.4.2-3build1) ... Preparing to unpack .../34-u-boot-tools_2021.01+dfsg-3ubuntu0~20.04.4_arm64.deb ... Unpacking u-boot-tools (2021.01+dfsg-3ubuntu0~20.04.4) over (2019.07+dfsg-1ubuntu6) ... Selecting previously unselected package libubootenv0.1:arm64. Preparing to unpack .../35-libubootenv0.1_0.2-1_arm64.deb ... Unpacking libubootenv0.1:arm64 (0.2-1) ... Selecting previously unselected package libubootenv-tool. Preparing to unpack .../36-libubootenv-tool_0.2-1_arm64.deb ... Unpacking libubootenv-tool (0.2-1) ... Selecting previously unselected package linux-image-4.4.143-68-rockchip-g222447a97264. Preparing to unpack .../37-linux-image-4.4.143-68-rockchip-g222447a97264_4.4.143-68-rockchip_arm64.deb ... Unpacking linux-image-4.4.143-68-rockchip-g222447a97264 (4.4.143-68-rockchip) ... Selecting previously unselected package linux-firmware-image-4.4.143-68-rockchip-g222447a97264. Preparing to unpack .../38-linux-firmware-image-4.4.143-68-rockchip-g222447a97264_4.4.143-68-rockchip_arm64.deb ... Unpacking linux-firmware-image-4.4.143-68-rockchip-g222447a97264 (4.4.143-68-rockchip) ... Selecting previously unselected package linux-headers-4.4.143-68-rockchip-g222447a97264. Preparing to unpack .../39-linux-headers-4.4.143-68-rockchip-g222447a97264_4.4.143-68-rockchip_arm64.deb ... Unpacking linux-headers-4.4.143-68-rockchip-g222447a97264 (4.4.143-68-rockchip)... Preparing to unpack .../40-linux-4.4-rock-pi-s-latest_4.4.143-68-rockchip_arm64.deb ... Unpacking linux-4.4-rock-pi-s-latest (4.4.143-68-rockchip) over (4.4.143-65-rockchip) ... Preparing to unpack .../41-rfkill_2.34-0.1ubuntu9.3_arm64.deb ... Unpacking rfkill (2.34-0.1ubuntu9.3) over (2.34-0.1ubuntu9) ... Preparing to unpack .../42-rockchip-overlay_3.0_all.deb ... Unpacking rockchip-overlay (3.0) over (2.9) ... Preparing to unpack .../43-gnupg2_2.2.19-3ubuntu2.1_all.deb ... Unpacking gnupg2 (2.2.19-3ubuntu2.1) over (2.2.19-3ubuntu2) ... Setting up libexpat1:arm64 (2.2.9-1ubuntu0.4) ... Setting up cpio (2.13+dfsg-2ubuntu0.3) ... Setting up libkeyutils1:arm64 (1.6-6ubuntu1.1) ... Setting up libapparmor1:arm64 (2.13.3-7ubuntu5.1) ... Setting up linux-base (4.5ubuntu3.7) ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based fronte nd cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline Setting up rockchip-overlay (3.0) ... Remove two files, hdmi.rules and hdmi-toggle Setting up perl-modules-5.30 (5.30.0-9ubuntu0.2) ... Setting up libgcc1 (1:10.3.0-1ubuntu1~20.04) ... Setting up libglib2.0-0:arm64 (2.64.6-1~ubuntu20.04.4) ... No schema files found: doing nothing. Setting up libtdb1:arm64 (1.4.3-0ubuntu0.20.04.1) ... Setting up libssl1.1:arm64 (1.1.1f-1ubuntu2.15) ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline Setting up libbrotli1:arm64 (1.0.7-6ubuntu0.1) ... Setting up libsqlite3-0:arm64 (3.31.1-4ubuntu0.3) ... Setting up binutils-common:arm64 (2.34-6ubuntu1.3) ... Setting up libctf-nobfd0:arm64 (2.34-6ubuntu1.3) ... Setting up libcom-err2:arm64 (1.45.5-2ubuntu1.1) ... Setting up libldap-common (2.4.49+dfsg-2ubuntu1.9) ... Setting up xxd (2:8.1.2269-1ubuntu5.7) ... Setting up libkrb5support0:arm64 (1.17-6ubuntu4.1) ... Setting up libsasl2-modules-db:arm64 (2.1.27+dfsg-2ubuntu0.1) ... Setting up libasound2-data (1.2.2-2.1ubuntu2.5) ... Setting up linux-firmware-image-4.4.143-68-rockchip-g222447a97264 (4.4.143-68-rockchip) ... Setting up libklibc:arm64 (2.0.7-1ubuntu5.1) ... Setting up libisc-export1105:arm64 (1:9.11.16+dfsg-3~ubuntu1) ... Setting up libubootenv0.1:arm64 (0.2-1) ... Setting up vim-common (2:8.1.2269-1ubuntu5.7) ... Setting up linux-image-4.4.143-68-rockchip-g222447a97264 (4.4.143-68-rockchip) ... update-initramfs: Generating /boot/initrd.img-4.4.143-68-rockchip-g222447a97264 Find /boot/uEnv.txt and will update it. installing initrd size: 0x8cedfc installing kernel version: 4.4.143-68-rockchip-g222447a97264 Kernel configuration : earlyprintk console=ttyFIQ0,1500000n8 rw init=/sbin/init rootfstype=ext4 rootwait root=UUID=d99ac41e-e8cc-4c73-a420-e71f15e42042 Creating new extlinux.conf... Installing new extlinux.conf... Find /boot/uEnv.txt and will update it. installing initrd size: 0x8cedfc installing kernel version: 4.4.143-68-rockchip-g222447a97264 Setting up gnupg-l10n (2.2.19-3ubuntu2.1) ... Setting up libdbus-1-3:arm64 (1.12.16-2ubuntu2.2) ... Setting up dbus (1.12.16-2ubuntu2.2) ... A reboot is required to replace the running dbus-daemon. Please reboot the system when convenient. Setting up rfkill (2.34-0.1ubuntu9.3) ... Setting up libss2:arm64 (1.45.5-2ubuntu1.1) ... Setting up sudo (1.8.31-1ubuntu1.2) ... Setting up libk5crypto3:arm64 (1.17-6ubuntu4.1) ... Setting up busybox-initramfs (1:1.30.1-4ubuntu6.4) ... Setting up libnm0:arm64 (1.22.10-1ubuntu2.3) ... Setting up logsave (1.45.5-2ubuntu1.1) ... Setting up libsasl2-2:arm64 (2.1.27+dfsg-2ubuntu0.1) ... Setting up lz4 (1.9.2-2ubuntu0.20.04.1) ... Setting up libfdisk1:arm64 (2.34-0.1ubuntu9.3) ... Setting up libparted2:arm64 (3.3-4ubuntu0.20.04.1) ... Setting up u-boot-tools (2021.01+dfsg-3ubuntu0~20.04.4) ... Setting up mount (2.34-0.1ubuntu9.3) ... Setting up libmm-glib0:arm64 (1.16.6-2~20.04.1) ... Setting up libbluetooth3:arm64 (5.53-0ubuntu3.6) ... Setting up libasound2:arm64 (1.2.2-2.1ubuntu2.5) ... Setting up gpgconf (2.2.19-3ubuntu2.1) ... Setting up libperl5.30:arm64 (5.30.0-9ubuntu0.2) ... Setting up linux-headers-4.4.143-68-rockchip-g222447a97264 (4.4.143-68-rockchip) ... Setting up libkrb5-3:arm64 (1.17-6ubuntu4.1) ... Setting up libjson-c4:arm64 (0.13.1+dfsg-7ubuntu0.3) ... Setting up libbinutils:arm64 (2.34-6ubuntu1.3) ... Setting up vim-runtime (2:8.1.2269-1ubuntu5.7) ... Setting up klibc-utils (2.0.7-1ubuntu5.1) ... Setting up gpg (2.2.19-3ubuntu2.1) ... Setting up libpolkit-gobject-1-0:arm64 (0.105-26ubuntu1.3) ... Setting up libprocps8:arm64 (2:3.3.16-1ubuntu2.3) ... Setting up libkmod2:arm64 (27-1ubuntu2.1) ... Setting up gnupg-utils (2.2.19-3ubuntu2.1) ... Setting up initramfs-tools-bin (0.136ubuntu6.7) ... Setting up libctf0:arm64 (2.34-6ubuntu1.3) ... Setting up libubootenv-tool (0.2-1) ... Setting up libpython3.8-minimal:arm64 (3.8.10-0ubuntu1~20.04.4) ... Setting up gpg-agent (2.2.19-3ubuntu2.1) ... Setting up libdns-export1109 (1:9.11.16+dfsg-3~ubuntu1) ... Setting up gpgsm (2.2.19-3ubuntu2.1) ... Setting up linux-4.4-rock-pi-s-latest (4.4.143-68-rockchip) ... Setting up isc-dhcp-client (4.4.1-2.1ubuntu5.20.04.2) ... Setting up libldap-2.4-2:arm64 (2.4.49+dfsg-2ubuntu1.9) ... Setting up parted (3.3-4ubuntu0.20.04.1) ... Setting up binutils-aarch64-linux-gnu (2.34-6ubuntu1.3) ... Setting up e2fsprogs (1.45.5-2ubuntu1.1) ... update-initramfs: deferring update (trigger activated) e2scrub_all.service is a disabled or a static unit not running, not starting it. Setting up binutils (2.34-6ubuntu1.3) ... Setting up kmod (27-1ubuntu2.1) ... update-initramfs: deferring update (trigger activated) Setting up fdisk (2.34-0.1ubuntu9.3) ... Setting up wpasupplicant (2:2.9-1ubuntu4.3) ... Setting up dirmngr (2.2.19-3ubuntu2.1) ... Setting up perl (5.30.0-9ubuntu0.2) ... Setting up libgssapi-krb5-2:arm64 (1.17-6ubuntu4.1) ... Setting up udev (245.4-4ubuntu3.17) ... update-initramfs: deferring update (trigger activated) Setting up libssh-4:arm64 (0.9.3-2ubuntu2.2) ... Setting up gpg-wks-server (2.2.19-3ubuntu2.1) ... Setting up procps (2:3.3.16-1ubuntu2.3) ... Setting up libpolkit-agent-1-0:arm64 (0.105-26ubuntu1.3) ... Setting up libcryptsetup12:arm64 (2:2.2.2-3ubuntu2.4) ... Setting up libpython3.8-stdlib:arm64 (3.8.10-0ubuntu1~20.04.4) ... Setting up initramfs-tools-core (0.136ubuntu6.7) ... Setting up initramfs-tools (0.136ubuntu6.7) ... update-initramfs: deferring update (trigger activated) Setting up gpg-wks-client (2.2.19-3ubuntu2.1) ... Setting up openssh-client (1:8.2p1-4ubuntu0.5) ... Setting up libcurl3-gnutls:arm64 (7.68.0-1ubuntu2.11) ... Setting up bluez (5.53-0ubuntu3.6) ... Setting up libpython3.8:arm64 (3.8.10-0ubuntu1~20.04.4) ... Setting up gnupg (2.2.19-3ubuntu2.1) ... Setting up openssh-sftp-server (1:8.2p1-4ubuntu0.5) ... Setting up gnupg2 (2.2.19-3ubuntu2.1) ... Setting up vim (2:8.1.2269-1ubuntu5.7) ... Setting up openssh-server (1:8.2p1-4ubuntu0.5) ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based fronte nd cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline rescue-ssh.target is a disabled or a static unit, not starting it. Setting up ssh (1:8.2p1-4ubuntu0.5) ... Setting up systemd-timesyncd (245.4-4ubuntu3.17) ... Setting up systemd (245.4-4ubuntu3.17) ... Installing new version of config file /etc/dhcp/dhclient-enter-hooks.d/resolved... Installing new version of config file /etc/systemd/resolved.conf ... Setting up systemd-sysv (245.4-4ubuntu3.17) ... Setting up libpam-systemd:arm64 (245.4-4ubuntu3.17) ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based fronte nd cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline Setting up policykit-1 (0.105-26ubuntu1.3) ... Setting up network-manager (1.22.10-1ubuntu2.3) ... find: ‘/etc/netplan’: No such file or directory Processing triggers for mime-support (3.64ubuntu1) ... Processing triggers for libc-bin (2.31-0ubuntu9.9) ... Processing triggers for initramfs-tools (0.136ubuntu6.7) ... ln: failed to create hard link '/boot/initrd.img-4.4.143-68-rockchip-g222447a972 64.dpkg-bak' => '/boot/initrd.img-4.4.143-68-rockchip-g222447a97264': Operation not permitted update-initramfs: Generating /boot/initrd.img-4.4.143-68-rockchip-g222447a97264 Find /boot/uEnv.txt and will update it. installing initrd size: 0x8cedf1 installing kernel version: 4.4.143-68-rockchip-g222447a97264 rock@rockpis:~$

May as well remove the unneeded packages as suggested and then check version numbers.

rock@rockpis:~$ sudo apt autoremove ... rock@rockpis:~$ uname -a Linux rockpis 4.4.143-65-rockchip-g58431d38f8f3 #1 SMP PREEMPT Sat Aug 14 09:31:07 UTC 2021 aarch64 aarch64 aarch64 GNU/Linux rock@rockpis:~$ cat /etc/*release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=20.04 DISTRIB_CODENAME=focal DISTRIB_DESCRIPTION="Ubuntu 20.04.4 LTS" NAME="Ubuntu" VERSION="20.04.4 LTS (Focal Fossa)" ID=ubuntu ID_LIKE=debian PRETTY_NAME="Ubuntu 20.04.4 LTS" VERSION_ID="20.04" HOME_URL="https://www.ubuntu.com/" SUPPORT_URL="https://help.ubuntu.com/" BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/" PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy" VERSION_CODENAME=focal UBUNTU_CODENAME=focal rock@rockpis:~$ cat /etc/debian_version bullseye/sid

Useful Housekeeping toc

Here are some additional steps I take that are useful but not necessary.

Add a Second User toc

I will be modifiing password permissions and renaming the default user and so on. As a precaution in case I make a mess of things, I add a second user with sudo priviledges. That way if I manage to lock myself out of the default account, I can log in as user2 and attempt to fix things from there.

rock@rockpis:~$ sudo useradd -m user2 -s /bin/bash rock@rockpis:~$ ls -la /home/user2 total 20 drwxr-xr-x 2 user2 user2 4096 Jun 23 19:41 . drwxr-xr-x 6 root root 4096 Jun 23 19:41 .. -rw-r--r-- 1 user2 user2 220 Feb 25 2020 .bash_logout -rw-r--r-- 1 user2 user2 3771 Feb 25 2020 .bashrc -rw-r--r-- 1 user2 user2 807 Feb 25 2020 .profile rock@rockpis:~$ id user2 uid=1001(user2) gid=1001(user2) groups=1001(user2) rock@rockpis:~$ sudo passwd user2 New password: ******** Retype new password: ******** passwd: password updated successfully rock@rockpis:~$ sudo usermod -a -G sudo,adm user2 rock@rockpis:~$ groups user2 user2 : user2 adm sudo

It is a good idea to log in as that additional user and to test that commands requiring higher privilges can be performed by user2 with the sudo prefix.

Change the Default User Name toc

There is an enhancement to security obtained from changing the name of the default user. The instructions from How to Rename the Default Raspberry Pi User by Jim McDonnell, can be easily adapted. The default user, rock, should have user id and group id of 1000.

rock@rockpis:~$ id uid=1000(rock) gid=1000(rock) groups=1000(rock),27(sudo)

If not already done so, add a second user and make that user a member of the sudo group. That's all explained in the previous section. Close all sessions opened by rock including on the debug console. Open a new session as the second user.

rock@rockpis:~$ exit michel@hp:~$ ssh user2@192.168.3.140 user2@192.168.3.140's password: ********* Welcome to Ubuntu 20.04 LTS (GNU/Linux 4.4.143-65-rockchip-g58431d38f8f3 aarch64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage Last login: Tue Jun 21 23:56:12 2022 from 192.168.3.100 user2@rockpis:~$ user2@pi ~ $ id uid=1001(user2) gid=1001(user2) groups=1001(user2),27(sudo)

Don’t worry if the uid or gid is not 1001, as long as it is not 1000 everything should be fine. Back up the files that will be modified and then use sed to change the name rock to print3D or whatever you want the default user name to be.

user2@rockpis:~$ cd /etc user2@rockpis:~$ sudo tar -cvf authfiles.tar passwd group shadow gshadow sudoers subuid subgid user2@rockpis:~$ sudo sed -i.$(date +'%y%m%d_%H%M%S') 's/\brock\b/print3D/g' passwd group shadow gshadow sudoers subuid subgid

Check the list of groups, print3D should appear where rock was.

user2@rockpis:/etc$ grep print3D group audio:x:29:print3D video:x:44:print3D sudo:x:27:print3D,user2 print3D:x:1000:

Now renamed the home directory, reboot and open a session with the new user name.

user2@rockpis/etc $ sudo mv /home/rock /home/print3D user2@rockpis/etc $ sudo reboot ... michel@hp:~$ ssh print3D@192.168.3.140 print3D@192.168.3.140's password: *************** use the rock password Welcome to Ubuntu 20.04 LTS (GNU/Linux 4.4.143-65-rockchip-g58431d38f8f3 aarch64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage Last login: Tue Jun 22 00:06:22 2022 from 192.168.3.100

Let's just check a few things.

print3D@rockpis:~$ id uid=1000(print3D) gid=1000(print3D) groups=1000(print3D),27(sudo) print3D@rockpis:~$ pwd /home/print3D print3D@rockpis:~$ ls -la total 28 drwxr-xr-x 3 print3D print3D 4096 Jun 23 20:13 . drwxr-xr-x 6 root root 4096 Jun 23 19:41 .. -rw------- 1 print3D print3D 3510 Jun 23 02:05 .bash_history -rw-r--r-- 1 print3D print3D 220 Jun 21 23:47 .bash_logout -rw-r--r-- 1 print3D print3D 3771 Jun 21 23:47 .bashrc drwx------ 3 print3D print3D 4096 Jun 22 02:00 .cache -rw-r--r-- 1 print3D print3D 807 Jun 21 23:47 .profile

Everything looks fine.

To avoid confusion, I will assume for the rest of the post that the default user name has not been changed.

Changing the Host Name toc

If there will be more than on Rock Pi S on the LAN then it would be preferable to change the host name. This is especially true if running the avahi-daemon. Or one may just prefer a memorable name. Changing the host name can be done with nmtui (that will be used later), by directly editing the /etc/hostname file or with the hostnamectl utility.

rock@rockpis:~$ hostnamectl set-hostname octorock

No matter which method is used, I find that the hosts file is not updated and that can cause problems. So after changing the hostname by which ever method desired, edit the file.

rock@rockpis:~$ sudo nano -B /etc/hosts

Then make sure that the locahost IP refers to the new host name and not to rockpis:

127.0.0.1 localhost 127.0.1.1 octorock ::1 localhost rockpi-s ip6-localhost ip6-loopback fe00::0 ip6-localnet ff00::0 ip6-mcastprefix ff02::1 ip6-allnodes ff02::2 ip6-allrouters

Reboot for the change to take effect.

rock@rockpis:~$ sudo reboot ... Connection to ... closed. michel@hp:~$ ssh rock@192.168.3.140 The authenticity of host '192.168.3.140' '(192.168.3.140)' can't be established. ECDSA key fingerprint is SHA256:L78C+TeI2ecHyFUx6ctz/aK5XuJ/PXgGqkpGUTf0uGg. Are you sure you want to continue connecting (yes/no/[fingerprint])? yes rock@192.168.3.140's password: ************ Welcome to Ubuntu 20.04.4 LTS (GNU/Linux 4.4.143-68-rockchip-g222447a97264 aarch64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage Last login: Wed Jun 22 12:45:39 2022 from 192.168.3.100 rock@octorock:~$

Again this is optional and again, to avoid confusion, I will assume for the rest of the post that the host name has not been changed.

Less Password Protection toc

While setting up the system there will be many requests for the user password when the user priviliges have to be promoted with sudo. This gets tiring very quickly so you may want to remove most of these request by adding a rule to the sudoer configuration. The README file in /etc/sudoers.d has some information about adding files to that directory.

rock@rockpis:~$ sudo cat sudoers.d/README [sudo] password for octpr: ******** # # As of Debian version 1.7.2p1-1, the default /etc/sudoers file created on # installation of the package now includes the directive: # # #includedir /etc/sudoers.d # # This will cause sudo to read and parse any files in the /etc/sudoers.d # directory that do not end in '~' or contain a '.' character. # # Note that there must be at least one file in the sudoers.d directory (this # one will do), and all files in this directory should be mode 0440. # # Note also, that because sudoers contents can vary widely, no attempt is # made to add this directive to existing sudoers files on upgrade. Feel free # to add the above directive to the end of your /etc/sudoers file to enable # this functionality for existing installations if you wish! # # Finally, please note that using the visudo command is the recommended way # to update sudoers content, since it protects against many failure modes. # See the man page for visudo for more information. #

Follow the sound advice and use visudo to add a one line file in the sudoers.d directory or live on the edge and execute the following two commands.

rock@rockpis:~$ echo "$USER ALL=(ALL:ALL) NOPASSWD: ALL" | sudo tee "/etc/sudoers.d/$USER-no-password" rock ALL=(ALL:ALL) NOPASSWD: ALL rock@rockpis:~$ sudo chmod 440 /etc/sudoers.d/$USER-no-password -r--r----- 1 root root 958 Feb 3 2020 README -r--r----- 1 root root 38 Jun 20 17:01 rock-no-password

Enable Zeroconf (avahi-daemon) toc

Enable the avahi-daemon to make it easy to find the board after reboots should the DHCP server give it a different IP address.

rock@rockpis:~$ sudo apt install avahi-daemon -y Reading package lists... Done Building dependency tree Reading state information... Done The following additional packages will be installed: bind9-host bind9-libs libavahi-common-data libavahi-common3 libavahi-core7 libdaemon0 libicu66 liblmdb0 libmaxminddb0 libuv1 libxml2 Suggested packages: avahi-autoipd mmdb-bin Recommended packages: libnss-mdns The following NEW packages will be installed: avahi-daemon bind9-host bind9-libs libavahi-common-data libavahi-common3 libavahi-core7 libdaemon0 libicu66 liblmdb0 libmaxminddb0 libuv1 libxml2 0 upgraded, 12 newly installed, 0 to remove and 0 not upgraded. Need to get 10.3 MB of archives. After this operation, 39.8 MB of additional disk space will be used. Get:1 http://ports.ubuntu.com focal-security/main arm64 libicu66 arm64 66.1-2ubuntu2.1 [8,360 kB] Get:2 http://ports.ubuntu.com focal-security/main arm64 libxml2 arm64 2.9.10+dfsg-5ubuntu0.20.04.3 [570 kB] Get:3 http://ports.ubuntu.com focal/main arm64 liblmdb0 arm64 0.9.24-1 [43.1 kB] Get:4 http://ports.ubuntu.com focal-security/main arm64 libmaxminddb0 arm64 1.4.2-0ubuntu1.20.04.1 [25.9 kB] Get:5 http://ports.ubuntu.com focal-security/main arm64 libuv1 arm64 1.34.2-1ubuntu1.3 [75.1 kB] Get:6 http://ports.ubuntu.com focal-security/main arm64 bind9-libs arm64 1:9.16.1-0ubuntu2.10 [995 kB] Get:7 http://ports.ubuntu.com focal-security/main arm64 bind9-host arm64 1:9.16.1-0ubuntu2.10 [41.3 kB] Get:8 http://ports.ubuntu.com focal-security/main arm64 libavahi-common-data arm64 0.7-4ubuntu7.1 [21.4 kB] Get:9 http://ports.ubuntu.com focal-security/main arm64 libavahi-common3 arm64 0.7-4ubuntu7.1 [20.4 kB] Get:10 http://ports.ubuntu.com focal-security/main arm64 libavahi-core7 arm64 0.7-4ubuntu7.1 [73.2 kB] Get:11 http://ports.ubuntu.com focal/main arm64 libdaemon0 arm64 0.14-7 [12.8 kB] Get:12 http://ports.ubuntu.com focal-security/main arm64 avahi-daemon arm64 0.7-4ubuntu7.1 [58.0 kB] Fetched 10.3 MB in 6s (1,705 kB/s) Selecting previously unselected package libicu66:arm64. (Reading database ... 23142 files and directories currently installed.) Preparing to unpack .../00-libicu66_66.1-2ubuntu2.1_arm64.deb ... Unpacking libicu66:arm64 (66.1-2ubuntu2.1) ... Selecting previously unselected package libxml2:arm64. Preparing to unpack .../01-libxml2_2.9.10+dfsg-5ubuntu0.20.04.3_arm64.deb ... Unpacking libxml2:arm64 (2.9.10+dfsg-5ubuntu0.20.04.3) ... Selecting previously unselected package liblmdb0:arm64. Preparing to unpack .../02-liblmdb0_0.9.24-1_arm64.deb ... Unpacking liblmdb0:arm64 (0.9.24-1) ... Selecting previously unselected package libmaxminddb0:arm64. Preparing to unpack .../03-libmaxminddb0_1.4.2-0ubuntu1.20.04.1_arm64.deb ... Unpacking libmaxminddb0:arm64 (1.4.2-0ubuntu1.20.04.1) ... Selecting previously unselected package libuv1:arm64. Preparing to unpack .../04-libuv1_1.34.2-1ubuntu1.3_arm64.deb ... Unpacking libuv1:arm64 (1.34.2-1ubuntu1.3) ... Selecting previously unselected package bind9-libs:arm64. Preparing to unpack .../05-bind9-libs_1%3a9.16.1-0ubuntu2.10_arm64.deb ... Unpacking bind9-libs:arm64 (1:9.16.1-0ubuntu2.10) ... Selecting previously unselected package bind9-host. Preparing to unpack .../06-bind9-host_1%3a9.16.1-0ubuntu2.10_arm64.deb ... Unpacking bind9-host (1:9.16.1-0ubuntu2.10) ... Selecting previously unselected package libavahi-common-data:arm64. Preparing to unpack .../07-libavahi-common-data_0.7-4ubuntu7.1_arm64.deb ... Unpacking libavahi-common-data:arm64 (0.7-4ubuntu7.1) ... Selecting previously unselected package libavahi-common3:arm64. Preparing to unpack .../08-libavahi-common3_0.7-4ubuntu7.1_arm64.deb ... Unpacking libavahi-common3:arm64 (0.7-4ubuntu7.1) ... Selecting previously unselected package libavahi-core7:arm64. Preparing to unpack .../09-libavahi-core7_0.7-4ubuntu7.1_arm64.deb ... Unpacking libavahi-core7:arm64 (0.7-4ubuntu7.1) ... Selecting previously unselected package libdaemon0:arm64. Preparing to unpack .../10-libdaemon0_0.14-7_arm64.deb ... Unpacking libdaemon0:arm64 (0.14-7) ... Selecting previously unselected package avahi-daemon. Preparing to unpack .../11-avahi-daemon_0.7-4ubuntu7.1_arm64.deb ... Unpacking avahi-daemon (0.7-4ubuntu7.1) ... Setting up liblmdb0:arm64 (0.9.24-1) ... Setting up libicu66:arm64 (66.1-2ubuntu2.1) ... Setting up libmaxminddb0:arm64 (1.4.2-0ubuntu1.20.04.1) ... Setting up libuv1:arm64 (1.34.2-1ubuntu1.3) ... Setting up libavahi-common-data:arm64 (0.7-4ubuntu7.1) ... Setting up libdaemon0:arm64 (0.14-7) ... Setting up libxml2:arm64 (2.9.10+dfsg-5ubuntu0.20.04.3) ... Setting up bind9-libs:arm64 (1:9.16.1-0ubuntu2.10) ... Setting up libavahi-common3:arm64 (0.7-4ubuntu7.1) ... Setting up libavahi-core7:arm64 (0.7-4ubuntu7.1) ... Setting up bind9-host (1:9.16.1-0ubuntu2.10) ... Setting up avahi-daemon (0.7-4ubuntu7.1) ... Created symlink /etc/systemd/system/dbus-org.freedesktop.Avahi.service → /lib/sy stemd/system/avahi-daemon.service. Created symlink /etc/systemd/system/multi-user.target.wants/avahi-daemon.service → /lib/systemd/system/avahi-daemon.service. Created symlink /etc/systemd/system/sockets.target.wants/avahi-daemon.socket → / lib/systemd/system/avahi-daemon.socket. Processing triggers for systemd (245.4-4ubuntu3.17) ... Processing triggers for dbus (1.12.16-2ubuntu2.2) ... Processing triggers for libc-bin (2.31-0ubuntu9.9) ... root@rockpis:~#

I edited the avahi configuration file in order to enable mDns advertising of the board as a workstation.

rock@rockpis:~$ sudo nano /etc/avahi/avahi-daemon.conf

All that is required is to change the

publish-workstation=no

line to

publish-workstation=yes

Start a terminal on the desktop and run the avahi-browse utility.

michel@hp:~$ avahi-browse --all ...

Then on the Rock Pi S, restart the avahi-daemon so that the changes in the configuration file take effect.

rock@rockpis:~$ sudo systemctl restart avahi-daemon.service

Almost immediately, the Rock Pi will show up in the avahi browser.

michel@hp:~$ avahi-browse --all ... + enp4s0 IPv4 rockpi-s [aa:bb:cc:00:11:22] Workstation local ... CtrlC

Reclaim RAM toc

The model of the Rock Pi S that I have has only 512 Mbytes of memory. The Radxa FAQ has a Reclaim RAM entry that I thought could be useful. Here is the amount of free memory before applying the hint.

rock@rockpis:~$ free total used free shared buff/cache available Mem: 435488 45060 254756 408 135672 379584 Swap: 0 0 0

And here is the amount of memory after.

rock@rockpis:~$ free total used free shared buff/cache available Mem: 499348 44980 371512 404 82856 442780 Swap: 0 0 0

The fix is to add extraargs=swiotlb=1024 at the end of the bootloader configuration file /boot/uEnv.txt, or the following command could be used. In both cases I would make a copy of the configuration file ahead of time.

rock@rockpis:~$ sudo cp /boot/uEnv.txt . rock@rockpis:~$ echo "extraargs=swiotlb=1024" | sudo tee -a "/boot/uEnv.txt" extraargs=swiotlb=1024 rock@rockpis:~$ cat /boot/uEnv.txt verbosity=7 fdtfile=rockchip/rk3308-rock-pi-s.dtb console=ttyS0,1500000n8 overlays=rk3308-uart0 rk3308-usb20-host rootuuid=d99ac41e-e8cc-4c73-a420-e71f15e42042 initrdsize=0x8cedf1 kernelversion=4.4.143-68-rockchip-g222447a97264 initrdimg=initrd.img-4.4.143-68-rockchip-g222447a97264 kernelimg=vmlinuz-4.4.143-68-rockchip-g222447a97264 extraargs=swiotlb=1024

Thankfully, the extra empty line does not matter even if it bothers OCD sufferers.

After the installation of a Octoprint with numerous additional packages and so on, the amount of available memory will be considerably reduced as can be seen below.

rock@rockpis:~$ free total used free shared buff/cache available Mem: 499348 139832 193208 1660 166308 346680 Swap: 0 0 0

Hopefully, 338 Kbytes of memory will be sufficient to run Octoprint, but things can be improved somewhat. First, I removed the Bluetooth stack which will be of no use to me. Then after setting up the static IP address permanently for the Rock Pi S, I disabled the avahi-daemon installed in the previous step only to make finding the Rock Pi S easier while configuring the system.

rock@rockpis:~$ sudo systemctl disable bluetooth.service ... rock@rockpis:~$ sudo apt remove --purge bluez -y ... rock@rockpis:~$ sudo systemctl disable avahi-daemon.service ...

After rebooting and waiting for all services to be installed before checking, it seems that a gain of about 12 KBytes of available RAM was obtained.

rock@rockpis:~$ free total used free shared buff/cache available Mem: 499348 128532 251816 1636 119000 358008 Swap: 0 0 0

Finally, looking at the loaded kernel modules (device drivers in other words), all but one were related to sound and midi.

rock@rockpis:~$ lsmod Module Size Used by rtl8723ds 1708032 0 snd_usb_audio 131072 0 snd_hwdep 16384 1 snd_usb_audio snd_usbmidi_lib 24576 1 snd_usb_audio snd_rawmidi 24576 1 snd_usbmidi_lib snd_seq_device 16384 1 snd_rawmidi

Thinking that these two technologies are not needed by Octoprint, the modules were removed.

rock@rockpis:~$ sudo rmmod snd_usb_audio snd_hwdep snd_usbmidi_lib snd_rawmidi snd_seq_device rock@rockpis:~$ lsmod Module Size Used by rtl8723ds 1708032 0 rock@rockpis:~$ free total used free shared buff/cache available Mem: 499348 133712 200556 1624 165080 352836 Swap: 0 0 0

There is a small gain in available RAM, so might as well make this permanent. This requires kernel module blacklisting./p>

rock@rockpis:~$ sudo nano /etc/modprobe.d/blacklist-sound.conf

The file contains the list of kernel modules that are not be loaded.

blacklist snd_hwdep blacklist usbmidi_lib blacklist snd_usb_audio blacklist snd_seq_device blacklist rawmidi

Limit the Footprint of the Journal Service toc

There were surprises with the system logs. The ubiquitous rsyslog utility was not present, only the systemd journaling service (systemd-journald.service) was running and the default user did not have access to most logs.

rock@rockpis:~$ journalctl Hint: You are currently not seeing messages from other users and the system. Users in groups 'adm', 'systemd-journal' can see all messages. Pass -q to turn off this notice.

That's easy to remedy by adding the user to the adm group. Because Octoprint will use the serial port to communicate with the 3D printer, it is necessary to add the user to the dialout group.

rock@rockpis:~$ sudo usermod -a -G adm,dialout rock ...

Checking the size of the persistent logs on the SD card showed that it was more than double the size of the logs on a Raspberry Pi hosting my home automation system for over a couple of years now.

rock@rockpis:~$ uptime -p up 4 minutes rock@rockpis:~$ sudo du -h /var/log 4.0K /var/log/private 4.0K /var/log/apt 41M /var/log/journal/399d3a6a0f6b42e1a92ca095d497da94 41M /var/log/journal 41M /var/log

nestor@domo:~ $ uptime -p up 2 days, 4 hours, 13 minutes nestor@domo:~ $ sudo du -h /var/log 256K /var/log/mosquitto 4.0K /var/log/watchdog 72K /var/log/apt 4.0K /var/log/chrony 104K /var/log/nginx 4.0K /var/log/private 18M /var/log

No options are set in the /etc/systemd/journald.conf configuration file. Thus, by default, the Storage mode is auto. That means that the journal service stores the log data persistently in files in the /var/log/journal directory if it exists or, failing the presence of that directory, in a volatile way in /run/log/journal. Volatile means that the logged journal data will not survive a boot because /run is the mount point of an in-memory (tmpfs) filesystem. If the storage mode is set to volatile in the journald.conf configuration file, then the log will be created in /run/log even if /var/log/journal exits. I was curious to see the size consequences of various combinations of the storage mode setting and the presence or not of the /var/log/journal directory.

Storage mode/var/log/journal<file>/run/log/journal/<file>used mem (from free)
autocreated25 MB-44804
autonot createdno1.3 MB44664
volatilenot createdno1.9 MB47380

At this point, I think the best option is to leave the storage mode set to auto, to delete the var/log/journal directory and to no install rsyslog. That decision can be revisited in the future, if all log messages were to be forwarded to a centralized logging service, for example.

Configure the Network toc

Given my intent to use the Rock Pi S as a server hosting Octoprint, it makes more sense to set up a static IP address instead of relying on mDNS to find the machine. I also want to be able to use a Wi-Fi connection to the LAN instead of a wired one, and it should have a fixed IP address also. So here is a procedure that achieves these goals.

Static IP for the Ethernet Interface toc

The interactive utility nmtui and the command line utility nmcli can be used to control the network management service NetworkManager. All are installed together in the same package.

rock@rockpis:~$ apt-cache policy network-manager network-manager: Installed: 1.22.10-1ubuntu2.3 Candidate: 1.22.10-1ubuntu2.3 Version table: *** 1.22.10-1ubuntu2.3 500 500 http://ports.ubuntu.com focal-updates/main arm64 Packages 100 /var/lib/dpkg/status 1.22.10-1ubuntu1 500 500 http://ports.ubuntu.com focal/main arm64 Packages

I will use nmtui to edit the default wired (Ethernet) interface configuration.

rock@rockpis:~$ sudo nmtui

start screen of nmtui

Change the IPv4 CONFIGURATION from Automatic to Manual and then press on the Show button to the right to see the details.

IPv4 Manual configuration

Enter the desired static IP address, the IP address of the gateway (my LAN router) and the desired DNS servers. Below I show the Google servers, but there are others that may be preferable.

setting static IP values

There is no need for IPv6 on my simple LAN so I set the IPv6 CONFIGURATION to Disabled, but there is no harm in leaving it to the default Automatic. Finally, click on the OK button at the bottom.

When back into the start screen of the utility, select Quit and click on OK or press the Enter key. Then check the current IP address, reboot and check that the static address is used.

rock@rockpis:~$ ip -4 a ... 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000 inet 192.168.3.140/24 brd 192.168.3.255 scope global dynamic noprefixroute eth0 valid_lft 1647sec preferred_lft 1647sec ... rock@rockpis:~$ sudo reboot Connection to rockpis.local closed by remote host. Connection to rockpis.local closed. wait a few tens of seconds michel@hp:~$ ssh rock@rockpis.local rock@rockpis.local's password: ********** Welcome to Ubuntu 20.04.4 LTS (GNU/Linux 4.4.143-68-rockchip-g222447a97264 aarch64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage Last login: Wed Jun 22 12:27:04 2022 from 192.168.3.100 rock@rockpis:~$ ip -4 a ... 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000 inet 192.168.3.23/24 brd 192.168.3.255 scope global dynamic noprefixroute eth0 valid_lft 1647sec preferred_lft 1647sec ...

So the desired result was obtained: the Rock Pi S has a fixed IP address. But don't think that is all there is to setting up a network inteface.

rock@rockpis:~$ nmcli -p -s connection show "Wired connection 1" =============================================================================== Connection profile details (Wired connection 1) =============================================================================== connection.id: Wired connection 1 connection.uuid: 5807f7b4-582b-3f92-bfc6-994da9cf2fd2 connection.stable-id: -- connection.type: 802-3-ethernet connection.interface-name: eth0 connection.autoconnect: yes connection.autoconnect-priority: -999 connection.autoconnect-retries: -1 (default) connection.multi-connect: 0 (default) connection.auth-retries: -1 connection.timestamp: 1655912964 connection.read-only: no connection.permissions: -- connection.zone: -- connection.master: -- connection.slave-type: -- connection.autoconnect-slaves: -1 (default) connection.secondaries: -- connection.gateway-ping-timeout: 0 connection.metered: unknown connection.lldp: default connection.mdns: -1 (default) connection.llmnr: -1 (default) connection.wait-device-timeout: -1 ------------------------------------------------------------------------------- 802-3-ethernet.port: -- 802-3-ethernet.speed: 0 802-3-ethernet.duplex: -- 802-3-ethernet.auto-negotiate: no 802-3-ethernet.mac-address: -- 802-3-ethernet.cloned-mac-address: -- 802-3-ethernet.generate-mac-address-mask:-- 802-3-ethernet.mac-address-blacklist: -- 802-3-ethernet.mtu: auto 802-3-ethernet.s390-subchannels: -- 802-3-ethernet.s390-nettype: -- 802-3-ethernet.s390-options: -- 802-3-ethernet.wake-on-lan: default 802-3-ethernet.wake-on-lan-password: -- ------------------------------------------------------------------------------- ipv4.method: manual ipv4.dns: 9.9.9.9,149.112.112.112 ipv4.dns-search: -- ipv4.dns-options: -- ipv4.dns-priority: 0 ipv4.addresses: 192.168.3.23/24 ipv4.gateway: 192.168.3.1 ipv4.routes: -- ipv4.route-metric: -1 ipv4.route-table: 0 (unspec) ipv4.routing-rules: -- ipv4.ignore-auto-routes: no ipv4.ignore-auto-dns: no ipv4.dhcp-client-id: -- ipv4.dhcp-iaid: -- ipv4.dhcp-timeout: 0 (default) ipv4.dhcp-send-hostname: yes ipv4.dhcp-hostname: -- ipv4.dhcp-fqdn: -- ipv4.dhcp-hostname-flags: 0x0 (none) ipv4.never-default: no ipv4.may-fail: yes ipv4.dad-timeout: -1 (default) ------------------------------------------------------------------------------- ipv6.method: disabled ipv6.dns: -- ipv6.dns-search: -- ipv6.dns-options: -- ipv6.dns-priority: 0 ipv6.addresses: -- ipv6.gateway: -- ipv6.routes: -- ipv6.route-metric: -1 ipv6.route-table: 0 (unspec) ipv6.routing-rules: -- ipv6.ignore-auto-routes: no ipv6.ignore-auto-dns: no ipv6.never-default: no ipv6.may-fail: yes ipv6.ip6-privacy: -1 (unknown) ipv6.addr-gen-mode: stable-privacy ipv6.ra-timeout: 0 (default) ipv6.dhcp-duid: -- ipv6.dhcp-iaid: -- ipv6.dhcp-timeout: 0 (default) ipv6.dhcp-send-hostname: yes ipv6.dhcp-hostname: -- ipv6.dhcp-hostname-flags: 0x0 (none) ipv6.token: -- ------------------------------------------------------------------------------- proxy.method: none proxy.browser-only: no proxy.pac-url: -- proxy.pac-script: -- ------------------------------------------------------------------------------- =============================================================================== Activate connection details (5807f7b4-582b-3f92-bfc6-994da9cf2fd2) =============================================================================== GENERAL.NAME: Wired connection 1 GENERAL.UUID: 5807f7b4-582b-3f92-bfc6-994da9cf2fd2 GENERAL.DEVICES: eth0 GENERAL.IP-IFACE: eth0 GENERAL.STATE: activated GENERAL.DEFAULT: yes GENERAL.DEFAULT6: no GENERAL.SPEC-OBJECT: -- GENERAL.VPN: no GENERAL.DBUS-PATH: /org/freedesktop/NetworkManager/ActiveConnection/1 GENERAL.CON-PATH: /org/freedesktop/NetworkManager/Settings/1 GENERAL.ZONE: -- GENERAL.MASTER-PATH: -- ------------------------------------------------------------------------------- IP4.ADDRESS[1]: 192.168.3.23/24 IP4.GATEWAY: 192.168.3.1 IP4.ROUTE[1]: dst = 192.168.3.0/24, nh = 0.0.0.0, mt = 100 IP4.ROUTE[2]: dst = 0.0.0.0/0, nh = 192.168.3.1, mt = 100 IP4.DNS[1]: 9.9.9.9 IP4.DNS[2]: 149.112.112.112 ------------------------------------------------------------------------------- IP6.GATEWAY: -- ------------------------------------------------------------------------------- rock@rockpis:~$

Enable Wi-Fi toc

Again, the nmtui utility can be used to activate wireless network interface.

Activating Wi-Fi in nmtui

Enter the wireless network password in the pop up window and click on the OK button

Password

Exit the utility and check the network interfaces, both will be activated.

rock@rockpis:~$ ip -4 a ... 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 inet 192.168.3.23/24 brd 192.168.3.255 scope global noprefixroute eth0 valid_lft forever preferred_lft forever 3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 inet 192.168.3.145/24 brd 192.168.3.255 scope global dynamic noprefixroute wlan0 valid_lft 1412sec preferred_lft 1412sec

Reboot and check that this remains true. It should.

Static IP for the Wireless Interface toc

On my LAN, 192.168.3.23 is in the pool of static IP addresses while 192.168.3.145 is in the pool of dynamic addresses assigned by the DHCP server. If the board will most often be connected to the local network using the wireless interface, then it makes sense to assign it a static IP address. This is done in exactly the same way as done with the wired connection. In the main mntui menu (do not forget to invoke the utility with the sudo prefix) chose the Edit a connection option and then select the Wi-Fi connection to edit.

Password

As before set the IPv4 CONFIGURATION to manual and enter the static IP address and the IP addresses of the gateway and DNS servers.

Password

Note that I have again disabled IPv6. Note also that the static IP address given to the Wi-Fi connection is different from the static IP address of the wired interface or any other device on the LAN for that matter. Here are the resulting IP addresses of the two interfaces.

rock@rockpis:~$ ip -4 a ... 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 inet 192.168.3.23/24 brd 192.168.3.255 scope global noprefixroute eth0 valid_lft forever preferred_lft forever 3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 inet 192.168.3.24/24 brd 192.168.3.255 scope global dynamic noprefixroute wlan0 valid_lft 1412sec preferred_lft 1412sec

My prefered way of setting up the IP addresses of the two network interfaces is to set a fixed IP address for the interface that is most often used and to let the other interface obtain its IP address from the DHCP server on the local network. Since my Rock Pi S will in all likelihood connect to the LAN with the Wi-Fi interface, I edited the wired connection and set the IPv4 CONFIGURATION back to Automatic. Here is the final network setup of the board.

rock@rockpis:~$ ip -4 a ... 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 inet 192.168.3.140/24 brd 192.168.3.255 scope global dynamic noprefixroute eth0 valid_lft 1629sec preferred_lft 1629sec 3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 inet 192.168.3.24/24 brd 192.168.3.255 scope global noprefixroute wlan0 valid_lft forever preferred_lft forever

Basically that means that should there be a major change to my LAN such a modification of the subnet used, I should be able to log into the Rock Pi S using a wired connection and fix the static IP address.

Cleaning Up the Network Configuration toc

After rebooting twice in a row and looking at the IP addresses each time, problems identified over a year ago remain.

rock@rockpis:~$ ip a 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever inet6 ::1/128 scope host valid_lft forever preferred_lft forever 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN group default qlen 1000 link/ether cb:7b:9c:c0:c1:c2 brd ff:ff:ff:ff:ff:ff inet 192.168.3.140/24 brd 192.168.3.255 scope global dynamic noprefixroute eth0 valid_lft 1773sec preferred_lft 1773sec 3: wlan0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN group default qlen 1000 link/ether 92:2b:b5:6a:ba:bd brd ff:ff:ff:ff:ff:ff 4: p2p0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 link/ether be:bc:1a:3c:69:9e brd ff:ff:ff:ff:ff:ff inet 192.168.3.24/24 brd 192.168.3.255 scope global noprefixroute p2p0 valid_lft forever preferred_lft forever inet6 fd00:fc:8d4f:71b2:c38:f0dd:53d8:cc0e/64 scope global temporary dynamic valid_lft 535421sec preferred_lft 85793sec ...

rock@rockpis:~$ ip a 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever inet6 ::1/128 scope host valid_lft forever preferred_lft forever 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN group default qlen 1000 link/ether cb:7b:9c:c0:c1:c2 brd ff:ff:ff:ff:ff:ff inet 192.168.3.140/24 brd 192.168.3.255 scope global dynamic noprefixroute eth0 valid_lft 1784sec preferred_lft 1784sec 3: wlan0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN group default qlen 1000 link/ether 42:27:4a:da:23:e6 brd ff:ff:ff:ff:ff:ff 4: p2p0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 link/ether be:bc:1a:3c:69:9e brd ff:ff:ff:ff:ff:ff inet 192.168.3.24/24 brd 192.168.3.255 scope global noprefixroute p2p0 valid_lft forever preferred_lft forever inet6 fd00:fc:8d4f:71b2:f99d:60e6:671d:de46/64 scope global temporary tentative dynamic valid_lft 535428sec preferred_lft 85800sec ...

As we can see,

I will not go into the details again, but here is how I "solved" most of these problems, based on my experience with the older Ubuntu image.

  1. Disable IPv6:
    rock@rockpis:~$ echo "net.ipv6.conf.all.disable_ipv6=1" | sudo tee "/etc/sysctl.d/local.conf"
    It was assumed that local.conf did not exist, if it did a different file name could be used or the -a (append) flag could be used with the tee command.
  2. Set Fixed MAC Addresses by editing the NetworkManager configuration file for the board:
    rock@rockpis:~$ sudo nano -B /usr/lib/NetworkManager/conf.d/20-rock.conf
    [device-mac-randomization] wifi.scan-rand-mac-address=no [connection-mac-randomization] wifi.cloned-mac-address=permanent
  3. Remove p2p0 from the interfaces managed by NetworkManager:
    rock@rockpis:~$ sudo nano -B /etc/NetworkManager/NetworkManager.conf
  4. and add the following two lines at the end of the file.
    [keyfile] unmanaged-devices=interface-name:p2p0
  5. If necessary remove the uuid of the Wi-Fi connection in its configuration file:
    rock@rockpis:~$ sudo nano /etc/NetworkManager/system-connections/playteck.nmconnection the file name will depend on the name of the Wi-Fi network
    Remove any line starting with uuid= in the [connection] section of the ini formated file.

That last step might not be necessary. It seems that when I rebooted the Rock Pi S while working out these details once again, NetworkManager decided to use the p2p0 interface in preference to the wlan0 interface and it used the former's uuid in the configuration file. Editing the playteck connection with nmtui to set the device to wlan0 did not seem to do anything, but the brute force step described above worked.

Multiple reboots give consistent results after these changes.

rock@rockpis:~$ ip a 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN group default qlen 1000 link/ether cb:7b:9c:c0:c1:c2 brd ff:ff:ff:ff:ff:ff inet 192.168.3.140/24 brd 192.168.3.255 scope global dynamic noprefixroute eth0 valid_lft 1787sec preferred_lft 1787sec 3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 link/ether 00:01:02:66:55:44 brd ff:ff:ff:ff:ff:ff inet 192.168.3.24/24 brd 192.168.3.255 scope global noprefixroute wlan0 valid_lft forever preferred_lft forever 4: p2p0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000 link/ether 02:e0:4c:6a:ff:45 brd ff:ff:ff:ff:ff:ff rock@rockpis:~$ dmesg | grep p2p0 rock@rockpis:~$ dmesg | grep wlan0 [ 8.783628] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready [ 9.114666] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready [ 9.383661] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready [ 16.722783] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready

This looks workable. The important packages for running Octoprint can now be added.

Install MJPG-Streamer toc

Video streaming from a webcam or a Raspberry Pi Camera (for those boards that support it) is often done with MJPG-Streamer in Octoprint installations.

According to the building and installation instructions [y]ou will also probably want to have a development version of libjpeg installed. I used libjpeg8-dev. On checking, the Ubuntu Focal image does contain that particular library, but the libjpeg-turbo8 library is present along with the libjpeg8 library.

rock@rockpis:~$ apt-cache policy libjpeg8 libjpeg-turbo8 libjpeg8: Installed: 8c-2ubuntu8 Candidate: 8c-2ubuntu8 Version table: *** 8c-2ubuntu8 500 500 http://ports.ubuntu.com/ubuntu-ports focal/main arm64 Packages 100 /var/lib/dpkg/status libjpeg-turbo8: Installed: 2.0.3-0ubuntu1.20.04.1 Candidate: 2.0.3-0ubuntu1.20.04.1 Version table: *** 2.0.3-0ubuntu1.20.04.1 500 500 http://ports.ubuntu.com/ubuntu-ports focal-security/main arm64 Packages 500 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 Packages 100 /var/lib/dpkg/status 2.0.3-0ubuntu1 500 500 http://ports.ubuntu.com/ubuntu-ports focal/main arm64 Packages

Consequently, I installed the development version of libjpeg-turbo8. More information about various versions of the JPEG library can be found here: Using libjpeg-turbo.

rock@rockpis:~$ sudo apt-get install cmake libjpeg-turbo8-dev unzip -y Reading package lists... Done Building dependency tree Reading state information... Done The following additional packages will be installed: binutils binutils-aarch64-linux-gnu binutils-common ca-certificates cmake-data cpp cpp-9 gcc gcc-9 gcc-9-base libarchive13 libasan5 libatomic1 libbinutils libc-dev-bin libc6-dev libcc1-0 libcrypt-dev libctf-nobfd0 libctf0 libcurl4 libgcc-9-dev libgomp1 libisl22 libitm1 libjsoncpp1 liblsan0 libmpc3 libmpfr6 librhash0 libtsan0 libubsan1 linux-libc-dev make manpages manpages-dev openssl Suggested packages: binutils-doc cmake-doc ninja-build cpp-doc gcc-9-locales gcc-multilib autoconf automake libtool flex bison gdb gcc-doc gcc-9-doc lrzip glibc-doc make-doc man-browser zip The following NEW packages will be installed: binutils binutils-aarch64-linux-gnu binutils-common ca-certificates cmake cmake-data cpp cpp-9 gcc gcc-9 gcc-9-base libarchive13 libasan5 libatomic1 libbinutils libc-dev-bin libc6-dev libcc1-0 libcrypt-dev libctf-nobfd0 libctf0 libcurl4 libgcc-9-dev libgomp1 libisl22 libitm1 libjpeg-turbo8-dev libjsoncpp1 liblsan0 libmpc3 libmpfr6 librhash0 libtsan0 libubsan1 linux-libc-dev make manpages manpages-dev openssl unzip 0 upgraded, 40 newly installed, 0 to remove and 1 not upgraded. Need to get 37.2 MB of archives. After this operation, 164 MB of additional disk space will be used. ... Running hooks in /etc/ca-certificates/update.d... done.

There is no mjpg-streamer package for Debian as far as I know. It must be compiled from the source code. Any one of wget, curl or git could be used to obtain the latter from the GitHub repository. Since none of these are in the image, one must be installed. I chose wget but it is really a matter of personal choice.

rock@rockpis:~$ sudo apt install wget Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: wget 0 upgraded, 1 newly installed, 0 to remove and 1 not upgraded. Need to get 331 kB of archives. After this operation, 987 kB of additional disk space will be used. Get:1 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 wget arm64 1.20.3-1ubuntu2 [331 kB] Fetched 331 kB in 1s (342 kB/s) debconf: delaying package configuration, since apt-utils is not installed Selecting previously unselected package wget. (Reading database ... 63262 files and directories currently installed.) Preparing to unpack .../wget_1.20.3-1ubuntu2_arm64.deb ... Unpacking wget (1.20.3-1ubuntu2) ... Setting up wget (1.20.3-1ubuntu2) ...

Here is how to get the latest version of MJPG-Streamer using wget.

rock@rockpis:~$ wget https://github.com/jacksonliam/mjpg-streamer/archive/refs/heads/master.zip -O mjpg-streamer.zip --2022-06-25 20:37:48-- https://github.com/jacksonliam/mjpg-streamer/archive/refs/heads/master.zip Resolving github.com (github.com)... 140.82.113.4 Connecting to github.com (github.com)|140.82.113.4|:443... connected. HTTP request sent, awaiting response... 302 Found Location: https://codeload.github.com/jacksonliam/mjpg-streamer/zip/refs/heads/master [following] --2022-06-25 20:37:49-- https://codeload.github.com/jacksonliam/mjpg-streamer/zip/refs/heads/master Resolving codeload.github.com (codeload.github.com)... 140.82.113.10 Connecting to codeload.github.com (codeload.github.com)|140.82.113.10|:443... connected. HTTP request sent, awaiting response... 200 OK Length: unspecified [application/zip] Saving to: ‘mjpg-streamer.zip’ mjpg-streamer.zip [ <=> ] 855.25K 2.03MB/s in 0.4s 2022-06-25 20:37:50 (2.03 MB/s) - ‘mjpg-streamer.zip’ saved [875777]

Now it’s simply a matter of unzipping the downloaded archive, compiling the source, and installing the package following the Simple compilation instructions in the repository. This is a relatively lengthy process with copious output to the console which has been elided below.

rock@rockpis:~$ unzip mjpg-streamer.zip Archive: mjpg-streamer.zip ... inflating: mjpg-streamer-master/mjpg-streamer-experimental/www/style.css inflating: mjpg-streamer-master/mjpg-streamer-experimental/www/videolan.html rock@rockpis:~$ cd mjpg-streamer-master/mjpg-streamer-experimental/ rock@rockpis:~/mjpg-streamer-master/mjpg-streamer-experimental$ make [ -d _build ] || mkdir _build [ -f _build/Makefile ] || (cd _build && cmake -DCMAKE_BUILD_TYPE=Release ..) -- The C compiler identification is GNU 9.4.0 ... make[2]: Leaving directory '/home/octpr/mjpg-streamer-master/mjpg-streamer-experimental/_build' make[1]: Leaving directory '/home/octpr/mjpg-streamer-master/mjpg-streamer-experimental/_build' rock@rockpis:~/mjpg-streamer-master/mjpg-streamer-experimental$ sudo make install make -C _build install make[1]: Entering directory '/home/octpr/mjpg-streamer-master/mjpg-streamer-experimental/_build' ... make[1]: Leaving directory '/home/octpr/mjpg-streamer-master/mjpg-streamer-experimental/_build'

We are now in a position to test the video streaming service with default values. Plug a USB webcam into the USB port of the Rock Pi S and enter the following command.

rock@rockpis:~/mjpg-streamer-master/mjpg-streamer-experimental$ cd ~ rock@rockpis:~$ mjpg_streamer -o "output_http.so" -i "input_uvc.so" MJPG Streamer Version.: 2.0 i: Using V4L2 device.: /dev/video0 i: Desired Resolution: 640 x 480 i: Frames Per Second.: -1 i: Format............: JPEG i: TV-Norm...........: DEFAULT UVCIOC_CTRL_ADD - Error at Pan (relative): Inappropriate ioctl for device (25) UVCIOC_CTRL_ADD - Error at Tilt (relative): Inappropriate ioctl for device (25) UVCIOC_CTRL_ADD - Error at Pan Reset: Inappropriate ioctl for device (25) UVCIOC_CTRL_ADD - Error at Tilt Reset: Inappropriate ioctl for device (25) UVCIOC_CTRL_ADD - Error at Pan/tilt Reset: Inappropriate ioctl for device (25) UVCIOC_CTRL_ADD - Error at Focus (absolute): Inappropriate ioctl for device (25) UVCIOC_CTRL_MAP - Error at Pan (relative): Inappropriate ioctl for device (25) UVCIOC_CTRL_MAP - Error at Tilt (relative): Inappropriate ioctl for device (25) UVCIOC_CTRL_MAP - Error at Pan Reset: Inappropriate ioctl for device (25) UVCIOC_CTRL_MAP - Error at Tilt Reset: Inappropriate ioctl for device (25) UVCIOC_CTRL_MAP - Error at Pan/tilt Reset: Inappropriate ioctl for device (25) UVCIOC_CTRL_MAP - Error at Focus (absolute): Inappropriate ioctl for device (25) UVCIOC_CTRL_MAP - Error at LED1 Mode: Inappropriate ioctl for device (25) UVCIOC_CTRL_MAP - Error at LED1 Frequency: Inappropriate ioctl for device (25) UVCIOC_CTRL_MAP - Error at Disable video processing: Inappropriate ioctl for device (25) UVCIOC_CTRL_MAP - Error at Raw bits per pixel: Inappropriate ioctl for device (25) o: www-folder-path......: disabled o: HTTP TCP port........: 8080 o: HTTP Listen Address..: (null) o: username:password....: disabled o: commands.............: enabled

Despite all the error messages that have to do with non-existent capabilities of my old webcam, the video stream can be seen on a web browser at the following address: http://192.168.3.24:8080/?action=stream. Single JPEG images, snapshots, can be obtained with the following HTTP request: http://192.168.3.24:8080/?action=snapshot. Of course, the local host name of the Pi could be used instead of the IP address, if the operating system and web browser support mDNS.

snapshot

The usual CtrlC keyboard combination stops the daemon.

.. o: username:password....: disabled o: commands.............: enabled CtrlC ^Csetting signal to stop i: cleaning up resources allocated by input thread force cancellation of threads and cleanup resources o: cleaning up resources allocated by server thread #00 done

While mjpg_streamer takes care of streaming .jpeg images, OctoPrint needs another rather big package, ffmpeg, to stitch together the images into a time-lapse video. This is easily added. Check where the package is installed because that path must be added to the octoprint settings later.

rock@rockpis:~ $ sudo apt install ffmpeg -y Reading package lists... Done ... 0 upgraded, 149 newly installed, 0 to remove and 0 not upgraded. Need to get 69.3 MB of archives. After this operation, 714 MB of additional disk space will be used. ... very long procedure! processing triggers for libgdk-pixbuf2.0-0:armhf (2.38.1+dfsg-1) ... rock@rockpis:~ $ which ffmpeg /usr/bin/ffmpeg

Python Requirements for Octoprint toc

Octoprint is a Python script, but Python is not installed in the images made by Raxda. Luckily it is not difficult to install the interpreter and other related packages.

rock@rockpis:~$ sudo apt install python3 python3-dev python3-venv python3-pip -y Reading package lists... Done Building dependency tree Reading state information... Done The following additional packages will be installed: build-essential bzip2 dpkg-dev fakeroot g++ g++-9 libalgorithm-diff-perl libalgorithm-diff-xs-perl libalgorithm-merge-perl libdpkg-perl libexpat1-dev libfakeroot libfile-fcntllock-perl liblocale-gettext-perl libpython3-dev libpython3-stdlib libpython3.8-dev libstdc++-9-dev patch python-pip-whl python3-distutils python3-lib2to3 python3-minimal python3-pkg-resources python3-setuptools python3-wheel python3.8 python3.8-dev python3.8-minimal python3.8-venv xz-utils zlib1g-dev Suggested packages: bzip2-doc debian-keyring gcc-9-doc git bzr libstdc++-9-doc ed diffutils-doc python3-doc python3-tk python-setuptools-doc python3.8-doc binfmt-support The following NEW packages will be installed: build-essential bzip2 dpkg-dev fakeroot g++ g++-9 libalgorithm-diff-perl libalgorithm-diff-xs-perl libalgorithm-merge-perl libdpkg-perl libexpat1-dev libfakeroot libfile-fcntllock-perl liblocale-gettext-perl libpython3-dev libpython3-stdlib libpython3.8-dev libstdc++-9-dev patch python-pip-whl python3 python3-dev python3-distutils python3-lib2to3 python3-minimal python3-pip python3-pkg-resources python3-setuptools python3-venv python3-wheel python3.8 python3.8-dev python3.8-minimal python3.8-venv xz-utils zlib1g-dev 0 upgraded, 36 newly installed, 0 to remove and 1 not upgraded. Need to get 19.4 MB of archives. After this operation, 79.4 MB of additional disk space will be used. ... Processing triggers for libc-bin (2.31-0ubuntu9.9) ... Processing triggers for mime-support (3.64ubuntu1) ...

Here are the versions of python3 and pip3 installed in the previous step.

rock@rockpis:~$ which python rock@rockpis:~$ which python3 /usr/bin/python3 rock@rockpis:~$ python3 -V Python 3.8.10 rock@rockpis:~$ python2 -V -bash: python2: command not found rock@rockpis:~$ pip3 -V pip 20.0.2 from /usr/lib/python3/dist-packages/pip (python 3.8)

Finally, a couple of libraries to handle YAML files must be installed.

rock@rockpis:~$ sudo apt install libyaml-dev -y Reading package lists... Done Building dependency tree Reading state information... Done The following additional packages will be installed: libyaml-0-2 Suggested packages: libyaml-doc The following NEW packages will be installed: libyaml-0-2 libyaml-dev 0 upgraded, 2 newly installed, 0 to remove and 1 not upgraded. Need to get 99.2 kB of archives. ... After this operation, 374 kB of additional disk space will be used. Get:1 http://ports.ubuntu.com/ubuntu-ports focal/main arm64 libyaml-0-2 arm64 0.2.2-1 [44.4 kB] Get:2 http://ports.ubuntu.com/ubuntu-ports focal/main arm64 libyaml-dev arm64 0.2.2-1 [54.8 kB] Fetched 99.2 kB in 1s (138 kB/s) debconf: delaying package configuration, since apt-utils is not installed Selecting previously unselected package libyaml-0-2:arm64. (Reading database ... 65693 files and directories currently installed.) Preparing to unpack .../libyaml-0-2_0.2.2-1_arm64.deb ... Unpacking libyaml-0-2:arm64 (0.2.2-1) ... Selecting previously unselected package libyaml-dev:arm64. Preparing to unpack .../libyaml-dev_0.2.2-1_arm64.deb ... Unpacking libyaml-dev:arm64 (0.2.2-1) ... Setting up libyaml-0-2:arm64 (0.2.2-1) ... Setting up libyaml-dev:arm64 (0.2.2-1) ... Processing triggers for libc-bin (2.31-0ubuntu9.9) ...

There's already a discussion on setting up Python 3 virtual environments on this site, so it will not be repeated here. By the way, this is just one way, there are others.

rock@rockpis:~$ mkdir -p .local/bin rock@rockpis:~$ wget https://sigmdel.ca/michel/program/python/dnld/mkvenv.ubuntu -O .local/bin/mkvenv --2022-06-14 22:00:06-- https://sigmdel.ca/michel/program/python/dnld/mkvenv.ubuntu Resolving sigmdel.ca (sigmdel.ca)... 198.50.215.64 Connecting to sigmdel.ca (sigmdel.ca)|198.50.215.64|:80... connected. HTTP request sent, awaiting response... 200 OK Length: 899 [application/octet-stream] Saving to: ‘.local/bin/mkvenv’ .local/bin/mkvenv 100%[===================>] 899 --.-KB/s in 0s 2022-06-14 22:00:06 (14.7 MB/s) - ‘.local/bin/mkvenv’ saved [899/899] rock@rockpis:~$ chmod +x .local/bin/mkvenv

Adding a macro and an alias in the bash configuration file makes using the virtual environments simpler. These are the lines to add.

# Python3 virtual environment ve() { source $1/bin/activate; } alias ev='deactivate'

As usual I use the nano editor to do such a simple task.

rock@rockpis:~$ nano .bashrc

Normally, I would reboot now. That will ensure that the .local/bin directory is added to the PATH. See the end of the ~/.profile configuration file where one sees that this is done when the user logs in and the directory already exists.

Install OctoPrint toc

I installed Python virtual environment tools in the previous section because I prefer to install Octoprint in a virtual environment.

rock@rockpis:~$ mkvenv OctoPrint creating virtual environment /home/michel/OctoPrint updating virtual environment /home/michel/OctoPrint

If this is the first virtual environment created, the operation can take more than a couple of minutes.

rock@rockpis:~$ ve OctoPrint (OctoPrint) rock@rockpis:~$ pip install octoprint Collecting octoprint Downloading OctoPrint-1.8.1-py2.py3-none-any.whl (3.9 MB) ... Successfully installed Babel-2.10.3 Click-8.1.3 Flask-Assets-2.0 Flask-Babel-2.0.0 Flask-Login-0.5.0 Jinja2-3.1.2 MarkupSafe-2.1.1 OctoPrint-FileCheck-2021.2.23 OctoPrint-FirmwareCheck-2021.10.11 OctoPrint-PiSupport-2022.6.13 PyYAML-5.4.1 blinker-1.4 cachelib-0.2.0 certifi-2022.6.15 charset-normalizer-2.0.12 colorlog-6.6.0 emoji-1.7.0 feedparser-6.0.10 filetype-1.0.13 flask-2.1.2 frozendict-2.3.2 future-0.18.2 idna-3.3 ifaddr-0.2.0 importlib-metadata-4.12.0 itsdangerous-2.1.2 markdown-3.3.7 netaddr-0.8.0 netifaces-0.11.0 octoprint-1.8.1 pathvalidate-2.5.0 pkginfo-1.8.3 psutil-5.9.1 pylru-1.2.1 pyserial-3.5 pytz-2022.1 regex-2022.6.2 requests-2.28.0 sarge-0.1.6 semantic-version-2.10.0 sentry-sdk-1.6.0 sgmllib3k-1.0.0 tornado-6.1 unidecode-1.3.4 urllib3-1.26.9 watchdog-1.0.2 webassets-2.0 websocket-client-1.3.3 werkzeug-2.0.3 wrapt-1.13.3 zeroconf-0.33.4 zipp-3.8.0 zipstream-ng-1.3.4

As can be seen, a large number of Python packages were installed in the process and that required a considerable amount of time. Nevertheless, it did complete without any problem.

Basically OctoPrint is a service that runs in the background. For a first test, the service will be started manually. Note that we are still in the OctoPrint virtual environment.

(OctoPrint) octpr@nauty:~$ which octoprint /home/octpr/OctoPrint/bin/octoprint (OctoPrint) octpr@nauty:~$ octoprint serve 2022-06-26 01:18:19,214 - octoprint.startup - INFO - ****************************************************************************** 2022-06-26 01:18:19,221 - octoprint.startup - INFO - Starting OctoPrint 1.8.1 2022-06-26 01:18:19,225 - octoprint.startup - INFO - ****************************************************************************** 2022-06-26 01:18:19,260 - octoprint.util.connectivity.connectivity_checker - INFO - Connectivity state is currently: online 2022-06-26 01:18:19,261 - octoprint.util.connectivity.connectivity_checker - INFO - Connecting to 1.1.1.1:53 is working 2022-06-26 01:18:19,261 - octoprint.util.connectivity.connectivity_checker - INFO - Resolving octoprint.org is working 2022-06-26 01:18:19,288 - octoprint.plugin.core - INFO - Loading plugins from /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins, /home/octpr/.octoprint/plugins and installed plugin packages... 2022-06-26 01:18:22,736 - octoprint.plugin.core - INFO - Plugin Pi Support Plugin (2022.6.13) did not pass check, not loading. 2022-06-26 01:18:23,058 - octoprint.plugin.core - INFO - Found 17 plugin(s) providing 17 mixin implementations, 34 hook handlers 2022-06-26 01:18:23,174 - octoprint.server.heartbeat - INFO - Starting server heartbeat, 900.0s interval 2022-06-26 01:18:23,213 - octoprint.server - INFO - Intermediary server started 2022-06-26 01:18:23,223 - octoprint.printer.profile - ERROR - Profile _default does not exist, creating _default again and setting it as default 2022-06-26 01:18:23,278 - octoprint.filemanager.storage - INFO - Initializing the file metadata for /home/octpr/.octoprint/uploads... 2022-06-26 01:18:23,283 - octoprint.filemanager.storage - INFO - ... file metadata for /home/octpr/.octoprint/uploads initialized successfully. 2022-06-26 01:18:23,298 - octoprint.server - INFO - Added new permission from plugin action_command_notification: PLUGIN_ACTION_COMMAND_NOTIFICATION_SHOW (needs: "Need(method='role', value='plugin_action_command_notification_show')") 2022-06-26 01:18:23,299 - octoprint.server - INFO - Added new permission from plugin action_command_notification: PLUGIN_ACTION_COMMAND_NOTIFICATION_CLEAR (needs: "Need(method='role', value='plugin_action_command_notification_clear')") 2022-06-26 01:18:23,301 - octoprint.server - INFO - Added new permission from plugin action_command_prompt: PLUGIN_ACTION_COMMAND_PROMPT_INTERACT (needs: "Need(method='role', value='plugin_action_command_prompt_interact')") 2022-06-26 01:18:23,303 - octoprint.server - INFO - Added new permission from plugin announcements: PLUGIN_ANNOUNCEMENTS_READ (needs: "Need(method='role', value='plugin_announcements_read')") 2022-06-26 01:18:23,307 - octoprint.server - INFO - Added new permission from plugin announcements: PLUGIN_ANNOUNCEMENTS_MANAGE (needs: "Need(method='role', value='plugin_announcements_manage'), Need(method='role', value='plugin_announcements_read')") 2022-06-26 01:18:23,311 - octoprint.server - INFO - Added new permission from plugin appkeys: PLUGIN_APPKEYS_ADMIN (needs: "Need(method='role', value='plugin_appkeys_admin')") 2022-06-26 01:18:23,322 - octoprint.server - INFO - Added new permission from plugin appkeys: PLUGIN_APPKEYS_GRANT (needs: "Need(method='role', value='plugin_appkeys_user')") 2022-06-26 01:18:23,327 - octoprint.server - INFO - Added new permission from plugin backup: PLUGIN_BACKUP_ACCESS (needs: "Need(method='role', value='plugin_backup_access')") 2022-06-26 01:18:23,331 - octoprint.server - INFO - Added new permission from plugin firmware_check: PLUGIN_FIRMWARE_CHECK_DISPLAY (needs: "Need(method='role', value='plugin_firmware_check_display')") 2022-06-26 01:18:23,336 - octoprint.server - INFO - Added new permission from plugin logging: PLUGIN_LOGGING_MANAGE (needs: "Need(method='role', value='plugin_logging_manage')") 2022-06-26 01:18:23,342 - octoprint.server - INFO - Added new permission from plugin pluginmanager: PLUGIN_PLUGINMANAGER_LIST (needs: "Need(method='role', value='plugin_pluginmanager_manage')") 2022-06-26 01:18:23,346 - octoprint.server - INFO - Added new permission from plugin pluginmanager: PLUGIN_PLUGINMANAGER_MANAGE (needs: "Need(method='role', value='plugin_pluginmanager_manage')") 2022-06-26 01:18:23,351 - octoprint.server - INFO - Added new permission from plugin pluginmanager: PLUGIN_PLUGINMANAGER_INSTALL (needs: "Need(method='role', value='plugin_pluginmanager_install'), Need(method='role', value='plugin_pluginmanager_manage')") 2022-06-26 01:18:23,356 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_CHECK (needs: "Need(method='role', value='plugin_softwareupdate_check')") 2022-06-26 01:18:23,360 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_UPDATE (needs: "Need(method='role', value='plugin_softwareupdate_update')") 2022-06-26 01:18:23,364 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_CONFIGURE (needs: "Need(method='role', value='plugin_softwareupdate_configure')") 2022-06-26 01:18:26,507 - octoprint.util.pip - INFO - Using "/home/octpr/OctoPrint/bin/python3 -m pip" as command to invoke pip 2022-06-26 01:18:29,596 - octoprint.util.pip - INFO - Version of pip is 22.1.2 2022-06-26 01:18:30,248 - octoprint.util.pip - INFO - pip installs to /home/octpr/OctoPrint/lib/python3.8/site-packages (writable -> yes), --user flag needed -> no, virtual env -> yes 2022-06-26 01:18:30,249 - octoprint.util.pip - INFO - ==> pip ok -> yes 2022-06-26 01:18:30,394 - octoprint.plugin.core - INFO - Initialized 17 plugin implementation(s) 2022-06-26 01:18:30,792 - octoprint.plugin.core - INFO - 17 plugin(s) registered with the system: | Action Command Notification Support (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/action_command_notification | Action Command Prompt Support (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/action_command_prompt | Announcement Plugin (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/announcements | Anonymous Usage Tracking (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/tracking | Application Keys Plugin (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/appkeys | Backup & Restore (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/backup | Core Wizard (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/corewizard | Discovery (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/discovery | Error Tracking (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/errortracking | Event Manager (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/eventmanager | File Check (2021.2.23) (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint_file_check | Firmware Check (2021.10.11) (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint_firmware_check | GCode Viewer (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/gcodeviewer | Logging (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/logging | Plugin Manager (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/pluginmanager | Software Update (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/softwareupdate | Virtual Printer (bundled) = /home/octpr/OctoPrint/lib/python3.8/site-packages/octoprint/plugins/virtual_printer Prefix legend: ! = disabled, # = blacklisted, * = incompatible 2022-06-26 01:18:30,810 - octoprint.environment - INFO - Detected environment is Python 3.8.10 under Linux (linux). Details: | hardware: | cores: 4 | freq: 1296.0 | ram: 511332352 | os: | bits: 64 | id: linux | platform: linux | python: | pip: 22.1.2 | version: 3.8.10 | virtualenv: /home/octpr/OctoPrint 2022-06-26 01:18:30,838 - octoprint.server - INFO - Reset webasset folder /home/octpr/.octoprint/generated/webassets... 2022-06-26 01:18:30,841 - octoprint.server - INFO - Reset webasset folder /home/octpr/.octoprint/generated/.webassets-cache... 2022-06-26 01:18:30,845 - octoprint.server - INFO - Reset webasset folder /home/octpr/.octoprint/generated/.webassets-manifest.json... 2022-06-26 01:18:32,201 - octoprint.server - INFO - Shutting down intermediary server... 2022-06-26 01:18:32,247 - octoprint.server - INFO - Intermediary server shut down 2022-06-26 01:18:32,256 - octoprint.events - INFO - Processing startup event, this is our first event 2022-06-26 01:18:32,257 - octoprint.events - INFO - Adding 0 events to queue that were held back before startup event 2022-06-26 01:18:32,260 - octoprint.filemanager - INFO - Adding backlog items from all storage types to analysis queue... 2022-06-26 01:18:32,284 - octoprint.server.util.watchdog - INFO - Running initial scan on watched folder... 2022-06-26 01:18:32,315 - octoprint.server.util.watchdog - INFO - ... initial scan done. 2022-06-26 01:18:32,316 - octoprint.filemanager - INFO - Added 0 items from storage type "local" to analysis queue 2022-06-26 01:18:33,198 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on nauty._http._tcp.local.' for _http._tcp.local. 2022-06-26 01:18:34,095 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on nauty._octoprint._tcp.local.' for _octoprint._tcp.local. 2022-06-26 01:18:34,113 - octoprint.plugins.discovery - INFO - Registered OctoPrint instance on nauty for SSDP 2022-06-26 01:18:34,159 - octoprint.server - INFO - Listening on http://0.0.0.0:5000 and http://[::]:5000 2022-06-26 01:18:35,001 - octoprint.plugins.announcements - INFO - Loaded channel _important from https://octoprint.org/feeds/important.xml in 0.56s 2022-06-26 01:18:35,357 - octoprint.plugins.pluginmanager - INFO - Loaded plugin repository data from https://plugins.octoprint.org/plugins.json 2022-06-26 01:18:36,291 - octoprint.plugins.announcements - INFO - Loaded channel _releases from https://octoprint.org/feeds/releases.xml in 0.96s 2022-06-26 01:18:37,651 - octoprint.plugins.announcements - INFO - Loaded channel _blog from https://octoprint.org/feeds/octoblog.xml in 0.63s 2022-06-26 01:18:37,907 - octoprint.util.pip - INFO - Using "/home/octpr/OctoPrint/bin/python3 -m pip" as command to invoke pip 2022-06-26 01:18:37,910 - octoprint.util.pip - INFO - pip installs to /home/octpr/OctoPrint/lib/python3.8/site-packages (writable -> yes), --user flag needed -> no, virtual env -> yes 2022-06-26 01:18:37,910 - octoprint.util.pip - INFO - ==> pip ok -> yes 2022-06-26 01:18:38,032 - octoprint.plugins.softwareupdate - INFO - Minimum free storage across all update relevant locations is 12.6GB. That is considered sufficient for updating. 2022-06-26 01:18:38,053 - octoprint.plugins.softwareupdate - INFO - Fetching check overlays from https://plugins.octoprint.org/update_check_overlay.json 2022-06-26 01:18:39,282 - octoprint.plugins.announcements - INFO - Loaded channel _plugins from https://plugins.octoprint.org/feed.xml in 0.63s 2022-06-26 01:18:40,976 - octoprint.plugins.announcements - INFO - Loaded channel _octopi from https://octoprint.org/feeds/octopi.xml in 0.64s 2022-06-26 01:18:43,084 - octoprint.util.pip - INFO - Using "/home/octpr/OctoPrint/bin/python3 -m pip" as command to invoke pip 2022-06-26 01:18:43,087 - octoprint.util.pip - INFO - pip installs to /home/octpr/OctoPrint/lib/python3.8/site-packages (writable -> yes), --user flag needed -> no, virtual env -> yes 2022-06-26 01:18:43,087 - octoprint.util.pip - INFO - ==> pip ok -> yes 2022-06-26 01:18:43,112 - octoprint.plugins.softwareupdate - INFO - Saved version cache to disk 2022-06-26 01:18:43,193 - octoprint.plugins.pluginmanager - INFO - Loaded plugin notices data from https://plugins.octoprint.org/notices.json

Start a web browser on the desktop machine and open the page with the following URL: http://192.168.3.24:5000 or http://rockpis.local:5000 if mDns is supported. The octoprint server will publish some messagess about the connection on the terminal.

2022-06-26 01:21:34,842 - octoprint.server.util.flask.PreemptiveCache - INFO - Adding entry for / and {'path': '/', 'base_url': 'http://rockpis.local:5000/', 'query_string': 'l10n=en', '_timestamp': 1656217294.8422449, '_count': 1} 2022-06-26 01:21:49,861 - octoprint.server.util.sockjs - INFO - New connection from client: 192.168.3.100

Octoprint Configuration toc

Time to configure and minimally test OctoPrint. To do this properly, the possibility of the 3D printer "back powering" itself from the Rock Pi S should be investigated. My printer is not listed in Printers known to have back powering issues, but I nevertheless followed the advice in Put tape on the 5 V pin - Why and how. Once this safeguard is in place here is what needs to be done.

  1. Connect the camera module to the Rock Pi S
  2. Connect the Rock Pi S to the 3D printer
  3. Start the printer
  4. Turn on the power to the Rock Pi S
  5. Open an SSH session with the Rock Pi S and start the mjpg-streamer service:
    rock@rockpis:~ $ mjpg_streamer -o "output_http.so" -i "input_uvc.so"
  6. Open a second SSH sessions and activate the Python virtual environment and start octoprint on the Rock pPi:
    rock@rockpis:~ $ ve OctoPrint rock@rockpis:~ $ octoprint serve
  7. Connect to the OctoPrint Web interface at URL: 192.168.3.24:5000 with a web browser on the desktop.

The start page of the Setup Wizard should be displayed.

OctoPrint First Screen

Frankly the setup wizard does a lot of hand-holding and the configuration is rather simple. There was no real need to reproduce all the steps as I have done below.. If, for some reason, the installation goes pear-shaped, then open the web interface again and click on the wrench (spanner) icon (the hint Settings pops up when the mouse pointer hovers over the icon situated on the title bar). This will bring up the complete OctoPrint Settings menu which contains many settings pages including those displayed by the wizard as shown next. Click on the Next button to start the process

Since I had never used OctoPrint before, the next step which allows for restoring the program settings from a backup was of no use to me.

But seeing this means that it is a good idea to save the settings in order to simplify future installations of OctoPrint. Pressing the Next button brings up the following mandatory step:

Enter a user name, password (twice) and click on the Create Account button. Don't forget the user name and password as these will be required from now on whenever logging into the OctoPrint web interface. Once the account has been created, the user name will show up in the top right corner (see next image). Click on Next button.

I clicked o the Enable Connectivity Check button accepting all default values, but, of course, it is possible to choose to disable this check or to modify the IP and URL that are "pinged" while performing the verification that the Rock Pi S can access the Internet. There seems to be a discrepancy about the default DNS server (is it Google=8.8.8.8 or Cloudflare=1.1.1.1?), but both are "highly available" DNS servers.

Click on the Enable... or the Disable Anonymous Usage Tracking button according to your preference and then move on to the Next step.

This setting is about protecting the OctoPrint instance from undesirable third-party plugins. That seemed like a good idea so I enabled the blacklist processing and moved on to the Next set of settings that have to do with the 3D printer.

The settings in the General tab identify the default profile printer. I left the _default Identifier value and changed the Name and Model to reasonable values given that I own only one 3D printer.

In the second tab, Print bed & build volume, I unchecked Heated Bed and modified the print volume. I didn't change anything in the Axes and the Hotend & extruder tabs.

I entered the suggested server commands that should work for all instances of OctoPrint running on Debian based Linux distributions such as the one installed on the Rock Pi S.

The last setup wizard settings page is used to configure the webcam and time-lapse recording. I set the following three values:

    Stream URL        http://192.168.3.24:8080/?action=stream
    Snapshot URL      http://192.168.3.24:8080/?action=Snapshot
    Path to FFMPGE    /usr/bin/ffmpeg

These values will need to be adapted for each particular installation. And that's about it for the setup wizard. The next page merely confirms that the process is finished.

At this point, I suggest closing the web interface.

Octoprint Usage toc

On accessing the Octoprint web interface again, it will be necessary to log in with the user name and password according to the Access Control settings.

Once the correct credentials are entered, the web interface will be displayed.

The window is divided into three main parts. There is a title bar across the top containing icons for settings, power, announcements and the user account. Below that bar, there are two panels. The left panel is where the user will perform tasks such as connecting to the printer, upload files to it, start prints and so on. The right panel is used to monitor the printer's temperature, view the video stream if a camera has been connected, view the GCode, and so on.

On my simple system, establishing the serial connection over USB is as easy as clicking on the Connect button in Connection section of the left panel. Even if neither the Serial Port nor the Baudrate is specified (they are both set to AUTO), octoprint has no problem finding the 3D printer.

If the 3D printer is not found, try setting the serial port and click on the Connect button. The script will attempt to connect with the printer using a number of commonly used bauds. If even this does not work, make sure that the default user is a member of the dialout group.

As soon as the serial connection is established, the printer sends the temperature of the nozzle which is plotted on the graph. Clicking on the Terminal tab will show the temperature reports as they come in every two seconds or so. Check the Suppress temperature messages and it will be easier to see the information octoprint obtained from the printer. Here is a line that seemed important.

Recv: FIRMWARE_NAME:Marlin V0.0.4 (Github) SOURCE_CODE_URL:https://github.com/MarlinFirmware/Marlin PROTOCOL_VERSION:1.0 MACHINE_TYPE:Mega Zero EXTRUDER_COUNT:1

Clearly, my 3D printer firmware, the ubiquitous Marlin, is rather old. There are newer versions available for the Mega Zero, but that's beyond the scope of this discussion. In the central panel Control tab sheet, there were buttons that made it possible to move the nozzle along the three axes. Because I had not modified the nozzle temperature (which can be in the Temperature tab sheet), I did not test extruding or retracting the filament. I did try to turn the fan off but that produced no effect. I checked in the terminal and saw that the correct GCode was sent to the printer:

Send: M106 S0 Recv: ok ...

It responded with an OK but the fan remained on. I was not too surprised by that; the printer menu choice to turn off the fan does not work. Something to look into. I then moved on to Control tab in the Web interface.

If a black border appears around the images, the correct stream aspect ratio may be specified in the OctoPrint Webcam & Timelapse Settings as shown below.

That particular page is reached by clicking on the spanner icon at the top of the Web page and then selecting the Webcam & Timelapse in the list on the left. Note that the image can be rotated if needed in the same page. Do not forget to clik on the Save button at the bottom of the page.

If there is something wrong, the following will be displayed.

The instructions on the screen provide a good starting point to find the error:

  1. Is mjpg_streamer running? Try
  2. rock@rockpis:~ $ pidof mjpg_streamer 1184
    If no pid number is shown, then the daemon is not running.
  3. If the streamer is running then perhaps the wrong input module was specified. Use input_uvc.so for a webcam.
  4. Check the URL.

If all that is seen is a black screen, or if the image is washed out or over saturated, then perhaps the problem can be fixed with the MJPG-Streamer Control interface. If mjpg_streamer is running, close it by entering CtrlC key combination in its terminal and then restart the streamer enabling its web interface.

rock@rockpis:~ $ mjpg_streamer -i 'input_uvc.so' -o 'output_http.so -p 8080 -w /usr/local/share/mjpg-streamer/www'

Open the MJPG-Streamer web interface at the correct address (http://192.168.3.24:8080/ in my case) in a web browser on the desktop machine. Click on Stream in the menu on the left and then click on Control in the same menu. This will bring up a pop up page where the camera parameters can be adjusted in real time.

This is not a 3D printed cup... I just wanted something red to help in setting the colour balance the nearest thing that filled the bill was my favourite coffee mug.

If the Privacy setting is checked, then the stream is blanked (actually that setting does not survive a reboot). If Saturation is set to 0 then the video stream will be in black & white. If Hue is too high, the colors will be way off and if Contrast is too low everything will be greyish. In any case experiment with these values and note what seems to work best. Turn the power off to the web cam, reboot the machine and return to this screen to see which parameters were reset during the reboot and which remained unchanged. The input module of mjpg_streamer accepts many options that can be set if needed.

rock@rockpis:~ $ mjpg_streamer -i "input_uvc.so --help" --------------------------------------------------------------- Help for input plugin..: UVC webcam grabber --------------------------------------------------------------- The following parameters can be passed to this plugin: [-d | --device ].......: video device to open (your camera) [-r | --resolution ]...: the resolution of the video device, can be one of the following strings: QQVGA QCIF CGA QVGA CIF PAL VGA SVGA XGA HD SXGA UXGA FHD or a custom value like the following example: 640x480 [-f | --fps ]..........: frames per second (camera may coerce to different value) [-q | --quality ] .....: set quality of JPEG encoding [-m | --minimum_size ].: drop frames smaller then this limit, useful if the webcam produces small-sized garbage frames may happen under low light conditions [-e | --every_frame ]..: drop all frames except numbered [-n | --no_dynctrl ]...: do not initalize dynctrls of Linux-UVC driver [-l | --led ]..........: switch the LED "on", "off", let it "blink" or leave it up to the driver using the value "auto" [-t | --tvnorm ] ......: set TV-Norm pal, ntsc or secam [-u | --uyvy ] ........: Use UYVY format, default: MJPEG (uses more cpu power) [-y | --yuv ] ........: Use YUV format, default: MJPEG (uses more cpu power) [-fourcc ] ............: Use FOURCC codec 'argopt', currently supported codecs are: RGB24, RGBP [-timestamp ]..........: Populate frame timestamp with system time [-softfps] ............: Drop frames to try and achieve this fps set your camera to its maximum fps to avoid stuttering [-timeout] ............: Timeout for device querying (seconds) [-dv_timings] .........: Enable DV timings queriyng and events processing --------------------------------------------------------------- Optional parameters (may not be supported by all cameras): [-br ].................: Set image brightness (auto or integer) [-co ].................: Set image contrast (integer) [-sh ].................: Set image sharpness (integer) [-sa ].................: Set image saturation (integer) [-cb ].................: Set color balance (auto or integer) [-wb ].................: Set white balance (auto or integer) [-ex ].................: Set exposure (auto, shutter-priority, aperature-priority, or integer) [-bk ].................: Set backlight compensation (integer) [-rot ]................: Set image rotation (0-359) [-hf ].................: Set horizontal flip (true/false) [-vf ].................: Set vertical flip (true/false) [-pl ].................: Set power line filter (disabled, 50hz, 60hz, auto) [-gain ]...............: Set gain (auto or integer) [-cagc ]...............: Set chroma gain control (auto or integer) ---------------------------------------------------------------

Obviously, what can be achieved will depend on the particular web camera used.

Enabling the Services toc

It would be practical if both OctoPrint and MJPG-Streamer were started automatically when the Rock Pi S is booted. Here is the suggested systemd service files for octoprint and mjpg_streamer that accomplish this.

[Unit] Description=The snappy web interface for your 3D printer After=network-online.target Wants=network-online.target [Service] Environment="LC_ALL=C.UTF-8" Environment="LANG=C.UTF-8" Type=simple User=rock ExecStart=/home/rockpi/OctoPrint/bin/octoprint [Install] WantedBy=multi-user.target

This file is from the Octoprint Github repository with adjustments to two fields as indicated.

Here is the other unit file for the webcam video streamer.

[Unit] Description=A server for streaming Motion-JPEG from /dev/video0 - Microsoft LifeCam VX-2000 (045e:0761) After=network.target [Service] ExecStart=/usr/local/bin/mjpg_streamer -i 'input_uvc.so -n' -o 'output_http.so -p 8080 -w /usr/local/share/mjpg-streamer/www' Restart=always RestartSec=10 [Install] WantedBy=multi-user.target

Save both files in the /etc/systems/system directory under the names octoprint.service and mjpg_streamer.service respectively, making sure that root is their owner. Then enable both.

rock@rockpis:~ $ sudo systemctl enable octoprint.service Created symlink /etc/systemd/system/multi-user.target.wants/octoprint.service → /etc/systemd/system/octoprint.service. rock@rockpis:~ $ sudo systemctl enable mjpg_streamer.service Created symlink /etc/systemd/system/multi-user.target.wants/mjpg_streamer.service → /etc/systemd/system/mjpg_streamer.service.

And that should be a working installation of Octoprint on the Rock Pi S.

<-Installing an OS on the Rock Pi S
<-OctoPrint on a Raspberry Pi 3