kernsuite / packaging

Use this repository to report issues with packages or request new packages
13 stars 4 forks source link

Problems installing wsclean #258

Open JSKenyon opened 2 years ago

JSKenyon commented 2 years ago

On Ubuntu 20.04 using KERN-7, wsclean fails to install with messages like:

sudo apt install wsclean
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:
 wsclean : Depends: libwsclean2 but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

I have verified that I have no held packages and I believe that I ran into the same issue on my previous PopOS install.

Athanaseus commented 2 years ago

Thanks for the issue @JSKenyon.

Can you please provide output of apt search wsclean

JSKenyon commented 2 years ago
apt search wsclean
Sorting... Done
Full Text Search... Done
libwsclean2/focal 2.10.1-1kern1 amd64
  Fast generic widefield interferometric imager (shared library)

wsclean/focal 2.10.1-1kern1 amd64
  Fast generic widefield interferometric imager

wsclean-dev/focal 2.10.1-1kern1 amd64
  Fast generic widefield interferometric imager (development files)
Athanaseus commented 2 years ago

Somehow I cannot reproduce this error. It installs successfully on my ubuntu20 desktop and on a docker container.

Also make sure that the restricted and multiverse: sudo apt-add-repository multiverse sudo apt-add-repository restricted

JSKenyon commented 2 years ago

I already have both of those - maybe something strange has happened. I find it odd that I ran into this on my old system too. Completely possible that the error is on my end. I already went ahead an installed from source so this isn't blocking me. Just strange that this and only this seems to give me problems.

gijzelaerr commented 2 years ago

What error do you get if you apt-get install libwsclean2

JSKenyon commented 2 years ago
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:
 libwsclean2 : Depends: libidg-api0 but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
gijzelaerr commented 2 years ago

And what happens if you install libidg0-api0 manually? Follow the trail

JSKenyon commented 2 years ago

Ah, it is the image domain gridding stuff. It wants cuda related dependencies. Perhaps because I have a GPU?

sudo apt install libidg-api0 
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:
 libidg-api0 : Depends: libidg-cuda0 but it is not going to be installed
               Depends: libidg-hybrid-cuda0 but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
sudo apt install libidg-cuda0
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:
 libidg-cuda0 : Depends: libnvidia-compute-418-server but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
JSKenyon commented 2 years ago

I can follow along further - just shout if you think it is needed.

gijzelaerr commented 2 years ago

yeah please follow. it looks like it can't install nvidia drivers and cuda. is your system up-to-date using apt-get upgrade? Are you sure you have restricted enabled? can you install cuda?

JSKenyon commented 2 years ago

Looks like that last one was the problem. I manually installed libnvidia-compute-418-server and now I can install wsclean. I do not know why that specific package would cause a problem though.

Athanaseus commented 2 years ago

is your system up-to-date using apt-get upgrade?

This rings a bell. The last time I've experienced this it was solved by updating the system and clearing cache.

sudo apt update sudo apt upgrade && sudo apt clean

https://itsfoss.com/clear-apt-cache/

JSKenyon commented 2 years ago

I cannot really say. I do know that installation failed literally just after I did a fresh Ubuntu install, so I wouldn't have thought there could be any state to cause problems.

o-smirnov commented 2 years ago

I can confirm this is still a problem @gijzelaerr @Athanaseus.

$ sudo apt install wsclean libwsclean2 libidg-api0 libidg-cuda0
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:
 libidg-api0 : Depends: libidg-hybrid-cuda0 but it is not going to be installed
 libidg-cuda0 : Depends: libnvidia-compute-418-server but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
oms@ike:~$

Why is there a hard dependency on libnvidia-compute-418-server? In any case, I can't install that version since it doesn't support the GPUs in that particular mode. Perhaps the package should be repackaged with an optional dependency? 99% of our use cases of wsclean don't even involve CUDA, so it should not be holding us back?

Athanaseus commented 2 years ago

Why is there a hard dependency on libnvidia-compute-418-server? ...

This is due to the hard dependency on idg-dev which requires Cuda libraries. I will repackage the wsclean package with an optional dependency. Perhaps in the upcoming kern release, we can have wsclean and wsclean-idg.

o-smirnov commented 2 years ago

Perhaps in the upcoming kern release, we can have wsclean and wsclean-idg.

Yes please!

gijzelaerr commented 2 years ago

i just tried this in a fresh focal linux/amd64 docker container, and I can't replicate this issue (kern-7 wsclean and ids install, nvidia libs install from multiverse).

Please make sure you have:

JSKenyon commented 2 years ago

i just tried this in a fresh focal linux/amd64 docker container, and I can't replicate this issue (kern-7 wsclean and ids install, nvidia libs install from multiverse).

Please make sure you have:

* restricted and multiverse repo enabled

* run apt-get update before you install any other packages.

Does your container have/see a GPU? I suspect that that is the crucial point.

gijzelaerr commented 2 years ago

The packages should install without issues even if you dont have a Cuda card installed.

On Mon, 15 Aug 2022 at 13:27, JSKenyon @.***> wrote:

i just tried this in a fresh focal linux/amd64 docker container, and I can't replicate this issue (kern-7 wsclean and ids install, nvidia libs install from multiverse).

Please make sure you have:

  • restricted and multiverse repo enabled

  • run apt-get update before you install any other packages.

Does you container have/see a GPU? I suspect that that is the crucial point.

— Reply to this email directly, view it on GitHub https://github.com/kernsuite/packaging/issues/258#issuecomment-1214907307, or unsubscribe https://github.com/notifications/unsubscribe-auth/AACPVJDMPTXHCXZ6I2IRPKLVZISRBANCNFSM5RJ74RYA . You are receiving this because you were mentioned.Message ID: @.***>

-- Gijs Molenaar http://pythonic.nl

o-smirnov commented 2 years ago

@gijzelaerr on nodes without a GPU, there is no issue because it sneakily installs libnvidia-compute-418-server, which does no harm. On nodes with a GPU, it fails because 418 conflicts with the already installed GPU drivers.

gijzelaerr commented 2 years ago

ah yes, that makes more sense. What driver do you install how? You can't mix kernsuite with non-ubuntu GPU driver repos unless we remove the cuda depending package from kern. If you say in practice nobody uses GPU support with wsclean I guess we can just do that.

o-smirnov commented 2 years ago

Using the official NVIDIA repo:

deb https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64

There'sa bit of a wrinkle because our Tesla cards are now considered "legacy", so the driver version can't go above 470 (or CUDA above 11.4). But that's not the current problem anyway.

If you say in practice nobody uses GPU support with wsclean I guess we can just do that.

Not at the moment, but why not make it optional like @Athanaseus suggests?

JSKenyon commented 2 years ago

I think that @Athanaseus's idea was sound - make two packages. I don't think we want to completely cut off the option of using IDG with GPU support.

gijzelaerr commented 2 years ago

ok, i think the easiest way is to just clone the https://github.com/kernsuite-debian/wsclean repo to https://github.com/kernsuite-debian/wsclean-idg and then update the packages accordingly.

Athanaseus commented 2 years ago

KERN-7 wsclean (2.10.1-1kern2) update should be ready to install. wsclean-idg with the latest wsclean will be made available in KERN-8.

apt update && apt install wsclean