Repository: bigtop Updated Branches: refs/heads/master e489faa63 -> c4764966c
BIGTOP-2165. ignite-hadoop service doesn't start Project: http://git-wip-us.apache.org/repos/asf/bigtop/repo Commit: http://git-wip-us.apache.org/repos/asf/bigtop/commit/c4764966 Tree: http://git-wip-us.apache.org/repos/asf/bigtop/tree/c4764966 Diff: http://git-wip-us.apache.org/repos/asf/bigtop/diff/c4764966 Branch: refs/heads/master Commit: c4764966c97d96514302f8533b2afcca133075e0 Parents: e489faa Author: Konstantin Boudnik <[email protected]> Authored: Fri Jun 9 16:45:15 2017 -0700 Committer: Konstantin Boudnik <[email protected]> Committed: Sat Jun 10 23:15:59 2017 -0700 ---------------------------------------------------------------------- .../ignite_hadoop/templates/default-config.xml | 27 +++++++++++--------- .../common/ignite-hadoop/ignite-hadoop.default | 2 ++ .../rpm/ignite-hadoop/SPECS/ignite-hadoop.spec | 15 ++++++----- 3 files changed, 25 insertions(+), 19 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/bigtop/blob/c4764966/bigtop-deploy/puppet/modules/ignite_hadoop/templates/default-config.xml ---------------------------------------------------------------------- diff --git a/bigtop-deploy/puppet/modules/ignite_hadoop/templates/default-config.xml b/bigtop-deploy/puppet/modules/ignite_hadoop/templates/default-config.xml index bfaee60..9d8fc1e 100644 --- a/bigtop-deploy/puppet/modules/ignite_hadoop/templates/default-config.xml +++ b/bigtop-deploy/puppet/modules/ignite_hadoop/templates/default-config.xml @@ -117,20 +117,23 @@ <property name="host" value="0.0.0.0" /> <property name="port" value="10500" /> </bean> - </property> - - <!-- Sample secondary file system configuration. - 'uri' - the URI of the secondary file system. - 'cfgPath' - optional configuration path of the secondary file system, - e.g. /opt/foo/core-site.xml. Typically left to be null. - 'userName' - optional user name to access the secondary file system on behalf of. Use it - if Hadoop client and the Ignite node are running on behalf of different users. - --> + </property> <property name="secondaryFileSystem"> <bean class="org.apache.ignite.hadoop.fs.IgniteHadoopIgfsSecondaryFileSystem"> - <constructor-arg name="uri" value='hdfs://<%= @hadoop_head_node %>:<%= @hadoop_namenode_port %>'/> - <constructor-arg name="cfgPath"><null/></constructor-arg> - <constructor-arg name="userName" value="ignite"/> + <property name="fileSystemFactory"> + <bean class="org.apache.ignite.hadoop.fs.CachingHadoopFileSystemFactory"> + <!-- ATTN: The trailing slash in the url is very important work around for a bug + in the Ignite's URL parsing logic. It might get fixed in Ignite 2.1, though + See https://is.gd/8c2LQY for more info --> + <property name="uri" value='hdfs://<%= @hadoop_head_node %>:<%= @hadoop_namenode_port %>/'/> + <property name="configPaths"> + <list> + <value>/etc/hadoop/conf/core-site.xml</value> + </list> + </property> + </bean> + </property> + <property name="defaultUserName" value="ignite"/> </bean> </property> </bean> http://git-wip-us.apache.org/repos/asf/bigtop/blob/c4764966/bigtop-packages/src/common/ignite-hadoop/ignite-hadoop.default ---------------------------------------------------------------------- diff --git a/bigtop-packages/src/common/ignite-hadoop/ignite-hadoop.default b/bigtop-packages/src/common/ignite-hadoop/ignite-hadoop.default index 87626d6..a094720 100644 --- a/bigtop-packages/src/common/ignite-hadoop/ignite-hadoop.default +++ b/bigtop-packages/src/common/ignite-hadoop/ignite-hadoop.default @@ -20,3 +20,5 @@ export IGNITE_PID_DIR="/var/run/ignite-hadoop" export IGNITE_LOG_DIR="/var/log/ignite-hadoop" export IGNITE_WORK_DIR="/var/run/ignite-hadoop/work" export IGNITE_IDENT_STRING=ignite + +export HADOOP_HOME=${HADOOP_HOME:-/usr/lib/hadoop} http://git-wip-us.apache.org/repos/asf/bigtop/blob/c4764966/bigtop-packages/src/rpm/ignite-hadoop/SPECS/ignite-hadoop.spec ---------------------------------------------------------------------- diff --git a/bigtop-packages/src/rpm/ignite-hadoop/SPECS/ignite-hadoop.spec b/bigtop-packages/src/rpm/ignite-hadoop/SPECS/ignite-hadoop.spec index 1d621c6..b360b0a 100644 --- a/bigtop-packages/src/rpm/ignite-hadoop/SPECS/ignite-hadoop.spec +++ b/bigtop-packages/src/rpm/ignite-hadoop/SPECS/ignite-hadoop.spec @@ -22,6 +22,7 @@ %define pids_ignite %{ignite_home}/pids %define man_dir %{_mandir} %define ignite_username ignite +%define service_name %{name}-service %define vcs_tag %{ignite_hadoop_version} %if %{?suse_version:1}0 @@ -163,8 +164,8 @@ ln -s %{_localstatedir}/log/%{name} %{buildroot}/%{logs_ignite} %__install -d -m 0755 %{buildroot}/%{_localstatedir}/run/%{name} ln -s %{_localstatedir}/run/%{name} %{buildroot}/%{pids_ignite} -init_file=$RPM_BUILD_ROOT/%{initd_dir}/%{name} -bash %{SOURCE4} ${RPM_SOURCE_DIR}/ignite.svc rpm $init_file +init_file=$RPM_BUILD_ROOT/%{initd_dir}/%{service_name} +bash %{SOURCE4} ${RPM_SOURCE_DIR}/ignite-hadoop.svc rpm $init_file chmod 755 $init_file %__install -d -m 0755 $RPM_BUILD_ROOT/usr/bin @@ -204,17 +205,17 @@ fi %define service_macro() \ %files %1 \ -%attr(0755,root,root)/%{initd_dir}/%{name} \ +%attr(0755,root,root)/%{initd_dir}/%{service_name} \ %post %1 \ -chkconfig --add %{name} \ +chkconfig --add %{service_name} \ \ %preun %1 \ if [ $1 = 0 ] ; then \ - service %{name} stop > /dev/null 2>&1 \ - chkconfig --del %{name} \ + service %{service_name} stop > /dev/null 2>&1 \ + chkconfig --del %{service_name} \ fi \ %postun %1 \ if [ $1 -ge 1 ]; then \ - service %{name} condrestart >/dev/null 2>&1 \ + service %{service_name} condrestart >/dev/null 2>&1 \ fi %service_macro service
