add some hacks to manipulate services better
This commit is contained in:
parent
f33e61098f
commit
a617210d68
27
torque.spec
27
torque.spec
@ -71,7 +71,7 @@
|
|||||||
|
|
||||||
Name: torque
|
Name: torque
|
||||||
Version: 4.2.10
|
Version: 4.2.10
|
||||||
Release: 1%{?dist}
|
Release: 2%{?dist}
|
||||||
Summary: Tera-scale Open-source Resource and QUEue manager
|
Summary: Tera-scale Open-source Resource and QUEue manager
|
||||||
Source0: http://www.adaptivecomputing.com/download/%{name}/%{name}-%{version}.tar.gz
|
Source0: http://www.adaptivecomputing.com/download/%{name}/%{name}-%{version}.tar.gz
|
||||||
Source2: xpbs.desktop
|
Source2: xpbs.desktop
|
||||||
@ -135,6 +135,8 @@ BuildRequires: tetex-latex
|
|||||||
%endif
|
%endif
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
Requires(post): /bin/grep /etc/services
|
||||||
|
|
||||||
%description
|
%description
|
||||||
TORQUE (Tera-scale Open-source Resource and QUEue manager) is a resource
|
TORQUE (Tera-scale Open-source Resource and QUEue manager) is a resource
|
||||||
manager providing control over batch jobs and distributed compute nodes.
|
manager providing control over batch jobs and distributed compute nodes.
|
||||||
@ -496,21 +498,17 @@ EOF
|
|||||||
rm -rf %{buildroot}
|
rm -rf %{buildroot}
|
||||||
|
|
||||||
%post
|
%post
|
||||||
if grep -q "PBS services" /etc/services;then
|
for srvs in pbs:15001 pbs_mon:15002 pbs_resmom:15003 pbs_sched:15004 ; do
|
||||||
: PBS services already installed
|
port=${srvs/*:/}
|
||||||
else
|
srvs=${srvs/:*/}
|
||||||
|
for proto in tcp udp ; do
|
||||||
|
if ! grep -q $srvs'\W\W*'$port'/'$proto /etc/services;then
|
||||||
cat<<__EOF__>>/etc/services
|
cat<<__EOF__>>/etc/services
|
||||||
# Standard PBS services
|
$srvs $port/$proto
|
||||||
pbs 15001/tcp # pbs server (pbs_server)
|
|
||||||
pbs 15001/udp # pbs server (pbs_server)
|
|
||||||
pbs_mom 15002/tcp # mom to/from server
|
|
||||||
pbs_mom 15002/udp # mom to/from server
|
|
||||||
pbs_resmom 15003/tcp # mom resource management requests
|
|
||||||
pbs_resmom 15003/udp # mom resource management requests
|
|
||||||
pbs_sched 15004/tcp # scheduler
|
|
||||||
pbs_sched 15004/udp # scheduler
|
|
||||||
__EOF__
|
__EOF__
|
||||||
fi
|
fi
|
||||||
|
done
|
||||||
|
done
|
||||||
|
|
||||||
%posttrans client
|
%posttrans client
|
||||||
/usr/sbin/alternatives --install %{_bindir}/qsub qsub %{_bindir}/qsub-torque 10 \
|
/usr/sbin/alternatives --install %{_bindir}/qsub qsub %{_bindir}/qsub-torque 10 \
|
||||||
@ -815,6 +813,9 @@ fi
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Apr 24 2015 David Brown <david.brown@pnnl.gov> - 4.2.10-2
|
||||||
|
- Bugfix - #1154413 make manipulating services better.
|
||||||
|
|
||||||
* Mon Apr 6 2015 David Brown <david.brown@pnnl.gov> - 4.2.10-1
|
* Mon Apr 6 2015 David Brown <david.brown@pnnl.gov> - 4.2.10-1
|
||||||
- Updated upstream version
|
- Updated upstream version
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user