{"id":3428,"date":"2022-03-23T17:17:02","date_gmt":"2022-03-23T23:17:02","guid":{"rendered":"https:\/\/linuxitos.com\/main\/?p=3428"},"modified":"2022-11-20T12:27:46","modified_gmt":"2022-11-20T18:27:46","slug":"solucionar-error-de-jdkhome-de-netbeas-12-fedora-35","status":"publish","type":"post","link":"https:\/\/linuxitos.com\/main\/solucionar-error-de-jdkhome-de-netbeas-12-fedora-35\/","title":{"rendered":"Solucionar error de jdkhome de netbeas 12 | Fedora 35"},"content":{"rendered":"\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-57-13.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-57-13-1024x576.png\" alt=\"\" class=\"wp-image-3429\" srcset=\"https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-57-13-1024x576.png 1024w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-57-13-300x169.png 300w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-57-13-768x432.png 768w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-57-13-1536x864.png 1536w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-57-13-1600x900.png 1600w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-57-13.png 1920w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Contexto<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">La versi\u00f3n de netbeans ya se encuentra en la versi\u00f3n 13, sin embargo, si por alguna raz\u00f3n necesitan utilizar una versi\u00f3n de JDK menor a la 15, algunos m\u00f3dulos de netbeans 12, o 13, se deshabilitan, por lo que no funciona correctamente el IDE. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">En Fedora, es posible instalar varias versiones de jdk al mismo tiempo, y seleccionar cu\u00e1l quieren utilizar por defecto, en mi caso por ejemplo, utilizo open-jdk 8, porque es el m\u00e1s utilizado por los programas que utilizo, sin embargo, est\u00e1 el detalle de netabeans, que me fue necesario utilizarlo, y me encontr\u00e9 con ese error.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Instalaci\u00f3n de JDK &gt;=15<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Para \u00e9sto, instal\u00e9 el jdk 15, desde el archivo rpm, descargado de la p\u00e1gina oficial de oracle.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/www.oracle.com\/java\/technologies\/javase\/javase8-archive-downloads.html\">https:\/\/www.oracle.com\/java\/technologies\/javase\/javase8-archive-downloads.html<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Se descarga el archivo la versi\u00f3n deseada, y se instala con el comando:<\/p>\n\n\n\n<pre style=\"background: rgb(54, 63, 72); border-radius: 6px; border: 0px; box-sizing: border-box; color: white; font-family: menlo, monaco, monospace; font-style: inherit; font-weight: inherit; line-height: 15.68px; margin-bottom: 1.1em; max-width: 100%; outline: 0px; overflow: auto; padding: 13.125px 16.4062px; vertical-align: baseline; white-space: pre-wrap; word-wrap: break-word;\">sudo rpm -ivh jdk-version.rpm<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Una vez instalado, con el comando alternatives, se puede cambiar la versi\u00f3n de jdk por defecto:<\/p>\n\n\n\n<pre style=\"background: rgb(54, 63, 72); border-radius: 6px; border: 0px; box-sizing: border-box; color: white; font-family: menlo, monaco, monospace; font-style: inherit; font-weight: inherit; line-height: 15.68px; margin-bottom: 1.1em; max-width: 100%; outline: 0px; overflow: auto; padding: 13.125px 16.4062px; vertical-align: baseline; white-space: pre-wrap; word-wrap: break-word;\">sudo alternatives --config java<\/pre>\n\n\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-17-10-46.png\"><img loading=\"lazy\" decoding=\"async\" width=\"942\" height=\"221\" src=\"https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-17-10-46.png\" alt=\"\" class=\"wp-image-3430\" srcset=\"https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-17-10-46.png 942w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-17-10-46-300x70.png 300w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-17-10-46-768x180.png 768w\" sizes=\"auto, (max-width: 942px) 100vw, 942px\" \/><\/a><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Seleccionar la versi\u00f3n que se desee utilizar por defecto, ingresando el n\u00famero de la opci\u00f3n elegida y a continuaci\u00f3n enter.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Para que netbeans 12 o superior funcione, es necesaria la instalaci\u00f3n de jdk 15 o superior, por lo que, si se estable por defecto la versi\u00f3n 8 de jdk, es necesario configurar netbeans, para que inicie con otra versi\u00f3n de jdk.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Configurar netbeans<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Par \u00e9sto, abrir el archivo ruta-instalaci\u00f3n-netbeans\/etc\/netbeans.conf y en la l\u00ednea que dice netbeans_jdkhome=\u00bb\/path\/to\/jdk\/\u00bb descomentarlo, y configurarlo la ruta en donde est\u00e9 instalado el jdk a utilizar, por ejemplo de \u00e9ste modo:<\/p>\n\n\n\n<pre style=\"background: rgb(242, 242, 242); border-radius: 2px; border: 1px solid #aaa; box-sizing: border-box; color: #222; font-family: menlo, monaco, monospace; font-style: inherit; font-weight: inherit; line-height: 15.68px; margin-bottom: 1.1em; max-width: 100%; outline: 0px; overflow: auto; padding: 13.125px 16.4062px; vertical-align: baseline; white-space: pre-wrap; word-wrap: break-word;\">netbeans_jdkhome=\"\/usr\/java\/jdk-15.0.2\/\"<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Una vez realizado ese cambio, guardar el archivo, y abrir netbeans,<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-59-24.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-59-24-1024x576.png\" alt=\"\" class=\"wp-image-3431\" srcset=\"https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-59-24-1024x576.png 1024w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-59-24-300x169.png 300w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-59-24-768x432.png 768w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-59-24-1536x864.png 1536w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-59-24-1600x900.png 1600w, https:\/\/linuxitos.com\/main\/wp-content\/uploads\/2022\/03\/Screenshot-from-2022-03-23-16-59-24.png 1920w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n","protected":false},"excerpt":{"rendered":"<p>Contexto La versi\u00f3n de netbeans ya se encuentra en la versi\u00f3n 13, sin embargo, si por alguna raz\u00f3n necesitan utilizar una versi\u00f3n de JDK menor a la 15, algunos m\u00f3dulos de netbeans 12, o 13, se deshabilitan, por lo que no funciona correctamente el IDE. En Fedora, es posible instalar varias versiones de jdk al [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":3429,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[140,359],"tags":[1700,1812,1702],"class_list":["post-3428","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-error","category-netbeans","tag-apache","tag-jdkhome","tag-netbeans"],"_links":{"self":[{"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/posts\/3428","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/comments?post=3428"}],"version-history":[{"count":2,"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/posts\/3428\/revisions"}],"predecessor-version":[{"id":3441,"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/posts\/3428\/revisions\/3441"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/media\/3429"}],"wp:attachment":[{"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/media?parent=3428"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/categories?post=3428"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/linuxitos.com\/main\/wp-json\/wp\/v2\/tags?post=3428"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}