Firmware-linux-nonfree unmet dependencies on Internet Cube [Solved]

Hi everybody,

I encounter a

E: Sub-process /usr/bin/dpkg returned an error code (1)

when I try to upgrade a fresh install of La Brique Internet on Olimex Lime1 from the image https://build.yunohost.org/yunohost-stretch-3.4.2.4-lime-stable.img.zip with a cube file generated through https://install.labriqueinter.net/
Wifi-Hotspot and VPN up to date.

ynh-hotspot:
active: active
active_at: 2019-07-05 05:28:11
description: YunoHost Wifi Hotspot.
loaded: enabled
service_file_path: /etc/systemd/system/ynh-hotspot.service
status: exited
ynh-vpnclient:
active: active
active_at: 2019-07-05 05:28:00
description: YunoHost VPN Client.
loaded: enabled
service_file_path: /etc/systemd/system/ynh-vpnclient.service
status: exited

My YunoHost server

  • Hardware: Internet Cube with VPN
  • YunoHost repo: now version: 3.5.2.2
  • yunohost-admin: repo: now version: 3.5.2
  • moulinette: repo: now version: 3.5.2
  • ssowat: repo: now version: 3.5.2.1

I have access to my server : Through SSH
Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : no

Description of my issue

I want to update and upgrade, then install other app.

apt update && apt dist-upgrade

I get an error message :

The following packages have unmet dependencies: firmware-linux-nonfree : Depends: firmware-misc-nonfree (= 20161130-5) but it is not installed firmware-ralink : Depends: firmware-misc-nonfree but it is not installed E: Unmet dependencies. Try ‘apt --fix-broken install’ with no packages (or specify a solution).

apt --fix-broken install gives :

Preparing to unpack …/firmware-misc-nonfree_20161130-5_all.deb … Unpacking firmware-misc-nonfree (20161130-5) … dpkg: error processing archive /var/cache/apt/archives/firmware-misc-nonfree_20161130-5_all.deb (–unpack): trying to overwrite ‘/lib/firmware/mt7601u.bin’, which is also in package armbian-firmware 5.83 dpkg-deb: error: subprocess paste was killed by signal (Broken pipe) Errors were encountered while processing: /var/cache/apt/archives/firmware-misc-nonfree_20161130-5_all.deb E: Sub-process /usr/bin/dpkg returned an error code (1)

yunohost tools upgrade gives :

Info: Upgrading packages…
Get:1 Index of /debian/ stretch/stable armhf moulinette all 3.6.4 [64.2 kB]
Get:2 Index of /debian/ stretch/stable armhf ssowat all 3.6.4 [741 kB]
Get:3 Index of /debian/ stretch/stable armhf yunohost all 3.6.4 [728 kB]
Fetched 1533 kB in 0s (0 B/s)
(Reading database … 45052 files and directories currently installed.)
Preparing to unpack …/firmware-misc-nonfree_20161130-5_all.deb …
Unpacking firmware-misc-nonfree (20161130-5) …
dpkg: error processing archive /var/cache/apt/archives/firmware-misc-nonfree_20161130-5_all.deb (–unpack):
trying to overwrite ‘/lib/firmware/mt7601u.bin’, which is also in package armbian-firmware 5.83
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Preparing to unpack …/moulinette_3.6.4_all.deb …
Unpacking moulinette (3.6.4) over (3.5.2) …
Errors were encountered while processing:
/var/cache/apt/archives/firmware-misc-nonfree_20161130-5_all.deb
E:Sub-process /usr/bin/dpkg returned an error code (1)
Warning: unable to upgrade packages: installArchives() failed
Error: Unable to upgrade all of the packages
Info: The operation ‘Upgrade debian packages’ has failed! To get help, please share the full log of this operation using the command ‘yunohost log display 20190705-161852-tools_upgrade --share’
Info: The following apps will be upgraded : hotspot, vpnclient
Info: Now upgrading app hotspot…
Success! hotspot is already up to date
Info: Now upgrading app vpnclient…
Success! vpnclient is already up to date
Success! The SSOwat configuration has been generated
Success! Upgrade complete

