Tomcat - The system cannot find the file specified - apache

I downloaded Tomcat 6 from Tomcat Website and try to install. I found the .exe file in C:\apache-tomcat-6.0.35\bin but when i run the exe file the command prompt disappeared after show "The system cannot find the file specified". I already installed JDK 6 update 29 in my system. Please advice

I had a simmilar problem after installing a java update, but JAVA_HOME was set correctly. If you run tomcat as a service, you might have to right click on the tomcat icon and open java tab and change java virtual machine path or just set "use default".

If I were to "guess" I would say that the JAVA_HOME is not set. But to confirm :
Can you go the command line, make sure that JAVA_HOME is set correctly, startup tomcat (from command line) ? If you run into errors, please send the text output.

Try to run "startup.bat" to start a tomcat instance.

Go to your/path/tomcat and execute script catalina_start.bat .I had the same issue and this worked for me (though I installed Tomcat as a part of XAMPP package)

Related

Lucee Express on local Dev

I’m currently running window 7, ACF 11, and IIS 7 and would like to install Lucee express to try.
I’m having the hardest time getting Lucee to work on my local desktop. I followed this article http://www.gpickin.com/index.cfm/blog/setting-up-lucee-in-my-dev-environment-changing-ports I can’t get the Lucee welcome page to work.
I download the Lucee Express from here http://lucee.org/downloads.html
I extract the file to C:\lucee
Ran the C:\lucee\bin\startup.bat
Navigated to 127.0.0.1:8888
I get the follow message: Firefox can't establish a connection to the server at 127.0.0.1:8888
Can someone tell me what am I doing wrong? Thank you in advance for your insights.
As identified in the comments on the question: you are missing the environment variable pointing to your Java runtime (you need one of JAVA_HOME or JRE_HOME.
This can be achieved in one of a coupla ways.
Set it globally:
Control Panel > System > Advanced system settings > Environment Variables > System Variables > New...
Or set it for just that environment by editing the startup.bat file you've already been using:
SET JAVA_HOME=[path]
In both situations you need a path to either a JRE or a JDK. You say you have CF11 already installed, so you can simply point to its one, which will be a subdirectory of your CF install, as Leigh points out above. So something like:
SET JRE_HOME=D:\apps\Adobe\ColdFusion\11\express\jre
If you have a Java JDK installed instead and want to use that, use JAVA_HOME instead of JRE_HOME, eg:
SET JAVA_HOME=D:\apps\Oracle\Java\jdk\1.8.0_60
As these things can be installed anywhere, you'll just need to locate 'em and use the path accordingly. You want to point it to the top level directory of your JRE or JDK, which contains the bin subdirectory.

SQLDeveloper not starting

When i try to start SQLDeveloper, it is giving me the following error in command prompt:
Error: This product requires a Java(TM) Platform 5.0 runtime.
You are using 1.4.2-b28 from C:\j2sdk1.4.2\jre
But my JAVA_HOME is set to java 6
JAVA_HOME=C:\Program Files\Java\jdk1.6.0_32
Can anyone explain what exactly to do to resolve this?
Oracle SQL Developer uses a configuration file named products.conf which is situated at your roaming directory.
If you are using Windows 7 then the directory path will be:
C:\Users\\AppData\Roaming\sqldeveloper\1.0.0.0.0
Delete whole sqldeveloper directory from C:\Users\\AppData\Roaming\
Re run sqldeveloper executable, this will prompt for jdk home
Select jdk home. i.e C:\Program Files\Java\jdk1.7.0_55
Enjoy!
In my case i had 2 folders under C:\Users\username\AppData\Roaming\
sqldeveloper
SQL developer
after removing both of them and launching installation dir\sqldeveloper\sqldeveloper\bin\sqldeveloper64.exe it worked.
True acknowledgement / attribution belongs to Vishal at the following URL:
http://vishalorcl.blogspot.com/2012/12/sql-developer-from-11201-client-software.html. It describes in detail how to resolve this problem. From the page:
I am running Oracle 11g version of SQLDeveloper. I have same problem
noted above, after fresh install of Oracle. The summary is that
SQLDeveloper seems to require the Java 32-bit JDK.
Install 32-bit jdk V7 from Oracle:
http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html
There is a sqldeveloper.conf file located in
C:\app\UserName\product\11.2.0\dbhome_1\sqldeveloper\sqldeveloper\bin
In the file change pathname within the line at end of file:
SetJavaHome C:\app\admin\product\11.2.0\client_1\jdk
To point to pathname of the jdk install directory; also sometimes
known as JAVA_HOME.
I had this problem too!
you should go to: C:\Users-your user name-\AppData\Roaming\sqldeveloper-version of your sql developer-
there is a file named product.conf there. Right click on it and edit it with notepad in the document change the address of java home and save it.
Done!
In my case, none of the other suggestions worked. Instead, I moved the installation directory from
c:\sqldeveloper
to
anything else
And things worked again. Perhaps, some Windows registry value got broken in an unfixable way...
I don't think SQLDeveloper uses the environment variable. There should be a .conf file that contains a reference to the JDK directory.
I solved this by deleting the folder /home/USERNAME/.sqldeveloper
After that, I started SQLDeveloper and without typing anything, it found the right java-version and started without complaining :-)
So, if you don't want to delete the whole folder, maybe search there for the file which defines the java-version :-)
edit: just found that:
"Type the full pathname of a J2SE installation (or Ctrl-C to quit), the path
will be stored in ~/.sqldeveloper/jdk"
check the version of java that you are installing to you Pc the error show that you are using 4 so uninstall the java that you have then install a new one that is version higher than 5
Removing the instances from the registry worked for me.

