[Ocfs2-tools-devel] [PATCH 4/4] Ocfs2-test: port remote_mount.py and remout_umount.py to openmpi
Marcos E. Matsunaga
Marcos.Matsunaga at oracle.com
Thu Sep 11 06:40:21 PDT 2008
Does OpenMPI allows you to run jobs as root? I think it is too dangerous
to run any tests (other than the tools for now) as root.
Other than that, looks good (make the name changes based on 3/4 patch
comments).
Regards,
Marcos Eduardo Matsunaga
Oracle USA
Linux Engineering
“The statements and opinions expressed here are my own and do not
necessarily represent those of Oracle Corporation.”
Tristan Ye wrote:
> Just a example to port a mpi binary launcher from lampi to openmpi
>
> Signed-off-by: Tristan Ye <tristan.ye at oracle.com>
> ---
> programs/python_common/remote_mount.py | 18 ++++++++++--------
> programs/python_common/remote_umount.py | 18 ++++++++++--------
> 2 files changed, 20 insertions(+), 16 deletions(-)
>
> diff --git a/programs/python_common/remote_mount.py b/programs/python_common/remote_mount.py
> index f0ee6b6..39b9ba2 100755
> --- a/programs/python_common/remote_mount.py
> +++ b/programs/python_common/remote_mount.py
> @@ -39,10 +39,10 @@ Usage = 'Usage: %prog [-l|-label label] \
> [-m|--mountpoint mountpoint] \
> [-n|--nodes nodelist]'
> #
> -if userid == 'root':
> - o2tf.printlog('This program uses LAM/MPI. Should not run as root',
> - logfile, 0, '')
> - sys.exit(1)
> +#if userid == 'root':
> +# o2tf.printlog('This program uses LAM/MPI. Should not run as root',
> +# logfile, 0, '')
> +# sys.exit(1)
> if __name__=='__main__':
> parser = optparse.OptionParser(Usage)
> #
> @@ -96,10 +96,12 @@ command = str('%s -l %s -m %s' % (buildcmd,
> options.label,
> options.mountpoint))
> #
> -o2tf.StartMPI(DEBUGON, options.nodelist, logfile)
> +#o2tf.StartMPI(DEBUGON, options.nodelist, logfile)
> +o2tf.StartOpenMPI(DEBUGON, options.nodelist, logfile)
> #
> #
> -o2tf.lamexec(DEBUGON, nproc, config.WAIT, str('%s' % command),
> - options.nodelist,
> - logfile )
> +#o2tf.lamexec(DEBUGON, nproc, config.WAIT, str('%s' % command),
> +# options.nodelist,
> +# logfile )
> +o2tf.openmpi_run(DEBUGON, nproc, str('%s' % command), options.nodelist, 'ssh', logfile)
>
> diff --git a/programs/python_common/remote_umount.py b/programs/python_common/remote_umount.py
> index 1fd36e7..4d7b809 100755
> --- a/programs/python_common/remote_umount.py
> +++ b/programs/python_common/remote_umount.py
> @@ -38,10 +38,10 @@ logfile = config.LOGFILE
> Usage = 'Usage: %prog [-m|--mountpoint mountpoint] \
> [-n|--nodes nodelist]'
> #
> -if userid == 'root':
> - o2tf.printlog('This program uses LAM/MPI. Should not run as root',
> - logfile, 0, '')
> - sys.exit(1)
> +#if userid == 'root':
> +# o2tf.printlog('This program uses LAM/MPI. Should not run as root',
> +# logfile, 0, '')
> +# sys.exit(1)
> if __name__=='__main__':
> parser = optparse.OptionParser(Usage)
> #
> @@ -86,10 +86,12 @@ else:
> command = str('%s -m %s' % (buildcmd,
> options.mountpoint))
> #
> -o2tf.StartMPI(DEBUGON, options.nodelist, logfile)
> +#o2tf.StartMPI(DEBUGON, options.nodelist, logfile)
> +o2tf.StartOpenMPI(DEBUGON, options.nodelist, logfile)
> #
> #
> -o2tf.lamexec(DEBUGON, nproc, config.WAIT, str('%s' % command),
> - options.nodelist,
> - logfile )
> +#o2tf.lamexec(DEBUGON, nproc, config.WAIT, str('%s' % command),
> +# options.nodelist,
> +# logfile )
> +o2tf.openmpi_run(DEBUGON, nproc, str('%s' % command), options.nodelist, 'ssh', logfile)
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://oss.oracle.com/pipermail/ocfs2-tools-devel/attachments/20080911/c250e619/attachment.html
More information about the Ocfs2-tools-devel
mailing list