[Fedora-directory-users] Windows console

Ian Blackwell ian at ikel.id.au
Thu Jan 3 01:48:38 UTC 2008


On closer inspection at home, I see that I didn't set the JAVA value, I
changed the PC so that the path to JAVA.EXE was in the environment.  The
script is able to detect this and then works.

Try adding the path to your Java installation to your environment via
the Windows Control Panel and System applet.

Ian

kiran madala wrote:
> Hi,
>
> Thanks for the reply. Where exactly do I need to set my java variable
> path?
>
> I set the java path in the .bat file its not working. I am not sure if
> i did it the right way. below is my .bat file with changes in bold.
> Thanks in advance
>
>
> rem
> rem This library is free software; you can redistribute it and/or
> rem modify it under the terms of the GNU Lesser General Public
> rem License as published by the Free Software Foundation version
> rem 2.1 of the License.
> rem                                                                                
>
> rem This library is distributed in the hope that it will be useful,
> rem but WITHOUT ANY WARRANTY; without even the implied warranty of
> rem MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
> rem Lesser General Public License for more details.
> rem                                                                                
>
> rem You should have received a copy of the GNU Lesser General Public
> rem License along with this library; if not, write to the Free Software
> rem Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 
> 02110-1301  USA
> rem END COPYRIGHT BLOCK
>
> rem set the JAVA to use here
> rem set JAVA=C:\Program Files\Java\jre1.6.0_03\bin\java
>
> if not "%JAVA%foo"=="foo" goto launch
>
> where java > nul 2>&1 || goto findjre
>
> set JAVA=java
> goto launch
>
> :findjre
> rem look for Java Runtime Environment in registry
> reg QUERY "HKLM\SOFTWARE\JavaSoft\Java Runtime Environment" > nul 2>&1
> || goto findjdk
>
> rem can we grab the java location from the registry?
> rem set JAVA=path\bin\java
> rem apparently not, in a batch file
> rem goto launch
> echo The Java Runtime Environment is installed on this machine, but the
> echo command java.exe is not in your PATH.  You can either make sure
> java.exe
> echo is in the PATH, or edit this script to set JAVA to the full path of
> echo java.exe
> pause
> goto end
>
> :findjdk
> reg QUERY "HKLM\SOFTWARE\JavaSoft\Java Development Kit" > nul 2>&1 ||
> goto nojava
>
> rem can we grab the java location from the registry?
> rem set JAVA=path\bin\java
> rem goto launch
> echo The Java Development Kit is installed on this machine, but the
> echo command java.exe is not in your PATH.  You can either make sure
> java.exe
> echo is in the PATH, or edit this script to set JAVA to the full path of
> echo java.exe
> pause
> goto end
>
> :nojava
> echo Java does not appear to be installed on this machine.  Please
> download and install the Java Runtime Environment and make sure the
> java.exe command is in the PATH of this command.
> pause
> goto end
>
> :launch
> set BASEPATH=.
> set FIDMCONSOLEJARDIR=%BASEPATH%
> set CONSOLEJARDIR=%BASEPATH%
> set JSSDIR=%BASEPATH%
> set LDAPJARDIR=%BASEPATH%
>
> set PATH=%BASEPATH%;%PATH%
>
> rem
> rem Launch the Console
> rem
> echo on
> "%JAVA%" "-Djava.library.path=%JSSDIR%" -cp
> "%JSSDIR%/jss4.jar;%LDAPJARDIR%/ldapjdk.jar;%CONSOLEJARDIR%/idm-console-base.jar;%CONSOLEJARDIR%/idm-console-mcc.jar;%CONSOLEJARDIR%/idm-console-mcc_en.jar;%CONSOLEJARDIR%/idm-console-nmclf.jar;%CONSOLEJARDIR%/idm-console-nmclf_en.jar;%FIDMCONSOLEJARDIR%/fedora-idm-console_en.jar"
> -Djava.util.prefs.systemRoot=%HOME%/.fedora-idm-console
> -Djava.util.prefs.userRoot=%HOME%/.fedora-idm-console
> com.netscape.management.client.console.Console %*
>
> :end
>
>
>
>     ------------------------------------------------------------------------
>     Date: Thu, 3 Jan 2008 07:59:42 +1030
>     From: ian at ikel.id.au
>     To: fedora-directory-users at redhat.com
>     Subject: Re: [Fedora-directory-users] Windows console
>
>     Hi,
>
>     This happened to me as well.  I think the installer can't cope
>     with or doesn't look for Java in your "Program Files" area, which
>     is where you will find the newer Javas 1.6.  Edit the .bat file
>     and set the Java variable yourself and it should work from then on.
>
>     Regards,
>
>     Ian
>     kiran madala wrote:
>
>         Hi,
>
>         The windows console for 1.1 server does not work it gives me
>         this error
>
>         F:\Program Files\Fedora Identity Management Console>echo off
>         The Java Runtime Environment is installed on this machine, but the
>         command java.exe is not in your PATH.  You can either make
>         sure java.exe
>         is in the PATH, or edit this script to set JAVA to the full
>         path of
>         java.exe
>         Press any key to continue . . .
>
>
>         All my java programs work. The java in my class path and also
>         in my registry . Any idea whats causing the problem?
>
>
>
>
>         ------------------------------------------------------------------------
>         HO HO HO, if you've been naughty this year, email Santa! Visit
>         asksanta.ca to learn more!
>         <http://asksanta.ca/?icid=SANTAENCA005>
>
>         ------------------------------------------------------------------------
>
>         --
>         Fedora-directory-users mailing list
>         Fedora-directory-users at redhat.com <mailto:Fedora-directory-users at redhat.com>
>         https://www.redhat.com/mailman/listinfo/fedora-directory-users
>           
>
>
>
> ------------------------------------------------------------------------
> HO HO HO, if you've been nice this year, email Santa! Visit
> asksanta.ca to learn more! <http://asksanta.ca/?icid=SANTAENCA005>
> ------------------------------------------------------------------------
>
> --
> Fedora-directory-users mailing list
> Fedora-directory-users at redhat.com
> https://www.redhat.com/mailman/listinfo/fedora-directory-users
>   




More information about the Fedora-directory-users mailing list