I am trying to open Jmeter by the batch file but it gives me a Windows error

Here is the related error its showing:
java.exe is not a recognized file as an internal or external command,
operable or external command
errorlevel=9009
i was getting the same error on WIndows 8.1(64 bit) and checked java path but it was ok
so i just run my jmeter.bat with Run as Administrator and it worked for me
Many operating systems have an environment variable such as PATH that contains a list of directories (or folders) to be searched when looking for a command to execute. Commands that can be found via the PATH are commonly called external commands. The program that reads the command line or the batch file and invoked the commands may have a number of built in commands, these are commonly called internal commands.
I suggest you examine the PATH (or equivalent) set when your java command executes from the command line and also when execution is attempted from the batch file. Compare the two and make sure the directory containing your java.exe is in the PATH.
Does not work with Java 9 beta:
Running:
C:\java -version
Gives:
java version "9-ea"
Just go into command line and run:
java -jar ApacheJMeter.jar
Set the correct Java Path (installed in your system) in Computer -> Advanced System settings -> Environment Variables -> Ok -> System Variables -> Path
I got the same issue and resolved by following the above steps.
I tried everything, this eventually worked.
Within System Variables:
PATH = "C:\WINDOWS\system32;C:\WINDOWS;C:\Program Files\Java\jdk1.8.0_101\bin"
May help someone.
This error occurs due to the path has not been set properly.
Either you can set it in environmental varialables or right click jmeter .bat file,choose edit set the path their,for reference see the jmeter.apache.org user manuals.
For me, my Java path has a space in it and jmeter said it can't find Java
/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home
.. I looked at the jmeter.sh script and saw it got the path from "Plugin-Ins" .. onward. I tried just commenting out the exit command after that check in the script .. and then I was able to run jmeter.
So apparently the validation logic has a bug, where the error message about can't find java is in fact not true (if Java is indeed set up correctly), so it can be ignored.
For windows 8.1 Users:
Error when trying to run jmeter.bat
Error message:
Not able to find Java executable or version. Please check your Java installation. errorlevel=2
Press any Key to continue
Resolution:
Right Click jmeter.bat and Run as Administrator.
This worked for me, hope this helps. Good luck
Set the correct JM_LAUNCH variable to java.exe
For Windows XP users set Java environment by following the steps here:
http://www.tutorialspoint.com/jmeter/jmeter_environment.htm
Note the path depends on your installed JDK.
And download the file from:
https://svn.apache.org/repos/asf/jmeter/trunk/bin/jmeter.bat
Then replace your jmeter.bat with the downloaded file.
If you have installed Java and still you get this error, please set the java_home path to below using typing below command in terminal:
export JAVA_HOME="/Library/InternetPlugIns/JavaAppletPlugin.plugin/Contents/Home"
Since I run many versions of Java.. I modified jmeter.bat.
rem JM_START - set this to "start" to launch JMeter in a separate window
rem this is used by the jmeterw.cmd script.
rem
rem =====================================================
setlocal
rem Minimal version to run JMeter
set MINIMAL_VERSION=1.8.0
set PATH=%PATH%;C:\Program Files (x86)\IBM\Java80\jre\bin <<< add This line to jmeter.bat
Copied the JAVA executable from Installed version of Java from C:\Program FilesJava\jdk1.8.0_191\bin and pasted in the folder where the jmeter bat resides and it worked for me.
Not exactly the same issue but somebody might find it helpful
Do not double click jmeter.bat but instead ApacheJMeter.jar in the same directory
For me jmeter.bat run but for a brief moment closing almost immediately and not prompting any error. Above workaround allowed me to start working
if JAVA -version shows as blank or empty in the command prompt (CMD) then you need to clear the all java paths in environment variable and again add JAVA_HOME=C:\Program Files\Java\jdk-11.0.15.1
path= C:\Program Files\Java\jdk-11.0.15.1\bin;
if you see C:\Program Files\Common Files\Oracle\Java\javapath; like this remove this
and try in new CMD prompt then Java -version will work.

Configuring and running integrated weblogic server in jdeveloper

