{"id":1939,"date":"2013-03-12T12:18:54","date_gmt":"2013-03-12T04:18:54","guid":{"rendered":"http:\/\/rmohan.com\/?p=1939"},"modified":"2013-03-12T12:26:16","modified_gmt":"2013-03-12T04:26:16","slug":"jdk-install-centos-6-3","status":"publish","type":"post","link":"https:\/\/mohan.sg\/?p=1939","title":{"rendered":"JDK INSTALL CENTOS 6.3"},"content":{"rendered":"<p> I need to use Java 1.7<br \/>\nSo I downloaded jdk-7u17-linux-x64.rpm <\/p>\n<p>when I try to install it, I get the following error.<\/p>\n<p>Unpacking JAR files&#8230;<br \/>\nrt.jar&#8230;<br \/>\nError: Could not open input file: \/usr\/java\/jre1.7.0_17\/lib\/rt.pack<br \/>\njsse.jar&#8230;<br \/>\nError: Could not open input file: \/usr\/java\/jre1.7.0_17\/lib\/jsse.pack<br \/>\ncharsets.jar&#8230;<br \/>\nError: Could not open input file: \/usr\/java\/jre1.7.0_17\/lib\/charsets.pack<br \/>\nlocaledata.jar&#8230;<br \/>\nError: Could not open input file: \/usr\/java\/jre1.7.0_17\/lib\/ext\/localedata.pack<\/p>\n<p>You can ignore the errors. The files named in the error lines do not exist in the rpm package, but are there as .jar files<\/p>\n<p>Open the following URL in a web browser on your PC:<\/p>\n<p>http:\/\/www.oracle.com\/technetwork\/java\/javase\/downloads\/index.html<\/p>\n<p>2. Click the JDK download button, accept the license agreement and download the JDE rpm package.<\/p>\n<p>3. jdk-7u17-linux-x64.rpm<\/p>\n<p>4. Login as root and use the YUM utility to install the RPM package. <\/p>\n<p># yum install .\/jdk-7u17-linux-x64.rpm<\/p>\n<p>5. Register the new installed java version, then change your default Java:<\/p>\n<p># alternatives &#8211;install \/usr\/bin\/java java \/usr\/java\/jdk1.7.0_17\/bin\/java 2<br \/>\n# alternatives &#8211;config java<\/p>\n<p>Display your default Java version:<\/p>\n<p># java -version<br \/>\njava version &#8220;1.7.0_17&#8221;<br \/>\nJava(TM) SE Runtime Environment (build 1.7.0_17-b02)<br \/>\nJava HotSpot(TM) 64-Bit Server VM (build 23.6-b04, mixed mode)<\/p>\n","protected":false},"excerpt":{"rendered":"<p> I need to use Java 1.7 So I downloaded jdk-7u17-linux-x64.rpm <\/p>\n<p>when I try to install it, I get the following error.<\/p>\n<p>Unpacking JAR files&#8230; rt.jar&#8230; Error: Could not open input file: \/usr\/java\/jre1.7.0_17\/lib\/rt.pack jsse.jar&#8230; Error: Could not open input file: \/usr\/java\/jre1.7.0_17\/lib\/jsse.pack charsets.jar&#8230; Error: Could not open input file: \/usr\/java\/jre1.7.0_17\/lib\/charsets.pack localedata.jar&#8230; Error: Could not open [&#8230;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[],"_links":{"self":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/1939"}],"collection":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1939"}],"version-history":[{"count":3,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/1939\/revisions"}],"predecessor-version":[{"id":1942,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/1939\/revisions\/1942"}],"wp:attachment":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1939"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1939"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1939"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}