docker-idrac6 icon indicating copy to clipboard operation
docker-idrac6 copied to clipboard

Can not build image: Package 'openjdk-7-jdk' has no installation candidate

Open koocotte opened this issue 3 years ago • 8 comments

It looks like the openjdk-7 for ubuntu xenial is no more available in the selected PPA.

Browsing http://ppa.launchpad.net/openjdk-r/ppa/ubuntu/dists/xenial/main/binary-amd64/ show that the Packages.gz have been updated on 2021-04-21 and there is (no more?) references to a jdk older than openjdk-9

There are .deb in http://ppa.launchpad.net/openjdk-r/ppa/ubuntu/pool/main/o/openjdk-7/ but probably only for Lucid Lynx.

--- Last lines of docker build -t docker-idrac6 . ---

gpg: keyring `/tmp/tmpx3vyk1p4/secring.gpg' created
gpg: keyring `/tmp/tmpx3vyk1p4/pubring.gpg' created
gpg: requesting key 86F44E2A from hkp server keyserver.ubuntu.com
gpg: /tmp/tmpx3vyk1p4/trustdb.gpg: trustdb created
gpg: key 86F44E2A: public key "Launchpad OpenJDK builds (all archs)" imported
gpg: Total number processed: 1
gpg:               imported: 1  (RSA: 1)
OK
Hit:1 http://archive.ubuntu.com/ubuntu xenial InRelease
Hit:2 http://deb.nodesource.com/node_12.x xenial InRelease
Hit:3 http://archive.ubuntu.com/ubuntu xenial-updates InRelease
Get:4 http://ppa.launchpad.net/openjdk-r/ppa/ubuntu xenial InRelease [23.8 kB]
Hit:5 http://archive.ubuntu.com/ubuntu xenial-backports InRelease
Hit:6 http://security.ubuntu.com/ubuntu xenial-security InRelease
Get:7 http://ppa.launchpad.net/openjdk-r/ppa/ubuntu xenial/main amd64 Packages [18.9 kB]
Fetched 42.8 kB in 0s (75.6 kB/s)
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
Package openjdk-7-jdk is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'openjdk-7-jdk' has no installation candidate
The command '/bin/sh -c apt-get update &&     apt-get install -y wget software-properties-common &&     add-apt-repository ppa:openjdk-r/ppa &&     apt-get update &&     apt-get install -y openjdk-7-jdk gcc &&     gcc -o /keycode-hack.so /keycode-hack.c -shared -s -ldl -fPIC &&     apt-get remove -y gcc software-properties-common &&     apt-get autoremove -y &&     rm -rf /var/lib/apt/lists/* &&     rm /keycode-hack.c' returned a non-zero code: 100

koocotte avatar Jun 15 '21 18:06 koocotte

It's quite possible that it's just not supported anymore.

I will test iDRAC with the newer Java versions and see if it works, otherwise I have to find a new source for OpenJDK 7. Will probably have some time to do this next week.

DomiStyle avatar Jun 15 '21 19:06 DomiStyle

I looked into it now and it seems like OpenJDK 7 is gone from all the repos for modern OS (obviously). There are some for older OS but I don't have a baseimage for them.

Looks like the only way around is downloading the JDK from Oracle, which I probably am not allowed to bundle with this image, or building Java by myself.

DomiStyle avatar Jul 02 '21 06:07 DomiStyle

I run the Alpine Linux version using the repo from pull request #9 and it looks like Java is found and working.

My french keyboard is not working as expected (mapping does not correspond neither to english nor french, maybe a double decode of mapping), but it's another problem. I see you have patchs about keyboard in the last release. I must check if I can merge both.

koocotte avatar Jul 02 '21 08:07 koocotte

Interesting. You're right, Alpine still has openjdk7 packages: https://pkgs.alpinelinux.org/packages?name=openjdk7*&branch=edge

I will check if I can get the keycode hack to compile on Alpine.

DomiStyle avatar Jul 05 '21 08:07 DomiStyle

It looks like Alpine still has the same issues for which I didn't accept the pull request in the first place:

  • Native libraries can't be loaded because of issues with libmawt.so
  • Opening Virtual media crashes container

DomiStyle avatar Jul 07 '21 09:07 DomiStyle

Zulu Java is the only openjdk distribution that is still packaging Java 7: https://www.azul.com/downloads/?package=jdk

I had a branch where I tried switching to it, but the build fails because you also need to install the libx11-dev in order to compile the keycode-hack. Once I got past that, I still ran in to issue #17 so I gave up on that branch.

Supposedly, you can get iDrac 6 working with Java 8 by modifying the allowed tls algorithms.

kusold avatar Jul 08 '21 16:07 kusold

@kusol Thanks, I will check if I can get things working with Java 8 in Ubuntu and switch to the Zulu Java builds if that doesn't work.

DomiStyle avatar Jul 09 '21 09:07 DomiStyle

@kusold does this solve your issue https://github.com/DomiStyle/docker-idrac6/pull/47 ?

ssmoss avatar Sep 15 '23 05:09 ssmoss