source: tags/4.0.1/CHANGES @ 324

Last change on this file since 324 was 231, checked in by bas, 14 years ago

New version 4.0.1 with a small fix, see #19

  • Property svn:keywords set to Id
File size: 16.4 KB
Line 
1=========== 4.0.1
2  * Fixed a bug in setting the right library path  for compiling.
3    Reported by: Chad Vizino ( vizino add psc dot edu )
4    Author: Bas van der Vlies
5   
6=========== 4.0.0
7  * pbs.py added some new functions for 2.4 version:
8    - pbs_fbserver(void);
9    - pbs_get_server_list(void);
10    - pbs_sigjobasync(int connect, char *job_id, char *signal, char *extend);
11    - pbs_alterjob_async(int connect, char *job_id, struct attrl *ATTRL, char *extend);
12    - pbs_checkpointjob(int connect, char *job_id, char *extend);
13    - log_ext(int,char *,char *,int);
14    - log_init(char *, char *);
15    - log_remove_old(char *,unsigned long);
16
17    Note: version 2.1.X is still supported
18
19  * autotools environment
20    - Added support for finding pbs-config (borrowed for mpiexec source)
21    - Detecting which version of torque is installed
22    - only support installations that have pbs-config installed.
23    - Removed old code for installations that do not a have pbs-config
24      installed.
25
26  * PBSQuery.py
27    - There was a bug in the new data interface (Resource_List for jobs)
28      Reported & Patch by: Mark Roberts ( mark at gingergeeks dot co dot uk)
29      Applied by with some minor changes: Bas van der Vlies
30
31    - The new data structure is the default. You can switch back to the old
32      one with:
33            p = PBSQuery()
34            p.old_data_structure()
35
36      Author: Bas van der Vlies
37
38   * examples/ha_server.py
39     An example how to use the High Availabilty torque functions
40     Author: Bas van der Vlies & Mark Roberts ( mark at gingergeeks dot co dot uk )
41
42=========== 3.6.0
43  * pbs, new generated pbs_wrap.c, pbs.py fixes a bug in pbs_runjob()
44    Reported by: Dennis Stam
45    Fixed by: Bas van der Vlies
46
47=========== 3.5.0
48  * PBSQuery
49        The class functions of node, job and queue support old and new data
50        structure.
51
52        Changed the behaviour of the new data stucture, We can use it as
53        dictionary and as class attribute, this is equivalent, eg:
54          - print node['np'] and print node.np
55
56        for a node we parse the 'status' line and split on '=' char, You now can
57        use these statements, eg
58          - print node.status.arch     (node['status'].arch or node['status']['arch'])
59          - print node.status.nsession
60
61        for a job we parse the 'Variable_List' line and split on '=' char, You now can
62        use the statements, eg:
63          - print job.Variable_List.PBS_O_WORKDIR
64          - print job.Variable_List.PBS_O_HOME
65
66        For more info see examples/new_interface.py
67
68    Author: Bas van der Vlies
69
70 * new_rack_pbsmon.py
71        Rewrite to new data structure and automatically determine how many nodes
72        and racks cluster has and skip printing of empty racks (default), use -w/--wide
73        for old behaviour.
74
75   Author: Bas van der Vlies
76
77
78=========== 3.2.0
79        - PBSQuery:
80          New data structure. In the old structure it is a dictionary
81          with a value and the value is a string. This is changed
82          that dictionary values are now of type list or dictionary depends
83          on the value of the keyword, eg for a node:
84            - np = 2:
85              * node['np'] = [ '2' ] 
86
87            - properties = cores2, mem4gb, parallel
88              * node['properties'] = [ 'cores2', 'mem4gb', 'parallel' ]
89
90            - status = arch=x86_64,sessions=22599,,size=70627864kb, ...
91              * node['status']['arch'] = [ 'x86_64' ]
92              * node['status']['sessions'] = [ '222599' ]
93              * ...
94
95         The data structure is activated by the function:
96          * new_data_structure()
97
98        In a future release it will be come the default.
99        example:
100                p = PBSQuery()
101                p.new_data_structure()
102
103                nodes = p.getnodes()
104                print nodes.np, nodes['np']
105
106        Author: Bas van der Vlies
107
108        - PBSQuery
109          For old and new data structure we now can use another syntax:
110           * node['np'] and node.np are equivalent
111
112          This new syntax works for all keywords.
113
114        Author: Bas van der Vlies
115
116        - Added iter object for job, node, queue and server objects, eg:
117          node = p.getnode('gb-r1n1')
118          print node.name
119          for attrib in node:
120                print '%\t%s = %s' %(attrib, node[attrib])
121        Author: Bas van der Vlies
122
123        - fixed an error in getnode, getqueue and getjob, return empty
124          dictionary if not found
125        Author: Bas van der Vlies
126       
127        - New build system for rpm packages, make -f Makefile.rpm
128          Author: Michel Jouvin <jouvin add lal dot in2p3 dot fr>
129
130        Applied: Bas van der Vlies
131
132=========== 3.0.1
133        - PBSQuery
134                * Removed a testing code line
135                Reported By: sam @ vpac dot org
136                Fixed by: Bas van der Vlies
137
138=========== 3.0.0
139        - PBSQuery
140                * Cleaned up some old lines of code which didn't do anything.
141                * Changed the returnvalue of getqueue, getnode and getjob. Now
142                  they return an instance of the object, instead of a dict.
143                  This is API change so we bumped the version to 3.0.0
144                * Now the getnode-function accepts the short name as well as
145                  the long name as an argument.
146
147                Author: Sil Westerveld <Sil.Westerveld@sara.nl>
148
149        - pbs.py, _pbs.so, PBSQuery.py
150                * Fixed a memory leak when used in daemon mode
151                Author: Bas van der Vlies <basv@sara.nl>
152
153=========== 2.9.8
154        - pbs_python.spec file patch added libdir and python defines so it
155          will build for RHEL5.1/CentOS 5.1
156          by        : Michael Sternberg <sternberg add anl dot gov>
157          applied by: Bas van der Vlies
158
159        - Updated the header files for pbs_python. So it can use some new
160          defines variables/defines, eg:
161                * ATTR_NODE_status
162                * ATTR_NODE_note
163                * ...
164          Added by: Dennis Stam <dennis.stam@sara.nl>, Bas van der Vlies
165
166        - Two new functions to log.h:
167                log_roll(int size);
168                log_size(void);
169          Added by: Bas van der Vlies
170
171        - We now have proper destructors (free memory) in SWIG for attrl and
172          attropl attributes.
173          Added by: Bas van der Vlies
174
175        - PBSQuery
176                * Added getnodes_with_property() function. This will get all nodes with
177                  a certain property, eg:
178                   - get all nodes with property 'cores8' and return all attributes:
179                      getnodes_with_property('cores8')
180               
181                   - get all nodes with property 'cores2' and only return the
182                     attributes 'state' and 'properties':
183                      attrl = [ 'state', 'properties' ]
184                      getnodes_with_property('cores2', attrl)
185               
186                     Only for torque version > 2.1.0
187             
188                Added by: Bas van der Vlies
189
190                * Added to class node the function
191                 - get_jobs(self, unique=None)
192                   Returns a list of the currently running job-id('s) on the node.
193                Added by: Sil Westerveld <Sil.Westerveld@sara.nl>
194
195                * Added get_server_name() function.
196                  This will return the PBS-server's name.
197                Added by: Sil Westerveld <Sil.Westerveld@sara.nl>
198
199                * Added to class _PBSobject the function
200                  - uniq(self, list)
201                    Filters out unique items of a list.
202                Added by: Sil Westerveld <Sil.Westerveld@sara.nl>
203
204                * Added to class job the function
205                  - get_nodes(self, unique=None)
206                    Returns a list of the nodes which run the job.
207                Added by: Sil Westerveld <Sil.Westerveld@sara.nl>
208
209=========== Version 2.9.4
210        -  Function pbs.pbs_geterrmsg does not exits any more is
211           replaced by pbs.error():
212                errno, text = pbs.error()
213                print errno, text
214           Reported by: pk at q-leap dot com
215           Fixed by   : Bas van der Vlies
216
217        - PBSQuery.py
218           * Added get_version() for server class, returns the version of
219             the batch server
220             Added by    : Bas van der Vlies
221
222           * Added get_nodes() for job class, returns a list of nodes on
223             which the job is run
224             Added by    : Bas van der Vlies
225
226           * PBSQuery.py rewrite make use of UserDict module.
227             Suggested by: Ramon Bastiaans
228             Fixed by    : Bas van der Vlies
229
230=========== Version 2.9.2
231        - The function pbs_rescquery() did not work. Fixed it
232        - The function avail(), did not work fixed it
233        - The functions pbs_rescreserve and pbs_rescrelease did not work
234          fixed it
235
236        - Fixed a bug in new_rack_pbsmon.py. Counting of serial
237          nodes was wrong and state down has topmost priority
238
239=========== Version 2.9.0
240        - Added support for new torque build system 2.1.0
241        - Added new_rack_pbsmon.py
242          Authors: Walter de Jong & Bas van der Vlies
243
244=========== Version 2.8.2
245
246Configure has a new option:
247        --with-pbsdir=PATH
248
249If set it will use PATH specified as argument to
250find the pbs/torque libraries. If unset it will use
251some useful defaults to find the libaries.
252Suggested by: Troy Baer
253
254PBSQuery.py:
255        - If we can not make a connection with the server
256          then raise an exception and let the programmer
257          decides what to do.
258
259pbs_python.spec:
260        - It can now handle mode bits
261          Author: Martin Pels from SARA
262       
263=========== Version 2.8.0
264
265setup.py:
266        - Added /usr/lib to PBS_LIB_DIR
267
268pbs.py:
269        - Added new function "pbs.error()". This function checks if
270          an error has occured with a pbs function, eg:
271            task_id = pbs.pbs_submit(c, attrl, "A.tsk", 'NULL', 'NULL')
272            error_number, err_txt = pbs.error()
273            if error_number:
274                print error_number, err_txt
275
276          prints the following message if script A.tsk does not exists:
277            15042 (qsub) cannot access script file
278
279pbs_python.spec:
280        - to make rpm packages from the source package, initial version
281        Author: Martin Pels from SARA
282
283README:
284        - Now requires python 2.1 and higher
285        - Explain how to build DEBIAN package
286
287=========== Version 2.7.10
288
289PBSQuery.py:
290        Fixed an error. You always got all resources from eg nodes
291        even when you supplied an attribute list where you only
292        requested the 'state' of the node.
293
294        Updated the inline python documentation
295
296=========== Version 2.7.9
297
298Fixed an error the previous version was in DEBUG mode. So
299you get an lot undesired output on the screen.
300
301debian package now also generated a package with the write
302version info.
303
304=========== Version 2.7.8
305
306Setup.py:
307        Can also handle ROCKS installations + the version
308        info is now the same as pbs.py
309        Thanks to: Roy Dragseth
310
311=========== Version 2.7.7
312
313PBSQuery module:
314  It can now be used in daemon programs. The pbs_server closes
315  the connection after an certain amount of time. This is fixed,
316  before every query there is an new connection and if the query
317  is finished the connection is closed.
318 
319=========== Version 2.7.6
320
321Now setup.py can also handle old Oscar Installations.
322Thanks To: Robin Humble
323
324Fixed an print statement fix in new_interface.py:
325Thanks To: Robin Humble
326
327Made some improvements for PBSQuery module:
328        - Updated the documentation
329        - Added the has_key() function to all
330          PBSObjects. So that the behaviour is similar to
331          an dictionary
332          Suggested By: Ramon Bastiaans
333       
334=========== Version 2.7.5
335 Added PBSQuery module.  This module requires pbs.py and it a simple module
336 for querying the pbs server. The documentation is in the module. Use for
337 example ipython to read it.
338
339 Written By: Roy Dragseth
340             Bas van der Vlies
341
342 eg: ( see also examples/new_interface.py)
343
344 from PBSQuery import PBSQuery
345 p = PBSQuery()
346
347 jobs = p.getjobs()
348 for name, job in jobs.items()
349        print job
350
351=========== Version 2.7.4
352 New versions fixes an bug in function pbs.pbs_statnode().
353 Reported by: Keith Poirier
354
355 Configure support:
356 Contributed By: Yaroslav Halchenko
357
358 Debian package support:
359 Contributed By: Yaroslav Halchenko
360
361 Added Support for Debuging the interface, You must edit pbs_wrap.c
362 and search for SARA_DEBUG:
363        #define SARA_DEBUG 1
364 Implemented by: Ramon Bastiaans
365
366 examples/pbsmon.py:
367        - Fixed an error when regex fails to determine node number,
368          no status was displayed
369        - It will now display and 'j' if the node is free for the batch
370          system and a job runs on the node (SMP-systems).
371 Changed by: Bas van der Vlies
372
373 examples/rack_pbsmon.py:
374        - An pbsmon that display node info per rack
375        - Edit the rack_pbsmon.py to adjust the values. It requires
376          that hostname contains rack and node id's,
377          eg: gb-r<number>n<number>
378 Contributed by: Walter de Jong
379
380=========== Version 2.7.3
381 The name SPBS is changed to the new name TORQUE (Tera-scale Open-source
382 Resource and QUEing manager).
383
384 The interface support OPENPBS and TORQUE.
385
386=========== Version 2.7.2
387 Some minor changes to include files. Now the Scalable PBS keywords
388 are also supported ( server attribute names: node_ping_rate and
389 node_check_rate). This does not interfere with the openpbs software.
390
391 pbsmon.py could not handle an one node cluster. Fixed it.
392
393=========== Version 2.7
394 Forgot to wrap the pbs_statfree() function. So we could not free
395 allocated memory from functions that return 'struct batch_status *'
396 like pbs_statjob().
397
398 pbsmon.py can now handle 2 and 3 digit hostnames. Patch supplied by
399 Daniel Olson
400
401=========== Version 2.6.1
402 Setup.py now checks if all openpbs libraries are installed to compile the
403 package.
404
405=========== Version 2.6
406
407 Fixed a bug in the pbs python module. Forgot to map the pbs_statjob()
408 function. This bug prevented to pass 'struct attrl' variables to this
409 function. Thanks to Evelyn Shiu for reporting this bug.
410
411
412=========== Version 2.5
413 Added the OpenPbs logging functions (log.h and liblog.a). There
414 is an example in the examples directory: logpbs.py
415
416 Fixed a bug in examples/resmom_info.py used the default port for
417 pbs_resmon if getservbyname fails.
418
419 Fixed a bug in resmom code. If the user has no permissions to query
420 the pbs_mom daemon a empty string is returned. Now we check for
421 the empty string. So we do not get a python exception.
422
423 Fixed a bug in setup.py forgot the exit statement when we did not
424 find the pbs libraries.
425
426=========== Version 2.3
427 Bugfix in the pbsnodes-a.py. Forgot to import the sys module.
428
429 Removed some obsolete code.
430
431 As for now we make use of the distutils module. So the package
432 is automatically compiled and installed in proper directories, usage:
433    python setup.py install
434 This requires that the package 'distutils' must be installed. As for
435 version 1.6 and higher it is in the distribution.
436
437 Added a function that prints the pbs python interface version. So we
438 can check if we have the right interface version:
439 import pbs
440 print pbs.version()
441 
442
443=========== Version 2.2
444
445In this release we can query the pbs_mom daemon with the aid of
446resource management functions:
447   pbs.openrm()
448   pbs.closerm()
449   pbs.downrm()
450   pbs.configrm()
451   pbs.addreq()
452   pbs.allreq()
453   pbs.flushreq()
454   pbs.activereq()
455   pbs.fullresp()
456   pbs.getreq()
457
458There is also a python function:
459   pbs.get_mom_values(id, [list]):
460     id   - connection id of pbs.openrm(node-name, port-number)
461     list - Is a optional paramter. A list of resource keywords
462
463   If 'list' is not supplied then this function will get the values
464   for the standard resource keywords, eg uname, loadave, .. + 'arch'
465   depended keywords. The arch feature is only implemented for linux,
466   but it can easily be ported to other oses.
467
468   if 'list' is supplied then we only fetch values for the keywords
469   that are in the list.
470
471   The function returns a dictonary. The keys are the resource keywords.
472
473   See 'resmom_info.py' for a example of this new feature.
474
475=========== Version 2.0
476
477The previous version was a simple interface above the PBS C API LIB.  This
478interface has gone a major changes. The most noticeable change is  that
479the functions accept/return Python lists instead of C-lists.  So you can now
480use standard Python syntax for manipulating Python lists. If you are familar
481with the Python syntax then you will appreciate this new interface.
482
483NOTE:
484  This interface is NOT compatible with the old one
485
486Here are some guidelines to convert your code to the new one:
487
488The constructors for the struct has gone a major change:
489  old code:
490    temp = pbs.new_attrl();
491    attrl_p = pbs.attrlPtr(temp)
492    attrl_p.name = 'state'
493
494  new_code:
495     attr_l = pbs.new_attrl(1)   // Creates a list of attrl structs length 1
496     attr_l[0].name = 'state'
497
498
499The pbs_stat functions returns Python lists instead of C-lists. There is
500NO next field anymore:
501  old_code:
502    temp = pbs.new_attrl();
503    attrl_p = pbs.attrlPtr(temp)
504    attrl_p.this = 'NULL'
505
506    nodes = pbs.pbs_statnode(con, "", attrl_p, "NULL")
507
508    while nodes.this != 'NULL':
509      print nodes.name
510
511      node_attrl = nodes.attribs
512      while node_attrl.this != 'NULL':
513        print '\t', node_attrl.name, '=', node_attrl.value
514        node_attrl = node_attrl.next
515
516    nodes = nodes.next
517
518
519  new_code:
520    nodes = pbs.pbs_statnode(con, "", "NULL", "NULL")
521    for node in nodes:
522      print node.name
523      for attrib in node.attribs:
524        print '\t', attrib.name, '=', attrib.value
525
526Another advantage is you can use the print statement to show the
527connect of attrl and attropl classes:
528   attr_l = pbs.new_attrl(2)
529   attr_l[0].name = 'bas'
530   attr_l[0].value = 'van der Vlies'
531
532   print  attr_l[0]
533   >> (bas,,van der Vlies)
534   
535I hope these examples illustrate the changes. If you specify a wrong type
536for a function then function wil raise a Python exception.
Note: See TracBrowser for help on using the repository browser.