最近使用 iDrac 和 iLO 總是會使用到 .jnlp 文件, 為了方便,今天把設置過程記錄下來。 JNLP 文件,全名為 Java Network Launching Protocol 文件, 我們需要 javaws 命令去執行它。 在 fedora 中 ,我們需要安裝 相應的 rpm 包,y ...
最近使用 iDrac 和 iLO 總是會使用到 .jnlp 文件, 為了方便,今天把設置過程記錄下來。
JNLP 文件,全名為 Java Network Launching Protocol 文件, 我們需要 javaws 命令去執行它。
在 fedora 中 ,我們需要安裝 相應的 rpm 包,yum 倉庫中已經為我們準備好了相關的文件,我們只需要運行命令來安裝就行了。當然你也可以使用 編譯源碼安裝。
➜ Downloads yum search icedtea Last metadata expiration check: 16 days, 20:58:23 ago on Fri 06 Jul 2018 05:04:10 PM CST. ==================================================================== Summary & Name Matched: icedtea ===================================================================== icedtea-web-javadoc.noarch : API documentation for IcedTea-Web icedtea-web-devel.noarch : pure sources for debugging IcedTea-Web ========================================================================= Name Matched: icedtea ========================================================================== icedtea-web.noarch : Additional Java components for OpenJDK - Java browser plug-in and Web Start implementation
➜ Downloads sudo yum install icedtea-web
Javaws 命令 執行
![](https://images.cnblogs.com/OutliningIndicators/ContractedBlock.gif)
➜ Downloads javaws SYNOPSIS javaws [-run-options] jnlp file javaws [-control-options] OPTIONS When specifying options, the name of the jnlp file can be after the command, the -jnlp option, an option with no arguments, or after an argument with an option that takes one argument. A html file that launches a jnlp can be specified after the -html option. The jnlp-file can either be a url or a local path. The JNLP file should only be specified once, whether as a main argument, after -jnlp or through an html file. Control options: -about - Shows a sample application.(No argument expected) -help - Prints out information about supported command and basic usage.(No argument expected) -license - Display the GPL license and exit.(No argument expected) -viewer - Shows the trusted certificate viewer.(No argument expected) -Xclearcache - Clean the JNLP application cache.(No argument expected) Run options: -allowredirect - Follows HTTP redirects.(No argument expected) -arg arg - Adds an application argument before launching.(Expected one or more arguments) -browser - Launch embeded browser. Use in great need only!(Expected one or more arguments) -headless - Disables download window, other UIs.(No argument expected) -html - Location of HTML file to launch (url or file). You can use parameter ALL or numbers (like 1 2 5) to select applets on page. However experimental, this switch should keep you still in safety.(Expected one or more arguments) -jnlp - Location of JNLP file to launch (url or file).(Exactly one argument expected) -nosecurity - Disables the secure runtime environment. You need also deployment.security.itw.ignorecertissues to workaround corrupted signatures(No argument expected) -noupdate - Disables checking for updates.(No argument expected) -param name=value - Adds an applet parameter before launching.(Expected one or more arguments) -property name=value - Sets a system property before launching.(Expected one or more arguments) -strict - Enables strict checking of JNLP file format.(No argument expected) -update seconds - Check for updates.(Exactly one argument expected) -verbose - Enable verbose output.(No argument expected) -version - Print the IcedTea-Web version and exit.(No argument expected) -Xignoreheaders - Skip jar header verification.(No argument expected) -xml - Uses a strict XML parser to parse the JNLP file.(No argument expected) -Xnofork - Do not create another JVM.(No argument expected) -Xoffline - Prevent ITW network connection. Only cache will be used. Application can still connect.(No argument expected) -Xtrustnone - Instead of asking user, will foretold all answers as no.(No argument expected)View Code
Javaws 命令 說明
NAME javaws - a Java Web Start client SYNOPSIS javaws [-run-options] jnlp file javaws [-control-options] DESCRIPTION javaws is an implementation of a JNLP client. It uses a JNLP (Java Network Launch Protocol) file to securely run a remote Java application or a Java applet. This implementation of javaws is from the IcedTea project and is based on the NetX project. A JNLP file is an xml file that describes how to securely run a remote Java application or a Java applet.
執行 jnlp 文件:
➜ Downloads javaws viewer.jnlp
同理,在 ubuntu 中,也可以使用 apt 等工具進行搜索安裝。
具體情況以實際執行為準。
參考:
https://linux-tips.com/t/execute-jnlp-files-in-linux/252
https://fedora.pkgs.org/27/fedora-i386/icedtea-web-1.7-4.fc27.noarch.rpm.html
https://icedtea.classpath.org/wiki/Main_Page
https://icedtea.classpath.org/wiki/FedoraBuildInstructions