Skip to content
Snippets Groups Projects
Commit 3911043c authored by Luc Papeleux's avatar Luc Papeleux
Browse files

configuration mumps stations

correction des commandes rsync de parametricJob (synchronisation disques noeuds/master)
parent 29943a24
No related branches found
No related tags found
No related merge requests found
# $id$
#
# configuration to allow CMake to automatically find mumps
#
LIB=$LIB:/opt/mumps-4.10.0/lib
export LIB
INCLUDE=$INCLUDE:/opt/mumps-4.10.0/include
export INCLUDE
# not necessary while cmake link with absolute path to libs
#LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/mumps-4.10.0/lib
#export LD_LIBRARY_PATH
# $id$
#
# configuration to allow CMake to automatically find mumps
#
LIB=$LIB:/opt/mumps-4.10.0/lib
export LIB
INCLUDE=$INCLUDE:/opt/mumps-4.10.0/include
export INCLUDE
# not necessary while cmake link with absolute path to libs
#LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/mumps-4.10.0/lib
#export LD_LIBRARY_PATH
# $id$
#
# configuration to allow CMake to automatically find mumps
#
LIB=$LIB:/opt/mumps-4.10.0/lib
export LIB
INCLUDE=$INCLUDE:/opt/mumps-4.10.0/include
export INCLUDE
# not necessary while cmake link with absolute path to libs
#LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/mumps-4.10.0/lib
#export LD_LIBRARY_PATH
# $id$
#
# configuration to allow CMake to automatically find mumps
#
LIB=$LIB:/opt/mumps-4.10.0/lib
export LIB
INCLUDE=$INCLUDE:/opt/mumps-4.10.0/include
export INCLUDE
# not necessary while cmake link with absolute path to libs
#LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/mumps-4.10.0/lib
#export LD_LIBRARY_PATH
......@@ -303,7 +303,8 @@ class ParametricJob(PRMSet):
file.write("import subprocess, sys\n")
file.write("print 'Copying data from %s local disk started ...'\n"%(nodeHost))
#cpCmd = 'ssh %s \"cp -pRvu %s %s\"' % (nodeHost, localWSpace, homeDir)
file.write("cpCmd = 'rsync -e ssh -abvz --delete-after %s:%s %s'" % (nodeHost, localWSpace, homeDir))
#file.write("cpCmd = 'rsync -e ssh -avz --delete-after %s:%s %s'" % (nodeHost, localWSpace, homeDir)) # --delete-after supprime les fichiers de la cible (homeDir) ne se trouvant pas dans la source (localNodeDir) aprs le transfert
file.write("cpCmd = 'rsync -e ssh -avz %s:%s %s'\n" % (nodeHost, localWSpace, homeDir))
file.write("outCp = subprocess.call(cpCmd, shell=True)\n")
file.write("if outCp == 0 :\n")
file.write("\tprint 'Copy of data from %s local disk successfully done'\n"%(nodeHost))
......@@ -382,7 +383,8 @@ class ParametricJob(PRMSet):
try: # -R : recursif / p : preserve attribut (owner/mode/timestamp) / u : update (copy only if source is newer than target)/ v : verbose
##cmd1 = "cp -Rpuv %s/* %s"%(localNodeDir, homeDir)
#cmd1 = "cp -Rpu %s/* %s"%(localNodeDir, homeDir)
cmd1 = "rsync -abvz --delete-after %s %s"%(localNodeDir, homeDir)
#cmd1 = "rsync -avz --delete-after %s/* %s"%(localNodeDir, homeDir) # --delete-after supprime les fichiers de la cible (homeDir) ne se trouvant pas dans la source (localNodeDir) aprs le transfert
cmd1 = "rsync -avz %s/* %s"%(localNodeDir, homeDir)
#--remove-source-files permet de nettoyer la source, mais ca risque de poser problme avec le check ci dessous
# qui plus est, ne supprime pas l'arborescence, juste les fichiers => nettoyage incomplet
print "cmd1 = ", cmd1
......@@ -528,7 +530,7 @@ def recCmp(cmp):
def rmCommonFiles(cmp):
#print "cmp.left = ", cmp.left
for subDir in cmp.subdirs :
for subdir in cmp.subdirs :
os.chdir(subdir)
subDirCmp = cmp.subdirs[subdir]
rmCommonFiles(subDirCmp) # recursive function
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment