1

I am trying to install the rpm package java-1.8.0-amazon-corretto-devel-1.8.0_192.b12-1.amzn2.x86_64.rpm on centos 7 OS.

I have downloaded the rpm java-1.8.0-amazon-corretto-devel-1.8.0_192.b12-1.amzn2.x86_64.rpm from https://docs.aws.amazon.com/corretto/latest/corretto-8-ug/downloads-list.html

When trying to install using the command

rpm -ivh java-1.8.0-amazon-corretto-devel-1.8.0_192.b12-1.amzn2.x86_64.rpm

I get the following error:

warning: java-1.8.0-amazon-corretto-devel-1.8.0_192.b12-1.amzn2.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID c87f5b1a: NOKEY
error: Failed dependencies:
    java-1.8.0-amazon-corretto(x86-64) = 1:1.8.0_192.b12-1.amzn2 is needed by java-1.8.0-amazon-corretto-devel-1:1.8.0_192.b12-1.amzn2.x86_64
    libX11.so.6()(64bit) is needed by java-1.8.0-amazon-corretto-devel-1:1.8.0_192.b12-1.amzn2.x86_64
    libawt.so()(64bit) is needed by java-1.8.0-amazon-corretto-devel-1:1.8.0_192.b12-1.amzn2.x86_64
    libawt_xawt.so()(64bit) is needed by java-1.8.0-amazon-corretto-devel-1:1.8.0_192.b12-1.amzn2.x86_64
    libawt_xawt.so(SUNWprivate_1.1)(64bit) is needed by java-1.8.0-amazon-corretto-devel-1:1.8.0_192.b12-1.amzn2.x86_64
    libjava.so()(64bit) is needed by java-1.8.0-amazon-corretto-devel-1:1.8.0_192.b12-1.amzn2.x86_64
    libjvm.so()(64bit) is needed by java-1.8.0-amazon-corretto-devel-1:1.8.0_192.b12-1.amzn2.x86_64

Any idea how to download the rpm's that are required by java-1.8.0-amazon-corretto-devel-1.8.0_192.b12-1.amzn2.x86_64.rpm ? I tried with yumdownloader but it didn't work.

yumdownloader --destdir=. --resolve java-1.8.0-amazon-corretto-devel-1.8.0_192.b12-1.amzn2.x86_64.rpm
Loaded plugins: fastestmirror, ovl
Determining fastest mirrors
 * base: ftp.heanet.ie
 * extras: ftp.heanet.ie
 * updates: ftp.heanet.ie
No Match for argument java-1.8.0-amazon-corretto-devel-1.8.0_192.b12-1.amzn2.x86_64.rpm
Nothing to download

Thank you

0

1 Answer 1

2

There are two packages, one providing the JDK and one providing the JRE. If you want the JDK, you'll also need to install the JRE.

  1. Download both RPMs from Amazon Corretto's downloads page.

  2. Install both simultaneously using yum localinstall:

    sudo yum localinstall -y java-1.8.0-amazon-corretto*.rpm
    
2
  • basically i want to download the rpms requred for java-1.8.0-amazon-corretto-devel-1.8.0_192.b12-1.amzn2.x86_64.rpm for offline usage. I know yum install will work . but wants to download all rpms for the java-1.8.0-amazon-corretto-devel-1.8.0_192.b12-1.amzn2.x86_64.rpm on to a file system and use offline. Nov 22, 2018 at 10:06
  • so using yumlocalinstall we can identify which rpms are required for amazon corretto rpms . then we can downloand those rpms using yumdownloader command , and dowonloade them offline then use rpm -vih to install all the rpms .. care must be take to resolve dependencies as rpm command is poor in handling dependences unlike yum Nov 27, 2018 at 13:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.