I’d don’t know how to repair firmware-misc-nonfree_20161130-5_all.deb to make it work.

Thank you to help me !
:wink:

Meh, yea … Basically this nonfree package conflicts with other stuff. Basically for now we tried to avoid as much installing it soooo … not sure how to fix your situation right now. Possibly if it’s easy to reinstall with non-free packages disabled, that would be the most straightforward fix

Packages armbian-firmware and firmware-linux-nonfree are in conflict.
Maybe you should try to uninstall one.

Maybe you don’t really need non-free firmwares at all depending on which wifi adapter you have.

Thanks for the answers.
I think that the wifi antenna is “non-free”.
I 'll get a try…

I tried to remove firmware-ralink and firmware-linux-nonfree and also firmware-linux-nonfree
I get :

apt remove --purge firmware-misc-nonfree

Reading package lists… Done
Building dependency tree
Reading state information… Done
Package ‘firmware-misc-nonfree’ is not installed, so not removed
You might want to run ‘apt --fix-broken install’ to correct these.
The following packages have unmet dependencies:
firmware-linux-nonfree : Depends: firmware-misc-nonfree (= 20161130-5) but it is not going to be installed
firmware-ralink : Depends: firmware-misc-nonfree but it is not going to be installed
E: Unmet dependencies. Try ‘apt --fix-broken install’ with no packages (or specify a solution).

Then, apt --fix-broken install :

Reading package lists… Done
Building dependency tree
Reading state information… Done
Correcting dependencies… Done
The following package was automatically installed and is no longer required:
python-toml
Use ‘sudo apt autoremove’ to remove it.
The following additional packages will be installed:
firmware-misc-nonfree
The following NEW packages will be installed:
firmware-misc-nonfree
0 upgraded, 1 newly installed, 0 to remove and 5 not upgraded.
2 not fully installed or removed.
Need to get 0 B/2,320 kB of archives.
After this operation, 8,155 kB of additional disk space will be used.
Do you want to continue? [Y/n]

If I say Y :

Reading package lists… Done
Building dependency tree
Reading state information… Done
Correcting dependencies… Done
The following package was automatically installed and is no longer required:
python-toml
Use ‘sudo apt autoremove’ to remove it.
The following additional packages will be installed:
firmware-misc-nonfree
The following NEW packages will be installed:
firmware-misc-nonfree
0 upgraded, 1 newly installed, 0 to remove and 5 not upgraded.
2 not fully installed or removed.
Need to get 0 B/2,320 kB of archives.
After this operation, 8,155 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
(Reading database … 45050 files and directories currently installed.)
Preparing to unpack …/firmware-misc-nonfree_20161130-5_all.deb …
Unpacking firmware-misc-nonfree (20161130-5) …
dpkg: error processing archive /var/cache/apt/archives/firmware-misc-nonfree_20161130-5_all.deb (–unpack):
trying to overwrite ‘/lib/firmware/mt7601u.bin’, which is also in package armbian-firmware 5.83
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing:
/var/cache/apt/archives/firmware-misc-nonfree_20161130-5_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

How could I get out of that trap?

Thank you!

Try removing both packages and then reinstall the one you want to keep.

Yes, I had to remove both in one command !

apt remove --purge firmware-ralink firmware-linux-nonfree

I try to update now…

If your problem is still unsolved, maybe you should try to use dpkg-divert against file /lib/firmware/mt7601u.bin.
It’s just a guess, I don’t know how to use dpkg-divert myself but it looks promising.

Hi Pitchum,
For the moment it looks ok.
I successed in upgrading operations and seems to have the wifi operating yet.
I hope it will be okay now.

Thank you !

I tried to install an app and it seems to run !
No need to non free things!
My problem is solved.
:grinning:

Thanks a lot!