X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=NodeManager.spec;h=58778e790bf68201de0756e9fdf4007ce4342f8b;hb=780e8dc287c9cef5ed48077d3f4b3eb0f5314302;hp=d38d73a7b7a5a3a8d4ed329151a80152ed84d6fc;hpb=b7ee4c8d69092d93a2e21ebe6ab88996dc28c5a5;p=nodemanager.git diff --git a/NodeManager.spec b/NodeManager.spec index d38d73a..58778e7 100644 --- a/NodeManager.spec +++ b/NodeManager.spec @@ -1,15 +1,11 @@ -# -# $Id$ -# -%define url $URL$ - %define slicefamily %{pldistro}-%{distroname}-%{_arch} %define name NodeManager -%define version 2.0 -%define taglevel 4 +%define version 2.1 +%define taglevel 1 %define release %{taglevel}%{?pldistro:.%{pldistro}}%{?date:.%{date}} +%global python_sitearch %( python -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)" ) Summary: PlanetLab Node Manager Name: %{name} @@ -23,30 +19,27 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root Vendor: PlanetLab Packager: PlanetLab Central Distribution: PlanetLab %{plrelease} -URL: %(echo %{url} | cut -d ' ' -f 2) +URL: %{SCMURL} # not possible because of forward_api_calls #BuildArch: noarch -# Old Node Manager -Obsoletes: sidewinder, sidewinder-common - -# vuseradd, vuserdel -Requires: vserver-%{slicefamily} -Requires: util-vserver >= 0.30.208-17 - -# vserver.py -Requires: util-vserver-python > 0.3-16 - -# Signed tickets -Requires: gnupg - -# Contact API server -Requires: curl +# old name +#Obsoletes: sidewinder, sidewinder-common # Uses function decorators Requires: python >= 2.4 - +# connecting PLC +Requires: python-pycurl +# Signed tickets +Requires: gnupg +# vserver-sliceimage or lxc-sliceimage to be added explicitly in nodeimage.pkgs +# we do need the slice images in any case +Requires: sliceimage-%{slicefamily} +# our interface to the vserver patch +#Requires: util-vserver >= 0.30.208-17 +# vserver.py +#Requires: util-vserver-python > 0.3-16 # sioc/plnet Requires: pyplnet >= 4.3 @@ -68,14 +61,46 @@ local operations on slices. # make manages the C and Python stuff rm -rf $RPM_BUILD_ROOT %{__make} %{?_smp_mflags} install DESTDIR="$RPM_BUILD_ROOT" +PYTHON_SITEARCH=`python -c 'from distutils.sysconfig import get_python_lib; print get_python_lib(1)'` + +# install the sliver initscript (that triggers the slice initscript if any) +mkdir -p $RPM_BUILD_ROOT/usr/share/NodeManager/sliver-initscripts/ +rsync -av sliver-initscripts/ $RPM_BUILD_ROOT/usr/share/NodeManager/sliver-initscripts/ +chmod 755 $RPM_BUILD_ROOT/usr/share/NodeManager/sliver-initscripts/ mkdir -p $RPM_BUILD_ROOT/%{_initrddir}/ rsync -av initscripts/ $RPM_BUILD_ROOT/%{_initrddir}/ chmod 755 $RPM_BUILD_ROOT/%{_initrddir}/* -install -D -m 644 logrotate/nm $RPM_BUILD_ROOT/%{_sysconfdir}/logrotate.d/nm +install -d -m 755 $RPM_BUILD_ROOT/var/lib/nodemanager +install -D -m 644 logrotate/nodemanager $RPM_BUILD_ROOT/%{_sysconfdir}/logrotate.d/nodemanager +install -D -m 755 sshsh $RPM_BUILD_ROOT/bin/sshsh +install -D -m 644 bwlimit.py ${RPM_BUILD_ROOT}/${PYTHON_SITEARCH}/bwlimit.py + +########## %post +# tmp - handle file renamings; old names are from 2.0-8 +renamings=" +/var/lib/misc/bwmon.dat@/var/lib/nodemanager/bwmon.pickle +/root/sliver_mgr_db.pickle@/var/lib/nodemanager/database.pickle +/var/log/getslivers.txt@/var/lib/nodemanager/getslivers.txt +/var/log/nm@/var/log/nodemanager +/var/log/nm.daemon@/var/log/nodemanager.daemon +/var/run/nm.pid@/var/run/nodemanager.pid +/tmp/sliver_mgr.api@/tmp/nodemanager.api +/etc/logrotate.d/nm@/etc/logrotate.d/nodemanager +" +for renaming in $renamings; do + old=$(echo $renaming | cut -d@ -f1) + new=$(echo $renaming | cut -d@ -f2) + newdir=$(dirname $new) + if [ -e "$old" -a ! -e "$new" ] ; then + mkdir -p $newdir + mv -f $old $new + fi +done +# chkconfig --add conf_files chkconfig conf_files on chkconfig --add nm @@ -87,7 +112,7 @@ if [ "$PL_BOOTCD" != "1" ] ; then service fuse-pl restart fi - +########## %preun # 0 = erase, 1 = upgrade if [ $1 -eq 0 ] ; then @@ -107,9 +132,149 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/NodeManager/ %{_bindir}/forward_api_calls %{_initrddir}/ -%{_sysconfdir}/logrotate.d/nm +%{_sysconfdir}/logrotate.d/nodemanager +/var/lib/ +/bin/sshsh +%{python_sitearch}/bwlimit.py* %changelog +* Sun Jun 03 2012 Thierry Parmentelat - nodemanager-2.0-36 +- /var/log/nodemanager shows duration of mainloop + +* Fri Apr 13 2012 Thierry Parmentelat - nodemanager-2.1-1 +- first working draft for dealing with libvirt/lxc on f16 nodes +- not expected to work with mainline nodes (use 2.0 for that for now) + +* Fri Apr 13 2012 Thierry Parmentelat - nodemanager-2.0-35 +- remove Requires to deprecated vserver-* rpms, use sliceimage-* instead + +* Fri Dec 09 2011 Thierry Parmentelat - nodemanager-2.0-34 +- Added memory scheduling to core scheduler +- Core scheduler will now attempt to schedule cores on the same CPU to a slice, if a slice uses multiple cores + +* Thu Jul 07 2011 Thierry Parmentelat - nodemanager-2.0-33 +- tweaked log policy for the core scheduler +- curlwrapper has an optional verbose mode + +* Mon Jun 06 2011 Baris Metin - nodemanager-2.0-32 +- fixes for hmac and omf_control tags +- optional besteffort flag to core scheduler +- logrotate entry for /var/log/nodemanager.daemon +- a template for bash initscripts + +* Tue Mar 22 2011 Thierry Parmentelat - nodemanager-2.0-31 +- rename initscript_body into initscript_code +- fix generic vinit for broken bash syntax &>> + +* Mon Mar 21 2011 Thierry Parmentelat - nodemanager-2.0-30 +- new initscript_body slice tag, with stop and restart +- generic vinit script live updated +- new coresched module +- protect against non-existing vsys scripts +- use Config. instead of globals + +* Sun Feb 20 2011 Thierry Parmentelat - nodemanager-2.0-29 +- more robust reservation plugin + +* Thu Feb 17 2011 Thierry Parmentelat - nodemanager-2.0-28 +- bind-mount slice's .ssh into sliver for omf-friendly slices - no need to use dotsshmount (vsys) anymore +- reservation plugin more robust + +* Tue Feb 01 2011 Thierry Parmentelat - nodemanager-2.0-27 +- pass device to bwlimit + +* Tue Jan 25 2011 S.Çağlar Onur - nodemanager-2.0-26 +- start to use /etc/vservers//sysctl//{setting,value} files as new kernels don't support old syntax + +* Tue Jan 04 2011 S.Çağlar Onur - nodemanager-2.0-25 +- Catch all exceptions for sfa plugin + +* Wed Dec 22 2010 S.Çağlar Onur - nodemanager-2.0-24 +- Handle exception AttributeError: ComponentAPI instance has no attribute 'get_registry' + +* Mon Nov 29 2010 S.Çağlar Onur - nodemanager-2.0-23 +- Use networks key if interfaces is missing to solve the incompatibility between new NM and old API + +* Mon Nov 29 2010 S.Çağlar Onur - nodemanager-2.0-22 +- plugins/sliverauth.py improvements + +* Mon Oct 11 2010 S.Çağlar Onur - nodemanager-2.0-21 +- Disable sfagids plugin + +* Mon Oct 11 2010 S.Çağlar Onur - nodemanager-2.0-20 +- Re-tag nodemanager to include conflicted commits + +* Thu Sep 23 2010 Thierry Parmentelat - nodemanager-2.0-19 +- hotfix - make the UpdateSliceTag for ssh_key really incremental (was storming the API) +- sfagids plugin deleted +- band-aid patch for lack of GetSliceFamily removed + +* Mon Aug 23 2010 S.Çağlar Onur - nodemanager-2.0-18 + +* Fri Jul 16 2010 Thierry Parmentelat - nodemanager-2.0-17 +- revert curlwrapper to former forking-curl version +- fixes in the omf plugin for ssh key location and node hrn +- set umask 0022 in tools.daemon + +* Thu Jul 08 2010 Baris Metin - nodemanager-2.0-16 +- configure omf-resctl for keys + +* Mon Jul 05 2010 Baris Metin - NodeManager-2.0-15 +- fix key generation + +* Mon Jul 05 2010 Baris Metin - NodeManager-2.0-14 +- name changes and fix typos + +* Mon Jun 28 2010 S.Çağlar Onur - NodeManager-2.0-13 +- remove config and options parameters from start function + +* Sat Jun 26 2010 Thierry Parmentelat - NodeManager-2.0-12 +- working version of reservable nodes +- sliverauth generates an ssh keypair and export pub part as 'ssh_key' tag +- dismantled the -s|--startup option (no convincing need for that) +- simpler and more robust init.d/nm +- initscript content management through replace_file_with_string +- sliverauth uses replace_file_with_string +- curlwrapper has a debug mode + +* Wed Jun 23 2010 Thierry Parmentelat - NodeManager-2.0-11 +- pretty-printing/normalized python code - hopefully neutral + +* Tue Jun 22 2010 Thierry Parmentelat - NodeManager-2.0-10 +- (1) unconditionnally install and chkconfig-like a generic 'vinit' service +- that triggers /etc/init.d/vinit.slice if present and executable +- (2) install the slice-provided initscript (as per the initscript tag) as +- /etc/init.d/vinit.slice +- (3) as a result the initscript are now triggered by rc as part of the +- standard vserver .. start, properly attached to the vserver, +- and properly killed upon vserver .. stop +- (4) this works best with util-vserver-pl 0.3-31 or 0.4-12 + +* Wed Jun 16 2010 Thierry Parmentelat - NodeManager-2.0-9 +- fix for 64bits nodes: add newline to the personality files that instruct util-vserver to create 32bits slivers +- basic/partial support from reservable nodes through the 'reservation plugin' (not fully working yet) +- plugins can set 'persistent_data' to receive the latests know GetSlivers in case the connection is down +- cleanup: moved runtime files in /var/lib/nodemanager, and logs as /var/log/nodemanager* (see specfile) +- cleanup: some modules renamed (e.g. nm.py becomes nodemanager.py) +- cleanup: nodemanger now is a class; however plugins are still dumb modules +- cleanup: does not depend on obsolete Set + +* Fri May 14 2010 Talip Baris Metin - NodeManager-2.0-8 +- tagging before RC + +* Wed May 12 2010 S.Çağlar Onur - NodeManager-2.0-7 +- Fix typos in plugins/drl.py and doc/NMAPI.xml.in +- Added some precautions to the slice id-saving code +- Added log message to code that records the slice id + +* Mon Apr 26 2010 Sapan Bhatia - NodeManager-2.0-6 +- This version changes the location of the slice id for components such as PlanetFlow to look up. Previously this piece +- of information was stored in the 'vserver name' field of the per-vserver context structure in the kernel but we needed +- to move it elsewhere since Daniel decided to use that for something else (the vserver name... pedantic!). + +* Wed Apr 14 2010 Talip Baris Metin - NodeManager-2.0-5 +- fix log_call in plugins/drl.py + * Fri Apr 02 2010 Thierry Parmentelat - NodeManager-2.0-4 - protect against nodes in migrated PLC's not having the hrn tag yet @@ -240,5 +405,3 @@ rm -rf $RPM_BUILD_ROOT * Mon Nov 13 2006 Mark Huang - - Initial build. - -%define module_current_branch 1.8