Downloaded packages fail to install on new image?

Hi,

I have just built and openwrt image and successfully flashed my device netgear wndr3700v2. But I get errors when I try to install via opkg, its giving me weird dependency errors that I dont understand.

The build is OpenWrt SNAPSHOT, r19123-2de86691b6

trying to install any kernel package (after a successful opkg update) gives these type of errors

opkg install kmod-nls-utf8
Multiple packages (libgcc1 and libgcc1) providing same name marked HOLD or PREFER. Using latest.
Unknown package 'kmod-nls-utf8'.
Collected errors:
 * pkg_hash_check_unresolved: cannot find dependency kernel (= 5.10.109-1-3b4fcf4c30b5469f3d848f376f9648de) for kmod-nls-base
 * pkg_hash_check_unresolved: cannot find dependency kernel (= 5.10.109-1-3b4fcf4c30b5469f3d848f376f9648de) for kmod-nls-utf8
 * pkg_hash_fetch_best_installation_candidate: Packages for kmod-nls-utf8 found, but incompatible with the architectures configured
 * opkg_install_cmd: Cannot install package kmod-nls-utf8.

I have no idea what these errors are really telling me, and advice most welcome!!

Thanks

nick

If you use your own build, you also have to use your own kmods, because of kernel dependencies.

2 Likes

Hmmm, I was following some online links for adding the capability of reading a USB pen drive. This had several kmod modules linked to the opkg install command.

If this article was correct, the opgk would always fail - since you were attempting to install the kernel module as your build kernel does not contain it!!!!!????

Or to put it another way, how can I ensure I build
an openwrt kernel that is compatible with an opkg installing a kernel module?

Many thanks for replying!

Nick

The safest way would be to include it in the kernel, so * instead of M in menuconfig.

But I doubt you need your own image to be able to read an USB storage device, use official images, if you can.

Thanks for your lightening response :slight_smile:

I'm not clear exactly what is the official image?!!

Clearly there are the images on Netgears site that are over 10 years old, and then there are the factory images that seem to drop out as part of each git clone and build, then I guess there are the images online from each openwrt update/release.

In the this context, which is the 'official image' that opkg kernel module installs will be guaranteed to work with.

Thank your patience!

Regards nick

Sorry, just assumed you built the image from scratch ...

The issue you're having is caused by trying to install newer snapshot kernel packages on an older snapshot firmware build.

You'll need to upgrade to the newest snapshot before you can install the packages.

Well, Netgear's own site has nothing to do with current OpenWrt firmwares or opkg package installations.

The stable "permanent" builds are the openwrt release builds, not snapshots. Snapshots get updated so frequently that packages computability is only short-term.

You should install the newest released firmware, 21.02.2
All add-on packages have been compiled for it and are permanently available for download. The kernel packages should all be compatible with the kernel itself.

1 Like

Hi hnyman,

Thanks for your input, which made perfect sense, I had not appreciated I had got a snapshot rather than stable release. However it still did not work :frowning:

I installed with
git clone https://git.openwrt.org/openwrt/openwrt.git
cd openwrt
git pull
git branch -a
git tag
git checkout v21.02.2
./scripts/feeds update -a
./scripts/feeds install -a
make menuconfig (put in wndr3700v1, and ath79) and built the image (no errors/warnings) and flashed the wndr, all good.

