Jetson Nano : Severe Issue with apt-get ("some packages could not be installed")

Hello guys ! I’ll try to keep this short, as I’m coming off a whole day of trying to fix a problem that (in my mind) shouldn’t even be happening. Don’t hesitate to ask for details, but right now I need a good night’s sleep…

I’m trying to setup a Jetson Nano using the JetPack 4.6 image from nVidia. Couldn’t be more official. For those who don’t know, it’s essentially Ubuntu 18.04 targetted at the Tegra X1 SoC on the Jetson Nano. And it comes with all sorts of crazy issues that include, for example, the System Settings tool crashing if you try to setup Desktop Sharing, or the CPU fan not being turned on unless you take care of it with a custom script on startup. Not the most mature distro, in spite of what “4.6” might suggest.

Last time I had to setup a Nano, I could “apt-get install” anything I needed, no problem, no worries. That’s no longer the case. As an example, here’s the output I get when I try to install samba with the command “sudo apt-get install samba” :

Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 samba : Depends: python-samba but it is not going to be installed
         Depends: samba-common-bin (= 2:4.7.6+dfsg~ubuntu-0ubuntu2) but it is not going to be installed
         Depends: samba-libs (= 2:4.7.6+dfsg~ubuntu-0ubuntu2) but 2:4.7.6+dfsg~ubuntu-0ubuntu2.23 is to be installed
         Recommends: samba-dsdb-modules but it is not going to be installed
         Recommends: samba-vfs-modules but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

I have no idea why “python-samba” wouldn’t be installed. The message reads more like a tantrum than an error message.

I have no idea why some of the packages have weird “~ubuntu” suffixes behind their version numbers. Surely 2:4.7.6 is 2:4.7.6. Moreover, it seems like the tool is complaining that it can’t get older versions of packages.

For example, on a previous attempt at setting up this system, I was able to install samba (and other packages) using “aptitude” instead of “apt-get”. It would also give me the same error, but then it would propose to downgrade some of the package and install without error.

This is the first time since apt-get has been invented that I have to resort to this workaround and I do not like it. I want to be able to install software the way I always do, the way it’s meant to work.

This issue happens on all sorts of packages, by the way. There’s no particular pattern.

Naturally, I’ve tried to find some leads using Google, but nothing has panned out. I’m hoping there’s a package manager guru among us who can show me the light.

Working with the Nvidia JetPack distro is a challenge. There are so many parts of it that are locked down.

A joke they purport that it is just an Ubuntu 18.04 port.

You can do an apt update and lots of core packages do update but anything to do with the kernel is locked down for example.

I just leave mine be and ignore it for the most part until I take a look at it via SSH or VNC and think, gee it’s been running for 3 months, maybe I better stop the running program and update it.

Have you tried the Jetson Nano forums at Nvidia Developers?
Jetson Nano forum

Yeah, but nothing even remotely looks like my problem and I don’t want to spread myself across multiple forums if I can avoid it. Also, this really feels more like an apt-get problem than a Jetson problem. It’s like that tool is obsessed with only using the latest version of everything even when it could solve its dependency problems by downgrading here and there.

Today I’m going to try to get an SD card up and working using aptitude to downgrade packages when I can. Good thing I didn’t choose to invest in a Xavier right away, I’d be way saltier.

@Nefastor, you could try Aptitude and see if you can downgrade your packages, but It has been my experience you will need to fix the broken packages first. I would do a google search for fixing broken packages using Ubuntu as your Linux distro. I have fixed broken packages before, but I can’t access my notes or the bookmarks for the websites I used since I don’t have a computer to access the information.

1 Like

It is not a problem with apt, it is a problem with the nVidia propriertary version of Ubuntu. It is not really standard ubuntu no matter how nVidia tries to swing it. Apt is doing exactly what it is supposed to do.

Try this to see if it will fix your broken and held packages.

apt update && apt install -f

This should update your repo cache and look locally as well and then try o fix the broken packages. If something is not there, then that is because the maintainers have moved the needed packages as it states in you terminal output.

Word of warning, when dealing with vendor supported distros that do not follow mainline, it is best to only update if something is not working or you need the new feature. The nVidia products have been plagued by this for ages, they just do not do a good job of maintaining their distro spins and they will not just contribute directly to the main projects.

You are correct. The reason why it has the ububtu suffixes is because that is how they pulled and imported them into their repo. They are doing their own custom spin of ubuntu.

Aptitude is just a graphical front end to apt/apt-get. Anything that you can do in Aptitude of Synaptic, you can do from the command line. If the xUI is easier for you, then use it. No one is going to ridicule you for that. Just use the tools that work.

2 Likes

Hello @Mastic_Warrior and @Shadowbane. Thanks for your input. I’ve tried fixing the broken packages but it rapidly turned into a game of whack-a-mole. I’ve managed to get samba to work using aptitude, but the rest is iffy. I’ve decided to give up on my old set of ML tools and will now try to work with what nVidia offers out of the box, at least until I have time to try and sort everything out.

I’m still very much a student when it comes to machine learning, so I’m not married to a setup or even a framework. For now I just need something that works even if it’s not optimal :sweat_smile:

If I end-up with a solution or something satisfactory, I’ll add a final post to this thread and that’ll be it. Thank you for your time, guys !

2 Likes

No worries. Good luck getting your system the way that you want it. With a little more Debian based distro knowledge under your belt, you will get there.