sanja Posted December 10, 2019 Posted December 10, 2019 Hi. I've upgraded Buinic to Eoan and encountered an error with apt-get. Decided to have a fresh install of Disco from https://dl.armbian.com/orangepizero/ and got exact same error. I did nothing with the installation except that I've configured WiFi with ntmui-connect command. So I guess this is some issue with Ubuntu releases 19.xx root@orangepizero:~# apt-get update && apt-get upgrade Hit:1 http://ports.ubuntu.com disco InRelease Hit:2 http://ports.ubuntu.com disco-security InRelease Hit:3 http://ports.ubuntu.com disco-updates InRelease Hit:5 http://ports.ubuntu.com disco-backports InRelease Hit:4 https://apt.armbian.com disco InRelease Traceback (most recent call last): File "/usr/lib/cnf-update-db", line 26, in <module> col.create(db) File "/usr/lib/python3/dist-packages/CommandNotFound/db/creator.py", line 93, in create self._fill_commands(con) File "/usr/lib/python3/dist-packages/CommandNotFound/db/creator.py", line 127, in _fill_commands self._parse_single_commands_file(con, fp) File "/usr/lib/python3/dist-packages/CommandNotFound/db/creator.py", line 165, in _parse_single_commands_file suite=tagf.section["suite"] KeyError: 'suite' Reading package lists... Done E: Problem executing scripts APT::Update::Post-Invoke-Success 'if /usr/bin/test -w /var/lib/command-not-found/ -a -e /usr/lib/cnf-update-db; then /usr/lib/cnf-update-db > /dev/null; fi' E: Sub-process returned an error code
guidol Posted December 10, 2019 Posted December 10, 2019 maybe this page could help a little bit?: https://askubuntu.com/questions/1041226/problem-with-sudo-apt-update-in-ubuntu-18-04/1041235
sanja Posted December 10, 2019 Author Posted December 10, 2019 No, I tried that - it didn't resolve the issue. I also considered a theory that an upgrade messed python 2.7 and 3.6 - didn't solve my problem as well.
guidol Posted December 10, 2019 Posted December 10, 2019 on my OrangePi One creator.py is at root@opi-one(192.168.6.114):/ # find / -name *creator* /usr/share/command-not-found/CommandNotFound/db/creator.py and cnf-update-db is as a symbolic link at the right place root@opi-one(192.168.6.114):/usr/lib# ls -l cnf* lrwxrwxrwx 1 root root 40 Nov 21 2018 cnf-update-db -> ../share/command-not-found/cnf-update-db so whats the error after sudo cp -r /usr/share/command-not-found/CommandNotFound /usr/lib/python3/dist-packages/
sanja Posted December 10, 2019 Author Posted December 10, 2019 I will check in a moment. Currently trying other distributions. Found out that there is no wireless connectivity on Armbian_19.11.3_Orangepizero_buster_current_5.3.9 (nmtui-connect only displays "Wired connection 1"). root@orangepizero:~# ip link 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 2: dummy0: <BROADCAST,NOARP> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000 link/ether 2a:d0:11:70:4e:02 brd ff:ff:ff:ff:ff:ff 3: eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN mode DEFAULT group default qlen 1000 link/ether 02:42:e8:02:49:d9 brd ff:ff:ff:ff:ff:ff 4: wlan0: <BROADCAST,MULTICAST> mtu 1500 qdisc mq state DOWN mode DEFAULT group default qlen 1000 link/ether e2:2f:6f:d6:df:b2 brd ff:ff:ff:ff:ff:ff root@orangepizero:~# ip link set dev wlan0 up RTNETLINK answers: Invalid argument root@orangepizero:~#
guidol Posted December 10, 2019 Posted December 10, 2019 19 minutes ago, sanja said: I will check in a moment. Currently trying other distributions. Found out that there is no wireless connectivity on Armbian_19.11.3_Orangepizero_buster_current_5.3.9 (nmtui-connect only displays "Wired connection 1"). your problem is just one thread aways (from the actual one's):
martinayotte Posted December 10, 2019 Posted December 10, 2019 7 minutes ago, guidol said: your problem is just one thread aways (from the actual one's): As I said in this other thread : Quote In my case, I'm using "old school" /etc/network/interface, running Stretch 5.4.2, and WiFi running properly as soon as I disabled NetworkManager service. 1
sanja Posted December 10, 2019 Author Posted December 10, 2019 Re-installed Disco, wireless connectivity worked, but apt-get update produces error. Checking: root@orangepizero:~# cd /usr/lib root@orangepizero:/usr/lib# ls -l cnf* -rwxr-xr-x 1 root root 684 Nov 9 2018 cnf-update-db root@orangepizero:/usr/lib# find / -name *creator* /usr/lib/python3/dist-packages/CommandNotFound/db/creator.py /usr/lib/python3/dist-packages/CommandNotFound/db/__pycache__/creator.cpython-37.pyc root@orangepizero:/usr/lib# cp -r /usr/share/command-not-found/CommandNotFound /usr/lib/python3/dist-packages/ cp: cannot stat '/usr/share/command-not-found/CommandNotFound': No such file or directory Tried sudo cp -r /usr/lib/python3/dist-packages/CommandNotFound /usr/share/command-not-found/ and also sudo cp -r /usr/lib/python3/dist-packages/CommandNotFound /var/lib/command-not-found/ Error is caused by /usr/lib/cnf-update-db in the line 165, which reads: # read header suite=tagf.section["suite"] and then causes error in line 127, which is def _fill_commands(self, con): for f in self.files: with open(f) as fp: self._parse_single_commands_file(con, fp) As far as I can understand, it works with this list of files: root@orangepizero:~# ls -la /var/lib/apt/lists/*Commands-* -rw-r--r-- 1 root root 699 May 29 2019 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-backports_main_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 74 Nov 21 2018 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-backports_multiverse_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 74 Nov 21 2018 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-backports_restricted_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 156 Sep 14 07:17 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-backports_universe_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 8023 Oct 23 22:22 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-security_main_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 73 Nov 21 2018 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-security_multiverse_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 73 Nov 21 2018 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-security_restricted_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 7297 Oct 21 20:17 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-security_universe_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 13128 Oct 24 14:17 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-updates_main_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 72 Nov 21 2018 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-updates_multiverse_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 72 Nov 21 2018 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-updates_restricted_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 9799 Oct 24 14:17 /var/lib/apt/lists/ports.ubuntu.com_dists_disco-updates_universe_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 48897 Apr 17 2019 /var/lib/apt/lists/ports.ubuntu.com_dists_disco_main_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 13300 Apr 17 2019 /var/lib/apt/lists/ports.ubuntu.com_dists_disco_multiverse_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 354 Feb 22 2019 /var/lib/apt/lists/ports.ubuntu.com_dists_disco_restricted_cnf_Commands-armhf.lz4 -rw-r--r-- 1 root root 475539 Apr 18 2019 /var/lib/apt/lists/ports.ubuntu.com_dists_disco_universe_cnf_Commands-armhf.lz4
guidol Posted December 10, 2019 Posted December 10, 2019 9 minutes ago, sanja said: Tried sudo cp -r /usr/lib/python3/dist-packages/CommandNotFound /usr/share/command-not-found/ Hmm - I did wrote the command with the path as oposite ( /usr/share in front , because it is there on my system): sudo cp -r /usr/share/command-not-found/CommandNotFound /usr/lib/python3/dist-packages/
sanja Posted December 10, 2019 Author Posted December 10, 2019 22 minutes ago, guidol said: Hmm - I did wrote the command with the path as oposite ( /usr/share in front , because it is there on my system): To double-check, wiped the SD card and burned the image again. On fresh system: Welcome to Armbian Disco with Linux 5.3.9-sunxi System load: 0.00 0.11 0.10 Up time: 8 min Memory usage: 15 % of 491MB IP: CPU temp: 66°C Usage of /: 6% of 15G root@orangepizero:~# ls -la /usr/lib/python3/dist-packages/CommandNotFound total 40 drwxr-xr-x 4 root root 4096 Nov 1 09:35 . drwxr-xr-x 14 root root 4096 Nov 1 09:34 .. -rw-r--r-- 1 root root 16319 May 4 2018 CommandNotFound.py drwxr-xr-x 3 root root 4096 Nov 1 09:35 db -rw-r--r-- 1 root root 40 Mar 16 2018 __init__.py drwxr-xr-x 2 root root 4096 Nov 1 09:35 __pycache__ -rw-r--r-- 1 root root 1641 Mar 16 2018 util.py root@orangepizero:~# ls -la /usr/share/command-not-found/ total 2624 drwxr-xr-x 2 root root 4096 Nov 1 09:27 . drwxr-xr-x 93 root root 4096 Nov 19 08:13 .. -rw-r--r-- 1 root root 2678784 Nov 9 2018 commands.db root@orangepizero:~# ls -la /var/lib/command-not-found/ total 32 drwxr-xr-x 2 root root 4096 Nov 19 08:15 . drwxr-xr-x 27 root root 4096 Nov 1 09:30 .. -rw-r--r-- 1 root root 24576 Nov 19 08:15 commands.db.tmp The /usr/lib/cnf-update-db throws error "out of the box": I never ran apt-get, I even haven't set up networking - it is "dead on arrival".
Werner Posted December 11, 2019 Posted December 11, 2019 Quote it is "dead on arrival". Non-LTS Ubuntu releases are not supported anyways. The ability to built those through the build system has been added by user contribution. They are to be considered experimental.
Igor Posted December 11, 2019 Posted December 11, 2019 12 minutes ago, Werner said: experimental Exactly. Anything out from Bionic and Buster is not supported / on your own risk. We have no intention nor resources to fix after buggy Ubuntu development and/or non LTS releases. But if one like to use it, use it ... Since last major upgrade, DISTRIBUTION status is getting a property and if you are running not one of them, you also get prompted: https://github.com/armbian/build/blob/master/lib/main.sh#L273-L286https://github.com/armbian/build/blob/master/packages/bsp/common/etc/profile.d/armbian-check-first-login.sh#L80-L82
sanja Posted December 11, 2019 Author Posted December 11, 2019 3 hours ago, Igor said: Exactly. Anything out from Bionic and Buster is not supported / on your own risk. We have no intention nor resources to fix after buggy Ubuntu development and/or non LTS releases. Well, my intention was to use Debian Buster, but its wifi connectivity is broken, so I had to start shopping around.
Igor Posted December 11, 2019 Posted December 11, 2019 1 hour ago, sanja said: but its wifi connectivity is broken Canonical / Ubuntu / Debian / * are not responsible for low level (hardware) functions, (Armbian) Linux kernel is. We provide different user space versions (Debian X, Ubuntu Y) for application level.purposes and testings. Wifi on this board is low/barely usable quality even when available.
emk2203 Posted May 22, 2020 Posted May 22, 2020 This error rears its ugly head again in Focal 20.04LTS with the OPi0. Googling for results for this error (it's exactly the same) gives exactly one google result - this thread. So, for anyone else stumbling over this, here the solution: sudo apt purge command-not-found sudo apt --purge autoremove sudo bash -c 'apt update && apt full-upgrade && apt autoremove && apt clean' Unfortunately, a reinstall of the pkg 'command-not-found' brings back the same error. This package is just for comfort. If you need suggestions for installing packages after entering nonexisting commands, just use another computer for reference. I advise to just leave it uninstalled for now.
chrmhoffmann Posted July 25, 2020 Posted July 25, 2020 Seems there are some hits: https://bugs.launchpad.net/ubuntu/+source/command-not-found/+bug/1876034 That one includes a patch that could be applied. Chris
Recommended Posts