Jre version in command line

My application is packed into 1 jar file and run by this command: "java -jar myapp.jar".
I config all the class paths in the manifest.mf file
java version is jdk1.6.0_23
How to tell in the command line (or other place) what JRE version to use?

If the JRE is properly installed on Windows, informations about each version are stored in the registry. The installation process installs a special java.exe in the system PATH. So you don't need to alter you PATH because this special java.exe will find the current JRE.
With release 1.6, it's now possible to select a different JRE installation than the last one without any registry modification.
The installed JRE are listed in the registry in the key HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment
You can select a specific by using the -version switch. For example, to select the "1.5" as defined in the registry :
java -version:"1.5" MyClass
See http://download.oracle.com/javase/6/docs/technotes/tools/windows/java.html and http://www.rgagnon.com/javadetails/java-0634.html for more infos.
Bye.

Similar Messages

  • IFS Versioning through Command Line

    I am no Java developer and am utilising the command line utilities to store/move/copy documents around in iFS. You seem to be able to cater for most operations but I cannot seem to find how to switch versioning on for a document once it has been stored. I assume you must be able to do it using ifssetattr?
    Anyone have any suggestions (with examples, if poss?)
    Thanks
    Chris

    Mark,
    Thanks for the info - now I know why I can't seem to find it! Unfortunately using Webui isn't really an option. I am pretty familiar with the Web and Windows interfaces but I am looking to impliment a batch process that automatically takes documents that are ftp'd into Unix filestore and creates the appropriate folders, stores the documents, applies the correct ACL, etc., all in real time.
    As mentioned previously I have no experience of Java but plenty of experience of hacking other bits of code. I can obviously retrieve a document id into a JSV using command line utilities. Am I being naive in assuming that it would only require a simple piece of Java to be produced (with document id supplied as a parameter) to be able to accomplish this?
    Thanks
    Chris

  • Use versions in command line

    Hi Community,
    is it possible to use the "versions" functions from CLI? When yes, how?
    I work more often with Vim and some scripts to create ASCII files... I think it should be possible to use a command for versioning (staging/commit) like in git, but couldn't find right now
    Thanks in advance
    kind regards
    Dirk

    Hi,
    Agree with garyc007. Exchange 2010 tools show the currently installed Service Pack version, and not what RU is currently installed.
    Exchange 2010 SP3's build number is 14.3.123.4. One CAS server ends up with version 14.03.0174.001, it means this server has installed Update Rollup 4 for Exchange Server 2010 SP3 successfully. I recommend you check if the other server has installed Update
    Rollup 4 for Exchange Server 2010 SP3 successfully.
    Here is a blog for your reference.
    Exchange Server and Update Rollups Build Numbers
    https://social.technet.microsoft.com/wiki/contents/articles/240.exchange-server-and-update-rollups-build-numbers.aspx
    Hope it helps.
    Best regards,
    If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Amy Wang
    TechNet Community Support

  • Is there a way to find Jdev version from command line.

    Hi All,
    Good Day. We have an application that launches jdeveloper xslt mapper. We set up classpaths and launch it. However we need to support all versions of jdev - 10.1.2, 10.1.3, 10.1.4. Is there a way to determine the jdev version I am using at runtime and set appropriate class path and launch. For now we let the user to decide. We are desperate to auto detect the version...Help plz
    -Confused

    Hi All,
    Good Day. We have an application that launches jdeveloper xslt mapper. We set up classpaths and launch it. However we need to support all versions of jdev - 10.1.2, 10.1.3, 10.1.4. Is there a way to determine the jdev version I am using at runtime and set appropriate class path and launch. For now we let the user to decide. We are desperate to auto detect the version...Help plz
    -Confused

  • How to change users short name in 10.7 Server version?  Command line possible?

    I just migrated from Snow Leo 10.6 Server to Lion 10.7 server.  All seems ok except for one user (me!).  It seems my short name is different.  It was Goerge Smith but now it is just George.   And All users can login and get mail etc, but not me.
    I try to reset password using Updated Workgroup utiliity and new Server App, but the app refuses to allow rest of password or chnage of short user name.
    All other users seem ok and their names, atributes, passwords can be easily reset.   So both Open Directoty and NDS ( all the normal cast of troublemakes) do not seem to be at issue.
    Clearly something odd or unexpected happened in migration of Open Directory users and attributes.
    How can I change my User Shortname Back to the correct one?  Or Any ideas why my Password is locked, and cannot be reset?
    I have rebooted sveral times, all other functions seem normal and working?  Mystified!!   Help?

    Someone in the Lion Server Forum might know?
    Regards,
    Colin R.

  • JRE Command Line Install - Error Opening File Java3BillDevices.jpg

    We are installing JRE using a command line script. We keep getting the following error. Is this a bug with the Installer package? Anyone know how to fix it?
    Error opening file C:\Users\USERID\AppData\LocalLow\Sun\Java\jre1.6.0_38\Java3BillDevices.jpg
    Error: 2
    JRE seems to install and work correctly, but the error is perplexing. We are of course installing with Administrative privileges. There are a bunch of posts on the interwebs about this, but nobody really seems to know how to fix it.
    OS: WIN7 64bit
    JRE: 1.6.0_38
    Install Command:
    C:\scripts\Java_JRE_1.6.0_38_32bit_W764\jre-6u38-windows-i586.exe /s INSTALLDIR=\C:\scripts\Java_JRE1.6.0_38_32bit_W764\" IEXPLORER=1 MOZILLA=1 STATIC=1 JAVAUPDATE=0 JU=0 UPDATECHECK=0 AUTOUPDATECHECK=0 /L C:\scripts\LOGS\Java_JRE1.6.0_38_32bit_W764_Install.txt

    On 30.12.2013 10:06, contentdevelopment wrote:
    >
    > Hi Laura,
    >
    > Thanks for your reply, I used to try this installer setupsp.exe, but it
    > prompted the following error:
    >
    > ---------------------------
    > Novell Client Support Pack Install
    > ---------------------------
    > Error: Unable to locate required Support Pack installation files.
    >
    > Attempted control INF: C:\491psp5_IR2\NLS\ENGLISH\SETUP2K.INF
    > Attempted install INF: C:\491psp5_IR2\NLS\ENGLISH\SETUP2K.INF
    > ---------------------------
    > OK
    > ---------------------------
    >
    > And there is no install.ini file in the 491psp5_IR2.zip.
    Please try the full client install:
    https://download.novell.com/Download...d=XBMCanfiNDY~
    CU,
    Massimo Rosen
    Novell Knowledge Partner
    No emails please!
    http://www.cfc-it.de

  • Command Line Tools installs the latest version of clang (and others) in /Library/Developer/CommandLineTools/... but not in /usr/bin/

    I've upgraded Xcode to the latest 5.1 Installed Command Line Tools via xcode-select --install Homebrew tells me "A newer Command Line Tools release is available"
    brew --config:
    Xcode: 5.1 CLT: 5.1.0.0.1.1393561416 LLVM-GCC: build 2336 Clang: 3.1 build 318
    Checking my clang executable:
    $ /usr/bin/clang --version Apple clang version 3.1 (tags/Apple/clang-318.0.58) (based on LLVM 3.1svn)
    $ /Library/Developer/CommandLineTools/usr/bin/clang --version Apple LLVM version 5.1 (clang-503.0.38) (based on LLVM 3.4svn)
    So it appears Command Line Tools didn't install clang (and perhaps other executables) into /usr/bin? I checked my other laptop (w/ Mavericks), and /usr/bin/clang is version 5.1.
    So I'm guessing this is the problem? I've tried to reinstall Command Line Tools as sudo, but now it won't let me install again (says software isn't currently available).
    Can anyone help me with this? I've spent hours on it now, but can't find a solution.
    Thanks

    BTW, I installed Xcode 5.1 from the Store, but have never run xcode-select --install.  Here is the verbose output from a clang.
    xew ~/$:clang -v -o hello main.c
    Apple LLVM version 5.1 (clang-503.0.38) (based on LLVM 3.4svn)
    Target: x86_64-apple-darwin13.1.0
    Thread model: posix
    "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain /usr/bin/clang" -cc1 -triple x86_64-apple-macosx10.9.0 -emit-obj -mrelax-all -disable-free -disable-llvm-verifier -main-file-name main.c -mrelocation-model pic -pic-level 2 -mdisable-fp-elim -masm-verbose -munwind-tables -target-cpu core2 -target-linker-version 236.3 -v -resource-dir /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/ usr/bin/../lib/clang/5.1 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/ SDKs/MacOSX10.9.sdk -fdebug-compilation-dir /Users/xew -ferror-limit 19 -fmessage-length 100 -stack-protector 1 -mstackrealign -fblocks -fobjc-runtime=macosx-10.9.0 -fencode-extended-block-signature -fdiagnostics-show-option -fcolor-diagnostics -vectorize-slp -o /var/folders/zf/d5vqmmtn5mq7h6766jtlkrvr0000gn/T/main-353995.o -x c main.c
    clang -cc1 version 5.1 based upon LLVM 3.4svn default target x86_64-apple-darwin13.1.0
    ignoring nonexistent directory "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer /SDKs/MacOSX10.9.sdk/usr/local/include"
    ignoring nonexistent directory "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer /SDKs/MacOSX10.9.sdk/Library/Frameworks"
    #include "..." search starts here:
    #include <...> search starts here:
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/ usr/bin/../lib/clang/5.1/include
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/ usr/include
    /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/ SDKs/MacOSX10.9.sdk/usr/include
    /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/ SDKs/MacOSX10.9.sdk/System/Library/Frameworks (framework directory)
    End of search list.
    "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain /usr/bin/ld" -demangle -dynamic -arch x86_64 -macosx_version_min 10.9.0 -syslibroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/ SDKs/MacOSX10.9.sdk -o hello /var/folders/zf/d5vqmmtn5mq7h6766jtlkrvr0000gn/T/main-353995.o -lSystem /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/ usr/bin/../lib/clang/5.1/lib/darwin/libclang_rt.osx.a
    xew ~/$:

  • How to set plug-in Java Runtime parameters on JRE setup command line

    Hi all:
    I need to install JRE and set the Java Runtime Parameters -Xmx
    by command line ..
    I mean I don't want enter Control panel and set this parameter manually in Java Runtime Parameters textBox..
    thanx.
    Best regards
    w.shiha

    Documentation for controlling the installation is sadly lacking in detail. This is the best I have seen for the Windows environment:
    http://java.com/en/download/help/silent_install.xml
    But, there are numerous other PROPERTY variables that are not discussed. Particularly annoying is the addition of yet another JavaUpdate item with the release of 1.5.0_05. If you can get more information, please post a link to it here.

  • Command line to detect installed flash player version

    Hi All,
    Happy New Year to you all.
    I have one desktop application (Flash Director/C++) for which I am developing Windows installer script. I am facing some problem developing the installer script regarding installed Flash Player version. When I am running the script, it is overriding the already installed Flash player irrespective of the version.
    Is there any command line (for Windows script) to know the version of the Flash player prior to install the installer contained Flash player so that I can check before pushing the installer Flash player?
    I would appreciate your quick reply.
    Thanks in advance.
    Sanjoy.

    Can anyone please give some inputs on this query?

  • Command line version of finder's get info command

    I am trying to find which version of MS Office 2008 is installed on a bunch of machines. On one machine, I can just do a get info on the MicrosoftComponentPlugin.framework, but I don't want to have to touch every machine.
    Does anyone know of a way to get this info using the command line?
    Ideally, I would like to use ARD's send unix command to grab this info from a lot of machines, then run install the .mpkg on the machines that aren't the latest version...
    Thanks in advance

    Maybe not. According to the defaults man page:
    WARNING: The defaults command will be changed in an upcoming
    major release to only operate on preferences domains. General
    plist manipulation utilities will be folded into a different
    command-line program.
    They say there will be an upgrade path, but I can't imagine it being named "PlistBuddy". That sounds way too much like some programmer named it. They need something more professional. plutil is already taken, but maybe it could be enhanced. plmanip maybe.

  • INdicating SWF version on mxmlc command line?

    I have been unable to embed SWF version 7 files into FLEX SDK
    3.2. Is there any way on the mxmlc command line to indicate that
    embedded SWF files were built as Version 7 SWF objects? I am just
    fishing for a solution here. The error I get from the compile is
    "unable to create source" for any version 7 SWF I have. The SWF
    files were built with Quark Interactive Designer and I am caught
    between a rock and hard place. Quark saying their SWF's are
    standard SWF files (version 7) and Adobe saying there must be
    something wrong with the SWF files. That's what I get with trying
    to get these two environments to talk to each other.

    "kjsperl" <[email protected]> wrote in
    message
    news:gkihri$k2o$[email protected]..
    >I have been unable to embed SWF version 7 files into FLEX
    SDK 3.2. Is there
    >any
    > way on the mxmlc command line to indicate that embedded
    SWF files were
    > built as
    > Version 7 SWF objects? I am just fishing for a solution
    here. The error I
    > get
    > from the compile is "unable to create source" for any
    version 7 SWF I
    > have. The
    > SWF files were built with Quark Interactive Designer and
    I am caught
    > between a
    > rock and hard place. Quark saying their SWF's are
    standard SWF files
    > (version
    > 7) and Adobe saying there must be something wrong with
    the SWF files.
    > That's
    > what I get with trying to get these two environments to
    talk to each
    > other.
    Do they have to be embedded? What happens if you load them
    through
    swfLoader?

  • Can't install trial version--command line parameters

    I'm considering buying Lightroom and have downloaded the trial version, but I can't install it.  I get the following<br />Command Line Parameters:<br /><br />/L language ID<br />/S Hide initialization dialog. For silent mode use: /S/v/qn<br />/V parameters to MSIExec.ese<br />/UA<url to InstMsiA.exe><br />/UW<url to InstMsiW.exe><br />/UM<url to msi package><br /><br />Please help.  I don't know what this means<br /><br />thanks

    Hi Cherie,
    Here's how you do it.
    1. Start the installation from the downloaded file or the CD.
    2. You will have a folder Lightroom 2.0.
    3. In that folder go to the Adobe Photoshop Lightroom 2 folder.
    4. Right click on "setup32.exe" and drag it to release it anywhere in the empty space.
    5. You will get 3 options.
    6. Choose the "Create Shortcut here" option.
    7. Once the shortcut is created, right-click on the shortcut and choose properties.
    8. In the target area, which might look some thing like this "C:\Documents and Settings\admin\Desktop\Adobe\Lightroom 2.0\Adobe Photoshop Lightroom 2\setup32.exe" go to the end of the line and add "/s" without the quotes.
    9. The same line would look <"C:\Documents and Settings\admin\Desktop\Adobe\Lightroom 2.0\Adobe Photoshop Lightroom 2\setup32.exe" /s>
    10. Click on Apply and then on OK.
    11. Double -click on the shortcut and the program will install.
    12. Try it! Thought the steps appear lengthy, they worked on the 3 PCs that I tried on. :)
    Regards,
    Abhijit

  • Startup and shutdown from command line with version 9i

    Hi, i'm an Oracle newbie. I heard it's possible to startup and shutdown an oracle (instance? or database? which one is it) from the command line.
    A little background on what it is that I want to do:
    I'm looking to backup a database by copying the files that make up the database to a location from where they will be commited to tape media. To do this I must shutdown the database, copy the files, and startup the database again.
    At the moment the backups are full exports which I find unnecessary since it is a development database which is never used at night. It is therefore not an issue if we want to shut it down and re-start it after a few minutes. (I think it would take longer to export as opposed to copy the files right?)
    I need help and advice :
    1. Is my way of going about this correct ?
    2. How do I startup/shutdown from the command line (sqlplus user/password command) or should I use another utility ?
    Thanks,
    Gabriel

    set oracle_sid=ORCL ==> your database namethis is NOT always true. It's instance name. usually, we set instance name is same as database name.But we also can set instance name is different from database name.
    for example.
    C:\>oradim -new -sid abc123
    C:\>set ORACLE_SID=abc123
    C:\>sqlplus /nolog
    SQL*Plus: Release 9.0.1.4.0 - Production on Tue Jun 20 22:40:59 2006
    (c) Copyright 2001 Oracle Corporation.  All rights reserved.
    SQL> conn / as sysdba
    Connected to an idle instance.
    SQL> startup pfile=E:\ora901DB\admin\init.ora
    ORACLE instance started.
    Total System Global Area  344748244 bytes
    Fixed Size                   282836 bytes
    Variable Size             184549376 bytes
    Database Buffers          159383552 bytes
    Redo Buffers                 532480 bytes
    Database mounted.
    Database opened.
    SQL> select name from v$database;
    NAME
    DB901
    SQL> select instance_name from v$instance;
    INSTANCE_NAME
    abc123

  • Microsoft (R) SQL Server Execute Package Utility Version 10.50.2500.0 for 64-bit Copyright (C) Microsoft Corporation 2010. All rights reserved. Argument "Data connector" for option "connection" is not valid. The command line parameters are invalid.

    sql server:- 2008 r2 stardard edition
    os:- 64
    Package is password procted.
    following is command line in ssis package .
    /FILE "E:\PostgressToSql_IPMS\PostgressToSql_IPMS\PostgressToSql.dtsx"
     /DECRYPT  /CONNECTION "Server.user";"\"Data Source=server;
    User ID=user;Provider=SQLOLEDB.1;Persist Security Info=True;
    Application Name=SSIS-Package-{DD33AC67-4A45-40D6-AF70-4BBD421931C1}BPOSQLDB01\BPOSQLDB01.log4BPO;
    Auto Translate=False;\"" /CONNECTION "server.conn 1";
    "\"Data Source=server;User ID=log4BPO;Initial Catalog=edb1;
    Provider=SQLOLEDB.1;Persist Security Info=True;Auto Translate=False;
    Application Name=SSIS-Package-{665E3825-6AFC-4DD3-ABC8-50B5F0F18EEB}server.conn 1;
    \"" /CHECKPOINTING OFF /REPORTING E
    Need change something? Seperate configuaration file required ?

    Hi Dinesh,
    Based on my research, the issue is caused by you are running a SSIS package with a connection manager that has a space-character in the connection name.
    To work around this issue, please refer to the following two suggestions:
    Rename the connection manager in THE package to not include certain special characters (spaces, dashes). Note that the connection manager name can be changed without having to edit any property of the connection string itself.
    Escape quote the connection name, such that
    /CONNECTION "server.conn 1";"..."
    becomes
    /CONNECTION "\"server.conn 1\"";"..."
    The following similar issue is for your reference:
    https://connect.microsoft.com/SQLServer/feedback/details/510869/dtexec-commandline-fails-when-connection-is-passed-to-commandline-and-connection-name-contains-a-space
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • How to change a setting in the Java Control Panel with command line

    Hi,
    I am trying to figure out how to change a setting in the Java Control Panel with command line or with a script. I want to enable "Use SSL 2.0 compatible ClientHello format"
    I can't seem to find any documentation on how to change settings in the Java Control Panel via the command line
    Edited by: 897133 on Nov 14, 2011 7:15 AM

    OK figured it out. This is for the next person seeking the same solution.
    When you click on the Java Control Panel (found in the Control panel) in any version of Windows, it first looks for a System Wide Java Configuration (found here: C:\Windows\Sun\Java\Deployment). At this point you must be wondering why you don't have this folder (C:\Windows\Sun\Java\Deployment) or why its empty. Well, for an enterprise environment, you have to create it and place something in it - it doesn't exist by default. So you'll need a script (I used Autoit) to create the directory structure and place the the two files into it. The two files are "deployment.properties" and "deployment.config".
    Example: When you click on the Java Control Panel it first checks to see if this directory exists (C:\Windows\Sun\Java\Deployment) and then checks if there is a "deployment.config". If there is one it opens it and reads it. If it doesn't exist, Java creates user settings found here C:\Users\USERNAME\AppData\LocalLow\Sun\Java\Deployment on Windows 7.
    __deployment.config__
    It should look like this inside:
    *#deployment.config*
    *#Mon Nov 14 13:06:38 AST 2011*
    *# The First line below specifies if this config is mandatory which is simple enough*
    *# The second line just tells Java where to the properties of your Java Configuration*
    *# NOTE: These java settings will be applied to each user file and will overwrite existing ones*
    deployment.system.config.mandatory=True
    deployment.system.config=file\:C\:/WINDOWS/Sun/Java/Deployment/deployment.properties
    If you look in C:\Users\USERNAME\AppData\LocalLow\Sun\Java\Deployment on Windows 7 for example you will find "deployment.properties". You can use this as your default example and add your settings to it.
    How?
    Easy. If you want to add *"Use SSL 2.0 compatible ClientHello format"*
    Add this line:
    deployment.security.SSLv2Hello=true
    Maybe you want to disable Java update (which is a big problem for enterprises)
    Add these lines:
    deployment.javaws.autodownload=NEVER
    deployment.javaws.autodownload.locked=
    Below is a basic AutoIt script you could use (It compiles the files into the executable. When you compile the script the two Java files must be in the directory you specify in the FileInstall line, which can be anything you choose. It will also create your directory structure):
    #NoTrayIcon
    #RequireAdmin
    #Region ;**** Directives created by AutoIt3Wrapper_GUI ****
    #AutoIt3Wrapper_UseX64=n
    #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
    Func _JavaConfig()
         $ConfigFile_1 = @TempDir & "\deployment.properties"
         $ConfigFile_2 = @TempDir & "\deployment.config"
         FileInstall ("D:\My Documents\Autoit\Java config\deployment.properties", $ConfigFile_1)
    FileInstall ("D:\My Documents\Autoit\Java config\deployment.config", $ConfigFile_2)
         FileCopy($ConfigFile_1, @WindowsDir & "\Sun\Java\Deployment\", 9)
         FileCopy($ConfigFile_2, @WindowsDir & "\Sun\Java\Deployment\", 9)
         Sleep(10000)
         FileDelete(@TempDir & "\deployment.properties")
         FileDelete(@TempDir & "\deployment.config")
    EndFunc
    _JavaConfig()
    Now if you have SCUP and have setup Self Cert for your organization, you just need to create a SCUP update for JRE.
    Edited by: 897133 on Nov 16, 2011 4:53 AM

Maybe you are looking for

  • How to change emailadress which apple use to sent verification on chancing password

    I like to change my password of my iCloudaccount. I've been logged in with mine Apple ID and selected 'Change password' Got 2 controle questions which I do not know the answers of. When forgotten the password Apple sent a safetyinformation to a email

  • Configuration guide for ESS/MSS mySAP ERP 2005

    Hi Can you please send me configuration guide for ESS/MSS mySAP ERP 2005. Thanks in advance Regards Gauri

  • LR3 does not remember last filter setting

    When accessing image folders in the Library module, LR3 does not remember the filter settings that were in used during the last visit. This was a great feature in 2.*. Is there any way to restore this desirable behavior?

  • How do I get rid of a script error?

    I keep getting this error message:  A script on this page may be busy, or it may have stopped responding. You can stop the script now, or you can continue to see if the script will complete.  Script: https://s3.amazonaws.com/hostjs/load.js:1 It seems

  • Basic HTTP Auth in HTML component

    When I use the HTML component in AIR and visit a page which has basic HTTP Auth and enter the correct username/password the credentials window just comes back up. In Firefox, IE, Safri and Opera it seems to be working. Can anyone please help?