I. BACKGROUND
Companies in the use of kettle to do data etl, every job or transformation released on the line want to immediately execute see data effect, every time is to find the operation of the login server open kettle Find the corresponding file click execution, the whole process inefficient, not only occupy the operation and maintenance time, During the period oneself also in vain wait, wasting life.
Google "kettle remotely execute" learned that this is a solution, in fact, kettle itself brought this solution, but has been busy working without (lan) free (de) Research. Basically is to use kettle bring carte to open a Web server, plus job or transformation do a little configuration to implement the login Web to trigger the execution of a Task.
Ii. preparatory work
This blog is based on Windows Server
1. Download Java JDK, version 1.5 or above, if you have previously installed and the version is confusing, please uninstall and then download an installation
2. Download Kettle. Kettle Green does not need to install, after downloading to the specified folder can be downloaded, while configuring the system environment variable (pentaho_java_home), value specified to the installed JDK corresponding to the directory of the JRE (such as), and find Spoon.bat click to open Kettle.
Please note that the directory assigned to the JRE is not Mistaken.
third, Open the server
After preparing for the second step, make sure that the Kettle software is turned on correctly. If there is a problem that does not open properly, Google Solutions.
We first see the root directory of the kettle, and after 5.0 the kettle will have carte.bat under the root directory (. sh is used under the Linux system), and that's what we're going to Use.
Under window, Open the CMD,CD switch to the root directory of kettle:
Then execute the command line and open a Web server.
Carte.bat 127.0.0.1 8081
Wait more than 10 seconds for the server to open successfully if prompted
The prerequisite for this success is that the PENTAHO_JAVA_HOME environment variable is configured correctly, otherwise it will prompt Java.exe to find an Error.
After success we can open the browser http:127.0.0.1:8081 to see the effect, will give a popup box requires you to enter the account password authentication:
What is the password for this account? Don't worry, we go back to Kettle root directory, Find the pwd folder, Double-click into, found the following several files:
Our account password is configured on the inside, open-8081 XML file:
<?XML version= "1.0"?>-<Slave_config><!--Document description-masters:you can list the slave servers to which this slave have to report back To. If This is a master, we'll contact the other masters to get a list of all the slaves in the Cluster. -report_to_masters:send a message to the defined masters to let them know we exist (y/n)-slaveserver:specify the SL Ave Server details of this carte instance. Important:the username and password specified here is used by the master instances to connect to this Slave. --<Masters>-<Slaveserver><name>Master1</name><hostname>localhost</hostname><Port>8080</Port><username>Cluster</username><Password>Cluster</Password><Master>Y</Master></Slaveserver></Masters><report_to_masters>Y</report_to_masters>-<Slaveserver><name>slave1-8081</name><hostname>localhost</hostname><Port>8081</Port><username>Cluster</username><Password>Cluster</Password><Master>N</Master></Slaveserver></Slave_config>
We opened is a slave server, so look at Slaveserver inside the configuration of username and password, to, The default is cluster, here is the configuration value of your login account Password. You can now log in to the configured carte Server.
Come in and find nothing, this is normal, because we also need to configure the kettle job and transformation, to this step of the entire Web server work is Done. The next step is the configuration of the kettle File.
Iv. Configuration of Kettle
1. Open kettle, and open a job alive transformation, in the left menu select view, menu Options There is a slave Server, here we need to configure.
We're New. a slaveserver, the value of the Response:
Note here that the IP and port must be the same as the Web server we previously opened, and after clicking ok, Remember to Share.
2. Configure the run options for the job or transformation
Open any job or transformation with the run options, such as:
Continue Configuration:
Will generate a new tab, where our configuration is Complete.
Open http://127.0.0.1:8081 to see, in the job list there has just been the job we configured
Is it convenient for us to go in and control the job in the web?
Kettle (Pentaho) to implement the Web way to perform a job or transformation remotely