java Pentaho 通过命令行运行作业

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/25480948/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-11-02 08:05:26  来源:igfitidea点击:

Pentaho running job through command line

javacommand-linepentaho

提问by freshMan

I have a pentaho job which runs successfully in pentaho but if i try to run the same through command line i get the error

我有一个在 pentaho 中成功运行的 pentaho 作业,但是如果我尝试通过命令行运行它,我会收到错误

Kitchen can't continue because the job could not be loaded.

厨房无法继续,因为无法加载作业。

D:\data-integration>kitchen.bat /file:D:\PENTAHO\pentahojobsNtrans_1\jobs\vws_sync_job_2.kjb /level:Basic
DEBUG: Using JAVA_HOME
DEBUG: _PENTAHO_JAVA_HOME=C:\Program Files\Java\jre7
DEBUG: _PENTAHO_JAVA=C:\Program Files\Java\jre7\bin\java.exe
2014/08/25 12:44:33 - Kitchen - Logging is at level : Basic logging
2014/08/25 12:44:33 - Kitchen - Start of run.
ERROR: Kitchen can't continue because the job couldn't be loaded.

What is that i am doing wrong? please help

我做错了什么?请帮忙

回答by kcondezo

The most common mistake that the begginers do (I am included) is to use "\" to give the path of the transformation or the job. Replace it by "/".

初学者最常犯的错误(包括我在内)是使用“\”来给出转换或工作的路径。将其替换为“/”。

回答by Alexandre Ribeiro

I get the same error on Windows (maybe de same solution works on Linux) because I have spaces on file names. If it is your case, protect the entire path of file directory with quotation marks.

我在 Windows 上遇到同样的错误(也许在 Linux 上使用相同的解决方案),因为我在文件名上空格。如果是您的情况,请用引号保护文件目录的整个路径。

For example:

例如:

"C:\Program Files\Pentaho Data Integration - Kettle 6.1.0.1\kitchen.bat" /file:"C:/Users/Username/Documents/Pentaho Projects/Job - System Integration.kjb" /level:Basic

Another important thing is to follow the instruction given by a_horse_with_no_name (funny username by the way) using slash.

另一个重要的事情是使用斜杠按照 a_horse_with_no_name (顺便说一下有趣的用户名)给出的说明。

Avoid the backslash instruction as given in the kitchen documentation (http://wiki.pentaho.com/display/EAI/Kitchen+User+Documentation) on its example: kitchen.bat /file:D:\Jobs\updateWarehouse.kjb /level:Basic

避免在其示例中的厨房文档(http://wiki.pentaho.com/display/EAI/Kitchen+User+Documentation)中给出反斜杠指令:kitchen.bat /file:D:\Jobs\updateWarehouse.kjb /level:Basic