VirtualBox uninstall problem

Or, disable Secure boot temporarily.

The problem is that I can't successfully do this because it wants me to create a private MOK and it's not something I feel I should be messing with. Especially as I'm trying to uninstall the very thing that is asking me to create it....

Rory, can we take a couple steps back here?

First question: Did you install (Or try to install) VirtualBox?

Can you try sudo apt reinstall virtualbox? Then sudo apt remove virtualbox?

Sure, no problem.

I didn't install VirtualBox, it came preloaded with Zorin 16 Pro. I've no need for it, no use case at the moment.....maybe later when I get rid of Win 10 and get a bit more Linux savvy and want to try other distro's etc.

It's just been sat there. I'm healthily paranoid about security so all my systems are always fully patched with the latest updates and I it's the first thing I do when log in is to check for software updates. Same on my Win 10 system with Kaspersky and PatchMyPC, Windows updates etc.

This makes a lot more sense now.

So, when you went to remove it, it must be configured prior to removal. And thus: You began running into problems.

I understand your statement about healthily paranoid but in this case, you have reached a bump in the road.
The only thing I can do is ask that you trust me.

  • I have no desire to sit here all day long trying to fix your system after I broke it. Because if I did anything to break it, I would not leave until I helped you fix it.
  • I have no desire to put you at risk from hackers or from wayward software, malicious or not.

The best thing you can do right now is Accept the Configuration for Secure Boot (MOK). I understand that it is something new; but that is a guided prompt that will not put you at any risk. Because once done, you will be Removing VirtualBox right after, anway.

Mate, the trouble is that if I try the first command you suggest, I end up back at the dialogue box about configuring secure boot and asking me to create a private MOK. I can only get out of it by killing the terminal.

I'm going to try the second one you suggest though....sudo apt remove virtualbox....but I suspect I may get back to the same place...

It is a fact and a reassurance that disabling this feature is safe. It may not be the current issue, but it will be one shortly if it's not addressed. In troubleshooting a user's system several things may come up that weren't part of the op, but for completeness and to prevent future problems we tend to address them as we go. It makes no sense not to since we are volunteers and not paid helpdesk. I do recognize your point though.

OK, I tried that and get this:

Could not get Lock:
This means that another process is using it. Do you have another terminal window or a package manager like Synaptic open?

As aravisian said, some things cannot be removed until they are configured (blame the software developers for that). It is something simply re-enabled if it's that important to you (like in next reboot). It will cause issues with your system in the future (an fyi).

I'm curious if it is a snap or flatpak?

Too many cooks...?

Just inform all of you who are participating this discussion, I created a new thread

and moved some of the postings with my moderator magic wand :star2:

Aravisian, I do hear you and I'm also trying to understand what creating a private third party driver MOK will do. The dialogue box suggests, well actually it's quite clear, that it wants to enroll a private key in the system's firmware and this will be used during UEFI Secure Boot.

What then happens when I uninstall VirtualBox, will the private MOK be disenrolled from my system firmware? Who knows, I don't, do you?

I am genuinely, and with reasonable grounds, reluctant to create a third party driver private MOK which will be written to the system firmware and used in secure boot. Then hope it will be disenrolled if I uninstall the software that wanted to put it there in the first place.

By the way, I had no idea that in Linux a user had to first configure a bit of software before uninstalling it, even if they've never used it. That might have saved me a lot of grief but that's the price of being naive newbie....

No, just Firefox to post these messages and Screenshot. Nothing else open.

It could be Kellog's Crispies for all I know :slight_smile: I do everything through the inbuilt one in Zorin called Software....

Can you please close all terminal windows. Then open a new one and enter in:

sudo killall apt apt-get

Once done, try running the command

sudo apt remove --purge virtualbox*

IF you still get the "could not get lock" error, please run the following in terminal and paste the output here:

ps aux | grep -i apt

Sadly, no. I believe that the enrollment will remain. However, I am absolutely certain that it is not a threat in any way whatsoever.
I understand being cautious. However, I disagree with you both here as the level of caution you are expressing is excessive. It would be no different than if someone expressed a refusal to run the updater or Synaptic Package Manager.
To give a bit of perspective, your computer and kernel are currently running about 700,000 lines of code of Third Party drivers. :expressionless:

1 Like

Mate this is what get when I try that:

Should I now try ps aux | grep -i apt?

No, that was only to see what apt process may have been causing the "Could not get a lock" error.

Rory, what you have in front of you is a Choice.

See, where you stand now is you will not be able to use apt until apt is satisfied that all packages are properly configured.
In short - Your Zorin OS is broken.
Tom believes it is preferable to reinstall the system than to proceed with the configuration.
That is an option. However, it comes with problems of its own. For example, you will be back with the preinstalled VirtualBox. You could just leave it be...
The other option would be to reinstall Zorin OS Pro, but as a Minimal install, which won't install VB. But, it won't install all the other apps that come with Pro, either. It's a bit of cutting off your nose to spite your face.

The last option is the one that I recommend. I understand that you have concerns. The most I can offer is that it is not a risk, even if you feel like you are taking a risk.
Enrolling the package in MOK is actually pretty normal and standard and there are a very large number of Linux apps already signed and included in the kernel. You are already using them. You just did not get a Prompt for them.

OK, but when I try to run sudo dpkg --configure -a I get straight back to the configure UEFI malarkey. It feels all a bit Monty Python