[padb] r324 committed - Minor tweaks to get mpirun_get_jobs running on solaris, the --all...

padb at googlecode.com padb at googlecode.com
Thu Nov 5 22:29:13 GMT 2009


Revision: 324
Author: apittman
Date: Thu Nov  5 14:28:07 2009
Log: Minor tweaks to get mpirun_get_jobs running on solaris, the --all
option now works as expected.

http://code.google.com/p/padb/source/detail?r=324

Modified:
  /trunk/src/padb

=======================================
--- /trunk/src/padb	Thu Nov  5 14:13:38 2009
+++ /trunk/src/padb	Thu Nov  5 14:28:07 2009
@@ -2770,12 +2770,27 @@
      map { $mpirun{$_}++ } split $COMMA, $conf{mpirun};

      foreach my $pid ( get_process_list($user) ) {
+
+        if ($running_on_solaris) {
+            my $slink = readlink "/proc/$pid/path/a.out";
+            if ( defined $slink ) {
+                if ( defined $mpirun{ basename($slink) } ) {
+                    push @jobs, $pid;
+                }
+            }
+            next;
+        }
+
+        # This test does work on solaris but as it reports a full path
+        # rather than just the basename it'll never pass.  It also
+        # takes a long time to run so skip it.
          my $name = find_from_status( $pid, 'Name' );
          if ( defined $name and defined $mpirun{$name} ) {
              push @jobs, $pid;
              next;
          }

+        # Linux only.
          my $link = readlink "/proc/$pid/exe";
          next unless defined $link;
          if ( defined $mpirun{ basename($link) } ) {




More information about the padb-devel mailing list