Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
RE: Cannot run program "java": error=2, No such file or directory
Hi All,
I got the below error ,while starting the server for
Liferay-7 in eclpise.Could any one help me out
17-Oct-2018 11:35:45.794 SEVERE [localhost-startStop-1]
org.apache.catalina.core.StandardContext.listenerStart Exception
sending context initialized event to listener instance of class
com.liferay.portal.spring.context.PortalContextLoaderListener
java.lang.RuntimeException:
com.liferay.portal.kernel.process.ProcessException:
java.io.IOException: Cannot run program "java":
error=2, No such file or directory
at
com.liferay.portal.spring.context.PortalContextLoaderListener.contextInitialized(PortalContextLoaderListener.java:256)
at
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4812)
at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5255)
at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:725)
at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:701)
at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717)
at
org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:585)
at
org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1794)
at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by:
com.liferay.portal.kernel.process.ProcessException:
java.io.IOException: Cannot run program "java":
error=2, No such file or directory
at
com.liferay.portal.kernel.process.local.LocalProcessExecutor.execute(LocalProcessExecutor.java:230)
at
com.liferay.portal.lpkg.deployer.internal.LPKGIndexValidator._getTargetPlatformIndexURIs(LPKGIndexValidator.java:301)
at
com.liferay.portal.lpkg.deployer.internal.LPKGIndexValidator.validate(LPKGIndexValidator.java:222)
at
com.liferay.portal.lpkg.deployer.internal.DefaultLPKGDeployer._doActivate(DefaultLPKGDeployer.java:266)
at
com.liferay.portal.lpkg.deployer.internal.DefaultLPKGDeployer.activate(DefaultLPKGDeployer.java:84)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
Thanks & Regards,
P.V.B.Raju
Attachments:
Bangaru Raju Potnuru:Caused by: com.liferay.portal.kernel.process.ProcessException: java.io.IOException: Cannot run program "java": error=2, No such file or directory at com.liferay.portal.kernel.process.local.LocalProcessExecutor.execute(LocalProcessExecutor.java:230) at com.liferay.portal.lpkg.deployer.internal.LPKGIndexValidator._getTargetPlatformIndexURIs(LPKGIndexValidator.java:301) at com.liferay.portal.lpkg.deployer.internal.LPKGIndexValidator.validate(LPKGIndexValidator.java:222) at com.liferay.portal.lpkg.deployer.internal.DefaultLPKGDeployer._doActivate(DefaultLPKGDeployer.java:266) at com.liferay.portal.lpkg.deployer.internal.DefaultLPKGDeployer.activate(DefaultLPKGDeployer.java:84) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498)
You're running into LPS-68512. To
resolve it, you need to make sure that your
${JAVA_HOME}/bin folder is on the system path.