Version 7.9.10 Command Line Utility

I’m still having problems with this error.

I alway get system cannot find the path specified but I this is the gwcmd file that is causing the problem.

my backup file is on drive e: I can take a dir and it shows, I have tried other backup but always the same. I have edited the gwcmd.bat to point to correct java path.

What am I missing?

If you comment out the the @ECHO OFF line in the .bat file, you’ll be able to specifically see which line is the problem (or at least see what it’s trying to do).

REM @ECHO OFF

OK here is what I got - can you see the problem?

Put backslashes in the JAVA_CMD line. Because… Windows. :wink:

Same error?

you should put quotes around current dir param. as the name has a space in it

Here is my gwcmd.bat file:
‘’’
Rem @echo off
set CURRENTDIR=%CD%
set IGNITION_DIR=“C:\Program Files\Inductive Automation\Ignition”
set JAVA_CMD=“C:\Program Files\Java\jre1.8.0_221\bin\java.exe”
cd %IGNITION_DIR%
%JAVA_CMD% -classpath ".;lib/" com.inductiveautomation.catapult.control.HeadlessControlUtil dataDir=data currentdir="%CURRENTDIR%" %
cd %CURRENTDIR%
‘’’

Will you show me as I have posted my gwcmd.bat file?

Please I really need some help?

Does

C:\Program Files\Java\jre1.8.0_221\bin\java.exe -version

in the command line work?

Just trying to break it down into smaller pieces.

Are you asking me if that version of java works? Is that a way for me to test it?

Copy it as a command. it should just return the version number of Java. Use it as a sanity check that you can run java from the directory we’re trying to run gwcmd.bat from.

That does not work it gives me the system cannot find the path specified error

Seems you have the wrong path for your java dir
You should be getting somehting like this. (ofc i have a different version)

OK, I’m sorry for being confused but It does work.

So is there anything else I might be missing?

I'm on a different version so i have no idea what com.inductiveautomation.catapult.control.HeadlessControlUtil is but
dataDir=data seems odd? no idea.

Copied this line from my only Windows install. Note the asterisk at the very end. I didn’t happen to see it on what you posted, but it could have been a copy / paste error.

%JAVA_CMD% -classpath ".;lib/core/gateway/*;lib/core/common/*" com.inductiveautomation.catapult.control.HeadlessControlUtil dataDir=data currentdir="%CURRENTDIR%" %*

EDIT: Nevermind, the rest of your parameters wouldn’t be there it the asterisk was missing.

I believe you’d be getting different errors if you were successfully invoking HeadlessControlUtil (and something like classpath, dataDir, etc was incorrect). The error message looks to be coming from Windows not being able to find java.exe (based on your JAVA_CMD var) to even be able to run the rest of it.

Should I not be able to type this at this command prompt:

I’m running the command prompt as administrator!
I’m at this command prompt.

c:\program files\inductive automation\ignition>gwcmd --help

This is what I get “The system cannot find the path specified”
I get the same error if I use -h

something strange is going on