Complete the following instructions to set up Oozie configuration files:
Extract the Oozie configuration files to a temporary directory.
The files are located in the
configuration_files/oozie
directory where you decompressed the companion files.Modify the configuration files.
In the temporary directory, locate the following file and modify the properties based on your environment. Search for
TODO
in the files for the properties to replace.Edit the
oozie-site.xml
and modify the following properties:<property> <name>oozie.base.url</name> <value>http://$oozie.full.hostname:11000/oozie</value> <description>Enter your Oozie server hostname.</description> </property>
<property> <name>oozie.service.StoreService.jdbc.url</name> <value>jdbc:derby:$OOZIE_DATA_DIR/$soozie.db.schema.name-db;create=true</value> </property>
<property> <name>oozie.service.JPAService.jdbc.driver</name> <value>org.apache.derby.jdbc.EmbeddedDriver</value> </property>
<property> <name>oozie.service.JPAService.jdbc.username</name> <value>$OOZIE_DBUSER</value> </property>
<property> <name>oozie.service.JPAService.jdbc.password</name> <value>$OOZIE_DBPASSWD</value> </property>
<property> <name>oozie.service.WorkflowAppService.system.libpath</name> <value>/user/oozie/share/lib</value> </property>
Edit the
oozie-env.sh
and modify the following properties to match the directories created:modify: export JAVA_HOME= add: JRE_HOME=$ {JAVA_HOME} export OOZIE_CONFIG=$ {OOZIE_CONFIG:-/etc/oozie/conf} export CATALINA_BASE=$ {CATALINA_BASE:-/var/lib/oozie/oozie-server} export CATALINA_TMPDIR=$ {CATALINA_TMPDIR:-/var/tmp/oozie} export OOZIE_CATALINA_HOME=/usr/lib/bigtop-tomcat
Copy the Configuration Files
On your Oozie server create the config directory, copy the configuration files, and set the permissions:
rm -r $OOZIE_CONF_DIR ; mkdir -p $OOZIE_CONF_DIR ;
Copy all the config files to
$OOZIE_CONF_DIR
directory.Set appropriate permissions.
chown -R $OOZIE_USER:$HADOOP_GROUP $OOZIE_CONF_DIR/../ ; chmod -R 755 $OOZIE_CONF_DIR/../ ;
where:
$OOZIE_CONF_DIR is the directory to store Oozie configuration files. For example, /etc/oozie/conf.
$OOZIE_DATA is the directory to store the Oozie data. For example, /var/db/oozie.
$OOZIE_LOG_DIR is the directory to store the Oozie logs. For example, /var/log/oozie.
$OOZIE_PID_DIR is the directory to store the Oozie process ID. For example, /var/run/oozie.
$OOZIE_TMP_DIR is the directory to store the Oozie temporary files. For example, /var/tmp/oozie.
$OOZIE_USER is the user owning the Oozie services. For example, oozie.
$HADOOP_GROUP is a common group shared by services. For example, hadoop.
Configure your database for Oozie:
For MySQL:
echo "create database if not exists oozie;" | mysql -u root echo "grant all privileges on oozie.* to 'oozie'@'localhost' identified by 'oozie';" | mysql -u root echo "grant all privileges on oozie.* to 'oozie'@`hostname -f` identified by 'oozie';" | mysql -u root
For Postgres:
echo "CREATE DATABASE oozie;" | psql -U postgres echo "CREATE USER oozie WITH PASSWORD 'oozie';" | psql -U postgres echo "GRANT ALL PRIVILEGES ON DATABASE oozie TO oozie;" | psql -U postgres