i know this can be very simple but i am not able to do so.
I am trying to start integrated weblogic server in jdeveloper(v11.1.1.7.0). But it always says the following error :
*** Using port 7101 ***
C:\Users\595452\AppData\Roaming\JDeveloper\system11.1.1.7.40.64.93\DefaultDomain\bin\startWebLogic.cmd
[waiting for the server to complete its initialization...]
The system cannot find the path specified.
The JRE was not found in directory C:\Oracle\MIDDLE~1\jdk160_29. (JAVA_HOME)
Please edit your environment and set the JAVA_HOME
variable to point to the root directory of your Java installation.
Press any key to continue . . . [Server Instance IntegratedWebLogicServer is shutting down. All applications currently running will be terminated and undeployed.]
My Java_home is set to the jdk i have installed and also have an entry in PATH of system variable.
**User variable:**
C:\Program Files\Java\jdk1.7.0_45;C:\Program Files\Java\jre7
**System Variable :**
C:\Program Files\Java\jdk1.7.0_45\bin;C:\Program Files\Java\jre7\bin
Please assist me in this regard.
I fixed mine by editing the setDomainEnv.cmd in my weblogic installation.
In my installation D:\srv\wls12120\user_projects\domains\mydomain\bin my installation pointed to:
set SUN_JAVA_HOME=D:\Java\jdk\jdk8u40 changed to
set DEFAULT_SUN_JAVA_HOME=C:\PROGRA~1\Java\JDK17~1.0_2
set DEFAULT_SUN_JAVA_HOME=D:\Java\jdk\jdk8u40 changed to
set JAVA_HOME=C:\PROGRA~1\Java\JDK17~1.0_2
as well as here:
if "%VM_TYPE%"=="JRockit" (
set JAVA_HOME=%BEA_JAVA_HOME%
) else (
if "%JAVA_VENDOR%"=="Sun" (
set JAVA_HOME=%SUN_JAVA_HOME%
) else (
set JAVA_VENDOR=Oracle
set JAVA_HOME=D:\Java\jdk\jdk8u40
set VM_TYPE=HotSpot
)
)
This has solved my issue.
Apparently the install routine thinks that your JAVA_HOME is set to the wrong jre. First test is to open a command shell and type in "java -version"
Verify that you see Java 1.7.0 and not 1.6.0
One this had been checked check the ide.conf file or jdev.conf file which java version is configured there. There you should see jdk 1.7.0 configured.
Then you remove the DefaultDomain folder out of the system 11.1.1.x.x.x folder.
Then start jdev again and try to start the integrated server again.
Solution: Windows 7
Delete the C:\Users\\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36 folder and then restart your JDeveloper.
Delete the C:\Users\"username"\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36 folder and then restart your JDeveloper
While upgrading Java version, remove all the files available in the below path
C:\Users\\AppData\Roaming\JDeveloper

Glassfish 3.1.2.2 in IDEA 11.1.4: "PWC6345: There is an error in invoking javac. A full JDK (not just JRE) is required"

I am trying to get our Mavenized web application up and running in a freshly installed IDEA 11.1.4 Ultimate (Windows 7) under a freshly unzipped Glassfish 3.1.2.2. I have done this many times in Eclipse, but am not familiar with IDEA.
I can build and deploy it just fine, but when I try to access pages with JSP-content I get:
PWC6345: There is an error in invoking javac. A full JDK (not just JRE) is required
The Glassfish Application Servers entry adds the javax.ejb.jar, javax.servlet-api.jar and javax.servlet.jsp-api.jar as libraries.
I have set the project SDK to point to a full JDK resulting in:
(which does not seem to include a jar with javac)
The IntelliJ tutorials I've found so far, does not mention this problem. My guess would be that the "please start using this JDK" information is not passed on to Glassfish, so it just picks up the system JRE.
What configuration step have I missed? I do not want to edit configuration files - I expect the IntelliJ plugin to do this if I know how to tell it to.
I got the same notification and just changed in admin port -> Configurations -> server-config -> JVM Settings -> Java Home as "C:\Program Files\Java\jdk1.8.0_72", and it started working.
PWC6345: There is an error in invoking javac. A full JDK (not just JRE) is required.
I was getting same error after restarting my glassfish 4 server.When I am trying to access my deployed application it was saying to mention full JDK.
login to Glassfish admin console.(http://localhost:4848).
Go to Configuration---->server-config--->JVM Settings
Set the java home with your correct jdk home (ex:C:\Program Files (x86)\Java\jdk1.8.0_121).
Restart the server.
It will work fine.
Next solution helped me
source: http://alvinalexander.com/blog/post/java/fixing-glassfish-jdk-path-problem-solved
Find your asenv.bat file. C:\Program Files\glassfish-4.0\glassfish\config\asenv.bat
Open it in text editor and find strings like "set AS_ = blahblah"
Add this string there "set AS_JAVA=C:\Program Files\Java\jdk1.7.0_60" (print your own JDK path here). If string "set AS_JAVA= blahblah" already exists then just fix the path.
Add JDK_HOME\lib\tools.jar file to the JDK configuration Classpath.
However, the problem in your case may be different as Glassfish JDK is not taken from IntelliJ IDEA settings, this question may help:
How do I specify the jdk for a glassfish domain?