I then tried to install the usb, modules (as documented here https://openwrt.org/docs/guide-user/storage/usb-drives-quickstart), and installing after opkg update gives:

opkg install block-mount e2fsprogs kmod-fs-ext4 kmod-usb-storage
 kmod-usb2 kmod-usb3
Installing block-mount (2021-01-04-c53b1882-1) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/targets/ath79/generic/packages/block-mount_2021-01-04-c53b1882-1_mips_24kc.ipk
Installing e2fsprogs (1.45.6-2) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/packages/mips_24kc/base/e2fsprogs_1.45.6-2_mips_24kc.ipk
Installing librt (1.1.24-3) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/targets/ath79/generic/packages/librt_1.1.24-3_mips_24kc.ipk
Installing libuuid1 (2.36.1-2) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/packages/mips_24kc/base/libuuid1_2.36.1-2_mips_24kc.ipk
Installing libblkid1 (2.36.1-2) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/packages/mips_24kc/base/libblkid1_2.36.1-2_mips_24kc.ipk
Installing libcomerr0 (1.45.6-2) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/packages/mips_24kc/base/libcomerr0_1.45.6-2_mips_24kc.ipk
Installing libss2 (1.45.6-2) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/packages/mips_24kc/base/libss2_1.45.6-2_mips_24kc.ipk
Installing libext2fs2 (1.45.6-2) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/packages/mips_24kc/base/libext2fs2_1.45.6-2_mips_24kc.ipk
Unknown package 'kmod-fs-ext4'.
Unknown package 'kmod-usb-storage'.
Package kmod-usb2 (5.4.179-1) installed in root is up to date.
Unknown package 'kmod-usb3'.
Configuring librt.
Configuring libuuid1.
Configuring block-mount.
Configuring libblkid1.
Configuring libcomerr0.
Configuring libss2.
Configuring libext2fs2.
Configuring e2fsprogs.
Collected errors:
 * pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-lib-crc16
 * pkg_hash_fetch_best_installation_candidate: Packages for kmod-lib-crc16 found, but incompatible with the architectures configured
 * pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-crypto-hash
 * pkg_hash_fetch_best_installation_candidate: Packages for kmod-crypto-hash found, but incompatible with the architectures configured
 * pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-crypto-crc32c
 * pkg_hash_fetch_best_installation_candidate: Packages for kmod-crypto-crc32c found, but incompatible with the architectures configured
 * pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-fs-ext4
 * pkg_hash_fetch_best_installation_candidate: Packages for kmod-fs-ext4 found, but incompatible with the architectures configured
 * opkg_install_cmd: Cannot install package kmod-fs-ext4.
 * pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-scsi-core
 * pkg_hash_fetch_best_installation_candidate: Packages for kmod-scsi-core found, but incompatible with the architectures configured
 * pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-usb-storage
 * pkg_hash_fetch_best_installation_candidate: Packages for kmod-usb-storage found, but incompatible with the architectures configured
 * opkg_install_cmd: Cannot install package kmod-usb-storage.
 * pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-usb3
 * pkg_hash_fetch_best_installation_candidate: Packages for kmod-usb3 found, but incompatible with the architectures configured
 * opkg_install_cmd: Cannot install package kmod-usb3.
Installing libcomerr0 (1.45.6-2) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/packages/mips_24kc/base/libcomerr0_1.45.6-2_mips_24kc.ipk
Installing libss2 (1.45.6-2) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/packages/mips_24kc/base/libss2_1.45.6-2_mips_24kc.ipk

Installing libext2fs2 (1.45.6-2) to root...
Downloading https://downloads.openwrt.org/releases/21.02.2/packages/mips_24kc/base/libext2fs2_1.45.6-2_mips_24kc.ipk
Unknown package 'kmod-fs-ext4'.
Unknown package 'kmod-usb-storage'.
Package kmod-usb2 (5.4.179-1) installed in root is up to date.
Unknown package 'kmod-usb3'.
Configuring librt.
Configuring libuuid1.
Configuring block-mount.
Configuring libblkid1.
Configuring libcomerr0.
Configuring libss2.
Configuring libext2fs2.
Configuring e2fsprogs.
Collected errors:
* pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-lib-crc16
* pkg_hash_fetch_best_installation_candidate: Packages for kmod-lib-crc16 found, but incompatible with the architectures configured
* pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-crypto-hash
* pkg_hash_fetch_best_installation_candidate: Packages for kmod-crypto-hash found, but incompatible with the architectures configured
* pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-crypto-crc32c

* pkg_hash_fetch_best_installation_candidate: Packages for kmod-crypto-crc32c found, but incompatible with the architectures configured
* pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-fs-ext4
* pkg_hash_fetch_best_installation_candidate: Packages for kmod-fs-ext4 found, but incompatible with the architectures configured
* opkg_install_cmd: Cannot install package kmod-fs-ext4.
* pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-scsi-core
* pkg_hash_fetch_best_installation_candidate: Packages for kmod-scsi-core found, but incompatible with the architectures configured
* pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-usb-storage
* pkg_hash_fetch_best_installation_candidate: Packages for kmod-usb-storage found, but incompatible with the architectures configured
* opkg_install_cmd: Cannot install package kmod-usb-storage.
* pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for kmod-usb3
* pkg_hash_fetch_best_installation_candidate: Packages for kmod-usb3 found, but incompatible with the architectures configured
* opkg_install_cmd: Cannot install package kmod-usb3.

The key errors seems to be

' Packages for -------- found, but incompatible with the architectures configured'

and 'pkg_hash_check_unresolved: cannot find dependency kernel (= 5.4.179-1-3dfa0daff435bb57055a8e5b5a232fe2) for ----'

Any further ideas, Other than frollics fix of building the packages into the kernel? I dont understand why this now fails, have I somehow badly configured the build at the menuconfig stage?

Further thought most welcome!!??

Thanks

nick

For kernel add-on packages there is a rather strict checksum logic, based on all kernel config options and packages, which in practice means that you can only install kmods from the same build run.

If you compile a personal build, you need to compile kmods into the build.

You can install kmods from the download repo to the actual official release builds.

4 Likes

Thank you both, works a treat.
I have learnt alot :smiley: :smiley: :smiley:

If your problem is solved, please consider marking this topic as [Solved]. See How to mark a topic as [Solved] for a short how-to.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.