2 Commits

Author SHA1 Message Date
(no author) b4374aaca1 This commit was manufactured by cvs2svn to create tag 'start'.
git-svn-id: svn://opensvn.adaptivecomputing.com/maui/tags/start@5 3f5042e3-fb1d-0410-be18-d6ca2573e517
2005-07-12 21:12:54 +00:00
(no author) 817d8bad25 This commit was manufactured by cvs2svn to create branch 'CRI'.
git-svn-id: svn://opensvn.adaptivecomputing.com/maui/branches/CRI@3 3f5042e3-fb1d-0410-be18-d6ca2573e517
2005-07-12 21:12:53 +00:00
77 changed files with 1528 additions and 3755 deletions
-595
View File
@@ -1,595 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<?fileVersion 4.0.0?>
<cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
<storageModule moduleId="org.eclipse.cdt.core.settings">
<cconfiguration id="cdt.managedbuild.config.gnu.exe.debug.299556713">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="cdt.managedbuild.config.gnu.exe.debug.299556713" moduleId="org.eclipse.cdt.core.settings" name="Debug">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.debug,org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="" id="cdt.managedbuild.config.gnu.exe.debug.299556713" name="Debug" parent="cdt.managedbuild.config.gnu.exe.debug">
<folderInfo id="cdt.managedbuild.config.gnu.exe.debug.299556713." name="/" resourcePath="">
<toolChain id="cdt.managedbuild.toolchain.gnu.exe.debug.401029269" name="Linux GCC" superClass="cdt.managedbuild.toolchain.gnu.exe.debug">
<targetPlatform id="cdt.managedbuild.target.gnu.platform.exe.debug.594361211" name="Debug Platform" superClass="cdt.managedbuild.target.gnu.platform.exe.debug"/>
<builder buildPath="${workspace_loc:/maui/Debug}" id="cdt.managedbuild.target.gnu.builder.exe.debug.382827758" managedBuildOn="true" name="Gnu Make Builder.Debug" superClass="cdt.managedbuild.target.gnu.builder.exe.debug"/>
<tool id="cdt.managedbuild.tool.gnu.archiver.base.564221972" name="GCC Archiver" superClass="cdt.managedbuild.tool.gnu.archiver.base"/>
<tool id="cdt.managedbuild.tool.gnu.cpp.compiler.exe.debug.458789041" name="GCC C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.exe.debug">
<option id="gnu.cpp.compiler.exe.debug.option.optimization.level.1578234847" superClass="gnu.cpp.compiler.exe.debug.option.optimization.level" value="gnu.cpp.compiler.optimization.level.none" valueType="enumerated"/>
<option id="gnu.cpp.compiler.exe.debug.option.debugging.level.118082022" superClass="gnu.cpp.compiler.exe.debug.option.debugging.level" value="gnu.cpp.compiler.debugging.level.max" valueType="enumerated"/>
</tool>
<tool id="cdt.managedbuild.tool.gnu.c.compiler.exe.debug.1944655974" name="GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler.exe.debug">
<option defaultValue="gnu.c.optimization.level.none" id="gnu.c.compiler.exe.debug.option.optimization.level.35492209" superClass="gnu.c.compiler.exe.debug.option.optimization.level" valueType="enumerated"/>
<option id="gnu.c.compiler.exe.debug.option.debugging.level.892007709" superClass="gnu.c.compiler.exe.debug.option.debugging.level" value="gnu.c.debugging.level.max" valueType="enumerated"/>
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.1111724644" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
</tool>
<tool id="cdt.managedbuild.tool.gnu.c.linker.exe.debug.1772104617" name="GCC C Linker" superClass="cdt.managedbuild.tool.gnu.c.linker.exe.debug">
<inputType id="cdt.managedbuild.tool.gnu.c.linker.input.1866769425" superClass="cdt.managedbuild.tool.gnu.c.linker.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool id="cdt.managedbuild.tool.gnu.cpp.linker.exe.debug.1962554265" name="GCC C++ Linker" superClass="cdt.managedbuild.tool.gnu.cpp.linker.exe.debug"/>
<tool id="cdt.managedbuild.tool.gnu.assembler.exe.debug.1435208245" name="GCC Assembler" superClass="cdt.managedbuild.tool.gnu.assembler.exe.debug">
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.605460294" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
</tool>
</toolChain>
</folderInfo>
</configuration>
</storageModule>
<storageModule moduleId="scannerConfiguration">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerFileProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="makefileGenerator">
<runAction arguments="-E -P -v -dD" command="" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.cpp" command="g++" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.c" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/${specs_file}&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'g++ -E -P -v -dD &quot;${plugin_state_location}/specs.cpp&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/specs.c&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.release.1054591848;cdt.managedbuild.config.gnu.exe.release.1054591848.;cdt.managedbuild.tool.gnu.c.compiler.exe.release.1897461423;cdt.managedbuild.tool.gnu.c.compiler.input.1306211526">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileC"/>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerFileProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="makefileGenerator">
<runAction arguments="-E -P -v -dD" command="" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.cpp" command="g++" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.c" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/${specs_file}&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'g++ -E -P -v -dD &quot;${plugin_state_location}/specs.cpp&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/specs.c&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.debug.299556713;cdt.managedbuild.config.gnu.exe.debug.299556713.;cdt.managedbuild.tool.gnu.c.compiler.exe.debug.1944655974;cdt.managedbuild.tool.gnu.c.compiler.input.1111724644">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileC"/>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerFileProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="makefileGenerator">
<runAction arguments="-E -P -v -dD" command="" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.cpp" command="g++" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.c" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/${specs_file}&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'g++ -E -P -v -dD &quot;${plugin_state_location}/specs.cpp&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/specs.c&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
</scannerConfigBuildInfo>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
</cconfiguration>
<cconfiguration id="cdt.managedbuild.config.gnu.exe.release.1054591848">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="cdt.managedbuild.config.gnu.exe.release.1054591848" moduleId="org.eclipse.cdt.core.settings" name="Release">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.release,org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="" id="cdt.managedbuild.config.gnu.exe.release.1054591848" name="Release" parent="cdt.managedbuild.config.gnu.exe.release">
<folderInfo id="cdt.managedbuild.config.gnu.exe.release.1054591848." name="/" resourcePath="">
<toolChain id="cdt.managedbuild.toolchain.gnu.exe.release.1641667346" name="Linux GCC" superClass="cdt.managedbuild.toolchain.gnu.exe.release">
<targetPlatform id="cdt.managedbuild.target.gnu.platform.exe.release.336649030" name="Debug Platform" superClass="cdt.managedbuild.target.gnu.platform.exe.release"/>
<builder buildPath="${workspace_loc:/maui/Release}" id="cdt.managedbuild.target.gnu.builder.exe.release.1564745497" managedBuildOn="true" name="Gnu Make Builder.Release" superClass="cdt.managedbuild.target.gnu.builder.exe.release"/>
<tool id="cdt.managedbuild.tool.gnu.archiver.base.1438565122" name="GCC Archiver" superClass="cdt.managedbuild.tool.gnu.archiver.base"/>
<tool id="cdt.managedbuild.tool.gnu.cpp.compiler.exe.release.4256546" name="GCC C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.exe.release">
<option id="gnu.cpp.compiler.exe.release.option.optimization.level.400350956" superClass="gnu.cpp.compiler.exe.release.option.optimization.level" value="gnu.cpp.compiler.optimization.level.most" valueType="enumerated"/>
<option id="gnu.cpp.compiler.exe.release.option.debugging.level.1306933396" superClass="gnu.cpp.compiler.exe.release.option.debugging.level" value="gnu.cpp.compiler.debugging.level.none" valueType="enumerated"/>
</tool>
<tool id="cdt.managedbuild.tool.gnu.c.compiler.exe.release.1897461423" name="GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler.exe.release">
<option defaultValue="gnu.c.optimization.level.most" id="gnu.c.compiler.exe.release.option.optimization.level.1290695235" superClass="gnu.c.compiler.exe.release.option.optimization.level" valueType="enumerated"/>
<option id="gnu.c.compiler.exe.release.option.debugging.level.1600799370" superClass="gnu.c.compiler.exe.release.option.debugging.level" value="gnu.c.debugging.level.none" valueType="enumerated"/>
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.1306211526" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
</tool>
<tool id="cdt.managedbuild.tool.gnu.c.linker.exe.release.938481580" name="GCC C Linker" superClass="cdt.managedbuild.tool.gnu.c.linker.exe.release">
<inputType id="cdt.managedbuild.tool.gnu.c.linker.input.302149400" superClass="cdt.managedbuild.tool.gnu.c.linker.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool id="cdt.managedbuild.tool.gnu.cpp.linker.exe.release.25141800" name="GCC C++ Linker" superClass="cdt.managedbuild.tool.gnu.cpp.linker.exe.release"/>
<tool id="cdt.managedbuild.tool.gnu.assembler.exe.release.247380559" name="GCC Assembler" superClass="cdt.managedbuild.tool.gnu.assembler.exe.release">
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.2057443732" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
</tool>
</toolChain>
</folderInfo>
</configuration>
</storageModule>
<storageModule moduleId="scannerConfiguration">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerFileProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="makefileGenerator">
<runAction arguments="-E -P -v -dD" command="" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.cpp" command="g++" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.c" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/${specs_file}&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'g++ -E -P -v -dD &quot;${plugin_state_location}/specs.cpp&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/specs.c&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.release.1054591848;cdt.managedbuild.config.gnu.exe.release.1054591848.;cdt.managedbuild.tool.gnu.c.compiler.exe.release.1897461423;cdt.managedbuild.tool.gnu.c.compiler.input.1306211526">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileC"/>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerFileProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="makefileGenerator">
<runAction arguments="-E -P -v -dD" command="" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.cpp" command="g++" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.c" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/${specs_file}&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'g++ -E -P -v -dD &quot;${plugin_state_location}/specs.cpp&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/specs.c&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.debug.299556713;cdt.managedbuild.config.gnu.exe.debug.299556713.;cdt.managedbuild.tool.gnu.c.compiler.exe.debug.1944655974;cdt.managedbuild.tool.gnu.c.compiler.input.1111724644">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileC"/>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerFileProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="makefileGenerator">
<runAction arguments="-E -P -v -dD" command="" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.cpp" command="g++" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-E -P -v -dD ${plugin_state_location}/specs.c" command="gcc" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfile">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/${specs_file}&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileCPP">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'g++ -E -P -v -dD &quot;${plugin_state_location}/specs.cpp&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfileC">
<buildOutputProvider>
<openAction enabled="true" filePath=""/>
<parser enabled="true"/>
</buildOutputProvider>
<scannerInfoProvider id="specsFile">
<runAction arguments="-c 'gcc -E -P -v -dD &quot;${plugin_state_location}/specs.c&quot;'" command="sh" useDefault="true"/>
<parser enabled="true"/>
</scannerInfoProvider>
</profile>
</scannerConfigBuildInfo>
</storageModule>
</cconfiguration>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<project id="maui.cdt.managedbuild.target.gnu.exe.387611182" name="Executable" projectType="cdt.managedbuild.target.gnu.exe"/>
</storageModule>
</cproject>
-82
View File
@@ -1,82 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>maui</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
<triggers>clean,full,incremental,</triggers>
<arguments>
<dictionary>
<key>?name?</key>
<value></value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.append_environment</key>
<value>true</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.autoBuildTarget</key>
<value>all</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.buildArguments</key>
<value></value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.buildCommand</key>
<value>make</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.buildLocation</key>
<value>${workspace_loc:/maui/Debug}</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.cleanBuildTarget</key>
<value>clean</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.contents</key>
<value>org.eclipse.cdt.make.core.activeConfigSettings</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.enableAutoBuild</key>
<value>false</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.enableCleanBuild</key>
<value>true</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.enableFullBuild</key>
<value>true</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.fullBuildTarget</key>
<value>all</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.stopOnError</key>
<value>true</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.useDefaultBuildCmd</key>
<value>true</value>
</dictionary>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
<triggers>full,incremental,</triggers>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.cdt.core.cnature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
</natures>
</projectDescription>
+1 -104
View File
@@ -1,113 +1,10 @@
Maui 3.3.1
- Fixed issue where hostlist was being overwritten resulting in broken $PBS_NODEFILE. (Alexis Cousein)
- Fixed issue where users could set system priority on their own jobs. (Bas van der Vlies)
- Made showgrid's, and other's, arguments case-insensitive. (David Chin)
- Added build system changes to support Cygwin (Yauheni Charniauski, UIIP Minsk)
- Added the --with-cygrunsrv configure option for start maui as Windows service (doesn't use a background daemon).
Cygwin utility cygrunsrv.exe goes it into background independently (Igor Ilyenko, UIIP Minsk)
- changed all remaining mallocs to callocs which zeros memory on allocation. Fixes a crash due
to the way some whiel loops in MResAdjustDRes() expect things to be. (Jason Williams)
- Added proper memory allocation checks to accompany the callocs in MRes.c to avoid
missing memory errors. (Jason Williams)
- Added debug print messages to MUSNPrintF() and added a proper check of the return
code to vsnprintf to be in accordance with glibc >=2.1, if installed. (Jason Williams)
- Changed top-level Makefile BUILDROOT assignment to allow RPM builds (Jason Williams)
- Minor changes to fix a few valgrind errors about uninitialized values (Jason Williams)
- Patch to fix SYSTEMMAXJOBWALLTIME, SYSTEMMAXPROCPERJOB, and SYSTEMMAXPROCSECONDPERJOB
which previously no-op'ed (Jason Williams)
- Patch for 'showq -r' to show the correct values between 0 - 100 percent if NODEALLOCMAXPS is set
to TRUE (Bas van der Vlies)
- Added UseMachineSpeedForFS patch. (Robin Roth)
"When using Fairshare it weights the Fairshareusage with the speed of
the nodes used by the job. Up to now the nodespeed is only used to allow
jobs to run longer, but with fairshare users on slower nodes are punished,
as their fs-usage is higher than on fast nodes. Additionally this allows
single nodes to be taken out of the fairshare-system by setting their speed
to very low numbers."
Maui 3.3
- Fixed configure script. Was putting RMCFG[name] TYPE=PBS@RMNMHOST@.
Maui 3.2.6p21
- Added RMCFG[] ASYNCJOBSTART=TRUE for asynchronous job starts in pbs. (Thanks to Bas van der Vlies and the community)
- Added StartTime and CompletionTime to Gold Charge.
- Fixed backfill issue with SINGLEUSER NODEACCESSPOLICY. (Thanks goes to Roy Dragseth)
- N->{A|C}Res.Swap is overcommitted with N->CRes.Swap instead of N->CRes.Mem. (Thanks goes to Roy Dragseth)
- Fixed a nodes configured swap from changing in a maui+pbs setup. (Thanks goes to Gareth Williams of CSIRO)
- Fixed CHECKSUM authentication for maui + slurm. Thanks goes to Eyegene Ryabinkin.
- Fixed 64bit issue. Maui assumed ints were always 8 bytes for 64bit systems even though x86_64 ints are still 4 bytes. This lead to aliasing of large indexed node properties to smaller indexed properties. Maui now triggers off of sizeof(int). Thanks goes to Alexis Cousein.
- Fixed an optimiztion issue with x86_64 systems. -O2 was optimizing out parts of the communication strings.
Maui 3.2.6p20
- Fixed a potential security issue when Maui is used with some PBS configurations.
- Fixed a bug pertaining to Maui's resource policy ExtendedViolation time (thanks goes to Nick Sonneveld).
- Fixed a bug with generic consumable floating resources which prevented them from working when a job also requested a 'mem' resource (thanks to Jeffrey Reed for the fix).
- Fixed typos in MPBSI.c that may have caused undesirable side-effects (thanks to Jeffrey Reed for the fix).
- Fixed a bug where group fairshare components were being miscalculated when percent based fairshare is enabled (thanks goes to Steve Traylen for the fix).
- Implemented FSSECONDARYGROUPS to map unix groups to fair share groups. Contributed by Bas van der Vlies (SARA).
- Implemented IGNPBSGROUPLIST to ignore 'qsub -W group_list=<value>'. Contributed by Bas van der Vlies (SARA).
- Note for FSSECONDARYGROUPS and IGNPBSGROUPLIST:
{{{
Maui did not parse the PBS group_list parameter:
qsub -W group_list=<value>
This variable has the highest priority and will set the group credential to
the value specified. We at SARA want to ignore this parameter, because we
do not want an user to specify its own group and bypass the FairShare
targets. So we added an option to ignore this parameter:
- IGNPBSGROUPLIST TRUE
This patch also fix some debug problems that i had when the debug level is
set to another value then the default one, eg:
- LOGLEVEL 9
Maui has a lot of keywords and the parsing of the keywords are only be
shown if a certain loglevel is set. Somebody thought it is nice that the
maui keyword table is sorted alphabetically. This is not correct because
now only the keywords after the LOG... definitions are shown. This patch
moves the LOG.. keywords definition to the beginning of keyword table and
fix this problem.
}}}
- Implemented fitting of jobs into available partitions. Contributed by Eygene Ryabinkin, Russian Research Centre "Kurchatov Institute".
ex. USERCFG[user] PLIST=par1,par2,par3 PDEF=par2 user's job will firt try to be fit in par2. If par2 doesn't work then par1 and par3 will be tried.
- Added DBG(3,fALL) to lone DPrint statements in src/moab/MRes.c because it was flooding the log file for Michael Barnes when working with 32k jobs.
Maui 3.2.6p19
- Implemented fixes for a segfault, FSPOLICY loading, and workload traces submitted by Ake Sandgren
- Implemented patch in MJobProcessExtensionString to avoid dropping first token (from Peter Gardfjäll)
- Added SUSE service startup script (suse.maui.d) to "contrib" directory (thanks goes to Stephen Cary)
Maui 3.2.6p18
- Implemented NODEALLOCMAXPS patch from Bas van der Vlies
- Implemented minor bug patch from Ake Sandgren
- Implemented NODECFG[] MAXPROC[CLASS] patch from Yaroslav Halchenko
Maui 3.2.6p16
- Maui's 'configure' script now compatible with latest TORQUE versions
Maui 3.2.6p15
- Various enhancements and bug fixes
Maui 3.2.6p14
Features
- Corrected logging in earliest start time evaluation handling
- Fixed buffer overflow in mdiag -p
- Fixed bug with floating generic resource tracking
- Added support for NODEMEMOVERCOMMITFACTOR on TORQUE
- Integrated latest DOE S3 communications library
- Cleaned up showconfig output
- Corrected multiple memory errors
- Fixed security initialization
- Fixed feature based reservation checkpoint recovery
- Improved command line arg handling
Maui 3.2.6p11
Scalability
+1 -1
View File
@@ -3,7 +3,7 @@ Moab Scheduling System - End User Open Source License
This software is based on the Moab Scheduling System which was created by
Cluster Resources, Inc.
Copyright (C) 1999-2010 Cluster Resources, Inc., all rights reserved.
Copyright (C) 1999-2004 Cluster Resources, Inc., all rights reserved.
Moab Scheduling System is a trademark of Cluster Resources, Inc.
+2 -4
View File
@@ -1,12 +1,11 @@
# Makefile @PACKAGE_NAME@ v @PACKAGE_VERSION@
# Copyright: (C) 2002-2010 Cluster Resources, Inc, All Rights Reserved
# Copyright: (C) 2002-2005 Cluster Resources, Inc, All Rights Reserved
#
# Generated by configure
BUILDROOT ?=
BUILDROOT=
export MSCHED_HOME=${BUILDROOT}@SPOOLDIR@
export INST_DIR=${BUILDROOT}@prefix@
export DAEMONDEF=@DAEMONDEF@
export OPSYS=@OPSYS@
export OS=@OS@
export CC=@CC@
@@ -51,4 +50,3 @@ setup:
distclean: clean
rm -f Makefile maui.cfg.dist include/Makefile.inc.*[!i][!n] include/maui.cfg.dist.inc.*[!i][!n]
rm -f etc/maui.sh etc/maui.csh include/moab-local.h config.log config.status
+1 -1
View File
@@ -1,4 +1,4 @@
Maui Scheduler, Release 3.3.1
Maui Scheduler, Release 3.2.6 (patch 14)
This package contains the Maui Scheduler, an advance reservation based HPC
batch scheduler with extensive job management and resource optimization
-87
View File
@@ -1,87 +0,0 @@
Checked against the Cygwin PBS Torque 2.5 realization.
Maui 3.3.1 tested with the stable release Cygwin 1.5.25 on
Windows XP Pro and on Windows Server 2003 SE (both 32-bit).
Tested with the stable release Cygwin 1.7.5 on 64-bit Windows 7 Ultimate.
Windows file system must be NTFS!!!
Maui needs two Windows users on each host:
<UserAdmin> with Computer administrator privileges and
<SimpleUser> with Limited account.
Both users must be password protected.
Maui scheduler can run as Cygwin daemon or as Windows service.
Run as administrator (right-click) on Windows 7 and similar.
###########################
### Install Cygwin ###
###########################
Enter into Windows as user <UserAdmin>.
To install Cygwin 1.5.25 browse to http://cygwin.com/win-9x.html and click the "setup-legacy.exe" link.
Download and run setup-legacy.exe.
To install Cygwin 1.7.5 (or later) browse to http://cygwin.com and click the "Install Cygwin now" link.
Download and run setup.exe.
Click through the defaults and under the package selection
to select the following packages:
autoconf;
automake;
cygrunsrv;
gcc or gcc4;
make;
vim or mc is desirable.
Download and install the default's and selected Cygwin packages.
###################################################
### Start Maui under Cygwin with PBS Torque ###
###################################################
Enter into working directory as <UserAdmin> and execute the following commands:
#./configure --with-pbs[=DIR] --with-spooldir=/var/spool/maui/
where DIR - target directory, location of PBS Torque lib dir (as default - /usr/local)
#make
#make install
Open the ports for Maui scheduler in your firewall.
Start the Maui:
#maui
Submit jobs as <SimpleUser> with Limited account.
See jobs information via the Maui showq command
and via the Torque qstat command.
See more the Maui Documentations.
######################################################
### Start Maui under Cygwin as Windows service ###
######################################################
Enter into working directory as <UserAdmin> and execute the following commands:
#./configure --with-cygrunsrv --with-pbs[=DIR] --with-spooldir=/var/spool/maui/
#make
#make install
Set additional privilege in order that user can log on as a service:
#editrights -a SeServiceLogonRight -u <UserAdmin>
Use cygrunsrv.exe for install, start, stop and remove services.
See more cygrunsrv.exe --help.
For example:
#cygrunsrv.exe -I maui -p /usr/sbin/maui.exe u <UserAdmin> -w <password>
Services and privileges are managed via the Windows Control Panel or command line.
Vendored
+51 -102
View File
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.57 for maui 3.3.1.
# Generated by GNU Autoconf 2.57 for maui 3.2p14.
#
# Report bugs to <help@supercluster.org>.
#
@@ -268,8 +268,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
# Identity of this package.
PACKAGE_NAME='maui'
PACKAGE_TARNAME='maui'
PACKAGE_VERSION='3.3.1'
PACKAGE_STRING='maui 3.3.1'
PACKAGE_VERSION='3.2p8'
PACKAGE_STRING='maui 3.2p8'
PACKAGE_BUGREPORT='help@supercluster.org'
ac_unique_file="src/mcom/MConst.c"
@@ -311,7 +311,7 @@ ac_includes_default="\
# include <unistd.h>
#endif"
ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT LN_S SPOOLDIR MACHINE SEED DAEMONDEF OPSYS OS HOSTNAME USER BUILDDATE BUILDDIR RMTYPE LLDIR LLDEF PBSTARGETDIR SGEBUILDDIR SGEOSDIR LSFDIR LSFLIBS LSFDEFS PBSCFLAGS PBSLDFLAGS RMPORT RMHOST RMSOCKETPROTOCOL RMWIREPROTOCOL RMVERSION RMNMPORT RMNMHOST AMTYPE AMHOST AMPORT AMSOCKETPROTOCOL AMWIREPROTOCOL AMOTHER PCREDIR CPP EGREP LIBOBJS POW_LIB LTLIBOBJS'
ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT LN_S SPOOLDIR MACHINE SEED OPSYS OS HOSTNAME USER BUILDDATE BUILDDIR RMTYPE LLDIR LLDEF PBSTARGETDIR PBSLIBS SGEBUILDDIR SGEOSDIR LSFDIR LSFLIBS LSFDEFS RMPORT RMHOST RMSOCKETPROTOCOL RMWIREPROTOCOL RMVERSION RMNMPORT RMNMSERVER AMTYPE AMHOST AMPORT AMSOCKETPROTOCOL AMWIREPROTOCOL AMOTHER PCREDIR CPP EGREP LIBOBJS POW_LIB LTLIBOBJS'
ac_subst_files='rm_config ll_definitions sdr_definitions pbs_definitions sge_definitions lsf_definitions mx_definitions pcre_definitions'
# Initialize some variables set by options.
@@ -780,7 +780,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures maui 3.3.1 to adapt to many kinds of systems.
\`configure' configures maui 3.2p8 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -837,7 +837,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of maui 3.3.1:";;
short | recursive ) echo "Configuration of maui 3.2p8:";;
esac
cat <<\_ACEOF
@@ -862,7 +862,6 @@ Optional Packages:
--with-sss-am[=PORT] use SSS Allocation Manager (default port [8865])
--with-mx use MX
--with-pcre[=DIR] use PCRE (pcre dir (location of PCRE include and lib directories) [/path/to/pcre]
--with-cygrunsrv run as Windows service for Cygwin (do not use a background daemon)
Some influential environment variables:
CC C compiler command
@@ -939,7 +938,7 @@ fi
test -n "$ac_init_help" && exit 0
if $ac_init_version; then
cat <<\_ACEOF
maui configure 3.3.1
maui configure 3.2p8
generated by GNU Autoconf 2.57
Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
@@ -954,7 +953,7 @@ cat >&5 <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by maui $as_me 3.3.1, which was
It was created by maui $as_me 3.2p8, which was
generated by GNU Autoconf 2.57. Invocation command line was
$ $0 $@
@@ -2218,53 +2217,46 @@ OS=`uname`
if test "$OS" = "AIX"; then
if test `uname -v` = 4; then
if test `uname -r` = 1; then
OPSYS="__AIX41"
OPSYS="AIX41"
elif test `uname -r` = 2; then
OPSYS="__AIX42"
OPSYS="AIX42"
elif test `uname -r` = 3; then
OPSYS="__AIX43"
OPSYS="AIX43"
else
OPSYS="__AIX43"
RELEASE=`uname -r`
{ echo "$as_me:$LINENO: WARNING: Unexpected OS release 'AIX4$RELEASE', attempting build with OPSYS=$OPSYS" >&5
echo "$as_me: WARNING: Unexpected OS release 'AIX4$RELEASE', attempting build with OPSYS=$OPSYS" >&2;}
OPSYS="AIX43"
RELEASE=`uname -r`
{ echo "$as_me:$LINENO: WARNING: Unexpected OS release 'AIX4$(RELEASE)', attempting build with OPSYS=$(OPSYS)" >&5
echo "$as_me: WARNING: Unexpected OS release 'AIX4$(RELEASE)', attempting build with OPSYS=$(OPSYS)" >&2;}
fi
else
OPSYS=__AIX43
OSLEVEL=`oslevel`
{ echo "$as_me:$LINENO: WARNING: Unexpected AIX level: $OSLEVEL, attempting build with OPSYS=$OPSYS" >&5
echo "$as_me: WARNING: Unexpected AIX level: $OSLEVEL, attempting build with OPSYS=$OPSYS" >&2;}
OPSYS=AIX43
OSLEVEL=`oslevel`
{ echo "$as_me:$LINENO: WARNING: Unexpected AIX level: $(OSLEVEL), attempting build with OPSYS=$(OPSYS)" >&5
echo "$as_me: WARNING: Unexpected AIX level: $(OSLEVEL), attempting build with OPSYS=$(OPSYS)" >&2;}
fi
elif echo "$OS" | grep -q "CYGWIN"; then
OPSYS="__CYGWIN"
elif test "$OS" = "Linux"; then
OPSYS="__LINUX"
OPSYS="LINUX"
elif test "$OS" = "HP-UX"; then
OPSYS="__HPUX"
OPSYS="HPUX"
elif test "$OS" = "HP-UX"; then
OPSYS="__HPUX"
OPSYS="HPUX"
elif test "$OS" = "IRIX" -o "$OS" = "IRIX64"; then
OPSYS="__IRIX"
OPSYS="IRIX"
OS="IRIX"
elif test "$OS" = "NT"; then
OPSYS="__NT"
OPSYS="NT"
OS="NT"
elif test "$OS" = "OSF1"; then
OPSYS="__OSF"
OPSYS="OSF"
OS="OSF"
else
OPSYS="__LINUX"
{ echo "$as_me:$LINENO: WARNING: Unsupported OS: $OS, attempting build with OPSYS=$OPSYS" >&5
echo "$as_me: WARNING: Unsupported OS: $OS, attempting build with OPSYS=$OPSYS" >&2;}
OPSYS="LINUX"
OS="LINUX"
{ echo "$as_me:$LINENO: WARNING: Unsupported OS: $(OS), attempting build with OPSYS=$(OPSYS)" >&5
echo "$as_me: WARNING: Unsupported OS: $(OS), attempting build with OPSYS=$(OPSYS)" >&2;}
fi
# Configure 64 bit dependent settings
BIT64=`uname -m | grep 64`
if test -n "$BIT64"; then
CFLAGS="$CFLAGS -D__M64"
LDFLAGS="$LDFLAGS"
fi
# Make generic variable Substitutions
@@ -2343,19 +2335,7 @@ else
fi;
if test "$PBSTARGETDIR" != 'FALSE'; then
if test "$PBSTARGETDIR" = 'yes'; then
if pbs-config --prefix 1>/dev/null 2>&1;then
PBSTARGETDIR=`pbs-config --prefix`
else
PBSTARGETDIR='/usr/local'
fi
elif test -f "$PBSTARGETDIR/bin/pbs-config"; then
PBSTARGETDIR=`$PBSTARGETDIR/bin/pbs-config --prefix`
elif test -f "$PBSTARGETDIR/../bin/pbs-config"; then
PBSTARGETDIR=`$PBSTARGETDIR/../bin/pbs-config --prefix`
elif test -f "$PBSTARGETDIR/pbs-config"; then
PBSTARGETDIR=`$PBSTARGETDIR/pbs-config --prefix`
elif test -f "$PBSTARGETDIR"; then
PBSTARGETDIR=`$PBSTARGETDIR --prefix`
PBSTARGETDIR='/usr/local';
fi
if test "$RMTYPE" = ''; then
RMTYPE=PBS
@@ -2367,6 +2347,12 @@ if test "$PBSTARGETDIR" != 'FALSE'; then
echo "$as_me: error: Only one Resource Manager can be specified (PBS, $RMTYPE)" >&2;}
{ (exit 1); exit 1; }; }
fi
if test "$OS" = "OSF"; then
PBSLIBS="$PBSTARGETDIR/ilib/libnet.a -lpbs"
else
PBSLIBS="-lnet -lpbs"
fi
pbs_definitions=include/Makefile.inc.pbs
@@ -2549,44 +2535,22 @@ fi
if test "$RMTYPE" = ''; then
{ echo "$as_me:$LINENO: WARNING: Resource Manager not specified - attempting build with pbs" >&5
{ echo "$as_me:$LINENO: WARNING: Resource Manager not specified - attempting build with pbs" >&5
echo "$as_me: WARNING: Resource Manager not specified - attempting build with pbs" >&2;}
RMTYPE=PBS
RMTYPE=PBS
rm_config=include/maui.cfg.dist.inc.rm
rm_config=include/maui.cfg.dist.inc.rm
if pbs-config --prefix 1>/dev/null 2>&1;then
PBSTARGETDIR=`pbs-config --prefix`
else
PBSTARGETDIR='/usr/local';
fi
fi
if test "$RMTYPE" = "PBS" ;then
if $PBSTARGETDIR/bin/pbs-config --cflags 1>/dev/null 2>&1;then
PBSCFLAGS=`$PBSTARGETDIR/bin/pbs-config --cflags`
else
PBSCFLAGS=-I$PBSTARGETDIR/include
fi
if $PBSTARGETDIR/bin/pbs-config --libs 1>/dev/null 2>&1;then
PBSLDFLAGS=`$PBSTARGETDIR/bin/pbs-config --libs`
elif test -f $PBSTARGETDIR/lib/libpbs.a ;then
if test "$OS" = "OSF"; then
PBSLDFLAGS="$PBSTARGETDIR/ilib/libnet.a -L$PBSTARGETDIR/lib -lpbs"
else
PBSLDFLAGS="-L$PBSTARGETDIR/lib -lnet -lpbs"
fi
else
{ { echo "$as_me:$LINENO: error: can't find pbs-config or libpbs.a" >&5
echo "$as_me: error: can't find pbs-config or libpbs.a" >&2;}
{ (exit 1); exit 1; }; }
fi
if test "$OS" = "OSF"; then
PBSLIBS="$PBSTARGETDIR/ilib/libnet.a -lpbs"
else
PBSLIBS="-lnet -lpbs"
fi
pbs_definitions=include/Makefile.inc.pbs
pbs_definitions=include/Makefile.inc.pbs
fi
@@ -2604,7 +2568,7 @@ fi;
if test "$USEWAREHOUSE" != 'FALSE'; then
if test "$NMTYPE" = ''; then
RMNMPORT=" NMPORT=12321"
RMNMHOST=" NMHOST=$HOSTNAME"
RMNMSERVER=" NMSERVER=$HOSTNAME"
fi
fi
@@ -2663,7 +2627,7 @@ echo "$as_me: error: Only one Allocation Manager can be specified (GOLD, $AMTYPE
{ (exit 1); exit 1; }; }
fi
AMTYPE=GOLD
AMTYPE=SSS
AMHOST=" HOST=$HOSTNAME"
AMPORT=" PORT=7112"
AMSOCKETPROTOCOL=" SOCKETPROTOCOL=HTTP"
@@ -2746,17 +2710,6 @@ if test "$PCREDIR" != 'FALSE'; then
pcre_definitions=include/Makefile.inc.pcre
fi
# CYGRUNSRV
# Check whether --with-cygrunsrv or --without-cygrunsrv was given.
if test "${with_cygrunsrv+set}" = set; then
withval="$with_cygrunsrv"
DAEMONDEF="-D__CYGRUNSRV"
else
DAEMONDEF=""
fi;
# Make sure one RM was specified
if test "$RMTYPE" = ''; then
{ { echo "$as_me:$LINENO: error: At least one Resource Manager must be specified" >&5
@@ -6949,7 +6902,7 @@ _ASBOX
} >&5
cat >&5 <<_CSEOF
This file was extended by maui $as_me 3.3.1, which was
This file was extended by maui $as_me 3.2p8, which was
generated by GNU Autoconf 2.57. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -7004,7 +6957,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
maui config.status 3.3.1
maui config.status 3.2p8
configured by $0, generated by GNU Autoconf 2.57,
with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
@@ -7215,7 +7168,6 @@ s,@LN_S@,$LN_S,;t t
s,@SPOOLDIR@,$SPOOLDIR,;t t
s,@MACHINE@,$MACHINE,;t t
s,@SEED@,$SEED,;t t
s,@DAEMONDEF@,$DAEMONDEF,;t t
s,@OPSYS@,$OPSYS,;t t
s,@OS@,$OS,;t t
s,@HOSTNAME@,$HOSTNAME,;t t
@@ -7226,20 +7178,19 @@ s,@RMTYPE@,$RMTYPE,;t t
s,@LLDIR@,$LLDIR,;t t
s,@LLDEF@,$LLDEF,;t t
s,@PBSTARGETDIR@,$PBSTARGETDIR,;t t
s,@PBSLIBS@,$PBSLIBS,;t t
s,@SGEBUILDDIR@,$SGEBUILDDIR,;t t
s,@SGEOSDIR@,$SGEOSDIR,;t t
s,@LSFDIR@,$LSFDIR,;t t
s,@LSFLIBS@,$LSFLIBS,;t t
s,@LSFDEFS@,$LSFDEFS,;t t
s,@PBSCFLAGS@,$PBSCFLAGS,;t t
s,@PBSLDFLAGS@,$PBSLDFLAGS,;t t
s,@RMPORT@,$RMPORT,;t t
s,@RMHOST@,$RMHOST,;t t
s,@RMSOCKETPROTOCOL@,$RMSOCKETPROTOCOL,;t t
s,@RMWIREPROTOCOL@,$RMWIREPROTOCOL,;t t
s,@RMVERSION@,$RMVERSION,;t t
s,@RMNMPORT@,$RMNMPORT,;t t
s,@RMNMHOST@,$RMNMHOST,;t t
s,@RMNMSERVER@,$RMNMSERVER,;t t
s,@AMTYPE@,$AMTYPE,;t t
s,@AMHOST@,$AMHOST,;t t
s,@AMPORT@,$AMPORT,;t t
@@ -7507,8 +7458,6 @@ fi
# Do miscellaneous configure steps
touch maui.ck
touch maui-private.cfg
test -d bin || mkdir bin
test -d lib || mkdir lib
# Display final messages
if test -z "`echo $PATH | grep \"$prefix\" 2>/dev/null`"; then
+43 -81
View File
@@ -2,7 +2,7 @@
# Process this file with autoconf to produce a configure script.
AC_PREREQ(2.57)
AC_INIT(maui, 3.3.1, help@supercluster.org)
AC_INIT(maui, 3.2p8, help@supercluster.org)
AC_CONFIG_SRCDIR([src/mcom/MConst.c])
#AC_CONFIG_HEADER([config.h])
@@ -38,42 +38,41 @@ OS=`uname`
if test "$OS" = "AIX"; then
if test `uname -v` = 4; then
if test `uname -r` = 1; then
OPSYS="__AIX41"
OPSYS="AIX41"
elif test `uname -r` = 2; then
OPSYS="__AIX42"
OPSYS="AIX42"
elif test `uname -r` = 3; then
OPSYS="__AIX43"
OPSYS="AIX43"
else
OPSYS="__AIX43"
RELEASE=`uname -r`
AC_MSG_WARN([Unexpected OS release 'AIX4$RELEASE', attempting build with OPSYS=$OPSYS])
OPSYS="AIX43"
RELEASE=`uname -r`
AC_MSG_WARN([Unexpected OS release 'AIX4$(RELEASE)', attempting build with OPSYS=$(OPSYS)])
fi
else
OPSYS=__AIX43
OSLEVEL=`oslevel`
AC_MSG_WARN([Unexpected AIX level: $OSLEVEL, attempting build with OPSYS=$OPSYS])
OPSYS=AIX43
OSLEVEL=`oslevel`
AC_MSG_WARN([Unexpected AIX level: $(OSLEVEL), attempting build with OPSYS=$(OPSYS)])
fi
elif echo "$OS" | grep -q "CYGWIN"; then
OPSYS="__CYGWIN"
elif test "$OS" = "Linux"; then
OPSYS="__LINUX"
OPSYS="LINUX"
elif test "$OS" = "HP-UX"; then
OPSYS="__HPUX"
OPSYS="HPUX"
elif test "$OS" = "HP-UX"; then
OPSYS="__HPUX"
OPSYS="HPUX"
elif test "$OS" = "IRIX" -o "$OS" = "IRIX64"; then
OPSYS="__IRIX"
OPSYS="IRIX"
OS="IRIX"
elif test "$OS" = "NT"; then
OPSYS="__NT"
OPSYS="NT"
OS="NT"
elif test "$OS" = "OSF1"; then
OPSYS="__OSF"
OPSYS="OSF"
OS="OSF"
else
OPSYS="__LINUX"
AC_MSG_WARN([Unsupported OS: $OS, attempting build with OPSYS=$OPSYS])
OPSYS="LINUX"
OS="LINUX"
AC_MSG_WARN([Unsupported OS: $(OS), attempting build with OPSYS=$(OPSYS)])
fi
AC_SUBST(OPSYS)
AC_SUBST(OS)
@@ -136,19 +135,7 @@ AC_ARG_WITH(pbs,
[PBSTARGETDIR='FALSE'])
if test "$PBSTARGETDIR" != 'FALSE'; then
if test "$PBSTARGETDIR" = 'yes'; then
if pbs-config --prefix 1>/dev/null 2>&1;then
PBSTARGETDIR=`pbs-config --prefix`
else
PBSTARGETDIR='/usr/local'
fi
elif test -f "$PBSTARGETDIR/bin/pbs-config"; then
PBSTARGETDIR=`$PBSTARGETDIR/bin/pbs-config --prefix`
elif test -f "$PBSTARGETDIR/../bin/pbs-config"; then
PBSTARGETDIR=`$PBSTARGETDIR/../bin/pbs-config --prefix`
elif test -f "$PBSTARGETDIR/pbs-config"; then
PBSTARGETDIR=`$PBSTARGETDIR/pbs-config --prefix`
elif test -f "$PBSTARGETDIR"; then
PBSTARGETDIR=`$PBSTARGETDIR --prefix`
PBSTARGETDIR='/usr/local';
fi
if test "$RMTYPE" = ''; then
RMTYPE=PBS
@@ -158,7 +145,13 @@ if test "$PBSTARGETDIR" != 'FALSE'; then
else
AC_MSG_ERROR([Only one Resource Manager can be specified (PBS, $RMTYPE)])
fi
if test "$OS" = "OSF"; then
PBSLIBS="$PBSTARGETDIR/ilib/libnet.a -lpbs"
else
PBSLIBS="-lnet -lpbs"
fi
AC_SUBST(PBSTARGETDIR)
AC_SUBST(PBSLIBS)
AC_SUBST_FILE(pbs_definitions)
pbs_definitions=include/Makefile.inc.pbs
fi
@@ -304,41 +297,21 @@ fi
if test "$RMTYPE" = ''; then
AC_MSG_WARN([Resource Manager not specified - attempting build with pbs])
RMTYPE=PBS
AC_SUBST(RMTYPE)
AC_SUBST_FILE(rm_config)
rm_config=include/maui.cfg.dist.inc.rm
if pbs-config --prefix 1>/dev/null 2>&1;then
PBSTARGETDIR=`pbs-config --prefix`
else
PBSTARGETDIR='/usr/local';
fi
fi
if test "$RMTYPE" = "PBS" ;then
if $PBSTARGETDIR/bin/pbs-config --cflags 1>/dev/null 2>&1;then
PBSCFLAGS=`$PBSTARGETDIR/bin/pbs-config --cflags`
else
PBSCFLAGS=-I$PBSTARGETDIR/include
fi
if $PBSTARGETDIR/bin/pbs-config --libs 1>/dev/null 2>&1;then
PBSLDFLAGS=`$PBSTARGETDIR/bin/pbs-config --libs`
elif test -f $PBSTARGETDIR/lib/libpbs.a ;then
if test "$OS" = "OSF"; then
PBSLDFLAGS="$PBSTARGETDIR/ilib/libnet.a -L$PBSTARGETDIR/lib -lpbs"
else
PBSLDFLAGS="-L$PBSTARGETDIR/lib -lnet -lpbs"
fi
else
AC_MSG_ERROR([can't find pbs-config or libpbs.a])
fi
AC_SUBST(PBSCFLAGS)
AC_SUBST(PBSLDFLAGS)
AC_SUBST_FILE(pbs_definitions)
pbs_definitions=include/Makefile.inc.pbs
AC_MSG_WARN([Resource Manager not specified - attempting build with pbs])
RMTYPE=PBS
AC_SUBST(RMTYPE)
AC_SUBST_FILE(rm_config)
rm_config=include/maui.cfg.dist.inc.rm
if test "$OS" = "OSF"; then
PBSLIBS="$PBSTARGETDIR/ilib/libnet.a -lpbs"
else
PBSLIBS="-lnet -lpbs"
fi
AC_SUBST(PBSTARGETDIR)
AC_SUBST(PBSLIBS)
AC_SUBST_FILE(pbs_definitions)
pbs_definitions=include/Makefile.inc.pbs
fi
@@ -352,7 +325,7 @@ AC_ARG_WITH(warehouse,
if test "$USEWAREHOUSE" != 'FALSE'; then
if test "$NMTYPE" = ''; then
RMNMPORT=" NMPORT=12321"
RMNMHOST=" NMHOST=$HOSTNAME"
RMNMSERVER=" NMSERVER=$HOSTNAME"
fi
fi
@@ -363,7 +336,7 @@ AC_SUBST(RMSOCKETPROTOCOL)
AC_SUBST(RMWIREPROTOCOL)
AC_SUBST(RMVERSION)
AC_SUBST(RMNMPORT)
AC_SUBST(RMNMHOST)
AC_SUBST(RMNMSERVER)
# END RM CONFIG --------------------------------------
@@ -399,7 +372,7 @@ if test "$USEGOLD" != 'FALSE'; then
AC_MSG_ERROR([Only one Allocation Manager can be specified (GOLD, $AMTYPE)])
fi
AMTYPE=GOLD
AMTYPE=SSS
AMHOST=" HOST=$HOSTNAME"
AMPORT=" PORT=7112"
AMSOCKETPROTOCOL=" SOCKETPROTOCOL=HTTP"
@@ -468,15 +441,6 @@ if test "$PCREDIR" != 'FALSE'; then
pcre_definitions=include/Makefile.inc.pcre
fi
# CYGRUNSRV
AC_ARG_WITH(cygrunsrv,
[ --with-cygrunsrv run as Windows service for Cygwin (do not use a background daemon)],
[DAEMONDEF="-D__CYGRUNSRV"],
[DAEMONDEF=""])
AC_SUBST(DAEMONDEF)
# Make sure one RM was specified
if test "$RMTYPE" = ''; then
AC_MSG_ERROR([At least one Resource Manager must be specified])
@@ -533,8 +497,6 @@ AC_OUTPUT
# Do miscellaneous configure steps
touch maui.ck
touch maui-private.cfg
test -d bin || mkdir bin
test -d lib || mkdir lib
# Display final messages
if test -z "`echo $PATH | grep \"$prefix\" 2>/dev/null`"; then
+1 -1
View File
@@ -7,7 +7,7 @@ maui326:
ACTION=snap ; \
PKG=maui ; \
VERSION=3.2.6 ; \
PATCH=p18 ; \
PATCH=p10 ; \
BASEDIR=$$PKG-$$VERSION$$PATCH ; \
cd $$BASEDIR ; \
for i in src/[ms]* include; do \
-36
View File
@@ -1,36 +0,0 @@
#!/bin/sh
#
# maui This script will start and stop the MAUI Scheduler
#
# chkconfig: 345 85 85
# description: maui
#
ulimit -n 32768
# Source the library functions
. /etc/rc.d/init.d/functions
MAUI_PREFIX=/opt
# let see how we were called
case "$1" in
start)
echo -n "Starting MAUI Scheduler: "
daemon --user maui $MAUI_PREFIX/sbin/maui
echo
;;
stop)
echo -n "Shutting down MAUI Scheduler: "
killproc maui
echo
;;
status)
status maui
;;
restart)
$0 stop
$0 start
;;
*)
echo "Usage: maui {start|stop|restart|status}"
exit 1
esac
-53
View File
@@ -1,53 +0,0 @@
#!/bin/sh
#
# Maui Scheduler This script will start and stop the Maui Scheduler (SUSE)
#
# chkconfig: 345 85 85
# description: maui
#
# Source the library functions
. /etc/rc.status
# ENVIRONMENT
MAUI=/opt/maui/sbin/maui
#
# Check for parameters in /etc/sysconfig,
# if so load them into the environment
[ -f /etc/sysconfig/maui ] && . /etc/sysconfig/maui
#
# make sure the binary exists
# exit if not
[ -x $MAUI ] || exit
#
# What command are we to do?
#
case "$1" in
start)
echo -n "Starting the Maui scheduler: "
startproc $MAUI
rc_status -v
;;
stop)
echo -n "Shutting down Maui Scheduler: "
killproc `basename $MAUI`
rc_status -v
;;
status)
checkproc `basename $MAUI`
rc_status -v
;;
restart)
$0 stop
$0 start
;;
*)
echo "Usage: maui {start|stop|restart|status}"
exit 1
esac
+3 -2
View File
@@ -1,4 +1,5 @@
# PBS Definitions
export PBSDEF = -D__MPBS
export PBSCFLAGS = @PBSCFLAGS@
export PBSLDFLAGS = @PBSLDFLAGS@
export PBSIP = -I@PBSTARGETDIR@/include
export PBSLP = -L@PBSTARGETDIR@/lib
export PBSLIB = @PBSLIBS@
+3 -3
View File
@@ -1,10 +1,10 @@
VERSION 3.3.1
VERSION 3.2.6p12
PACKAGE moab
AUTHOR Cluster Resources, Inc
FILETYPE Module
COPYRIGHT Copyright (C) 1999-2010 Cluster Resources, Inc
COPYRIGHT Copyright (C) 1999-2005 Cluster Resources, Inc
DISCLAIMER
-----------------------------------------------------------------------------
@@ -13,7 +13,7 @@ Moab Scheduling System - End User Open Source License
This software is based on the Moab Scheduling System which was created by
Cluster Resources, Inc.
Copyright (C) 1999-2010 Cluster Resources, Inc., all rights reserved.
Copyright (C) 1999-2005 Cluster Resources, Inc., all rights reserved.
Moab Scheduling System is a trademark of Cluster Resources, Inc.
+1 -1
View File
@@ -13,7 +13,7 @@ Moab Workload Manager - End User License
This product was created by Cluster Resources, Inc. and is protected by
copyright and patent law.
Copyright (C) 1999-2010 Cluster Resources, Inc., all rights reserved.
Copyright (C) 1999-2005 Cluster Resources, Inc., all rights reserved.
Moab Workload Manager, Moab Cluster Scheduler and Moab Scheduler
are trademarks of Cluster Resources, Inc.
-1
View File
@@ -60,7 +60,6 @@ int MXMLGetChildCI(mxml_t *,char *,int *,mxml_t **);
int MXMLFromString(mxml_t **,char *,char **,char *);
int MXMLDupE(mxml_t *,mxml_t **);
mbool_t MXMLStringIsValid(char *);
int MXMLToXString(mxml_t *,char **,int *,int,char **,mbool_t);
View File
+6 -11
View File
@@ -65,9 +65,6 @@ int MGroupAdd(char *,mgcred_t **);
int MGroupToString(mgcred_t *,char *);
int MGroupProcessConfig(mgcred_t *,char *);
/* HvB */
int MGroupGetFSGroups();
int MGroupSecondary(char *, mjob_t *);
/* acct object */
@@ -97,7 +94,7 @@ int MCredConfigLShow(void *,int,int,int,char *);
char *MOGetName(void *,int,char **);
int MCredInitialize(int,void *,char *);
int MCredAdd(int,char *,void **);
int MCredLoadConfig(int,char *,char *,char *);
int MCredLoadConfig(int,char *,char *);
int MCredAdjustConfig(int,void *);
int MOLoadPvtConfig(void **,int,char *,mpsi_t *,char *);
int MCredSetDefaults(void);
@@ -292,7 +289,6 @@ int MJobSetState(mjob_t *,enum MJobStateEnum);
int MJobPreempt(mjob_t *,mjob_t **,enum MPreemptPolicyEnum,char *,int *);
int MJobResume(mjob_t *,char *,int *);
int MJobGetPAL(mjob_t *,int *,int *,mpar_t **);
mpar_t *MJobFindDefPart(mjob_t *, mclass_t *, int *);
int MJobRemove(mjob_t *);
int MJobGetAccount(mjob_t *,mgcred_t **);
int MJobSetCreds(mjob_t *,char *,char *,char *);
@@ -302,7 +298,7 @@ int MJobSelectMNL(mjob_t *,mpar_t *,nodelist_t,mnodelist_t,char *,int);
int MJobDistributeTasks(mjob_t *,mrm_t *,mnalloc_t *,short *);
int MJobTrap(mjob_t *);
char *MJobGetName(mjob_t *,char *,mrm_t *,char *,int,enum MJobNameEnum);
int MJobGetStartPriority(mjob_t *,int,double *,int,char **,int *);
int MJobGetStartPriority(mjob_t *,int,double *,int,char *);
int MJobGetRunPriority(mjob_t *,int,double *,char *);
int MJobGetBackfillPriority(mjob_t *,unsigned long,int,double *,char *);
int MJobGetPartitionAccess(mjob_t *);
@@ -338,7 +334,7 @@ int MJobDestroy(mjob_t **);
int MJobSelectPJobList(mjob_t *,int,int,mjob_t **,mnalloc_t *,mjob_t **,int *,int *,nodelist_t **);
int MJobCheckDependency(mjob_t *,enum MJobDependEnum *,char *);
int MJobSetDependency(mjob_t *,enum MJobDependEnum,char *);
int MJobSelectResourceSet(mjob_t *,mreq_t *,int,int,char **,mnalloc_t *,int);
int MJobSelectResourceSet(mjob_t *,int,int,char **,mnalloc_t *,int);
int MJobCheckNRes(mjob_t *,mnode_t *,mreq_t *,long,int *,double,int *,char *,long *,int);
int MJobGetEStartTime(mjob_t *,mpar_t **,int *,int *,mnodelist_t,long *);
int MJobAddToNL(mjob_t *,nodelist_t);
@@ -384,11 +380,11 @@ int MQueuePrioritizeJobs(mjob_t **,int *);
int MQueueGetBestRQTime(int *,long *);
int MQueueScheduleRJobs(int *);
int MQueueScheduleSJobs(int *);
int MQueueDiagnose(mjob_t **,int *,int,mpar_t *,char *,int);
int MQueueDiagnose(mjob_t **,int *,int,mpar_t *,char *);
int MQueueCheckStatus(void);
int MQueueGetRequeueValue(int *,long,long,double *);
int MQueueSelectAllJobs(mjob_t **,int,mpar_t *,int *,int,int,int,char *);
int MQueueSelectJobs(int *,int *,int,int,int,unsigned long,int,int *,mbool_t,mbool_t);
int MQueueSelectJobs(int *,int *,int,int,int,unsigned long,int,int *,mbool_t);
int MQueueAddAJob(mjob_t *);
int MQueueRemoveAJob(mjob_t *,int);
int MQueueBackFill(int *,int,mpar_t *);
@@ -448,12 +444,11 @@ int MSysDSQuery(char *,char *,char *,int *,char *,char *);
int MSysEMSubmit(mpsi_t *,char *,char *,char *);
int MSysEMRegister(mpsi_t *,char *,char *,char *,char *);
int MSysSynchronize(void);
int MSysInitialize(mbool_t);
int MSysInitialize(void);
void MSysShutdown(int);
int MSysDestroyObjects(void);
int MSysDiagnose(char *,int,long);
int MSysStartServer(int);
int M64Init(m64_t *);
+12 -38
View File
@@ -7,7 +7,7 @@
#include "moab-local.h"
#include "mcom.h"
#define MOAB_VERSION "3.3.1"
#define MOAB_VERSION "3.2.6p14"
/* elemental objects */
@@ -21,32 +21,17 @@ typedef struct {
typedef struct {
long MTime;
int FailureCount;
int QCount;
int JCount;
int RCount;
int CCount;
int QCount; /* query count */
int JCount; /* job count */
int RCount; /* reservation count */
int CCount; /* command count */
int SIsInitialized;
int IIsInitialized;
int SIsInitialized; /* server (boolean) */
int IIsInitialized; /* interface (boolean) */
char *Messages;
} mgrid_t;
typedef struct
{
char *Data;
char *Owner;
char *Source;
long ExpireTime;
long CTime;
int Type;
int Priority;
int Count;
void *Next;
} mmb_t;
enum MValModEnum {
mvmByte = 0,
mvmWord,
@@ -125,7 +110,6 @@ enum MActivePolicyTypeEnum {
#define M32UINT4 unsigned long
#define M32UINT8 unsigned long long
/* ints on x86_64 are still 4 bytes */
#ifdef __M64
#define MINTBITS 64
#define MINTLBITS 6
@@ -207,10 +191,6 @@ typedef struct {
# define MAX_MRES 1024
#endif /* MAX_MRES */
#ifndef MMAX_RSV
# define MMAX_RSV MAX_MRES
#endif
#ifndef MAX_MFSDEPTH
# define MAX_MFSDEPTH 24
#endif /* MAX_MFSDEPTH */
@@ -275,7 +255,6 @@ typedef struct {
#define DEFAULT_MRESOURCELIMITVIOLATIONACTION mrlaRequeue
#define MDEF_SPVJOBISPREEMPTIBLE TRUE
#define MDEF_MINSUSPENDTIME 10
/* node access policy */
@@ -342,8 +321,7 @@ enum MHoldReasonEnum {
mhrAPIFailure,
mhrRMReject,
mhrPolicyViolation,
mhrQOSAccess,
mhrCredAccess };
mhrQOSAccess };
/* node states */
@@ -880,7 +858,6 @@ enum MClassAttrType {
mclaDefReqFeature,
mclaHostList,
mclaName,
mclaNAPolicy,
mclaMaxProcPerNode,
mclaOCDProcFactor,
mclaState,
@@ -1013,7 +990,6 @@ enum MLimitAttrType {
enum MRMAttrType {
mrmaNONE = 0,
mrmaAuthType,
mrmaASyncJobStart, /* asynchronous job start */
mrmaConfigFile,
mrmaCSAlgo,
mrmaCSKey,
@@ -1064,8 +1040,7 @@ enum {
mjfSPViolation,
mjfIgnNodePolicies,
mjfNoRMStart,
mjfGlobalQueue,
mjfIsExiting };
mjfGlobalQueue };
enum {
mjifNONE = 0,
@@ -1125,9 +1100,9 @@ typedef struct {
int (*ResourceQuery)(mnode_t *,mrm_t *,char *,int *);
int (*RMEventQuery)(mrm_t *,int *);
int (*RMGetData)(mrm_t *,int *);
int (*RMInitialize)(mrm_t *,int *);
int (*RMInitialize)(mrm_t *, int *);
int (*RMQuery)(void);
int (*WorkloadQuery)(mrm_t *,int *,int *);
int (*WorkloadQuery)(mrm_t *, int *, int *);
mbool_t IsInitialized;
} mrmfunc_t;
@@ -1566,7 +1541,6 @@ enum MJobAttrEnum {
enum MXAttrType {
mxaNONE,
mxaAdvRes,
mxaDDisk,
mxaDistPolicy,
mxaDMem,
mxaFlags,
@@ -1831,7 +1805,7 @@ typedef struct {
int (*JobDistributeTasks)(mjob_t *,mrm_t *,mnalloc_t *,short int *);
int (*JobFind)(char *, mjob_t **, int);
int (*JobGetFeasibleTasks)(mjob_t *,mreq_t *,mpar_t *,nodelist_t,nodelist_t,int *,int *,long int,long unsigned int);
int (*JobGetStartPriority)(mjob_t *,int,double *,int,char **,int *);
int (*JobGetStartPriority)(mjob_t *,int,double *,int,char *);
int (*JobGetTasks)(mjob_t *,mpar_t *,nodelist_t,mnodelist_t,char *,int);
int (*JobSetCreds)(mjob_t *, char *, char *, char *);
int (*JobSetQOS)(mjob_t *, mqos_t *, int);
+1 -7
View File
@@ -495,7 +495,6 @@ enum {
pSimJobSubmissionPolicy,
pSimNCPolicy,
pUseMachineSpeed,
pUseMachineSpeedForFS,
pUseSystemQueueTime,
pNodeAvailPolicy,
mcoResourceLimitPolicy,
@@ -662,7 +661,6 @@ enum {
pRUProcWeight,
pRUJobWeight,
pUConsWeight,
pUExeTimeWeight,
pURemWeight,
pUPerCWeight,
pXFMinWCLimit,
@@ -700,7 +698,6 @@ enum {
pRPECap,
pRWallTimeCap,
pUConsCap,
pUExeTimeCap,
pURemCap,
pUPerCCap,
pQOSName,
@@ -766,10 +763,7 @@ enum {
pOLDAFSWeight,
pOLDDirectSpecWeight,
pOLDBankServer,
pOLDRMServer,
pNAMaxPS,
pFSSecondaryGroups, /* To enable secondary fairshare group lookups for PBS, HvB */
pIgnPbsGroupList /* ignore the -W group_list parameter for PBS, HvB */
pOLDRMServer
};
#endif /* __M_COMMON_H__ */
-1
View File
@@ -1 +0,0 @@
#define MSCHED_VERSION "3.3.1"
+4 -19
View File
@@ -4,6 +4,7 @@
#ifndef __M_H__
#define __M_H__
#define MSCHED_VERSION "3.2.6p14"
#define MSCHED_NAME "Maui"
#define MSCHED_SNAME "maui"
@@ -11,8 +12,6 @@
#define __M32COMPAT
#endif /* __M32COMPAT */
#include "msched-version.h"
#ifdef __LOCAL
# include "msched-local.h"
#endif /* __LOCAL */
@@ -205,7 +204,6 @@
#define DEFAULT_SRPERIOD mpDay
#define DEFAULT_USEMACHINESPEED FALSE
#define DEFAULT_USEMACHINESPEEDFORFS FALSE
#define DEFAULT_USESYSTEMQUEUETIME ptOFF
#define DEFAULT_JOBPRIOACCRUALPOLICY jpapQueuePolicy
#define DEFAULT_RESOURCEAVAILPOLICY mrapCombined
@@ -1137,8 +1135,6 @@ typedef struct {
void *S; /* resource manager specific data */
void *xd;
mbool_t ASyncJobStart; /* asynchronous job start */
} mrm_t;
enum MClassStateEnum {
@@ -1164,7 +1160,6 @@ typedef struct {
int IsDisabled; /* queue cannot execute jobs */
int DistPolicy;
int NAPolicy;
char **NodeList;
char *OCNodeName; /* overcommit node */
@@ -1274,12 +1269,11 @@ enum MPrioSubComponentEnum {
mpsRUProc,
mpsRUJob,
mpsUCons,
mpsUExeTime,
mpsURem,
mpsUPerC,
mpsUPerC
};
#define MAX_MPRIOSUBCOMPONENT 33
#define MAX_MPRIOSUBCOMPONENT 32
/* fairshare */
@@ -1357,7 +1351,6 @@ typedef struct {
/* booleans */
int UseMachineSpeed;
int UseMachineSpeedForFS;
int UseSystemQueueTime;
int UseCPUTime;
int RejectNegPrioJobs;
@@ -1391,12 +1384,8 @@ typedef struct {
xres_t XRes[MAX_MNODE];
char *Message; /* event messages */
int IgnPbsGroupList; /* Ignore -W group_list parameter for Torque/PBS HvB */
int FSSecondaryGroups; /* To enable secondary fairshare group lookups for PBS, HvB */
} mpar_t;
/* cred */
typedef struct {
@@ -1520,8 +1509,6 @@ typedef struct {
int OType;
} sres_t;
#define srsv_t sres_t
typedef struct {
long Time;
short Type;
@@ -2168,7 +2155,6 @@ typedef struct {
int SPVJobIsPreemptible; /* (config boolean) */
mbool_t EnableEncryption;
mbool_t PercentBasedFS;
char *Argv[MAX_MARG];
@@ -2199,7 +2185,6 @@ typedef struct {
char PartitionFeatureHeader[MAX_MNAME];
int PartitionFeatureIsVisible; /* (boolean) */
int InitialLoad;
int NodeAllocMaxPS;
mgcred_t *DefaultU;
mgcred_t *DefaultG;
View File
+2 -3
View File
@@ -285,9 +285,8 @@ int __MGSSGetToken(
len |= ((size_t) buffer[1]) << 16;
len |= ((size_t) buffer[2]) << 8;
len |= ((size_t) buffer[3]);
tok = calloc(len, 1);
tok = malloc(len);
if (!tok)
{
+16 -2
View File
@@ -63,7 +63,7 @@ int MS3JobSuspend(mjob_t *,mrm_t *,char *,int *);
int MS3JobResume(mjob_t *,mrm_t *,char *,int *);
int MS3JobCheckpoint(mjob_t *,mrm_t *,mbool_t,char *,int *);
int MS3ClusterQuery(mrm_t *,int *,char *,enum MStatusCodeEnum *);
int MS3WorkloadQuery(mrm_t *,int *,enum MStatusCodeEnum *);
int MS3WorkloadQuery(mrm_t *,int *,int *,char *,enum MStatusCodeEnum *);
int MS3QueueQuery(mrm_t *,int *,char *,enum MStatusCodeEnum *);
int MS3JobLoad(char *,void *,mjob_t **,short *,mrm_t *);
int MS3JobUpdate(void *,mjob_t **,short *,mrm_t *);
@@ -1346,6 +1346,8 @@ int MS3WorkloadQuery(
mrm_t *R, /* I */
int *WCount, /* O (optional) */
int *NWCount, /* O (optional) */
char *EMsg, /* O (optional,minsize=MMAX_LINE) */
enum MStatusCodeEnum *SC) /* O (optional) */
{
@@ -1377,7 +1379,7 @@ int MS3WorkloadQuery(
const char *FName = "MS3WorkloadQuery";
#ifndef __MPROD
MDB(1,fS3) MLog("%s(%s,WCount,SC)\n",
MDB(1,fS3) MLog("%s(%s,WCount,NWCount,EMsg,SC)\n",
FName,
(R != NULL) ? R->Name : "NULL");
#endif /* !__MPROD */
@@ -1385,6 +1387,12 @@ int MS3WorkloadQuery(
if (WCount != NULL)
*WCount = 0;
if (NWCount != NULL)
*NWCount = 0;
if (EMsg != NULL)
EMsg[0] = '\0';
if (SC != NULL)
*SC = mscNoError;
@@ -1404,6 +1412,9 @@ int MS3WorkloadQuery(
if (S->WorkloadBuffer == NULL)
{
if (EMsg != NULL)
strcpy(EMsg,MWorkloadErrMsg);
return(FAILURE);
}
} /* END if (MISSET(R->Flags,mrmfLocalQueue) */
@@ -1816,6 +1827,9 @@ int MS3WorkloadQuery(
break;
}
if (NWCount != NULL)
(*NWCount)++;
/* if new job, load data */
#ifdef __M32COMPAT
+20 -28
View File
@@ -470,7 +470,7 @@ int MSUListen(
{
for (S->RemotePort = 10000;S->RemotePort < 20000;S->RemotePort++)
{
sin.sin_port = htons((unsigned short)S->RemotePort);
sin.sin_port = htons((u_short)S->RemotePort);
if (bind(sd,(struct sockaddr *)&sin,sizeof(sin)) == -1)
{
@@ -503,7 +503,7 @@ int MSUListen(
}
else
{
sin.sin_port = htons((unsigned short)S->RemotePort);
sin.sin_port = htons((u_short)S->RemotePort);
if (bind(sd,(struct sockaddr *)&sin,sizeof(sin)) == -1)
{
@@ -956,9 +956,6 @@ int MSUSendData(
#endif /* !__MPROD */
/* initialize */
TSLine[0]='\0';
CKLine[0]='\0';
SHeader[0]='\0';
tmpSBuf[0] = '\0'; /* tmpSBuf is global (not threadsafe) */
@@ -1064,23 +1061,18 @@ int MSUSendData(
default:
{
char *BPtr;
int BSpace;
sptr = S->SBuffer;
S->SBuffer = tmpSBuf;
MUSNInit(&BPtr,&BSpace,tmpSBuf,sizeof(tmpSBuf));
MUSNPrintF(&BPtr,&BSpace,"%s%d ",
sprintf(S->SBuffer,"%s%d ",
MCKeyword[mckStatusCode],
scSUCCESS);
Align = (int)strlen(tmpSBuf) + (int)strlen(MCKeyword[mckArgs]);
Align = (int)strlen(S->SBuffer) + (int)strlen(MCKeyword[mckArgs]);
MUSNPrintF(&BPtr,&BSpace,"%*s%s",
sprintf(S->SBuffer,"%s%*s%s",
S->SBuffer,
16 - (Align % 16),
" ",
MCKeyword[mckData]);
@@ -1102,7 +1094,6 @@ int MSUSendData(
*ptr = tmpStatus[0];
}
}
break;
} /* END switch(S->SocketProtocol) */
@@ -1306,11 +1297,9 @@ int MSUSendData(
if (DoSocketLayerAuth == TRUE)
{
char tmpStr[MMAX_BUFFER];
time(&Now);
sprintf(tmpStr,"%s%ld %s%s",
sprintf(TSLine,"%s%ld %s%s",
MCKeyword[mckTimeStamp],
(long)Now,
MCKeyword[mckAuth],
@@ -1325,7 +1314,7 @@ int MSUSendData(
}
sprintf(TSLine,"%s %s",
tmpStr,
TSLine,
MCKeyword[mckData]);
MSecGetChecksum2(
@@ -1760,7 +1749,8 @@ int MSURecvData(
return(FAILURE);
}
if ((S->RBuffer = (char *)calloc(S->RBufSize + 1, 1)) == NULL)
if ((S->RBuffer = (char *)malloc(S->RBufSize + 1)) == NULL)
{
MDB(1,fSOCK) MLog("ERROR: cannot allocate buffer space (%ld bytes requested) errno: %d (%s)\n",
S->RBufSize,
@@ -1811,7 +1801,8 @@ int MSURecvData(
/* allocate large receive space */
S->RBufSize = MMAX_BUFFER << 4;
if ((S->RBuffer = (char *)calloc(S->RBufSize + 1, 1)) == NULL)
if ((S->RBuffer = (char *)malloc(S->RBufSize + 1)) == NULL)
{
MDB(1,fSOCK) MLog("ERROR: cannot allocate buffer space (%ld bytes requested) errno: %d (%s)\n",
S->RBufSize,
@@ -1967,7 +1958,8 @@ int MSURecvData(
if (S->RBuffer == NULL)
{
/* allocate receive space */
if ((S->RBuffer = (char *)calloc(S->RBufSize + 1, 1)) == NULL)
if ((S->RBuffer = (char *)malloc(S->RBufSize + 1)) == NULL)
{
MDB(1,fSOCK) MLog("ERROR: cannot allocate buffer space (%ld bytes requested) errno: %d (%s)\n",
S->RBufSize,
@@ -2023,8 +2015,6 @@ int MSURecvData(
ptr = tmpLine;
ptr[0] = '\0';
if (TimeLimit != 0)
{
/* allow polling */
@@ -2120,7 +2110,8 @@ int MSURecvData(
return(FAILURE);
}
if ((S->RBuffer = (char *)calloc(S->RBufSize + 1, 1)) == NULL)
if ((S->RBuffer = (char *)malloc(S->RBufSize + 1)) == NULL)
{
MDB(1,fSOCK) MLog("ERROR: cannot allocate buffer space (%ld bytes requested) errno: %d (%s)\n",
S->RBufSize,
@@ -2386,7 +2377,7 @@ int MSURecvData(
{
MSecGetChecksum(
ptr,
strlen(ptr),
(S->RBufSize - (ptr - S->RBuffer)),
CKSum,
NULL,
S->CSAlgo,
@@ -3915,7 +3906,7 @@ int MSUAdjustSBuffer(
if (S->SBIsDynamic == FALSE)
{
ptr = (char *)calloc(NewSize, 1);
ptr = (char *)malloc(NewSize);
memcpy(ptr,S->SBuffer,S->SBufSize);
}
@@ -4051,7 +4042,8 @@ int MSUDup(
}
/* do shallow memcpy first */
S = (msocket_t *)calloc(1,sizeof(msocket_t));
S = (msocket_t *)malloc(sizeof(msocket_t));
memcpy(S,Src,sizeof(msocket_t));
+17 -17
View File
@@ -130,6 +130,7 @@ int MSecMD5GetDigest(char *,int,char *,int,char *,int);
#ifndef __M32COMPAT
int M64Init(
@@ -142,10 +143,10 @@ int M64Init(
M->Is64 = FALSE;
M->INTBITS = M32INTBITS;
M->INTLBITS = M32INTLBITS;
M->INTSIZE = M32INTSIZE;
M->INTSHIFT = M32INTSHIFT;
M->INTBC = M32INTBITS;
M->INTLBC = M32INTLBITS;
M->MIntSize = M32INTSIZE;
M->IntShift = M32INTSHIFT;
}
else
{
@@ -153,10 +154,10 @@ int M64Init(
M->Is64 = TRUE;
M->INTBITS = M64INTBITS;
M->INTLBITS = M64INTLBITS;
M->INTSIZE = M64INTSIZE;
M->INTSHIFT = M64INTSHIFT;
M->INTBC = M64INTBITS;
M->INTLBC = M64INTLBITS;
M->MIntSize = M64INTSIZE;
M->IntShift = M64INTSHIFT;
}
MDB(5,fSTRUCT) MLog("INFO: 64Bit enabled: %s UINT4[%d] UINT8[%d]\n",
@@ -167,6 +168,7 @@ int M64Init(
return(SUCCESS);
} /* END M64Init() */
#endif /* !__M32COMPAT */
@@ -350,7 +352,7 @@ int MSecGetChecksum2(
/* NOTE: merge header and data */
ptr = (char *)calloc(BufSize1 + BufSize2, 1);
ptr = (char *)malloc(BufSize1 + BufSize2);
strcpy(ptr,Buf1);
strcpy(ptr + BufSize1,Buf2);
@@ -378,8 +380,7 @@ int MSecGetChecksum2(
/* NOTE: merge header and data */
ptr = (char *)calloc(BufSize1 + BufSize2, 1);
ptr = (char *)malloc(BufSize1 + BufSize2);
strcpy(ptr,Buf1);
strcpy(ptr + BufSize1,Buf2);
@@ -407,8 +408,7 @@ int MSecGetChecksum2(
/* NOTE: merge header and data */
ptr = (char *)calloc(BufSize1 + BufSize2, 1);
ptr = (char *)malloc(BufSize1 + BufSize2);
strcpy(ptr,Buf1);
strcpy(ptr + BufSize1,Buf2);
@@ -1601,7 +1601,7 @@ int MSecCompress(
unsigned int Key;
unsigned int Size;
unsigned int Pos;
unsigned int Command = 0;
unsigned int Command;
unsigned int X = 0;
unsigned int Y = 9;
unsigned int Z = 3;
@@ -1630,7 +1630,7 @@ int MSecCompress(
if (LocalDstString == NULL)
{
LocalDstString = (char *)calloc(NewLength, 1);
LocalDstString = (char *)malloc(NewLength);
LocalDstSize = NewLength;
}
@@ -1791,7 +1791,7 @@ int MSecDecompress(
else if (DDstBuf != NULL)
{
if ((OutBuf == NULL) &&
((OutBuf = (unsigned char *)calloc(MMAX_BUFFER, 1)) == NULL))
((OutBuf = (unsigned char *)malloc(MMAX_BUFFER)) == NULL))
{
return(FAILURE);
}
@@ -1816,7 +1816,7 @@ int MSecDecompress(
if (tmpBuf == NULL)
{
if ((tmpBuf = (unsigned char *)calloc(NewLength, 1)) == NULL)
if ((tmpBuf = (unsigned char *)malloc(NewLength)) == NULL)
{
return(FAILURE);
}
+6 -3
View File
@@ -43,7 +43,8 @@ comm_thread_t* comm_thread_new(
{
comm_thread_t* thread;
if ((thread = (comm_thread_t *)calloc(1,sizeof(comm_thread_t))) == NULL)
if ((thread = (comm_thread_t *)malloc(sizeof(comm_thread_t))) == NULL)
{
return(NULL);
}
@@ -52,7 +53,8 @@ comm_thread_t* comm_thread_new(
thread->read_handler = NULL;
thread->close_handler = NULL;
thread->error_handler = NULL;
thread->connection = (communication_t **)calloc(max_connections, sizeof(void*));
thread->connection = (communication_t **)malloc(max_connections * sizeof(void*));
thread->connections = 0;
thread->max_connections = max_connections;
@@ -242,7 +244,8 @@ communication_t *communication_new(
{
communication_t *comm;
if ((comm = (communication_t *)calloc(1, sizeof(communication_t))) == NULL)
if ((comm = (communication_t *)malloc(sizeof(communication_t))) == NULL)
{
return(NULL);
}
+2 -1
View File
@@ -632,7 +632,8 @@ int MXMLToXString(
if (*Buf == NULL)
{
NewSize = MMAX_BUFFER;
if ((*Buf = (char *)calloc(NewSize, 1)) == NULL)
if ((*Buf = (char *)malloc(NewSize)) == NULL)
{
/* cannot allocate buffer */
+2 -2
View File
@@ -1,5 +1,5 @@
# Makefile for libmcom
# Copyright 1999 - 2010 Cluster Resources, Inc, All Rights Reserved
# Copyright 1999 - 2005 Cluster Resources, Inc, All Rights Reserved
TOP =../..
BIN =$(TOP)/bin/
@@ -13,7 +13,7 @@ SHELL =/bin/sh
LP =-L$(LIB) $(SCHEDLP) $(MXLP) $(REGEXLP)
IP =$(SCHEDIP) $(REGEXIP) $(MXIP)
INCS =$(INC)moab.h $(INC)moab-proto.h
DEFS =-D$(OPSYS) $(OSDEF) $(MXDEF) $(REGEXDEF) $(SECDEF) $(DAEMONDEF)
DEFS =-D$(OPSYS) $(OSDEF) $(MXDEF) $(REGEXDEF) $(SECDEF)
LIBMCOM =libmcom.a
LOBJECTS =MSU.o MSec.o MS3I.o MXML.o MConst.o MTComm.o MComm.o
+53
View File
@@ -0,0 +1,53 @@
# Makefile for GridSuite: MCom 4.2.2
# Copyright 1999 - 2005 Cluster Resources, Inc, All Rights Reserved
prefix=$(ROOT)@prefix@
exec_prefix=@exec_prefix@
bindir=@bindir@
sbindir=@sbindir@
sysconfdir=@sysconfdir@
localstatedir=@localstatedir@
libdir=@libdir@
includedir=@includedir@
mandir=@mandir@
CC=@CC@
CFLAGS=@CFLAGS@
SEED=@seed@
moab_defs=@moab_defs@ -D__MGRIDENABLE
moab_ip=@moab_ip@
moab_lp=@moab_lp@
moab_libs=@moab_libs@
LD=$(CC)
CP=cp
RM=rm -f
AR=ar rcs
TOP =../..
BIN =$(TOP)/bin
INC =$(TOP)/include
LIB =$(TOP)/lib
LP =-L$(LIB) $(moab_lp)
IP =-I$(INC) $(moab_ip)
DEFS =$(moab_defs)
LIBS = $(moab_libs)
LIBMCOM =$(LIB)/libmcom.a
OBJS =MSU.o MSec.o MXML.o MSSSI.o MConst.o MComm.o MTComm.o
DEPS =$(INC)/moab.h $(INC)/moab-proto.h $(INC)/mcom.h $(INC)/mg2.h
all: $(LIBMCOM)
.c.o: $(DEPS)
$(CC) $(CFLAGS) $(IP) $(DEFS) -c $<
$(LIBMCOM): $(OBJS)
$(AR) $(LIBMCOM) $(OBJS)
clean:
$(RM) *.o $(LIBMCOM)
+3 -3
View File
@@ -1,10 +1,10 @@
VERSION 3.3.1
VERSION 3.2.6p14
PACKAGE moab
AUTHOR Cluster Resources, Inc
FILETYPE Module
COPYRIGHT Copyright (C) 1999-2010 Cluster Resources, Inc
COPYRIGHT Copyright (C) 1999-2005 Cluster Resources, Inc
DISCLAIMER
-----------------------------------------------------------------------------
@@ -13,7 +13,7 @@ Moab Scheduling System - End User Open Source License
This software is based on the Moab Scheduling System which was created by
Cluster Resources, Inc.
Copyright (C) 1999-2010 Cluster Resources, Inc., all rights reserved.
Copyright (C) 1999-2005 Cluster Resources, Inc., all rights reserved.
Moab Scheduling System is a trademark of Cluster Resources, Inc.
+1 -1
View File
@@ -13,7 +13,7 @@ Moab Workload Manager - End User License
This product was created by Cluster Resources, Inc. and is protected by
copyright and patent law.
Copyright (C) 1999-2010 Cluster Resources, Inc., all rights reserved.
Copyright (C) 1999-2005 Cluster Resources, Inc., all rights reserved.
Moab Workload Manager, Moab Cluster Scheduler and Moab Scheduler
are trademarks of Cluster Resources, Inc.
+9 -8
View File
@@ -201,7 +201,8 @@ char *MACLShow(
case mcmpSNE:
default:
sprintf(&ACLString[strlen(ACLString)],"%s%s%s",
sprintf(ACLString,"%s%s%s%s",
ACLString,
MComp[cindex],
ACL.Name,
ModString);
@@ -219,14 +220,16 @@ char *MACLShow(
{
/* human readable */
sprintf(&ACLString[strlen(ACLString)],"%s%s%s",
sprintf(ACLString,"%s%s%s%s",
ACLString,
MComp[cindex],
MULToTString(ACL.Value),
ModString);
}
else
{
sprintf(&ACLString[strlen(ACLString)],"%s%ld%s",
sprintf(ACLString,"%s%s%ld%s",
ACLString,
MComp[cindex],
ACL.Value,
ModString);
@@ -363,9 +366,7 @@ int MACLLoadConfig(
ACL[ACLStart + AIndex].Affinity = nmPositiveAffinity;
tail = ptr + strlen(ptr) - 1;
if (strchr("-+=%^!*",*tail) != NULL)
for (tail = ptr + strlen(ptr) - 1;strchr("-+=%^!*",*tail);tail++)
{
switch(*tail)
{
@@ -422,8 +423,8 @@ int MACLLoadConfig(
/* NO-OP */
break;
} /* END switch(*tail) */
} /* END if (tail) */
} /* END switch(*tail) */
} /* END for (tail) */
/* extract modifier */
+57 -160
View File
@@ -457,7 +457,7 @@ int MAMAllocJDebit(
/* PROCCOUNT -> PROCS (QBank 2.9) */
/* CLASS supported in 2.9 */
sprintf(AMISBuffer,"COMMAND=make_withdrawal AUTH=%s MACHINE=%s%s%s USER=%s WCTIME=%ld PROCCOUNT=%d PROCCRATE=%.2lf %sCLASS=%s NODETYPE=%s JOBID=%s JOBTYPE=job NODES=%d",
sprintf(AMISBuffer,"COMMAND=make_withdrawal AUTH=%s MACHINE=%s%s%s USER=%s WCTIME=%ld PROCCOUNT=%d PROCCRATE=%.2lf %sCLASS=%s NODETYPE=%s JOBID=%s JOBTYPE=job",
MSched.Admin1User[0],
R->Name,
(AccountName[0] != '\0') ? " ACCOUNT=" : "",
@@ -469,8 +469,7 @@ int MAMAllocJDebit(
QOSString,
(J->Cred.C != NULL) ? J->Cred.C->Name : DEFAULT,
NodeType,
J->Name,
J->NodeCount);
J->Name);
rc = MAMQBDoCommand(
A,
@@ -540,7 +539,7 @@ int MAMAllocJDebit(
if (J->Cred.Q != NULL)
{
AE = NULL;
MXMLCreateE(&AE,(char *)MS3JobAttr[A->Version][mjaQOSReq]);
MXMLCreateE(&AE,(char *)MS3JobAttr[A->Version][mjaQOS]);
MXMLSetVal(AE,(void *)J->Cred.Q->Name,mdfString);
MXMLAddE(JE,AE);
}
@@ -577,22 +576,6 @@ int MAMAllocJDebit(
MXMLAddE(JE,AE);
}
if (J->StartTime > 0)
{
AE = NULL;
MXMLCreateE(&AE,(char *)MS3JobAttr[A->Version][mjaStartTime]);
MXMLSetVal(AE,&J->StartTime,mdfLong);
MXMLAddE(JE,AE);
}
if (J->CompletionTime > 0)
{
AE = NULL;
MXMLCreateE(&AE,"EndTime"); /* change to (char *)MS3JobAttr[A->Version][mjaCompletion]); */
MXMLSetVal(AE,&J->CompletionTime,mdfLong);
MXMLAddE(JE,AE);
}
if (J->Cred.C != NULL)
{
AE = NULL;
@@ -700,11 +683,9 @@ int MAMAllocRDebit(
double PCRate;
mrm_t *RM = NULL;
const char *FName = "MAMAllocRDebit";
MDB(3,fAM) MLog("%s(%s,RIndex,SC,ErrMsg)\n",
MDB(3,fAM) MLog("%s(%s,SC,ErrMsg)\n",
FName,
(R != NULL) ? R->Name : "NULL");
@@ -790,7 +771,7 @@ int MAMAllocRDebit(
case mamtQBANK:
sprintf(AMISBuffer,"COMMAND=make_withdrawal AUTH=%s MACHINE=%s ACCOUNT=%s USER=%s WCTIME=%ld PROCCRATE=%.2lf PROCCOUNT=%d QOS=%s CLASS=%s NODETYPE=%s JOBID=%s JOBTYPE=res NODES=%d",
sprintf(AMISBuffer,"COMMAND=make_withdrawal AUTH=%s MACHINE=%s ACCOUNT=%s USER=%s WCTIME=%ld PROCCRATE=%.2lf PROCCOUNT=%d QOS=%s CLASS=%s NODETYPE=%s JOBID=%s JOBTYPE=res",
MSched.Admin1User[0],
MRM[0].Name,
AName,
@@ -801,8 +782,7 @@ int MAMAllocRDebit(
DEFAULT,
"DEFAULT",
NodeType,
R->Name,
R->NodeCount);
R->Name);
rc = MAMQBDoCommand(
AM,
@@ -846,138 +826,59 @@ int MAMAllocRDebit(
case mamtGOLD:
{
mxml_t *JE = NULL;
char *RspBuf = NULL;
mxml_t *RE;
mxml_t *DE;
mxml_t *AE;
long tmpL;
/* create request string, populate S->SE */
RE = NULL;
MXMLCreateE(&RE,MSON[msonRequest]);
MXMLSetAttr(RE,(char *)MSAN[msanAction],(void *)"Charge",mdfString);
MS3SetObject(RE,"Job",NULL);
DE = NULL;
MXMLCreateE(&DE,MSON[msonData]);
MXMLAddE(RE,DE);
JE = NULL;
MXMLCreateE(&JE,"Job");
MXMLAddE(DE,JE);
AE = NULL;
MXMLCreateE(&AE,"JobId");
MXMLSetVal(AE,(void *)R->Name,mdfString);
MXMLAddE(JE,AE);
if (R->U != NULL)
{
AE = NULL;
MXMLCreateE(&AE,(char *)MS3JobAttr[AM->Version][mjaUser]);
MXMLSetVal(AE,(void *)R->U->Name,mdfString);
MXMLAddE(JE,AE);
}
mxml_t *E = NULL;
mxml_t *C1 = NULL;
mxml_t *C2 = NULL;
mxml_t *A = NULL;
MXMLCreateE(&E,"AllocationManagerRequests");
MXMLSetAttr(E,"xmlns","http://www.scidac.org/ScalableSystems/AllocationManager",mdfString);
MXMLCreateE(&C1,"createDebitRequest");
MXMLAddE(E,C1);
MXMLCreateE(&C2,"set");
MXMLAddE(C1,C2);
MXMLCreateE(&A,"name");
MXMLSetVal(A,(void *)R->Name,mdfString);
MXMLAddE(C2,A);
A = NULL;
if (R->A != NULL)
{
AE = NULL;
MXMLCreateE(&AE,(char *)MS3JobAttr[AM->Version][mjaAccount]);
MXMLSetVal(AE,(void *)R->A->Name,mdfString);
MXMLAddE(JE,AE);
MXMLCreateE(&A,"account");
MXMLSetVal(A,(void *)R->A->Name,mdfString);
MXMLAddE(C2,A);
A = NULL;
}
MXMLToString(E,AMISBuffer,sizeof(AMISBuffer),NULL,TRUE);
rc = MAMQBDoCommand(
AM,
0,
AMISBuffer,
(void **)&E,
&tmpSC,
AMIRBuffer);
if (MRM[0].Name[0] != '\0')
if (E != NULL)
MXMLDestroyE(&E);
if (rc == FAILURE)
{
AE = NULL;
MXMLCreateE(&AE,"MachineName");
MXMLSetVal(AE,(void *)MRM[0].Name,mdfString);
MXMLAddE(JE,AE);
}
if (R->AllocPC > 0)
{
AE = NULL;
MXMLCreateE(&AE,(char *)MS3ReqAttr[AM->Version][mrqaTCReqMin]);
MXMLSetVal(AE,(void *)&R->AllocPC,mdfInt);
MXMLAddE(JE,AE);
}
if (R->DRes.Mem > 0)
{
int Memory;
Memory = R->TaskCount * R->DRes.Mem;
AE = NULL;
MXMLCreateE(&AE,"Memory");
MXMLSetVal(AE,(void *)&Memory,mdfInt);
MXMLAddE(JE,AE);
}
AE = NULL;
MXMLCreateE(&AE,(char *)MS3JobAttr[AM->Version][mjaAWDuration]);
MXMLSetVal(AE,(void *)&WCTime,mdfLong);
MXMLAddE(JE,AE);
if (NodeType[0] != '\0')
{
AE = NULL;
MXMLCreateE(&AE,"NodeType");
MXMLSetVal(AE,(void *)NodeType,mdfString);
MXMLAddE(JE,AE);
}
AE = NULL;
MXMLCreateE(&AE,"Type");
MXMLSetVal(AE,(void *)"Reservation",mdfString);
MXMLAddE(JE,AE);
/* submit request */
{
enum MHoldReasonEnum tRIndex;
if (MAMGoldDoCommand(RE,&AM->P,&tRIndex,ErrMsg) == FAILURE)
{
MDB(2,fAM) MLog("ALERT: cannot debit allocation for job\n");
if (RIndex != NULL)
*RIndex = tRIndex;
if ((AM->JFAction == mamjfaNONE) && (tRIndex != mhrNoFunds))
{
return(SUCCESS);
}
*RIndex = mhrAMFailure;
return(FAILURE);
}
} /* END BLOCK */
/* charge successful */
MSysEMSubmit(
&MSched.EM,
(char *)MS3CName[mpstAM],
"rsvalloccharge",
R->Name);
MUFree(&RspBuf);
} /* END BLOCK (GOLD) */
return(SUCCESS);
/*NOTREACHED*/
break;
case mamtNONE:
@@ -1183,7 +1084,7 @@ int MAMAllocJReserve(
case mamtQBANK:
sprintf(AMISBuffer,"COMMAND=make_reservation AUTH=%s MACHINE=%s%s%s USER=%s WCLIMIT=%ld PROCCOUNT=%d %sCLASS=%s NODETYPE=%s TYPE=%s JOBID=%s JOBTYPE=%s NODES=%d",
sprintf(AMISBuffer,"COMMAND=make_reservation AUTH=%s MACHINE=%s%s%s USER=%s WCLIMIT=%ld PROCCOUNT=%d %sCLASS=%s NODETYPE=%s TYPE=%s JOBID=%s JOBTYPE=%s",
MSched.Admin1User[0],
RM->Name,
(AccountName[0] != '\0') ? " ACCOUNT=" : "",
@@ -1196,8 +1097,7 @@ int MAMAllocJReserve(
NodeType,
AM->ClientName,
J->Name,
(TestAlloc == TRUE) ? "tempjob" : "job",
J->NodeCount);
(TestAlloc == TRUE) ? "tempjob" : "job");
rc = MAMQBDoCommand(
AM,
@@ -1311,7 +1211,7 @@ int MAMAllocJReserve(
if (J->Cred.Q != NULL)
{
AE = NULL;
MXMLCreateE(&AE,(char *)MS3JobAttr[AM->Version][mjaQOSReq]);
MXMLCreateE(&AE,(char *)MS3JobAttr[AM->Version][mjaQOS]);
MXMLSetVal(AE,(void *)J->Cred.Q->Name,mdfString);
MXMLAddE(JE,AE);
}
@@ -2313,7 +2213,8 @@ int MAMConfigShow(
if (tmpVal[0] != '\0')
{
sprintf(&tmpLine[strlen(tmpLine)]," %s=%s",
sprintf(tmpLine,"%s %s=%s",
tmpLine,
MAMAttr[aindex],
tmpVal);
}
@@ -2890,9 +2791,6 @@ int MAMQBDoCommand(
(A != NULL) ? A->Name : "NULL",
CmdIndex,
Transaction);
if (E != NULL)
*E = NULL;
if ((A == NULL) ||
((A->Type != mamtQBANK) && (A->Type != mamtGOLD)))
@@ -3913,7 +3811,7 @@ int MAMAllocRReserve(
case mamtQBANK:
sprintf(Line,"COMMAND=make_reservation AUTH=%s MACHINE=%s ACCOUNT=%s USER=%s WCLIMIT=%ld PROCCOUNT=%d QOS=%s CLASS=%s NODETYPE=%s TYPE=%s JOBID=%s NODES=%d",
sprintf(Line,"COMMAND=make_reservation AUTH=%s MACHINE=%s ACCOUNT=%s USER=%s WCLIMIT=%ld PROCCOUNT=%d QOS=%s CLASS=%s NODETYPE=%s TYPE=%s JOBID=%s",
MSched.Admin1User[0],
MRM[0].Name,
AName,
@@ -3924,8 +3822,7 @@ int MAMAllocRReserve(
DEFAULT,
NodeType,
MSCHED_SNAME,
ResName,
NodeCount);
ResName);
rc = MAMQBDoCommand(A,0,Line,NULL,&StatusCode,Response);
+2
View File
@@ -80,6 +80,8 @@ int MAcctLoadCP(
return(FAILURE);
}
MXMLCreateE(&E,(char *)MXO[mxoAcct]);
MXMLFromString(&E,ptr,NULL,NULL);
MOFromXML((void *)A,mxoAcct,E);
+19 -10
View File
@@ -836,13 +836,15 @@ int MBFGetWindow(
{
if ((N->State != mnsIdle) && (N->State != mnsActive))
{
sprintf(&Msg[strlen(Msg)],"node %s is unavailable (state '%s')\n",
sprintf(Msg,"%snode %s is unavailable (state '%s')\n",
Msg,
N->Name,
MNodeState[N->State]);
}
else
{
sprintf(&Msg[strlen(Msg)],"node %s is unavailable (expected state '%s')\n",
sprintf(Msg,"%snode %s is unavailable (expected state '%s')\n",
Msg,
N->Name,
MNodeState[N->EState]);
}
@@ -857,7 +859,8 @@ int MBFGetWindow(
N->Name);
if (Msg != NULL)
sprintf(&Msg[strlen(Msg)],"node %s is unavailable (partition '%s')\n",
sprintf(Msg,"%snode %s is unavailable (partition '%s')\n",
Msg,
N->Name,
MPar[N->PtIndex].Name);
@@ -872,7 +875,8 @@ int MBFGetWindow(
if (Msg != NULL)
{
sprintf(&Msg[strlen(Msg)],"node %s is unavailable (%s)\n",
sprintf(Msg,"%snode %s is unavailable (%s)\n",
Msg,
N->Name,
MAllocRejType[RIndex]);
}
@@ -900,7 +904,8 @@ int MBFGetWindow(
if (Msg != NULL)
{
sprintf(&Msg[strlen(Msg)],"node %s does not meet requirements (%s)\n",
sprintf(Msg,"%snode %s does not meet requirements (%s)\n",
Msg,
N->Name,
MAllocRejType[RIndex]);
}
@@ -923,7 +928,8 @@ int MBFGetWindow(
if (Msg != NULL)
{
sprintf(&Msg[strlen(Msg)],"node %s is blocked immediately\n",
sprintf(Msg,"%snode %s is blocked immediately\n",
Msg,
N->Name);
}
@@ -940,14 +946,16 @@ int MBFGetWindow(
{
if (AvailableTime < (MAX_MTIME >> 1))
{
sprintf(&Msg[strlen(Msg)],"node %s is blocked by reservation %s in %s\n",
sprintf(Msg,"%snode %s is blocked by reservation %s in %s\n",
Msg,
N->Name,
BRes,
MULToTString(AvailableTime));
}
else
{
sprintf(&Msg[strlen(Msg)],"node %sx%d is available with no timelimit\n",
sprintf(Msg,"%snode %sx%d is available with no timelimit\n",
Msg,
N->Name,
TC);
}
@@ -959,7 +967,8 @@ int MBFGetWindow(
{
if (Msg != NULL)
{
sprintf(&Msg[strlen(Msg)],"node %sx%d is available with no timelimit\n",
sprintf(Msg,"%snode %sx%d is available with no timelimit\n",
Msg,
N->Name,
TC);
}
@@ -1393,7 +1402,7 @@ int MBFGreedy(
sindex = 0;
scount = 0;
memset(LBFQueue,0,sizeof(LBFQueue));
memcpy(LBFQueue,0,sizeof(LBFQueue));
memset(BFIndex,0,sizeof(BFIndex));
SPC = 0;
+1 -1
View File
@@ -1493,7 +1493,7 @@ int MCPLoadSysStats(
/* LABL TME PHA PHB ITM CT SJ MSA MSD NJA JAC MXF MB MQT TXF TB TQT PSR PSD PSU JE SPH WEF WIT */
sscanf(Line,"%s %ld %lf %lf %ld %d %d %lf %lf %lf %lf %lf %d %lu %lf %d %lu %lf %lf %lf %d %lf %lf %d\n",
sscanf(Line,"%s %ld %lf %lf %ld %d %d %lf %lf %lf %lf %lf %d %ld %lf %d %ld %lf %lf %lf %d %lf %lf %d\n",
tmpName,
&CkTime,
&tmpS.TotalPHAvailable,
+4 -9
View File
@@ -19,7 +19,6 @@ extern const char *MJobFlags[];
extern const char *MClassAttr[];
extern const char *MCredAttr[];
extern const char *MXO[];
extern const char *MNAccessPolicy[];
@@ -319,7 +318,8 @@ int MClassShow(
(tmpLString[0] != '\0') &&
strcmp(tmpLString,NONE))
{
sprintf(&tmpLine[strlen(tmpLine)]," %s=%s",
sprintf(tmpLine,"%s %s=%s",
tmpLine,
MClassAttr[ClAList[aindex]],
tmpLString);
}
@@ -332,7 +332,8 @@ int MClassShow(
if ((MCredAToString((void *)C,mxoClass,CAList[aindex],tmpLString,mdfString) == SUCCESS) &&
(tmpLString[0] != '\0'))
{
sprintf(&tmpLine[strlen(tmpLine)]," %s=%s",
sprintf(tmpLine,"%s %s=%s",
tmpLine,
MCredAttr[CAList[aindex]],
tmpLString);
}
@@ -408,12 +409,6 @@ int MClassProcessConfig(
switch(aindex)
{
case mclaNAPolicy:
C->NAPolicy = MUGetIndex(ValLine,MNAccessPolicy,FALSE,0);
break;
case mclaOCNode:
case mclaDefReqFeature:
case mclaMaxProcPerNode:
-7
View File
@@ -1563,7 +1563,6 @@ int MCfgSetVal(
case mcoJobFBAction:
case mcoMailAction:
case pAdminEAction:
case pAdminEInterval:
case pCheckPointFile:
case pCheckPointInterval:
case pCheckPointExpirationTime:
@@ -1580,7 +1579,6 @@ int MCfgSetVal(
case pProcSpeedFeatureHeader:
case pNodeTypeFeatureHeader:
case pPartitionFeatureHeader:
case pNAMaxPS:
case pNAPolicy:
case pSchedMode:
case pClientTimeout:
@@ -1697,7 +1695,6 @@ int MCfgSetVal(
case pJobSizePolicy:
case pJobNodeMatch:
case pUseMachineSpeed:
case pUseMachineSpeedForFS:
case pNodeAllocationPolicy:
case pBFMetric:
case mcoAdminMinSTime:
@@ -1715,8 +1712,6 @@ int MCfgSetVal(
case pSystemMaxJobProc:
case pSystemMaxJobTime:
case pSystemMaxJobPS:
case pIgnPbsGroupList:
case pFSSecondaryGroups:
MParProcessOConfig(P,PIndex,val,valf,valp,valpa);
@@ -1757,7 +1752,6 @@ int MCfgSetVal(
case pUConsWeight:
case pURemWeight:
case pUPerCWeight:
case pUExeTimeWeight:
case pServCap:
case pTargCap:
case pCredCap:
@@ -1791,7 +1785,6 @@ int MCfgSetVal(
case pUConsCap:
case pURemCap:
case pUPerCCap:
case pUExeTimeCap:
case pXFMinWCLimit:
case pFSPolicy:
case pFSInterval:
+10 -19
View File
@@ -441,7 +441,6 @@ const char *MFSAttr[] = {
const char *MRMAttr[] = {
NONE,
"AUTHTYPE",
"ASYNCJOBSTART",
"CONFIGFILE",
"CSALGO",
"CSKEY",
@@ -579,7 +578,6 @@ const char *MClassAttr[] = {
"DEFAULT.FEATURES",
"HOSTLIST",
"NAME",
"NODEACCESSPOLICY",
"MAXPROCPERNODE",
"OCDPROCFACTOR",
"STATE",
@@ -810,7 +808,6 @@ const char *MJobAttr[] = {
const char *MRMXAttr[] = {
NONE,
"ADVRES",
"DDISK",
"DISTPOLICY",
"DMEM",
"FLAGS",
@@ -1009,7 +1006,7 @@ const char *MBFMPolicy[] = {
"SECONDS",
NULL };
const char *MJSPolicy[] = { "MINPROC", "MAXPROC", "NDMAXPROC", NULL };
const char *MJSPolicy[] = { "MINPROC", "MAXPROC", "NDMAXPROC", NULL };
const char *MResPolicy[] = { "DEFAULT", "HIGHEST", "CURRENTHIGHEST", "NEVER" };
const char *MHoldType[] = { NONE, "User", "System", "Batch", "Defer", "All", NULL };
const char *MComType[] = { "ROUNDROBIN", "BROADCAST", "TREE", "MASTERSLAVE", NULL };
@@ -1280,12 +1277,6 @@ const char *MTimePolicy[] = {
const mcfg_t MCfg[] = {
{ NONE, pParamNONE, mdfString, -1, NULL },
{ "LOGLEVEL", pLogLevel, mdfInt, mxoSched, NULL },
{ "LOGDIR", pSchedLogDir, mdfString, mxoSched, NULL },
{ "LOGFACILITY", pLogFacility, mdfStringArray, mxoSched, NULL },
{ "LOGFILEMAXSIZE", pLogFileMaxSize, mdfInt, mxoSched, NULL },
{ "LOGFILE", pSchedLogFile, mdfString, mxoSched, NULL },
{ "LOGFILEROLLDEPTH", pLogFileRollDepth, mdfInt, mxoSched, NULL },
{ "ACCOUNTCAP", pCACap, mdfInt, mxoPar, NULL },
{ "ACCOUNTWEIGHT", pCAWeight, mdfInt, mxoPar, NULL },
{ "ADMIN1", mcoAdmin1Users, mdfStringArray, mxoSched, NULL },
@@ -1378,7 +1369,6 @@ const mcfg_t MCfg[] = {
{ "FSQOSCAP", pFQCap, mdfInt, mxoPar, NULL },
{ "FSQOSWEIGHT", pFQWeight, mdfInt, mxoPar, NULL },
{ "FSQOSWEIGHT", pOLDFSQWeight, mdfInt, mxoPar, NULL },
{ "FSSECONDARYGROUPS", pFSSecondaryGroups, mdfString, mxoPar, NULL },
{ "FSUSERCAP", pFUCap, mdfInt, mxoPar, NULL },
{ "FSUSERWEIGHT", pFUWeight, mdfInt, mxoPar, NULL },
{ "FSUSERWEIGHT", pOLDFSUWeight, mdfInt, mxoPar, NULL },
@@ -1386,7 +1376,6 @@ const mcfg_t MCfg[] = {
{ "GFSWEIGHT", pOLDGFSWeight, mdfInt, mxoPar, NULL },
{ "GROUPCAP", pCGCap, mdfInt, mxoPar, NULL },
{ "GROUPWEIGHT", pCGWeight, mdfInt, mxoPar, NULL },
{ "IGNPBSGROUPLIST", pIgnPbsGroupList, mdfString, mxoPar, NULL },
{ "JOBAGGREGATIONTIME", pJobAggregationTime, mdfString, mxoSched, NULL },
{ "JOBMAXOVERRUN", pJobMaxOverrun, mdfString, mxoSched, NULL },
{ "JOBMAXSTARTTIME", pMaxJobStartTime, mdfString, mxoPar, NULL },
@@ -1397,6 +1386,12 @@ const mcfg_t MCfg[] = {
{ "JOBSIZEPOLICY", pJobSizePolicy, mdfString, mxoPar, NULL },
{ "JOBSYNCTIME", pJobSyncDeadline, mdfString, mxoSched, NULL },
{ "LOCKFILE", pSchedLockFile, mdfString, mxoSched, NULL },
{ "LOGDIR", pSchedLogDir, mdfString, mxoSched, NULL },
{ "LOGFACILITY", pLogFacility, mdfStringArray, mxoSched, NULL },
{ "LOGFILEMAXSIZE", pLogFileMaxSize, mdfInt, mxoSched, NULL },
{ "LOGFILE", pSchedLogFile, mdfString, mxoSched, NULL },
{ "LOGFILEROLLDEPTH", pLogFileRollDepth, mdfInt, mxoSched, NULL },
{ "LOGLEVEL", pLogLevel, mdfInt, mxoSched, NULL },
{ "MACHINECONFIGFILE", pMachineConfigFile, mdfString, mxoSched, NULL },
{ "MAILPROGRAM", mcoMailAction, mdfString, mxoSched, NULL },
{ "MAXJOBPERACCOUNTCOUNT", pHMaxJobPerAccountCount, mdfInt, mxoSched, NULL },
@@ -1436,7 +1431,6 @@ const mcfg_t MCfg[] = {
{ "MINADMINSTIME", mcoAdminMinSTime, mdfString, mxoSched, NULL },
{ "MINDISPATCHTIME", pMinDispatchTime, mdfString, mxoSched, NULL },
{ "NODEACCESSPOLICY", pNAPolicy, mdfString, mxoSched, NULL },
{ "NODEALLOCMAXPS", pNAMaxPS, mdfString, mxoSched, NULL },
{ "NODEALLOCATIONPOLICY", pNodeAllocationPolicy, mdfString, mxoPar, NULL },
{ "NODECAP", pRNodeCap, mdfInt, mxoPar, NULL },
{ "NODECPUOVERCOMMITFACTOR", pNodeCPUOverCommitFactor, mdfDouble, mxoSched, NULL },
@@ -1601,9 +1595,9 @@ const mcfg_t MCfg[] = {
{ "STEPCOUNT", pSchedStepCount, mdfInt, mxoSched, NULL },
{ "SWAPCAP", pRSwapCap, mdfInt, mxoPar, NULL },
{ "SWAPWEIGHT", pRSwapWeight, mdfInt, mxoPar, NULL },
{ "SYSTEMMAXJOBWALLTIME", pSystemMaxJobTime, mdfString, mxoPar, NULL },
{ "SYSTEMMAXPROCPERJOB", pSystemMaxJobProc, mdfInt, mxoPar, NULL },
{ "SYSTEMMAXPROCSECONDPERJOB", pSystemMaxJobPS, mdfInt, mxoPar, NULL },
{ "SYSTEMMAXJOBWALLTIME", pSystemMaxJobTime, mdfString, mxoSched, NULL },
{ "SYSTEMMAXPROCPERJOB", pSystemMaxJobProc, mdfInt, mxoSched, NULL },
{ "SYSTEMMAXPROCSECONDPERJOB", pSystemMaxJobPS, mdfInt, mxoSched, NULL },
{ "TARGETCAP", pTargCap, mdfInt, mxoPar, NULL },
{ "TARGETQUEUETIMECAP", pTQTCap, mdfInt, mxoPar, NULL },
{ "TARGETQUEUETIMEWEIGHT", pTQTWeight, mdfInt, mxoPar, NULL },
@@ -1619,15 +1613,12 @@ const mcfg_t MCfg[] = {
{ "UFSWEIGHT", pOLDUFSWeight, mdfInt, mxoPar, NULL },
{ "UJOBWEIGHT", pRUJobWeight, mdfInt, mxoPar, NULL },
{ "UPROCWEIGHT", pRUProcWeight, mdfInt, mxoPar, NULL },
{ "USAGEEXECUTIONTIMECAP", pUExeTimeCap, mdfInt, mxoPar, NULL },
{ "USAGEEXECUTIONTIMEWEIGHT", pUExeTimeWeight, mdfInt, mxoPar, NULL },
{ "USAGECAP", pUsageCap, mdfInt, mxoPar, NULL },
{ "USAGEWEIGHT", pUsageWeight, mdfString, mxoPar, NULL },
{ "USECPUTIME", pUseCPUTime, mdfString, mxoPar, NULL },
{ "USEJOBREGEX", mcoUseJobRegEx, mdfString, mxoSched, NULL },
{ "USELOCALMACHINEPRIORITY", pUseLocalMachinePriority, mdfString, mxoSched, NULL },
{ "USEMACHINESPEED", pUseMachineSpeed, mdfString, mxoSched, NULL },
{ "USEMACHINESPEEDFORFS", pUseMachineSpeedForFS, mdfString, mxoSched, NULL },
{ "USERCAP", pCUCap, mdfInt, mxoPar, NULL },
{ "USERWEIGHT", pCUWeight, mdfInt, mxoPar, NULL },
{ "USESYSLOG", mcoUseSyslog, mdfString, mxoSched, NULL },
+121 -120
View File
@@ -40,10 +40,9 @@ char *__MCredShowLimit(mpu_t *,int,int,int);
int MCredLoadConfig(
int OIndex,
char *CName,
char *ABuf,
char *EMsg)
int OIndex, /* I */
char *CName, /* I */
char *ABuf) /* I (optional) */
{
char IndexName[MAX_MNAME];
@@ -58,6 +57,11 @@ int MCredLoadConfig(
mfs_t *CFSPtr = NULL;
mcredl_t *CLPtr = NULL;
/* FORMAT: <KEY>=<VAL>[<WS><KEY>=<VAL>]... */
/* <VAL> -> <ATTR>=<VAL>[:<ATTR>=<VAL>]... */
/* load all/specified cred config info */
head = (ABuf != NULL) ? ABuf : MSched.ConfigBuffer;
if (head == NULL)
@@ -1167,28 +1171,18 @@ int MCredProcessConfig(
case mcaMaxIJob:
if (L->IP == NULL)
{
L->IP = (mpu_t *)calloc(1,sizeof(mpu_t));
}
if (L->IP == NULL)
break;
if (L->IP != NULL)
{
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxJob][0],
&L->IP->HLimit[mptMaxJob][0]);
}
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxJob][0],
&L->IP->HLimit[mptMaxJob][0]);
break;
case mcaMaxINode:
if (L->IP == NULL)
{
L->IP = (mpu_t *)calloc(1,sizeof(mpu_t));
}
if (L->IP != NULL)
{
__MCredParseLimit(
@@ -1201,87 +1195,62 @@ int MCredProcessConfig(
case mcaMaxIPE:
if (L->IP == NULL)
{
L->IP = (mpu_t *)calloc(1,sizeof(mpu_t));
}
if (L->IP == NULL)
break;
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxPE][0],
&L->IP->HLimit[mptMaxPE][0]);
if (L->IP != NULL)
{
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxPE][0],
&L->IP->HLimit[mptMaxPE][0]);
}
break;
case mcaMaxIProc:
if (L->IP == NULL)
{
L->IP = (mpu_t *)calloc(1,sizeof(mpu_t));
}
if (L->IP != NULL)
{
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxProc][0],
&L->IP->HLimit[mptMaxProc][0]);
}
if (L->IP == NULL)
break;
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxProc][0],
&L->IP->HLimit[mptMaxProc][0]);
break;
case mcaMaxIPS:
if (L->IP == NULL)
{
L->IP = (mpu_t *)calloc(1,sizeof(mpu_t));
}
if (L->IP != NULL)
{
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxPS][0],
&L->IP->HLimit[mptMaxPS][0]);
}
if (L->IP == NULL)
break;
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxPS][0],
&L->IP->HLimit[mptMaxPS][0]);
break;
case mcaMaxIWC:
if (L->IP == NULL)
{
L->IP = (mpu_t *)calloc(1,sizeof(mpu_t));
}
if (L->IP != NULL)
{
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxWC][0],
&L->IP->HLimit[mptMaxWC][0]);
}
if (L->IP == NULL)
break;
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxWC][0],
&L->IP->HLimit[mptMaxWC][0]);
break;
case mcaMaxIMem:
if (L->IP == NULL)
{
L->IP = (mpu_t *)calloc(1,sizeof(mpu_t));
}
if (L->IP != NULL)
{
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxMem][0],
&L->IP->HLimit[mptMaxMem][0]);
}
if (L->IP == NULL)
break;
__MCredParseLimit(
ValLine,
&L->IP->SLimit[mptMaxMem][0],
&L->IP->HLimit[mptMaxMem][0]);
break;
case mcaOMaxJob:
@@ -1665,9 +1634,6 @@ char *MCredShowAttrs(
long Mode)
{
char *BPtr;
int BSpace;
static char Line[MAX_MLINE];
char *ptr;
@@ -1676,13 +1642,13 @@ char *MCredShowAttrs(
int ShowUsage;
Line[0] = '\0';
if (Mode & (1 << mcsUsage))
ShowUsage = TRUE;
else
ShowUsage = FALSE;
MUSNInit(&BPtr,&BSpace,Line,sizeof(Line));
for (pindex = mcaPriority;pindex <= mcaJobFlags;pindex++)
{
switch(pindex)
@@ -1691,7 +1657,8 @@ char *MCredShowAttrs(
if (Priority != 0)
{
MUSNPrintF(&BPtr,&BSpace," %s=%ld",
sprintf(Line,"%s %s=%ld",
Line,
MCredAttr[pindex],
Priority);
}
@@ -1703,7 +1670,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(AP,mptMaxJob,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1715,7 +1683,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(AP,mptMaxNode,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1727,7 +1696,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(AP,mptMaxPE,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1739,7 +1709,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(AP,mptMaxProc,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1751,7 +1722,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(AP,mptMaxPS,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1763,7 +1735,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(AP,mptMaxWC,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1775,7 +1748,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(AP,mptMaxMem,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1787,7 +1761,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(IP,mptMaxJob,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1799,7 +1774,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(IP,mptMaxNode,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1811,7 +1787,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(IP,mptMaxPE,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1823,7 +1800,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(IP,mptMaxProc,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1835,7 +1813,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(IP,mptMaxPS,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1847,7 +1826,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(IP,mptMaxWC,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1859,7 +1839,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(IP,mptMaxMem,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1871,7 +1852,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OAP,mptMaxJob,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1883,7 +1865,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OAP,mptMaxNode,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1895,7 +1878,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OAP,mptMaxPE,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1907,7 +1891,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OAP,mptMaxProc,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1919,7 +1904,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OAP,mptMaxPS,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1931,7 +1917,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OAP,mptMaxWC,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1943,7 +1930,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OAP,mptMaxMem,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1955,7 +1943,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OIP,mptMaxJob,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1967,7 +1956,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OIP,mptMaxNode,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1979,7 +1969,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OIP,mptMaxPE,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -1991,7 +1982,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OIP,mptMaxProc,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -2003,7 +1995,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OIP,mptMaxPS,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -2015,7 +2008,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OIP,mptMaxWC,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -2027,7 +2021,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OIP,mptMaxMem,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -2039,7 +2034,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OJP,mptMaxNode,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -2051,7 +2047,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OJP,mptMaxPE,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -2063,7 +2060,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OJP,mptMaxProc,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -2075,7 +2073,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OJP,mptMaxPS,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -2087,7 +2086,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OJP,mptMaxWC,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
@@ -2099,7 +2099,8 @@ char *MCredShowAttrs(
if ((Mode & (1 << mcsLimits)) &&
((ptr = __MCredShowLimit(OJP,mptMaxMem,0,ShowUsage)) != NULL))
{
MUSNPrintF(&BPtr,&BSpace," %s=%s",
sprintf(Line,"%s %s=%s",
Line,
MCredAttr[pindex],
ptr);
}
+2 -15
View File
@@ -855,8 +855,6 @@ int MFSProcessOConfig(
char **SArray) /* I */
{
char *ptr;
if (F == NULL)
{
return(FAILURE);
@@ -888,15 +886,6 @@ int MFSProcessOConfig(
case pFSPolicy:
if ((ptr = strchr(SVal,'%')) != NULL)
{
MSched.PercentBasedFS = TRUE;
/* patch submitted by Ake Sandgren--assumes that % is always at the end of SVal */
*ptr = '\0';
}
if (MUBoolFromString(SVal,FALSE) == TRUE)
{
/* enable backlevel support */
@@ -965,10 +954,9 @@ int MFSProcessOConfig(
case pUConsWeight:
case pURemWeight:
case pUPerCWeight:
case pUExeTimeWeight:
F->PSW[PIndex - pSQTWeight + 1] = (long)IVal;
break;
case pServCap:
@@ -1009,7 +997,6 @@ int MFSProcessOConfig(
case pUConsCap:
case pURemCap:
case pUPerCCap:
case pUExeTimeCap:
F->PSC[PIndex - pSQTCap + 1] = (long)IVal;
+30 -42
View File
@@ -82,7 +82,7 @@ char *MFULoad(
DBG(5,fCORE) DPrint("%s(%s,%d,%s,BlockCount,SC)\n",
FName,
(FileName != NULL) ? FileName : "NULL",
FileName,
BlockSize,
(AccessMode == macmRead) ? "READ" : "WRITE");
@@ -91,9 +91,7 @@ char *MFULoad(
/* check if file is cached */
if ((FileName != NULL) &&
(FileName[0] != '\0') &&
(__MFUGetCachedFile(FileName,&buf,&BufSize) == SUCCESS))
if (__MFUGetCachedFile(FileName,&buf,&BufSize) == SUCCESS)
{
if (BlockCount != NULL)
*BlockCount = BufSize / BlockSize;
@@ -107,14 +105,15 @@ char *MFULoad(
else
{
/* copy cached data */
if ((ptr = (char *)calloc(BufSize + 1, 1)) == NULL)
if ((ptr = (char *)malloc(BufSize + 1)) == NULL)
{
MOSSyslog(LOG_ERR,"cannot calloc buffer for file '%s', errno: %d (%s)",
MOSSyslog(LOG_ERR,"cannot malloc buffer for file '%s', errno: %d (%s)",
FileName,
errno,
strerror(errno));
DBG(2,fCORE) DPrint("ERROR: cannot calloc file buffer for file '%s', errno: %d (%s)\n",
DBG(2,fCORE) DPrint("ERROR: cannot malloc file buffer for file '%s', errno: %d (%s)\n",
FileName,
errno,
strerror(errno));
@@ -126,7 +125,7 @@ char *MFULoad(
}
else
{
/* fill calloc'd buffer */
/* fill malloc'd buffer */
memcpy(ptr,buf,BufSize + 1);
@@ -185,19 +184,19 @@ char *MFULoad(
BufSize = ReadCount * BlockSize;
DBG(5,fCORE) DPrint("INFO: new file '%s' opened with %d bytes (ReadCount = %d)\n",
DBG(5,fCORE) DPrint("INFO: new file '%s' opened (%d bytes)\n",
FileName,
BufSize,
ReadCount);
if ((ptr = (char *)calloc(BufSize + 1,1)) == NULL)
BufSize);
if ((ptr = (char *)malloc(BufSize + 1)) == NULL)
{
MOSSyslog(LOG_ERR,"cannot calloc %d byte buffer for file '%s', errno: %d (%s)",
MOSSyslog(LOG_ERR,"cannot malloc %d byte buffer for file '%s', errno: %d (%s)",
BufSize,
FileName,
errno,
strerror(errno));
DBG(2,fCORE) DPrint("ERROR: cannot calloc file buffer for file '%s', errno: %d (%s)\n",
DBG(2,fCORE) DPrint("ERROR: cannot malloc file buffer for file '%s', errno: %d (%s)\n",
FileName,
errno,
strerror(errno));
@@ -287,19 +286,7 @@ int __MFUGetCachedFile(
DBG(5,fSTRUCT) DPrint("%s(%s,Buffer,BufSize)\n",
FName,
(FileName != NULL) ? FileName : "NULL");
if (Buffer == NULL)
{
return(FAILURE);
}
*Buffer = NULL;
if ((FileName == NULL) || (FileName[0] == '\0'))
{
return(FAILURE);
}
FileName);
for (index = 0;index < MAX_FILECACHE;index++)
{
@@ -403,14 +390,15 @@ int __MFUCacheFile(
MFileCache[index].Buffer = NULL;
}
if ((MFileCache[index].Buffer = (char *)calloc(BufSize + 1, 1)) == NULL)
if ((MFileCache[index].Buffer = (char *)malloc(BufSize + 1)) == NULL)
{
MOSSyslog(LOG_ERR,"cannot calloc cache buffer for file '%s', errno: %d (%s)",
MOSSyslog(LOG_ERR,"cannot malloc cache buffer for file '%s', errno: %d (%s)",
FileName,
errno,
strerror(errno));
DBG(2,fSTRUCT) DPrint("ERROR: cannot calloc file buffer for file '%s', errno: %d (%s)\n",
DBG(2,fSTRUCT) DPrint("ERROR: cannot malloc file buffer for file '%s', errno: %d (%s)\n",
FileName,
errno,
strerror(errno));
@@ -444,16 +432,16 @@ int __MFUCacheFile(
{
if (MFileCache[index].FileName[0] == '\0')
{
/* calloc space for buffer */
/* malloc space for buffer */
if ((MFileCache[index].Buffer = (char *)calloc(BufSize + 1, 1)) == NULL)
if ((MFileCache[index].Buffer = (char *)malloc(BufSize + 1)) == NULL)
{
MOSSyslog(LOG_ERR,"cannot calloc cache buffer for file '%s', errno: %d (%s)",
MOSSyslog(LOG_ERR,"cannot malloc cache buffer for file '%s', errno: %d (%s)",
FileName,
errno,
strerror(errno));
DBG(2,fSTRUCT) DPrint("ERROR: cannot calloc cache buffer for file '%s', errno: %d (%s)\n",
DBG(2,fSTRUCT) DPrint("ERROR: cannot malloc cache buffer for file '%s', errno: %d (%s)\n",
FileName,
errno,
strerror(errno));
@@ -749,14 +737,14 @@ int MFUGetRecord(
}
else if (!strcmp(Index[index].Key,Key))
{
if ((*Buffer = (char *)calloc(RecSize, 1)) == NULL)
if ((*Buffer = (char *)malloc(RecSize)) == NULL)
{
MOSSyslog(LOG_ERR,"cannot calloc buffer for record '%s', errno: %d (%s)",
MOSSyslog(LOG_ERR,"cannot malloc buffer for record '%s', errno: %d (%s)",
Key,
errno,
strerror(errno));
DBG(2,fCORE) DPrint("ERROR: cannot calloc %d buffer for record '%s', errno: %d (%s)\n",
DBG(2,fCORE) DPrint("ERROR: cannot malloc %d buffer for record '%s', errno: %d (%s)\n",
RecSize,
Key,
errno,
@@ -787,13 +775,13 @@ int MFUGetRecord(
return(SUCCESS);
}
if ((*Buffer = (char *)calloc(rcount, RecSize)) == NULL)
if ((*Buffer = (char *)malloc(rcount * RecSize)) == NULL)
{
MOSSyslog(LOG_ERR,"cannot calloc buffer for all records, errno: %d (%s)",
MOSSyslog(LOG_ERR,"cannot malloc buffer for all records, errno: %d (%s)",
errno,
strerror(errno));
DBG(2,fCORE) DPrint("ERROR: cannot calloc %d byte buffer for all records, errno: %d (%s)\n",
DBG(2,fCORE) DPrint("ERROR: cannot malloc %d byte buffer for all records, errno: %d (%s)\n",
rcount * RecSize,
errno,
strerror(errno));
@@ -1181,7 +1169,7 @@ int MFULock(
char *LockFile) /* I */
{
#if !defined(__LINUX) && !defined(__CYGWIN) && !defined(__HPUX) && !defined(__NT)
#if !defined(__LINUX) && !defined(__HPUX) && !defined(__NT)
int fd;
struct flock lock;
char Name[MAX_MLINE];
@@ -1194,7 +1182,7 @@ int MFULock(
Directory,
LockFile);
#if !defined(__LINUX) && !defined(__CYGWIN) && !defined(__HPUX) && !defined(__NT)
#if !defined(__LINUX) && !defined(__HPUX) && !defined(__NT)
if (!strstr(LockFile,Directory))
{
+2 -101
View File
@@ -22,10 +22,6 @@ extern const char *MXO[];
extern const char *MJobFlags[];
/*
* HvB
*/
extern int FSGroupKeys[];
int MGroupLoadCP(
@@ -89,6 +85,8 @@ int MGroupLoadCP(
return(FAILURE);
}
MXMLCreateE(&E,(char *)MXO[mxoGroup]);
MXMLFromString(&E,ptr,NULL,NULL);
MOFromXML((void *)G,mxoGroup,E);
@@ -99,104 +97,7 @@ int MGroupLoadCP(
} /* END MGroupLoadCP() */
/*
* HvB: Get all GroupNames that have a Fairshare target set
*/
int MGroupGetFSGroups()
{
int gindex;
int fsindex = 0;
mgcred_t *G;
const char *FName = "MGroupGetFSGroups";
DBG(5,fFS) DPrint("%s\n", FName);
for (gindex = 0;gindex < MAX_MGROUP + MAX_MHBUF;gindex++)
{
G = &MGroup[gindex];
if ((G == NULL) || (G->Name[0] == '\0') || (G->Name[0] == '\1'))
continue;
if (!strcmp(G->Name,ALL) || !strcmp(G->Name,"NOGROUP"))
continue;
if ( G->F.FSTarget > 0 )
{
DBG(5,fFS) DPrint("Found FSGroup %s(%f) with key %d \n", G->Name, G->F.FSTarget, G->Key);
FSGroupKeys[fsindex++] = G->Key;
}
}
} /* MGroupGetFSGroups */
/* HvB */
int MGroupSecondary(
char *UName, /* I */
mjob_t *J) /* O */
{
int i;
int gindex;
int ng = 0;
int rc;
gid_t *groups = NULL;
struct group *sec_grp;
struct group grp;
mgcred_t *GRP_cred;
const char *FName = "MGroupSecondary";
DBG(5,fFS) DPrint("%s(%s)\n",
FName,
(UName != NULL) ? UName : "NULL");
/*
MGroupGetFSGroups();
*/
i=0;
while ( FSGroupKeys[i] != -1 )
{
DBG(5,fFS) DPrint("Checking if user(%s) is member of group(%s)\n", UName, MGroup[FSGroupKeys[i]].Name);
if ( (sec_grp = getgrnam(MGroup[FSGroupKeys[i]].Name)) != NULL )
{
gindex=0;
while ( sec_grp->gr_mem[gindex] )
{
if ( !strcmp(sec_grp->gr_mem[gindex], UName) )
{
DBG(5,fFS) DPrint("Setting Group credentials for user %s to %s\n", UName, sec_grp->gr_name);
if ( MGroupAdd(sec_grp->gr_name, &J->Cred.G) == FAILURE )
{
DBG(1,fPBS) DPrint("ERROR: cannot add secondary group for job %s (Name: %s)\n",
J->Name,
sec_grp->gr_name);
return(FAILURE);
}
else
{
return(SUCCESS);
}
} /* if !strcmp */
else
{
gindex++;
}
} /* while sec_grp */
} /* if sec_grp */
i++;
} /* while FSGroupKeys[i] */
return(SUCCESS);
} /* MGroupSecondary */
int MGroupAdd(
+27 -89
View File
@@ -49,7 +49,6 @@ extern const char *MRMXAttr[];
extern const char *MAllocRejType[];
extern const char *MRMType[];
extern const char *MPreemptPolicy[];
extern const char *MBool[];
extern mx_t X;
@@ -83,10 +82,9 @@ int MJobCreate(
const char *FName = "MJobCreate";
DBG(5,fSTRUCT) DPrint("%s(%s,%s,%s)\n",
DBG(5,fSTRUCT) DPrint("%s(%s,%s)\n",
FName,
JName,
MBool[AddJob],
(JP != NULL) ? "JP" : "NULL");
/* attempt to MJobFind() first ? */
@@ -471,6 +469,14 @@ int MJobGetAccount(
return(SUCCESS);
}
if ((MSched.DefaultU != NULL) &&
(MSched.DefaultU->F.ADef != NULL))
{
*A = MSched.DefaultU->F.ADef;
return(SUCCESS);
}
if ((J->Cred.G != NULL) &&
(J->Cred.G->F.ADef != NULL))
{
@@ -507,22 +513,6 @@ int MJobGetAccount(
return(FAILURE);
}
} /* END if (MAM[0].Type != mamtNONE) */
if ((MSched.DefaultU != NULL) &&
(MSched.DefaultU->F.ADef != NULL))
{
*A = MSched.DefaultU->F.ADef;
return(SUCCESS);
}
if ((MSched.DefaultG != NULL) &&
(MSched.DefaultG->F.ADef != NULL))
{
*A = MSched.DefaultG->F.ADef;
return(SUCCESS);
}
return(SUCCESS);
} /* END MJobGetAccount() */
@@ -709,8 +699,6 @@ char *MJobGetName(
Host = ptr;
JobID = NULL;
StepID = NULL;
while (ptr != NULL)
@@ -887,9 +875,9 @@ int MJobDestroy(
MResDestroy(&J->R);
}
/* why was this commented out */
/*
MUFree((char **)&J->Cred.ACL);
*/
MUFree((char **)&J->Cred.CL);
@@ -897,7 +885,6 @@ int MJobDestroy(
MUFree(&J->Message);
MUFree(&J->E.Env);
MUFree(&J->E.IWD);
MUFree(&J->E.Input);
MUFree(&J->E.Output);
MUFree(&J->E.Error);
@@ -1032,8 +1019,7 @@ int MJobGetRunPriority(
*Priority = MPar[0].FSC.PCW[mpcUsage] * (
MPar[0].FSC.PSW[mpsUCons] * ResourcesConsumed +
MPar[0].FSC.PSW[mpsURem] * ResourcesRemaining +
MPar[0].FSC.PSW[mpsUPerC] * PercentResUsage,
MPar[0].FSC.PSW[mpsUExeTime] * (MSched.Time - J->StartTime));
MPar[0].FSC.PSW[mpsUPerC] * PercentResUsage);
*Priority += J->StartPriority;
@@ -1233,10 +1219,9 @@ int MJobUpdateFlags(
}
} /* END if (RQ != NULL) */
DBG(7,fSTRUCT) DPrint("INFO: job flags for job %s: %x, req napolicy=%s\n",
DBG(7,fSTRUCT) DPrint("INFO: job flags for job %s: %x\n",
J->Name,
(int)J->Flags,
(RQ != NULL) ? MNAccessPolicy[RQ->NAccessPolicy] : "N/A");
(int)J->Flags);
/* update job attributes */
@@ -1315,21 +1300,17 @@ int MReqCheckResourceMatch(
(J->ReqHList != NULL) &&
(RQ->DRes.Procs != 0))
{
Found = FALSE;
for (index = 0;J->ReqHList[index].N != NULL;index++)
{
if (N == J->ReqHList[index].N)
{
DBG(5,fSCHED) DPrint("INFO: node in requested hostlist\n");
Found = TRUE;
break;
return(SUCCESS);
}
} /* END for (index) */
if ((Found == FALSE) &&
if ((J->ReqHList[index].N == NULL) &&
((J->ReqHLMode != mhlmSubset) ||
(MPar[0].EnableMultiNodeJobs == FALSE)))
{
@@ -1340,16 +1321,6 @@ int MReqCheckResourceMatch(
return(FAILURE);
}
if ((Found == FALSE) && (J->ReqHLMode == mhlmExactSet))
{
DBG(5,fSCHED) DPrint("INFO: node is not in specified hostlist\n");
if (RIndex != NULL)
*RIndex = marHostList;
return(FAILURE);
}
} /* END if ((J->Flags & (1 << mjfHostList)) && ... ) */
} /* END if (J != NULL) */
@@ -2042,12 +2013,12 @@ int MJobPreempt(
MJobSetState(J,mjsSuspended);
/* NOTE: to prevent thrashing, by default, suspended jobs should not *
* resume for MDEF_MINSUSPENDTIME */
* resume for 1 minute */
{
long tmpL;
tmpL = MSched.Time + MDEF_MINSUSPENDTIME;
tmpL = MSched.Time + 60;
MJobSetAttr(J,mjaSysSMinTime,(void **)&tmpL,mdfLong,mSet);
} /* END BLOCK */
@@ -2684,16 +2655,7 @@ int MJobCheckLimits(
JUsage[mptMaxProc] = MJobGetProcCount(J);
JUsage[mptMaxNode] = J->Request.NC;
JUsage[mptMaxWC] = J->WCLimit;
if ((J->Req[0]->NAccessPolicy == mnacSingleJob) &&
(MSched.NodeAllocMaxPS == TRUE))
{
JUsage[mptMaxPS] = J->NodesRequested * JUsage[mptMaxWC];
}
else
{
JUsage[mptMaxPS] = JUsage[mptMaxProc] * JUsage[mptMaxWC];
}
JUsage[mptMaxPS] = JUsage[mptMaxProc] * JUsage[mptMaxWC];
MJobGetPE(J,&MPar[0],&PE);
@@ -3326,13 +3288,13 @@ int MJobProcessExtensionString(
{
if ((aindex = MUGetIndex(key,MRMXAttr,TRUE,mxaNONE)) == mxaNONE)
{
key = MUStrTok(NULL,";\n",&TokPtr);
if (X.XJobProcessRMXString != (int (*)())0)
{
(*X.XJobProcessRMXString)(X.xd,J,key);
}
key = MUStrTok(NULL,";\n",&TokPtr);
continue;
}
@@ -3382,25 +3344,11 @@ int MJobProcessExtensionString(
break;
case mxaDDisk:
/* dedicated disk */
RQ->DRes.Disk = (int)MURSpecToL(Value,mvmMega,mvmByte);
if (Value[0] != '0')
RQ->DRes.Disk = MAX(RQ->DRes.Disk,1);
DBG(5,fCONFIG) DPrint("INFO: per task dedicated disk set to %d MB\n",
RQ->DRes.Disk);
break;
case mxaDMem:
/* dedicated memory */
RQ->DRes.Mem = (int)strtol(Value,NULL,10);
RQ->DRes.Mem = (int)strtol(Value,NULL,0);
DBG(5,fCONFIG) DPrint("INFO: per task dedicated memory set to %d MB\n",
RQ->DRes.Mem);
@@ -7308,7 +7256,7 @@ int MJobGetEStartTime(
BestTaskCount,
EP->Name,
J->Name,
MULToTString(BestStartTime - MSched.Time));
MULToTString(*EStartTime - MSched.Time));
/* apply locality constraints */
@@ -7347,7 +7295,6 @@ int MJobGetEStartTime(
if (MJobSelectResourceSet(
J,
RQ,
(RQ->SetType != mrstNONE) ? RQ->SetType : MPar[0].NodeSetAttribute,
(tmpRSS != mrssOneOf) ? tmpRSS : mrssFirstOf,
(RQ->SetList[0] != NULL) ? RQ->SetList : MPar[0].NodeSetList,
@@ -7544,7 +7491,7 @@ int MJobGetEStartTime(
DBG(2,fSCHED) DPrint("INFO: located resources for %d tasks for spanning job %s at time %s in range %d\n",
J->Request.TC,
J->Name,
MULToTString(BestRange[rindex].StartTime - MSched.Time),
MULToTString(*EStartTime - MSched.Time),
rindex);
if (MJobAllocMNL(
@@ -7576,11 +7523,6 @@ int MJobGetEStartTime(
return(FAILURE);
}
if ((BestStartTime >= MAX_MTIME) && (BestRange[0].StartTime < BestStartTime))
{
BestStartTime = BestRange[0].StartTime;
}
tmpTaskCount = 0;
@@ -7702,7 +7644,7 @@ int MJobWriteStats(
if (MJobToTString(J,DEFAULT_WORKLOAD_TRACE_VERSION,Buf,sizeof(Buf)) == SUCCESS)
{
fprintf(MSched.statfp,"%s",Buf);
fprintf(MSched.statfp,Buf);
fflush(MSched.statfp);
@@ -8820,7 +8762,6 @@ int MReqGetFNL(
MJobSelectResourceSet(
J,
RQ,
(RQ->SetType != mrstNONE) ? RQ->SetType : MPar[0].NodeSetAttribute,
(tmpRSS != mrssFirstOf) ? tmpRSS : mrssOneOf,
(RQ->SetList != NULL) ? RQ->SetList : MPar[0].NodeSetList,
@@ -9659,7 +9600,7 @@ int MJobGetNRange(
}
else
{
if ((N->RM != NULL) && (N->RM->Type == mrmtLL))
if (N->RM->Type == mrmtLL)
{
if (RQ->NodeCount > 0)
{
@@ -10301,10 +10242,7 @@ int MJobGetSNRange(
if ((J->Req[0]->NAccessPolicy == mnacSingleUser) &&
(tmpJ != NULL) &&
(tmpJ->Cred.U != NULL) &&
(J->Cred.U != NULL) &&
(tmpJ->Cred.U != J->Cred.U) &&
(strcmp(J->Cred.U->Name,"[ALL]")))
(tmpJ->Cred.U != J->Cred.U))
{
/* user dedicated resources removed */
+5 -19
View File
@@ -31,12 +31,11 @@ int MLimitEnforceAll(
mjob_t *J;
mreq_t *RQ;
mbool_t ResourceLimitsExceeded;
mbool_t JobExceedsLimits;
int ResourceLimitsExceeded; /* boolean */
int VRes = -1;
int VLimit = -1;
int VVal = -1;
int VRes;
int VLimit;
int VVal;
int rc;
@@ -64,7 +63,6 @@ int MLimitEnforceAll(
JobWCX = J->Cred.C->F.Overrun;
if ((JobWCX >= 0) &&
(J->WCLimit > 0) &&
(MSched.Time > J->StartTime) &&
((unsigned long)(MSched.Time - J->StartTime) > (J->WCLimit + J->SWallTime + JobWCX)))
{
@@ -106,7 +104,6 @@ int MLimitEnforceAll(
/* enforce CRes utilization limits */
ResourceLimitsExceeded = FALSE;
JobExceedsLimits = FALSE;
RQ = J->Req[0]; /* FIXME */
@@ -123,7 +120,6 @@ int MLimitEnforceAll(
VVal = RQ->URes.Procs;
ResourceLimitsExceeded = TRUE;
JobExceedsLimits = TRUE;
}
else if ((P->ResourceLimitPolicy[mrMem] != mrlpNONE) &&
(RQ->DRes.Mem > 0) &&
@@ -139,7 +135,6 @@ int MLimitEnforceAll(
VVal = RQ->URes.Mem;
ResourceLimitsExceeded = TRUE;
JobExceedsLimits = TRUE;
}
else if ((P->ResourceLimitPolicy[mrSwap] != mrlpNONE) &&
(RQ->DRes.Swap > 0) &&
@@ -155,7 +150,6 @@ int MLimitEnforceAll(
VVal = RQ->URes.Swap;
ResourceLimitsExceeded = TRUE;
JobExceedsLimits = TRUE;
}
else if ((P->ResourceLimitPolicy[mrDisk] != mrlpNONE) &&
(RQ->DRes.Disk > 0) &&
@@ -171,7 +165,6 @@ int MLimitEnforceAll(
VVal = RQ->URes.Disk;
ResourceLimitsExceeded = TRUE;
JobExceedsLimits = TRUE;
}
if (ResourceLimitsExceeded == FALSE)
@@ -181,7 +174,7 @@ int MLimitEnforceAll(
/* job is using more resources than requested */
J->RULVTime += (mulong)((MSched.Interval + 50) / 100);
J->RULVTime += MSched.Iteration;
switch (P->ResourceLimitPolicy[VRes])
{
@@ -280,13 +273,6 @@ int MLimitEnforceAll(
DBG(1,fSCHED) DPrint("ALERT: limit violation action %s %s\n",
MPolicyAction[P->ResourceLimitViolationAction[VRes]],
(rc == SUCCESS) ? "succeeded" : "failed");
if (JobExceedsLimits == FALSE)
{
/* clear job violation time */
J->RULVTime = 0;
}
} /* END for (jindex) */
return(SUCCESS);
+3 -3
View File
@@ -82,7 +82,7 @@ int MLogInitialize(
if (SigSet == 0)
{
# if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__IRIX) || defined(__LINUX) || defined(__CYGWIN) || defined(__HPUX) || defined(__SOLARIS)
# if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__IRIX) || defined(__LINUX) || defined(__HPUX) || defined(__SOLARIS)
signal(SIGUSR1,(void(*)(int))MLogLevelAdjust);
signal(SIGUSR2,(void(*)(int))MLogLevelAdjust);
# else
@@ -414,7 +414,7 @@ void MLogLevelAdjust(
mlog.Threshold);
}
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__IRIX) || defined(__LINUX) || defined(__CYGWIN) || defined(__HPUX) || defined(__SOLARIS)
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__IRIX) || defined(__LINUX) || defined(__HPUX) || defined(__SOLARIS)
signal(SIGUSR1,(void(*)(int))MLogLevelAdjust);
@@ -441,7 +441,7 @@ void MLogLevelAdjust(
mlog.Threshold);
}
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__IRIX) || defined(__LINUX) || defined(__CYGWIN) || defined(__HPUX) || defined(__SOLARIS) || defined(__OSF)
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__IRIX) || defined(__LINUX) || defined(__HPUX) || defined(__SOLARIS) || defined(__OSF)
signal(SIGUSR2,(void(*)(int))MLogLevelAdjust);
+9 -27
View File
@@ -86,7 +86,7 @@ int MNodeCreate(
if (*NP == NULL)
{
*NP = (mnode_t *)calloc(1, sizeof(mnode_t));
*NP = (mnode_t *)malloc(sizeof(mnode_t));
N = *NP;
@@ -1149,15 +1149,10 @@ int MNodeGetPreemptList(
NodeIsPreemptee = FALSE;
R = NULL; /* NOTE: for compiler warnings only */
for (rindex = 0;N->R[rindex] != NULL;rindex++)
{
R = N->R[rindex];
if (R == NULL)
break;
if ((R == (mres_t *)1) ||
(R->Name[0] == '\0') ||
(R->Name[0] == '\1'))
@@ -3594,8 +3589,8 @@ int MNodeSetClass(
int Mode) /* I (mClear/mAdd/mSet) */
{
char *ptr = NULL;
char *ptr2 = NULL;
char *ptr;
char *ptr2;
char *TokPtr;
@@ -3622,10 +3617,6 @@ int MNodeSetClass(
{
ptr = MUStrTok(ClassString,"+",&TokPtr);
}
else
{
ptr = NULL;
}
while ((C != NULL) && (ptr != NULL))
{
@@ -4107,8 +4098,7 @@ int MNodeSetAttr(
case mnaStatATime:
if (Format == mdfString)
sscanf((char *)Value,"%lu",
&N->SATime);
sscanf((char *)Value,"%ld",&N->SATime);
else
N->SATime = *(long *)Value;
@@ -4117,8 +4107,7 @@ int MNodeSetAttr(
case mnaStatTTime:
if (Format == mdfString)
sscanf((char *)Value,"%lu",
&N->STTime);
sscanf((char *)Value,"%ld",&N->STTime);
else
N->STTime = *(long *)Value;
@@ -4127,8 +4116,7 @@ int MNodeSetAttr(
case mnaStatUTime:
if (Format == mdfString)
sscanf((char *)Value,"%lu",
&N->SUTime);
sscanf((char *)Value,"%ld",&N->SUTime);
else
N->SUTime = *(long *)Value;
@@ -5114,7 +5102,7 @@ int MUNLGetMinAVal(
mnalloc_t *NL, /* I */
int NAttr, /* I */
mnode_t **NPtr, /* O (optional) */
void **Val) /* O */
void **Val) /* O (optional) */
{
mnode_t *N;
@@ -5130,12 +5118,7 @@ int MUNLGetMinAVal(
{
return(FAILURE);
}
if (NAttr == mnaNodeType)
{
((char *)Val)[0] = '\0';
}
switch (NAttr)
{
case mnaSpeed:
@@ -5746,11 +5729,10 @@ int MNodeGetLocation(
int nindex;
char tmpName[MAX_MNAME];
tmpName[0]='\0';
char *ptr;
long Address=0;
long Address;
mhost_t *S;
+156 -295
View File
@@ -3,11 +3,11 @@
/* Contains: *
* int MPBSInitialize(R,SC) *
* int MPBSWorkloadQuery(R,JCount,SC) *
* int __MPBSJobGetState(Name,Status,PJob,IE) *
* int __MPBSJobGetState(Name,Status,PJob,FlagsP) *
* int MPBSClusterQuery(R,RCount,SC) *
* int __MPBSGetNodeState(Name,State,PNode) *
* int MPBSJobStart(J,R,Msg,SC) *
* int MPBSJobCancel(J,Message,R) *
* int MPBSCancelJob(J,Message,R) *
* int MPBSJobMigrate(J,R,NL,Msg,SC) *
* int MPBSJobSubmit(String,R,J,JobName,Msg,SC) *
* int MPBSNodeLoad(N,PNode,State,RMIndex) *
@@ -56,14 +56,6 @@ extern const char *MNodeState[];
char *getreq(int);
#endif /* getreq */
#ifndef ND_cluster
#define ND_cluster "cluster"
#endif /* !ND_cluster */
#ifndef ND_reserve
#define ND_reserve "reserve"
#endif /* !ND_reserve */
extern int pbs_errno;
extern int get_svrport(const char *,char *,int);
@@ -97,7 +89,7 @@ int __MPBSSystemQuery(mrm_t *,int *);
int MPBSJobUpdate(struct batch_status *,mjob_t *,short *,int);
int MPBSNodeLoad(mnode_t *,struct batch_status *,int,mrm_t *);
int MPBSNodeUpdate(mnode_t *,struct batch_status *,enum MNodeStateEnum,mrm_t *);
int __MPBSJobGetState(struct batch_status *,mrm_t *,char *,enum MJobStateEnum *,mbool_t *);
int __MPBSJobGetState(struct batch_status *,mrm_t *,char *,enum MJobStateEnum *,mulong *);
int __MPBSGetNodeState(char *,enum MNodeStateEnum *,struct batch_status *);
int MPBSQueryMOM(mnode_t *,mrm_t *,char *,int *);
int MPBSGetClassInfo(mnode_t *N,char C[][MAX_MNAME],char A[][MAX_MNAME]);
@@ -553,7 +545,7 @@ int MPBSWorkloadQuery(
mjob_t *JNext;
mbool_t IsExiting;
mulong JobFlagBM;
const char *FName = "MPBSWorkloadQuery";
@@ -588,21 +580,21 @@ int MPBSWorkloadQuery(
*JCount = 0;
if ((MSim.RMFailureTime >= MSched.Time) ||
(jobs = pbs_statjob(R->U.PBS.ServerSD,NULL,NULL,"exec_queue_only")) == NULL)
(jobs = pbs_statjob(R->U.PBS.ServerSD,NULL,NULL,NULL)) == NULL)
{
if (MSim.RMFailureTime < MSched.Time)
ErrMsg = pbs_geterrmsg(R->U.PBS.ServerSD);
else
ErrMsg = NULL;
if (pbs_errno == 0)
if (ErrMsg == NULL)
{
DBG(3,fPBS) DPrint("INFO: queue is empty\n");
}
else
{
DBG(0,fPBS) DPrint("ALERT: queue is empty or cannot get PBS job info: %s\n",
(ErrMsg != NULL) ? ErrMsg : "N/A");
ErrMsg);
R->U.PBS.ServerSDTimeStamp = 0;
@@ -625,10 +617,6 @@ int MPBSWorkloadQuery(
for (cur_job = jobs;cur_job != NULL;cur_job = cur_job->next)
{
/* torque-2.0.0p1 and up can limit pbs_statjob() to only return executable jobs */
#ifndef EXECQUEONLY
/* ignore jobs that are in route queues */
if (__MPBSJobChkExecutable(cur_job) == FAILURE)
@@ -638,18 +626,19 @@ int MPBSWorkloadQuery(
continue;
}
#endif
if (JCount != NULL)
(*JCount)++;
RMJID[0] = '\0';
if (__MPBSJobGetState(cur_job,R,RMJID,&Status,&IsExiting) == FAILURE)
if (__MPBSJobGetState(cur_job,R,RMJID,&Status,&JobFlagBM) == FAILURE)
break;
MJobGetName(NULL,RMJID,R,SJID,sizeof(SJID),mjnShortName);
J = NULL;
switch (Status)
{
case mjsIdle:
@@ -660,9 +649,6 @@ int MPBSWorkloadQuery(
if (MJobFind(SJID,&J,0) == SUCCESS)
{
if (IsExiting == TRUE)
J->Flags |= (1 << mjfIsExiting);
MRMJobPreUpdate(J);
MPBSJobUpdate(cur_job,J,TaskList,R->Index);
@@ -673,9 +659,6 @@ int MPBSWorkloadQuery(
{
/* if new job, load data */
if (IsExiting == TRUE)
J->Flags |= (1 << mjfIsExiting);
MRMJobPreLoad(J,SJID,R->Index);
MJobSetAttr(J,mjaRMJID,(void **)RMJID,mdfString,mSet);
@@ -709,9 +692,6 @@ int MPBSWorkloadQuery(
if (MJobFind(SJID,&J,0) == SUCCESS)
{
if (IsExiting == TRUE)
J->Flags |= (1 << mjfIsExiting);
/* if job never ran, remove record. job cancelled externally */
if ((J->State != mjsRunning) && (J->State != mjsStarting))
@@ -794,6 +774,9 @@ int MPBSWorkloadQuery(
break;
} /* END switch (Status) */
if (J != NULL)
J->IFlags |= JobFlagBM;
} /* END for (cur_job) */
pbs_statfree(jobs);
@@ -854,22 +837,22 @@ int __MPBSJobGetState(
struct batch_status *PJob, /* I */
mrm_t *R, /* I */
char *JobName, /* O (optional) */
enum MJobStateEnum *Status, /* O */
mbool_t *IsExiting)
enum MJobStateEnum *Status,
mulong *FlagsP)
{
struct attrl *AP;
*Status = mjsNONE;
if (IsExiting != NULL)
*IsExiting = FALSE;
if ((JobName != NULL) && (JobName[0] == '\0'))
{
strcpy(JobName,PJob->name);
}
if (FlagsP != NULL)
*FlagsP = 0;
for (AP = PJob->attribs;AP != NULL;AP = AP->next)
{
if (!strcmp(AP->name,ATTR_state))
@@ -910,15 +893,15 @@ int __MPBSJobGetState(
/* job has not reached release time */
*Status = mjsHold;
*Status = mjsNotQueued;
break;
case 'E': /* differences between 'exiting' and 'completed?' */
if (IsExiting != NULL)
*IsExiting = TRUE;
case 'E':
if (FlagsP != NULL)
*FlagsP |= (1 << mjifIsExiting);
*Status = mjsRunning;
break;
@@ -1058,48 +1041,9 @@ int __MPBSSystemQuery(
sizeof(MSched.DefaultC->Name));
}
}
else if (!strcmp(AP->name,"pbs_version"))
{
char tmpLine[MMAX_LINE];
char *ptr;
char *TokPtr;
int Version;
/* FORMAT: <PRODNAME>_X.Y.Z.<BUILDNUMBER> where <PRODNAME> is { PBSPro | TORQUE } */
if (R->Version <= 0)
{
MUStrCpy(tmpLine,AP->value,sizeof(tmpLine));
Version = 0;
ptr = MUStrTok(tmpLine,"_",&TokPtr);
ptr = MUStrTok(NULL,".",&TokPtr);
if (ptr != NULL)
Version += (int)strtol(ptr,NULL,10) * 100;
ptr = MUStrTok(NULL,".",&TokPtr);
if (ptr != NULL)
Version += (int)strtol(ptr,NULL,10) * 10;
ptr = MUStrTok(NULL,".",&TokPtr);
if (ptr != NULL)
Version += (int)strtol(ptr,NULL,10);
R->Version = Version;
}
}
} /* END for (AP) */
} /* END for (SP) */
pbs_statfree(Server);
return(SUCCESS);
} /* END __MPBSSystemQuery() */
@@ -1523,8 +1467,7 @@ int MPBSLoadQueueInfo(
}
else if (!strcmp(AP->name,"resources_default"))
{
if (!strcmp(AP->resource,"neednodes") ||
!strcmp(AP->resource,"select"))
if (!strcmp(AP->resource,"neednodes"))
{
char *ptr;
@@ -1588,11 +1531,6 @@ int MPBSLoadQueueInfo(
if (IsGlobal == TRUE)
{
DBG(3,fPBS) DPrint("INFO: class to node not mapping enabled for queue '%s' adding class to all nodes\n",
QP->name);
IsGlobal = FALSE;
/* add class to all nodes not listed in ACLHosts */
for (nindex = 0;nindex < MAX_MNODE;nindex++)
@@ -1622,11 +1560,6 @@ int MPBSLoadQueueInfo(
{
CCount = MIN(CCount,N->MaxProcPerClass[C->Index]);
}
else if ((MSched.DefaultN.MaxProcPerClass != NULL) &&
(MSched.DefaultN.MaxProcPerClass[C->Index] > 0))
{
CCount = MIN(CCount,MSched.DefaultN.MaxProcPerClass[C->Index]);
}
N->CRes.PSlot[C->Index].count += CCount;
N->CRes.PSlot[0].count += CCount;
@@ -1796,6 +1729,34 @@ int MPBSJobStart(
return(FAILURE);
}
if (MPBSJobModify(J,R,ATTR_l,"neednodes",HostList,NULL,NULL) == FAILURE)
{
DBG(0,fPBS) DPrint("ERROR: cannot set hostlist for job '%s'\n",
J->Name);
if (R->FailIteration != MSched.Iteration)
{
R->FailIteration = MSched.Iteration;
R->FailCount = 0;
}
R->FailCount++;
if (Msg != NULL)
strcpy(Msg,"job cannot be started - cannot set hostlist");
if (SC != NULL)
*SC = mscRemoteFailure;
return(FAILURE);
}
else
{
DBG(7,fPBS) DPrint("INFO: hostlist for job '%s' set to '%s'\n",
J->Name,
HostList);
}
}
else
{
@@ -1874,16 +1835,7 @@ int MPBSJobStart(
MJobGetName(J,NULL,R,tmpJobName,sizeof(tmpJobName),mjnRMName);
if (R->ASyncJobStart == FALSE )
{
DBG(7,fPBS) DPrint("INFO: use pbs_runjob\n");
rc = pbs_runjob(R->U.PBS.ServerSD,tmpJobName,HostList,NULL);
}
else
{
DBG(7,fPBS) DPrint("INFO: use pbs_asyrun\n");
rc = pbs_asyrunjob(R->U.PBS.ServerSD,tmpJobName,HostList,NULL);
}
rc = pbs_runjob(R->U.PBS.ServerSD,tmpJobName,MasterHost,NULL);
if (rc != 0)
{
@@ -1907,6 +1859,21 @@ int MPBSJobStart(
JobStartFailed = TRUE;
}
if (J->NeedNodes != NULL)
{
if (MPBSJobModify(J,R,ATTR_l,"neednodes",J->NeedNodes,NULL,NULL) == FAILURE)
{
DBG(7,fPBS) DPrint("WARNING: cannot reset hostlist for job '%s')\n",
J->Name);
}
else
{
DBG(7,fPBS) DPrint("INFO: hostlist for job '%s' set to '%s'\n",
J->Name,
J->NeedNodes);
}
}
if (JobStartFailed == TRUE)
{
/* job could not be started */
@@ -2144,11 +2111,6 @@ int MPBSJobCancel(
(R != NULL) ? R->Name : "NULL",
(Message != NULL) ? Message : "NULL");
if (J->Flags & (1 << mjfIsExiting))
{
return(SUCCESS);
}
if (MSched.PreemptPolicy == mppCheckpoint)
{
return(MPBSJobCkpt(J,R,TRUE,Message,SC));
@@ -2333,10 +2295,9 @@ int MPBSNodeLoad(
N->CRes.Swap = MAX(MIN_SWAP,N->CRes.Mem);
}
/* PBS does not provide pool, machine speed, or network info */
/* PBS does not provide pool, opsys, machine speed, or network info */
if (N->ActiveOS == 0)
N->ActiveOS = MUMAGetIndex(eOpsys,"DEFAULT",mAdd);
N->ActiveOS = MUMAGetIndex(eOpsys,"DEFAULT",mAdd);
if (N->Network == 0)
N->Network = MUMAGetBM(eNetwork,"DEFAULT",mAdd);
@@ -2657,7 +2618,7 @@ int MPBSQueryMOM(
"arch", /* the architecture of the machine */
"physmem", /* the amount of physical memory */
"loadave", /* the current load average */
#if defined(__AIX43) || defined(__AIX51) || defined(__LINUX) || defined(__CYGWIN) || defined(__IRIX)
#if defined(__AIX43) || defined(__AIX51) || defined(__LINUX) || defined(__IRIX)
"availmem",
"totmem",
#endif /* AIX43 || LINUX || IRIX */
@@ -2837,8 +2798,8 @@ int MPBSQueryMOM(
/* NOTE: PBS totmem = swap + RAM */
if (TotMem > 0)
N->CRes.Swap = TotMem;
if ((TotMem > 0) && (N->CRes.Mem > 0))
N->CRes.Swap = TotMem - N->CRes.Mem;
closerm(sd);
@@ -2854,8 +2815,8 @@ int MPBSQueryMOM(
N->CRes.Mem = (int)(N->CRes.Mem * MSched.NodeMemOverCommitFactor);
N->ARes.Mem = (int)(N->CRes.Mem * MSched.NodeMemOverCommitFactor);
N->CRes.Swap = (int)(N->CRes.Swap * MSched.NodeMemOverCommitFactor);
N->ARes.Swap = (int)(N->CRes.Swap * MSched.NodeMemOverCommitFactor);
N->CRes.Swap = (int)(N->CRes.Mem * MSched.NodeMemOverCommitFactor);
N->ARes.Swap = (int)(N->CRes.Mem * MSched.NodeMemOverCommitFactor);
/* memory factor not applied to node load */
}
@@ -3030,10 +2991,9 @@ int MPBSNodeUpdate(
N->CRes.Swap = MAX(MIN_SWAP,N->CRes.Mem);
}
/* PBS does not provide pool, machine speed, or network info */
/* PBS does not provide pool, opsys, machine speed, or network info */
if (N->ActiveOS == 0)
N->ActiveOS = MUMAGetIndex(eOpsys,"DEFAULT",mAdd);
N->ActiveOS = MUMAGetIndex(eOpsys,"DEFAULT",mAdd);
if (N->Network == 0)
N->Network = MUMAGetBM(eNetwork,"DEFAULT",mAdd);
@@ -3210,8 +3170,6 @@ int MPBSNodeUpdate(
{
MUStrCpy(tmpBuffer,AP->value,sizeof(tmpBuffer));
memset(N->FBM,0,sizeof(N->FBM));
ptr = MUStrTok(tmpBuffer,", \t",&TokPtr);
while (ptr != NULL)
@@ -3370,7 +3328,7 @@ int MPBSJobLoad(
tpbsa_t TA;
mbool_t IsExiting;
mulong tmpUL;
const char *FName = "MPBSJobLoad";
@@ -3387,7 +3345,7 @@ int MPBSJobLoad(
memset(&TA,0,sizeof(TA));
if (__MPBSJobGetState(PJob,&MRM[RMIndex],NULL,&J->State,&IsExiting) == FAILURE)
if (__MPBSJobGetState(PJob,&MRM[RMIndex],NULL,&J->State,&tmpUL) == FAILURE)
{
DBG(1,fPBS) DPrint("ALERT: cannot get job state info for job '%s'\n",
J->Name);
@@ -3397,8 +3355,7 @@ int MPBSJobLoad(
return(FAILURE);
}
if (IsExiting == TRUE)
J->Flags |= (1 << mjfIsExiting);
J->IFlags |= tmpUL;
/* add resource requirements information */
@@ -3619,7 +3576,7 @@ int MPBSJobUpdate(
int MaxJobMem;
int MaxJobSwap;
mbool_t IsExiting;
mulong tmpUL;
const char *FName = "MPBSJobUpdate";
@@ -3640,7 +3597,7 @@ int MPBSJobUpdate(
TaskList[0] = -1;
if (__MPBSJobGetState(PJob,&MRM[RMIndex],NULL,&J->State,&IsExiting) == FAILURE)
if (__MPBSJobGetState(PJob,&MRM[RMIndex],NULL,&J->State,&tmpUL) == FAILURE)
{
DBG(1,fPBS) DPrint("ALERT: cannot get job state info for job '%s'\n",
J->Name);
@@ -3648,8 +3605,7 @@ int MPBSJobUpdate(
return(FAILURE);
}
if (IsExiting == TRUE)
J->Flags |= (1 << mjfIsExiting);
J->IFlags |= tmpUL;
RQ = J->Req[0];
@@ -3954,58 +3910,40 @@ int MPBSJobUpdate(
}
else if (!strcmp(AP->resource,"software"))
{
int rqindex;
int RIndex;
mreq_t *tmpRQ;
if ((RIndex = MUMAGetIndex(eGRes,AP->value,mAdd)) == 0)
{
/* cannot add support for generic res */
DBG(1,fPBS) DPrint("ALERT: cannot add support for GRes software '%s'\n",
AP->value);
continue;
}
/* verify software req does not already exist */
for (rqindex = 0;J->Req[rqindex] != NULL;rqindex++)
{
if (J->Req[rqindex]->DRes.GRes[RIndex].count > 0)
break;
} /* END for (rqindex) */
if (J->Req[rqindex] != NULL)
{
/* software req already added */
continue;
}
/* add software req */
if (MReqCreate(J,NULL,&tmpRQ,FALSE) == FAILURE)
{
DBG(1,fPBS) DPrint("ALERT: cannot add req to job %s for GRes software '%s'\n",
J->Name,
AP->value);
continue;
}
/* NOTE: PBS currently supports only one license request per job */
tmpRQ->DRes.GRes[RIndex].count = 1;
tmpRQ->DRes.GRes[0].count = 1;
tmpRQ->TaskCount = 1;
tmpRQ->NodeCount = 1;
/* NOTE: prior workaround (map software to node feature) */
/* NOTE: old hack (map software to node feature */
/* MReqSetAttr(J,RQ,mrqaReqNodeFeature,(void **)AP->value,mdfString,mAdd); */
/* NOTE: software handled at job load time, no support for dynamic software spec */
/* Food for further ruminations:
* software licenses can be either floating or node-locked
* the above works in the situation of a node-locked license
for unlimited users; limiting # of concurrent uses could
be accomplished by forcing users to submit to a specific
queue/class and limit the number of concurrent jobs in
that class
* one can imagine future support looking something like this (from the POV
of the config file):
# Node-locked on a single host, unlimited concurrent usage
SOFTWARECFG[pkg1] HOSTLIST=node01
# Node-locked on a single host, limited to one concurrent use
SOFTWARECFG[pkg2] HOSTMAXCOUNT=1 HOSTLIST=node02
# Floating across several hosts, global maximum on concurrent usage
SOFTWARECFG[pkg3] MAXCOUNT=5 HOSTLIST=node[1-4][0-9]
# Floating across several hosts, global and per-host maxima on concurrent usage
SOFTWARECFG[pkg4] MAXCOUNT=10 HOSTMAXCOUNT=2 HOSTLIST=node[5-8][0-9]
* this would probably also require support in diagnose ("diagnose -S",
maybe?)
*/
}
else
{
@@ -4109,9 +4047,9 @@ int MPBSJobUpdate(
CPUTime = 1;
}
/* adjust per task limits */
/* adjust 'per task limits */
if ((MaxJobMem > 0) && (RQ->DRes.Procs > 0))
if (MaxJobMem > 0)
{
/* set job wide dedicated resources */
@@ -4123,7 +4061,7 @@ int MPBSJobUpdate(
RQ->URes.Mem /= RQ->TaskCount;
}
if ((MaxJobSwap > 0) && (RQ->DRes.Procs > 0))
if (MaxJobSwap > 0)
{
/* set both dedicated resources AND node requirements */
@@ -4460,14 +4398,7 @@ int MPBSJobRequeue(
/* restore PBS 'neednodes' value to original value */
if (MPBSJobModify(
J,
R,
ATTR_l,
(char *)(R->Version >= 710 ? "select" : "neednodes"),
J->NeedNodes,
NULL,
NULL) == FAILURE)
if (MPBSJobModify(J,R,ATTR_l,"neednodes",J->NeedNodes,NULL,NULL) == FAILURE)
{
DBG(7,fPBS) DPrint("WARNING: cannot reset hostlist for job '%s')\n",
J->Name);
@@ -4903,7 +4834,7 @@ int MPBSJobMigrate(
J,
R,
"Resource_List",
(char *)(R->Version >= 710 ? "select" : "neednodes"),
"neednodes",
tmpHList,
EMsg,
SC) == FAILURE)
@@ -5074,8 +5005,11 @@ int MPBSNodeSetAttr(
memset(&tmpAP,0,sizeof(tmpAP));
AP = (struct attrl *)A;
if (A != NULL)
{
AP = (struct attrl *)A;
}
DBG(6,fPBS) DPrint("INFO: PBS node attribute '%s' value: '%s' (r: %s)\n",
AP->name,
(AP->value != NULL) ? AP->value : "NULL",
@@ -5088,11 +5022,6 @@ int MPBSNodeSetAttr(
if (AP->value[0] != '?')
N->Arch = MUMAGetIndex(eArch,AP->value,mAdd);
}
else if (!strcmp(AP->resource,"opsys"))
{
if (AP->value[0] != '?')
N->ActiveOS = MUMAGetIndex(eOpsys,AP->value,mAdd);
}
else if (!strcmp(AP->resource,"mem"))
{
N->CRes.Mem = (MPBSGetResKVal(AP->value) >> 10);
@@ -5400,88 +5329,30 @@ int MPBSJobSetAttr(
return(FAILURE);
}
if ((J->Cred.U == NULL) || !strcmp(AP->name,ATTR_owner))
if (MUserAdd(ptr,&J->Cred.U) == FAILURE)
{
if (MUserAdd(ptr,&J->Cred.U) == FAILURE)
{
DBG(1,fPBS) DPrint("ERROR: cannot add user for job %s (Name: %s)\n",
J->Name,
ptr);
MJobRemove(J);
return(FAILURE);
}
/* HvB
* Check the secondary groups of the user for FSTargets
*/
if ( MPar[0].FSSecondaryGroups == TRUE )
{
if ( MGroupSecondary(ptr,J) == FAILURE )
{
MJobRemove(J);
return(FAILURE);
}
}
}
if ((J->Cred.U != NULL) && (!strcmp(AP->name,ATTR_euser)))
{
if (strcmp(J->Cred.U->Name,ptr))
{
/* effective user requested which does not match job owner */
MJobSetHold(
J,
(1 << mhBatch),
0,
mhrCredAccess,
"job not authorized to use proxy credentials");
}
DBG(1,fPBS) DPrint("ERROR: cannot add user for job %s (Name: %s)\n",
J->Name,
ptr);
MJobRemove(J);
return(FAILURE);
}
}
else if (!strcmp(AP->name,ATTR_egroup))
{
/* HvB
* Only update job credentials when credentials are not set by MGroupSecondary
*/
if ( J->Cred.G == NULL )
/* get group name */
if (MGroupAdd(AP->value,&J->Cred.G) == FAILURE)
{
if (MGroupAdd(AP->value,&J->Cred.G) == FAILURE)
{
DBG(1,fPBS) DPrint("ERROR: cannot add group for job %s (Name: %s)\n",
DBG(1,fPBS) DPrint("ERROR: cannot add group for job %s (Name: %s)\n",
J->Name,
AP->value);
MJobRemove(J);
return(FAILURE);
} /* end MGroupAdd */
}
}
else if (!strcmp(AP->name,ATTR_g))
/* HvB
* set group credential to the one specified via qsub paramter -W group_list=<value>
*/
{
if ( MPar[0].IgnPbsGroupList == FALSE )
{
if (MGroupAdd(AP->value,&J->Cred.G) == FAILURE)
{
DBG(1,fPBS) DPrint("ERROR: cannot add group for job %s (Name: %s)\n",
J->Name,
AP->value);
MJobRemove(J);
return(FAILURE);
}
} /* end MPar[0] .. */
else
{
DBG(3,fPBS) DPrint("INFO: ignoring PBS group_list(%s) attribute as requested\n",
AP->value);
MJobRemove(J);
return(FAILURE);
}
}
else if (!strcmp(AP->name,ATTR_A))
@@ -5545,7 +5416,7 @@ int MPBSJobSetAttr(
/* get resource information */
if (!strcmp(AP->resource,"neednodes") || !strcmp(AP->resource,"select"))
if (!strcmp(AP->resource,"neednodes"))
{
/* record PBS neednodes value */
@@ -5593,10 +5464,6 @@ int MPBSJobSetAttr(
{
RQ->Arch = MUMAGetIndex(eArch,AP->value,mAdd);
}
else if (!strcmp(AP->resource,"opsys"))
{
RQ->Opsys = MUMAGetIndex(eOpsys,AP->value,mAdd);
}
else if (!strcmp(AP->resource,"pmem"))
{
/* NOTE: called 'workingset'? (indiana) */
@@ -5954,10 +5821,10 @@ int MPBSJobAdjustResources(
if (TA != NULL)
{
if ((TA->JobMemLimit > 0) && (RQ->DRes.Procs > 0))
if (TA->JobMemLimit > 0)
RQ->DRes.Mem = MAX(RQ->DRes.Mem,TA->JobMemLimit / RQ->TaskCount);
if ((TA->JobSwapLimit > 0) && (RQ->DRes.Procs > 0))
if (TA->JobSwapLimit > 0)
RQ->DRes.Swap = MAX(RQ->DRes.Swap,TA->JobSwapLimit / RQ->TaskCount);
} /* END if (TA != NULL) */
@@ -5974,9 +5841,9 @@ int MPBSJobAdjustResources(
RQ->RequiredMemory = J->Req[0]->RequiredMemory;
RQ->MemCmp = J->Req[0]->MemCmp;
RQ->RequiredSwap = J->Req[0]->RequiredSwap;
RQ->RequiredSwap = J->Req[0]->RequiredMemory;
RQ->SwapCmp = J->Req[0]->SwapCmp;
RQ->RequiredDisk = J->Req[0]->RequiredDisk;
RQ->RequiredDisk = J->Req[0]->RequiredMemory;
RQ->DiskCmp = J->Req[0]->DiskCmp;
}
@@ -6160,10 +6027,6 @@ int __MPBSIGetSSSStatus(
{
N->Arch = MUMAGetIndex(eArch,Value,mAdd);
}
else if (!strcmp(Name,"opsys"))
{
N->ActiveOS = MUMAGetIndex(eOpsys,Value,mAdd);
}
else if (!strcmp(Name,"totmem"))
{
TotMem = (MPBSGetResKVal(Value) >> 10);
@@ -6215,11 +6078,6 @@ int __MPBSIGetSSSStatus(
} /* END else if (!strcmp(Name,"message")) */
} /* END while (ptr != NULL) */
/* NOTE: PBS totmem = swap + RAM */
if (TotMem > 0)
N->CRes.Swap = TotMem;
if (MSched.NodeMemOverCommitFactor > 0.0)
{
/* NOTE: both real memory and swap overcommitted */
@@ -6227,12 +6085,17 @@ int __MPBSIGetSSSStatus(
N->CRes.Mem = (int)(N->CRes.Mem * MSched.NodeMemOverCommitFactor);
N->ARes.Mem = (int)(N->ARes.Mem * MSched.NodeMemOverCommitFactor);
N->CRes.Swap = (int)(N->CRes.Swap * MSched.NodeMemOverCommitFactor);
N->ARes.Swap = (int)(N->ARes.Swap * MSched.NodeMemOverCommitFactor);
N->CRes.Swap = (int)(N->CRes.Mem * MSched.NodeMemOverCommitFactor);
N->ARes.Swap = (int)(N->ARes.Mem * MSched.NodeMemOverCommitFactor);
/* memory factor not applied to node load */
}
/* NOTE: PBS totmem = swap + RAM */
if ((TotMem > 0) && (N->CRes.Mem > 0))
N->CRes.Swap = TotMem - N->CRes.Mem;
return(SUCCESS);
} /* END __MPBSIGetSSSStatus() */
@@ -6250,7 +6113,6 @@ int __MPBSNLToTaskString(
int tindex;
char tmpHostName[MAX_MLINE];
char tmpTaskList[MAX_MLINE+10];
mnode_t *N;
@@ -6303,11 +6165,10 @@ int __MPBSNLToTaskString(
}
else
{
snprintf(tmpTaskList,sizeof(tmpTaskList),"%s:ppn=%d",
sprintf(TSBuf,"%s%s:ppn=%d",
TSBuf,
tmpHostName,
NL[tindex].TC);
MUStrCat(TSBuf,tmpTaskList,BufSize);
}
} /* END for (tindex) */
+44 -112
View File
@@ -23,7 +23,6 @@ extern mckpt_t MCP;
extern mrm_t MRM[];
extern mstat_t MStat;
extern mattrlist_t MAList;
extern m64_t M64;
extern const char *MQALType[];
extern const char *MResourceType[];
@@ -240,11 +239,52 @@ int MJobGetPAL(
if (PAL != NULL)
MUBMCopy(PAL,tmpPAL,MAX_MPAR);
/* determine allowed partition default */
/* determine allowed partition default (precedence: U,G,A,C,S,0) */
if (PDef != NULL)
{
*PDef = MJobFindDefPart(J, C, tmpPAL);
if ((J->Cred.U->F.PDef != NULL) &&
(J->Cred.U->F.PDef != &MPar[0]) &&
MUBMCheck(((mpar_t *)J->Cred.U->F.PDef)->Index,tmpPAL))
{
*PDef = (mpar_t *)J->Cred.U->F.PDef;
}
else if ((J->Cred.G->F.PDef != NULL) &&
(J->Cred.G->F.PDef != &MPar[0]) &&
MUBMCheck(((mpar_t *)J->Cred.G->F.PDef)->Index,tmpPAL))
{
*PDef = (mpar_t *)J->Cred.G->F.PDef;
}
else if ((J->Cred.A != NULL) &&
(J->Cred.A->F.PDef != NULL) &&
(J->Cred.A->F.PDef != &MPar[0]) &&
MUBMCheck(((mpar_t *)J->Cred.A->F.PDef)->Index,tmpPAL))
{
*PDef = (mpar_t *)J->Cred.A->F.PDef;
}
else if ((C != NULL) &&
(C->F.PDef != NULL) &&
(C->F.PDef != &MPar[0]) &&
MUBMCheck(((mpar_t *)C->F.PDef)->Index,tmpPAL))
{
*PDef = (mpar_t *)C->F.PDef;
}
else if ((J->Cred.Q != NULL) &&
(J->Cred.Q->F.PDef != NULL) &&
(J->Cred.Q->F.PDef != &MPar[0]) &&
MUBMCheck(((mpar_t *)J->Cred.Q->F.PDef)->Index,tmpPAL))
{
*PDef = (mpar_t *)J->Cred.Q->F.PDef;
}
else if ((MPar[0].F.PDef != NULL) &&
(MPar[0].F.PDef != &MPar[0]))
{
*PDef = (mpar_t *)MPar[0].F.PDef;
}
else
{
*PDef = &MPar[MDEF_SYSPDEF];
}
/* verify access to default partition */
@@ -291,70 +331,7 @@ int MJobGetPAL(
return(SUCCESS);
} /* END MJobGetPAL() */
/*
* Determines default partition for a job (precedence: U,G,A,C,S,0)
* 'PAL' is consulted to determine partition access if it is not NULL.
* 'C' is consulted for the default partition if it is not NULL.
*/
mpar_t *MJobFindDefPart(
mjob_t *J, /* I: job */
mclass_t *C, /* I: job class */
int *PAL) /* I: partition access list */
{
mpar_t *PDef;
if ((J->Cred.U->F.PDef != NULL) &&
(J->Cred.U->F.PDef != &MPar[0]) &&
(PAL == NULL ||
MUBMCheck(((mpar_t *)J->Cred.U->F.PDef)->Index,PAL)))
{
PDef = (mpar_t *)J->Cred.U->F.PDef;
}
else if ((J->Cred.G->F.PDef != NULL) &&
(J->Cred.G->F.PDef != &MPar[0]) &&
(PAL == NULL ||
MUBMCheck(((mpar_t *)J->Cred.G->F.PDef)->Index,PAL)))
{
PDef = (mpar_t *)J->Cred.G->F.PDef;
}
else if ((J->Cred.A != NULL) &&
(J->Cred.A->F.PDef != NULL) &&
(J->Cred.A->F.PDef != &MPar[0]) &&
(PAL == NULL ||
MUBMCheck(((mpar_t *)J->Cred.A->F.PDef)->Index,PAL)))
{
PDef = (mpar_t *)J->Cred.A->F.PDef;
}
else if ((C != NULL) &&
(C->F.PDef != NULL) &&
(C->F.PDef != &MPar[0]) &&
(PAL == NULL ||
MUBMCheck(((mpar_t *)C->F.PDef)->Index,PAL)))
{
PDef = (mpar_t *)C->F.PDef;
}
else if ((J->Cred.Q != NULL) &&
(J->Cred.Q->F.PDef != NULL) &&
(J->Cred.Q->F.PDef != &MPar[0]) &&
(PAL == NULL ||
MUBMCheck(((mpar_t *)J->Cred.Q->F.PDef)->Index,PAL)))
{
PDef = (mpar_t *)J->Cred.Q->F.PDef;
}
else if ((MPar[0].F.PDef != NULL) &&
(MPar[0].F.PDef != &MPar[0]))
{
PDef = (mpar_t *)MPar[0].F.PDef;
}
else
{
PDef = &MPar[MDEF_SYSPDEF];
}
return PDef;
} /* END MJobFindDefPart() */
int MParFind(
@@ -602,23 +579,12 @@ int MParSetDefaults(
P->BFProcFactor = DEFAULT_BACKFILLNODEFACTOR;
P->BFMaxSchedules = DEFAULT_MAXBACKFILLSCHEDULES;
P->UseMachineSpeedForFS = DEFAULT_USEMACHINESPEEDFORFS;
P->UseMachineSpeed = DEFAULT_USEMACHINESPEED;
P->UseSystemQueueTime = DEFAULT_USESYSTEMQUEUETIME;
P->JobPrioAccrualPolicy = DEFAULT_JOBPRIOACCRUALPOLICY;
P->NAvailPolicy[0] = DEFAULT_RESOURCEAVAILPOLICY;
/*
* HvB: default is to honour group_list parameter
*/
P->IgnPbsGroupList = 0;
/*
* HvB: default is to disable secondary group lookups for fairshare
*/
P->FSSecondaryGroups = 0;
for (index = 0;index < MAX_MRESOURCETYPE;index++)
{
P->ResourceLimitPolicy[index] = DEFAULT_MRESOURCELIMITPOLICY;
@@ -1254,7 +1220,7 @@ char *MParBMToString(
{
P = &MPar[pindex];
if (!(BM[pindex >> M64.INTLBITS] & (1 << (pindex % M64.INTBITS))))
if (!(BM[pindex >> MINTLBITS] & (1 << (pindex % MINTBITS))))
continue;
if (P->Name[0] == '\0')
@@ -1668,12 +1634,6 @@ int MParProcessOConfig(
break;
case pUseMachineSpeedForFS:
P->UseMachineSpeedForFS = MUBoolFromString(SVal,FALSE);
break;
case pUseMachineSpeed:
P->UseMachineSpeed = MUBoolFromString(SVal,FALSE);
@@ -1760,20 +1720,6 @@ int MParProcessOConfig(
break;
/* HvB */
case pIgnPbsGroupList:
P->IgnPbsGroupList = MUBoolFromString(SVal,FALSE);
break;
/* HvB */
case pFSSecondaryGroups:
P->FSSecondaryGroups = MUBoolFromString(SVal,TRUE);
break;
default:
/* NOT HANDLED */
@@ -2077,15 +2023,6 @@ int MParConfigShow(
if (P->Index == 0)
{
if ((P->UseMachineSpeedForFS == TRUE) ||
(VFlag || (PIndex == -1) || (PIndex == pUseMachineSpeedForFS)))
{
sprintf(Buffer,"%s%-30s %s\n",
Buffer,
MParam[pUseMachineSpeedForFS],
(P->UseMachineSpeedForFS == TRUE) ? "TRUE" : "FALSE");
}
if ((P->UseMachineSpeed == TRUE) ||
(VFlag || (PIndex == -1) || (PIndex == pUseMachineSpeed)))
{
@@ -2525,11 +2462,6 @@ int MParConfigShow(
sprintf(Buffer,"%s%-30s %s\n",Buffer,MParam[pFSPolicy],MFSPolicyType[F->FSPolicy]);
sprintf(Buffer,"%s%-30s %s%s\n",
Buffer,
MParam[pFSPolicy],MFSPolicyType[F->FSPolicy],
(MSched.PercentBasedFS == TRUE) ? "%" : "");
if ((F->FSPolicy == fspNONE) || (VFlag || (PIndex == -1) || (PIndex == pFSPolicy)))
{
sprintf(Buffer,"%s%-30s %s\n",Buffer,MParam[pFSInterval],MULToTString(F->FSInterval));
+331 -399
View File
@@ -39,21 +39,11 @@ extern mres_t *MRes[];
*/
static int MQueueCheckSingleJob(
mjob_t *J,
int *Reason,
mpar_t *P,
mpar_t *GP,
int PLevel,
int MaxNC,
int MaxPC,
unsigned long MaxWCLimit,
int OrigPIndex,
mbool_t UpdateStats);
/* NYI: must handle effqduration */
int MQueueSelectJobs(
int *SrcQ, /* I */
@@ -64,8 +54,7 @@ int MQueueSelectJobs(
unsigned long MaxWCLimit, /* I */
int OrigPIndex, /* I */
int *FReason, /* O */
mbool_t UpdateStats, /* I: (boolean) */
mbool_t OnlyDefPart) /* I: (boolean) */
mbool_t UpdateStats) /* I: (boolean) */
{
int index;
@@ -74,14 +63,27 @@ int MQueueSelectJobs(
mjob_t *J;
char DValue[MAX_MNAME];
enum MJobDependEnum DType;
mpar_t *P;
mpar_t *GP;
long PS;
int LReason[MAX_MREJREASON];
int PReason;
int *Reason;
int PIndex;
int PReq;
mreq_t *RQ;
double PE;
char tmpLine[MAX_MLINE];
const char *FName = "MQueueSelectJobs";
@@ -157,28 +159,324 @@ int MQueueSelectJobs(
continue;
}
if (OnlyDefPart == TRUE && MJobFindDefPart(J, NULL, NULL) != P)
RQ = J->Req[0]; /* FIXME */
/* if job removed */
if (J->Name[0] == '\0')
{
DBG(7,fSCHED) DPrint("INFO: skipping job[%d] '%s', only default partition check requested (and current partition is %s)\n",
jindex,
J->Name,
P->Name);
Reason[marCorruption]++;
continue;
}
if (MQueueCheckSingleJob(
J,
Reason,
P,
GP,
PLevel,
MaxNC,
MaxPC,
MaxWCLimit,
OrigPIndex,
UpdateStats) == FAILURE)
if (UpdateStats == TRUE)
{
J->BlockReason = 0;
if (J->State == mjsIdle)
MStat.IdleJobs++;
}
PReq = MJobGetProcCount(J);
MJobGetPE(J,P,&PE);
PS = (long)PReq * J->SpecWCLimit[0];
/* check partition */
if (OrigPIndex != -1)
{
if ((P->Index == 0) && !(J->Flags & (1 << mjfSpan)))
{
/* why? what does partition '0' mean in partition mode? */
DBG(3,fSCHED) DPrint("INFO: job %s not considered for spanning\n",
J->Name);
Reason[marPartitionAccess]++;
continue;
}
else if ((P->Index != 0) && (J->Flags & (1 << mjfSpan)))
{
DBG(3,fSCHED) DPrint("INFO: spanning job %s not considered for partition scheduling\n",
J->Name);
Reason[marPartitionAccess]++;
continue;
}
if ((P->Index > 0) && (MUBMCheck(P->Index,J->PAL) == FAILURE))
{
DBG(7,fSCHED) DPrint("INFO: job %s not considered for partition %s (allowed %s)\n",
J->Name,
P->Name,
MUListAttrs(ePartition,J->PAL[0]));
Reason[marPartitionAccess]++;
continue;
}
} /* END if (OrigPIndex != -1) */
/* check job state */
if ((J->State != mjsIdle) && (J->State != mjsSuspended))
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected (job in non-idle state '%s')\n",
J->Name,
MJobState[J->State]);
Reason[marState]++;
if ((MaxNC == MAX_MNODE) &&
(MaxWCLimit == MAX_MTIME) &&
(J->R != NULL))
{
if ((J->State != mjsStarting) && (J->State != mjsRunning))
MResDestroy(&J->R);
}
continue;
}
/* check if job has been previously scheduled or deferred */
if ((J->EState != mjsIdle) && (J->EState != mjsSuspended))
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected (job in non-idle expected state: '%s')\n",
J->Name,
MJobState[J->EState]);
Reason[marEState]++;
if ((MaxNC == MAX_MNODE) && (MaxWCLimit == MAX_MTIME) && (J->R != NULL))
{
if ((J->EState != mjsStarting) && (J->EState != mjsRunning))
MResDestroy(&J->R);
}
continue;
}
/* check available procs */
if (PReq > P->CRes.Procs)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected in partition %s (exceeds configured procs: %d > %d)\n",
J->Name,
P->Name,
PReq,
P->CRes.Procs);
Reason[marNodeCount]++;
if (P->Index <= 0)
{
if (J->R != NULL)
MResDestroy(&J->R);
if (J->Hold == 0)
{
MJobSetHold(
J,
(1 << mhDefer),
MSched.DeferTime,
mhrNoResources,
"exceeds partition configured procs");
}
}
continue;
}
/* check partition specific limits */
if (MJobCheckLimits(
J,
PLevel,
P,
(1 << mlSystem),
tmpLine) == FAILURE)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected, partition %s (%s)\n",
J->Name,
P->Name,
tmpLine);
Reason[marSystemLimits]++;
if (P->Index <= 0)
{
if (J->R != NULL)
MResDestroy(&J->R);
MJobSetHold(
J,
(1 << mhDefer),
MSched.DeferTime,
mhrSystemLimits,
"exceeds system proc/job limit");
}
continue;
} /* END if (MJobCheckLimits() == FAILURE) */
/* check job size */
if (PReq > MaxPC)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected in partition %s (exceeds window size: %d > %d)\n",
J->Name,
P->Name,
PReq,
MaxPC);
Reason[marNodeCount]++;
continue;
}
/* check job duration */
if (J->SpecWCLimit[0] > MaxWCLimit)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected in partition %s (exceeds window time: %ld > %ld)\n",
J->Name,
P->Name,
J->SpecWCLimit[0],
MaxWCLimit);
Reason[marTime]++;
continue;
}
/* check partition class support */
if (P->Index > 0)
{
if (MUNumListGetCount(J->StartPriority,RQ->DRes.PSlot,P->CRes.PSlot,0,NULL) == FAILURE)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected, partition %s (classes not supported '%s')\n",
J->Name,
P->Name,
MUCAListToString(RQ->DRes.PSlot,P->CRes.PSlot,NULL));
Reason[marClass]++;
if (J->R != NULL)
MResDestroy(&J->R);
continue;
}
} /* END if (PIndex) */
if (MJobCheckDependency(J,&DType,DValue) == FAILURE)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected (dependent on job '%s' %s)\n",
J->Name,
DValue,
MJobDependType[DType]);
if (GP->JobPrioAccrualPolicy == jpapFullPolicy)
{
J->SystemQueueTime = MSched.Time;
}
Reason[marDepend]++;
if ((MaxNC == MAX_MNODE) &&
(MaxWCLimit == MAX_MTIME) &&
(J->R != NULL))
{
MResDestroy(&J->R);
}
continue;
} /* END if (MJobCheckDependency(J,&JDepend) == FAILURE) */
/* check partition active job policies */
if (MJobCheckPolicies(
J,
PLevel,
(1 << mlActive),
P, /* NOTE: may set to &MPar[0] */
&PReason,
NULL,
MAX_MTIME) == FAILURE)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected, partition %s (policy failure: '%s')\n",
J->Name,
P->Name,
MPolicyRejection[PReason]);
if (PLevel == ptHARD)
{
if (GP->JobPrioAccrualPolicy == jpapFullPolicy)
{
J->SystemQueueTime = MSched.Time;
}
}
Reason[marPolicy]++;
if ((MaxNC == MAX_MNODE) &&
(MaxWCLimit == MAX_MTIME) &&
(J->R != NULL))
{
MResDestroy(&J->R);
}
continue;
}
J->Cred.U->MTime = MSched.Time;
J->Cred.G->MTime = MSched.Time;
if (J->Cred.A != NULL)
J->Cred.A->MTime = MSched.Time;
if (MPar[0].FSC.FSPolicy != fspNONE)
{
int OIndex;
if (MFSCheckCap(NULL,J,P,&OIndex) == FAILURE)
{
DBG(5,fSCHED) DPrint("INFO: job '%s' exceeds %s FS cap\n",
J->Name,
(OIndex > 0) ? MXO[OIndex] : "NONE");
if (GP->JobPrioAccrualPolicy == jpapFullPolicy)
{
J->SystemQueueTime = MSched.Time;
}
Reason[marFairShare]++;
continue;
}
} /* END if (FS[0].FSPolicy != fspNONE) */
/* NOTE: idle queue policies handled in MQueueSelectAllJobs() */
if (MLocalCheckFairnessPolicy(J,MSched.Time,NULL) == FAILURE)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected, partition %s (violates local fairness policy)\n",
J->Name,
P->Name);
if (GP->JobPrioAccrualPolicy == jpapFullPolicy)
{
J->SystemQueueTime = MSched.Time;
}
Reason[marPolicy]++;
continue;
}
/* NOTE: effective queue duration not yet properly supported */
@@ -224,363 +522,6 @@ int MQueueSelectJobs(
return(SUCCESS);
} /* END MQueueSelectJobs() */
/*
* Helper for MQueueSelectJobs: performs the single job evaluation.
* Returns SUCCESS if job can be queued and FAILURE otherwise.
*/
static int MQueueCheckSingleJob(
mjob_t *J,
int *Reason,
mpar_t *P,
mpar_t *GP,
int PLevel,
int MaxNC,
int MaxPC,
unsigned long MaxWCLimit,
int OrigPIndex,
mbool_t UpdateStats)
{
char DValue[MAX_MNAME];
enum MJobDependEnum DType;
long PS;
int PReason;
int PReq;
mreq_t *RQ;
double PE;
char tmpLine[MAX_MLINE];
const char *FName = "MQueueCheckSingleJob";
RQ = J->Req[0]; /* FIXME */
/* if job removed */
if (J->Name[0] == '\0')
{
Reason[marCorruption]++;
return(FAILURE);
}
if (UpdateStats == TRUE)
{
J->BlockReason = 0;
if (J->State == mjsIdle)
MStat.IdleJobs++;
}
PReq = MJobGetProcCount(J);
/* XXX: PE is unused? */
MJobGetPE(J,P,&PE);
PS = (long)PReq * J->SpecWCLimit[0];
/* check partition */
if (OrigPIndex != -1)
{
if ((P->Index == 0) && !(J->Flags & (1 << mjfSpan)))
{
/* why? what does partition '0' mean in partition mode? */
DBG(3,fSCHED) DPrint("INFO: job %s not considered for spanning\n",
J->Name);
Reason[marPartitionAccess]++;
return(FAILURE);
}
else if ((P->Index != 0) && (J->Flags & (1 << mjfSpan)))
{
DBG(3,fSCHED) DPrint("INFO: spanning job %s not considered for partition scheduling\n",
J->Name);
Reason[marPartitionAccess]++;
return(FAILURE);
}
if ((P->Index > 0) && (MUBMCheck(P->Index,J->PAL) == FAILURE))
{
DBG(7,fSCHED) DPrint("INFO: job %s not considered for partition %s (allowed %s)\n",
J->Name,
P->Name,
MUListAttrs(ePartition,J->PAL[0]));
Reason[marPartitionAccess]++;
return(FAILURE);
}
} /* END if (OrigPIndex != -1) */
/* check job state */
if ((J->State != mjsIdle) && (J->State != mjsSuspended))
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected (job in non-idle state '%s')\n",
J->Name,
MJobState[J->State]);
Reason[marState]++;
if ((MaxNC == MAX_MNODE) &&
(MaxWCLimit == MAX_MTIME) &&
(J->R != NULL))
{
if ((J->State != mjsStarting) && (J->State != mjsRunning))
MResDestroy(&J->R);
}
return(FAILURE);
}
/* check if job has been previously scheduled or deferred */
if ((J->EState != mjsIdle) && (J->EState != mjsSuspended))
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected (job in non-idle expected state: '%s')\n",
J->Name,
MJobState[J->EState]);
Reason[marEState]++;
if ((MaxNC == MAX_MNODE) && (MaxWCLimit == MAX_MTIME) && (J->R != NULL))
{
if ((J->EState != mjsStarting) && (J->EState != mjsRunning))
MResDestroy(&J->R);
}
return(FAILURE);
}
/* check available procs */
if (PReq > P->CRes.Procs)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected in partition %s (exceeds configured procs: %d > %d)\n",
J->Name,
P->Name,
PReq,
P->CRes.Procs);
Reason[marNodeCount]++;
if (P->Index <= 0)
{
if (J->R != NULL)
MResDestroy(&J->R);
if (J->Hold == 0)
{
MJobSetHold(
J,
(1 << mhDefer),
MSched.DeferTime,
mhrNoResources,
"exceeds partition configured procs");
}
}
return(FAILURE);
}
/* check partition specific limits */
if (MJobCheckLimits(
J,
PLevel,
P,
(1 << mlSystem),
tmpLine) == FAILURE)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected, partition %s (%s)\n",
J->Name,
P->Name,
tmpLine);
Reason[marSystemLimits]++;
if (P->Index <= 0)
{
if (J->R != NULL)
MResDestroy(&J->R);
MJobSetHold(
J,
(1 << mhDefer),
MSched.DeferTime,
mhrSystemLimits,
"exceeds system proc/job limit");
}
return(FAILURE);
} /* END if (MJobCheckLimits() == FAILURE) */
/* check job size */
if (PReq > MaxPC)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected in partition %s (exceeds window size: %d > %d)\n",
J->Name,
P->Name,
PReq,
MaxPC);
Reason[marNodeCount]++;
return(FAILURE);
}
/* check job duration */
if (J->SpecWCLimit[0] > MaxWCLimit)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected in partition %s (exceeds window time: %ld > %ld)\n",
J->Name,
P->Name,
J->SpecWCLimit[0],
MaxWCLimit);
Reason[marTime]++;
return(FAILURE);
}
/* check partition class support */
if (P->Index > 0)
{
if (MUNumListGetCount(J->StartPriority,RQ->DRes.PSlot,P->CRes.PSlot,0,NULL) == FAILURE)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected, partition %s (classes not supported '%s')\n",
J->Name,
P->Name,
MUCAListToString(RQ->DRes.PSlot,P->CRes.PSlot,NULL));
Reason[marClass]++;
if (J->R != NULL)
MResDestroy(&J->R);
return(FAILURE);
}
} /* END if (PIndex) */
if (MJobCheckDependency(J,&DType,DValue) == FAILURE)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected (dependent on job '%s' %s)\n",
J->Name,
DValue,
MJobDependType[DType]);
if (GP->JobPrioAccrualPolicy == jpapFullPolicy)
{
J->SystemQueueTime = MSched.Time;
}
Reason[marDepend]++;
if ((MaxNC == MAX_MNODE) &&
(MaxWCLimit == MAX_MTIME) &&
(J->R != NULL))
{
MResDestroy(&J->R);
}
return(FAILURE);
} /* END if (MJobCheckDependency(J,&JDepend) == FAILURE) */
/* check partition active job policies */
if (MJobCheckPolicies(
J,
PLevel,
(1 << mlActive),
P, /* NOTE: may set to &MPar[0] */
&PReason,
NULL,
MAX_MTIME) == FAILURE)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected, partition %s (policy failure: '%s')\n",
J->Name,
P->Name,
MPolicyRejection[PReason]);
if (PLevel == ptHARD)
{
if (GP->JobPrioAccrualPolicy == jpapFullPolicy)
{
J->SystemQueueTime = MSched.Time;
}
}
Reason[marPolicy]++;
if ((MaxNC == MAX_MNODE) &&
(MaxWCLimit == MAX_MTIME) &&
(J->R != NULL))
{
MResDestroy(&J->R);
}
return(FAILURE);
}
J->Cred.U->MTime = MSched.Time;
J->Cred.G->MTime = MSched.Time;
if (J->Cred.A != NULL)
J->Cred.A->MTime = MSched.Time;
if (MPar[0].FSC.FSPolicy != fspNONE)
{
int OIndex;
if (MFSCheckCap(NULL,J,P,&OIndex) == FAILURE)
{
DBG(5,fSCHED) DPrint("INFO: job '%s' exceeds %s FS cap\n",
J->Name,
(OIndex > 0) ? MXO[OIndex] : "NONE");
if (GP->JobPrioAccrualPolicy == jpapFullPolicy)
{
J->SystemQueueTime = MSched.Time;
}
Reason[marFairShare]++;
return(FAILURE);
}
} /* END if (FS[0].FSPolicy != fspNONE) */
/* NOTE: idle queue policies handled in MQueueSelectAllJobs() */
if (MLocalCheckFairnessPolicy(J,MSched.Time,NULL) == FAILURE)
{
DBG(6,fSCHED) DPrint("INFO: job %s rejected, partition %s (violates local fairness policy)\n",
J->Name,
P->Name);
if (GP->JobPrioAccrualPolicy == jpapFullPolicy)
{
J->SystemQueueTime = MSched.Time;
}
Reason[marPolicy]++;
return(FAILURE);
}
return(SUCCESS);
} /* END MQueueCheckSingleJob() */
@@ -660,7 +601,7 @@ int MQueueSelectAllJobs(
if (UpdateStats == TRUE)
{
MStatClearUsage(0,(1 << mlIdle)|(1 << mlActive),FALSE);
MStatClearUsage(0,(1 << mlActive)|(1 << mlIdle),FALSE);
}
else if (TrackIdle == TRUE)
{
@@ -1597,16 +1538,7 @@ int MPolicyAdjustUsage(
PConsumed[mptMaxJob] = 1;
PConsumed[mptMaxProc] = MJobGetProcCount(J);
PConsumed[mptMaxNode] = J->Request.NC;
if ((J->Req[0]->NAccessPolicy == mnacSingleJob) &&
(MSched.NodeAllocMaxPS == TRUE))
{
PConsumed[mptMaxPS] = J->NodesRequested * PConsumed[mptMaxWC];
}
else
{
PConsumed[mptMaxPS] = PConsumed[mptMaxProc] * PConsumed[mptMaxWC];
}
PConsumed[mptMaxPS] = PConsumed[mptMaxProc] * PConsumed[mptMaxWC];
MJobGetPE(J,&MPar[0],&PE);
+1 -1
View File
@@ -232,7 +232,7 @@ int MJobSelectPJobList(
if (PreempteeTaskList != NULL)
{
pJ[index].TL = (nodelist_t *)calloc(1, sizeof(nodelist_t));
pJ[index].TL = (nodelist_t *)malloc(sizeof(nodelist_t));
memcpy(pJ[index].TL,&tmpTaskList,sizeof(mnalloc_t) * (tindex + 1));
}
+32 -78
View File
@@ -32,8 +32,7 @@ int MJobGetStartPriority(
int PIndex, /* I */
double *Priority, /* O */
int Mode, /* I */
char **BPtr, /* O (optional,minsize=MMAX_BUFFER) */
int *BSpace) /* O (optional) */
char *Buffer) /* O (optional) */
{
double Prio;
@@ -103,7 +102,7 @@ int MJobGetStartPriority(
(J != NULL) ? J->Name : "[NONE]",
PIndex,
(Priority != NULL) ? "Priority" : "NULL",
((BPtr != NULL) && (*BPtr != NULL)) ? "Buffer" : "NULL");
(Buffer != NULL) ? "Buffer" : "NULL");
/* NOTE: NULL 'J' allowed */
@@ -116,11 +115,7 @@ int MJobGetStartPriority(
if (X.XJobGetStartPriority != (int (*)())0)
{
return (*X.XJobGetStartPriority)(
X.xd,
J,
Priority,
(BPtr != NULL) ? *BPtr : NULL);
return((*X.XJobGetStartPriority)(X.xd,J,Priority,Buffer));
}
for (index = 1;index < MAX_MPRIOCOMPONENT;index++)
@@ -494,7 +489,8 @@ int MJobGetStartPriority(
}
} /* END if (CWeight[mpcUsage] != 0) */
MUSNPrintF(BPtr,BSpace,"%-20s %10s%c %*s%*s%*s%*s%*s%*s%*s\n",
sprintf(Buffer,"%s%-20s %10s%c %*s%*s%*s%*s%*s%*s%*s\n",
Buffer,
"Job",
"PRIORITY",
'*',
@@ -513,7 +509,8 @@ int MJobGetStartPriority(
(int)strlen(CHeader[mpcUsage]),
CHeader[mpcUsage]);
MUSNPrintF(BPtr,BSpace,"%20s %10s%c %*s%*s%*s%*s%*s%*s%*s\n",
sprintf(Buffer,"%s%20s %10s%c %*s%*s%*s%*s%*s%*s%*s\n",
Buffer,
"Weights",
"--------",
' ',
@@ -532,7 +529,7 @@ int MJobGetStartPriority(
(int)strlen(CWLine[mpcUsage]),
CWLine[mpcUsage]);
MUSNPrintF(BPtr,BSpace,"\n");
strcat(Buffer,"\n");
DBG(5,fUI) DPrint("INFO: %s header created\n",
FName);
@@ -646,9 +643,10 @@ int MJobGetStartPriority(
}
} /* END for (cindex) */
MUSNPrintF(BPtr,BSpace,"\n");
strcat(Buffer,"\n");
MUSNPrintF(BPtr,BSpace,"%-20s %10s%c %*s%*s%*s%*s%*s%*s%*s\n",
sprintf(Buffer,"%s%-20s %10s%c %*s%*s%*s%*s%*s%*s%*s\n",
Buffer,
"Percent Contribution",
"--------",
' ',
@@ -667,9 +665,9 @@ int MJobGetStartPriority(
(int)strlen(CFooter[mpcUsage]),
CFooter[mpcUsage]);
MUSNPrintF(BPtr,BSpace,"\n");
strcat(Buffer,"\n");
MUSNPrintF(BPtr,BSpace,"* indicates system prio set on job\n");
strcat(Buffer,"* indicates system prio set on job\n");
return(SUCCESS);
} /* END if (Mode == 2) */
@@ -761,18 +759,9 @@ int MJobGetStartPriority(
if (FSTargetUsage > 0.0)
{
if (MSched.PercentBasedFS == TRUE)
{
SFactor[mpsFU] = 1.0 -
(((J->Cred.U->F.FSUsage[0] + J->Cred.U->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0)/FSTargetUsage);
}
else
{
SFactor[mpsFU] = FSTargetUsage -
(J->Cred.U->F.FSUsage[0] + J->Cred.U->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0;
}
SFactor[mpsFU] = FSTargetUsage -
(J->Cred.U->F.FSUsage[0] + J->Cred.U->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0;
switch(FSMode)
{
@@ -806,18 +795,9 @@ int MJobGetStartPriority(
if (FSTargetUsage > 0.0)
{
if (MSched.PercentBasedFS == TRUE)
{
SFactor[mpsFG] = 1.0 -
(((J->Cred.G->F.FSUsage[0] + J->Cred.G->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0)/FSTargetUsage);
}
else
{
SFactor[mpsFG] = FSTargetUsage -
(J->Cred.G->F.FSUsage[0] + J->Cred.G->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0;
}
SFactor[mpsFG] = FSTargetUsage -
(J->Cred.G->F.FSUsage[0] + J->Cred.G->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0;
switch(FSMode)
{
@@ -851,18 +831,9 @@ int MJobGetStartPriority(
{
if (J->Cred.A != NULL)
{
if (MSched.PercentBasedFS == TRUE)
{
SFactor[mpsFA] = 1.0 -
(((J->Cred.A->F.FSUsage[0] + J->Cred.A->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0)/FSTargetUsage);
}
else
{
SFactor[mpsFA] = FSTargetUsage -
(J->Cred.A->F.FSUsage[0] + J->Cred.A->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0;
}
SFactor[mpsFA] = FSTargetUsage -
(J->Cred.A->F.FSUsage[0] + J->Cred.A->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0;
}
else
{
@@ -900,18 +871,9 @@ int MJobGetStartPriority(
{
if (J->Cred.C != NULL)
{
if (MSched.PercentBasedFS == TRUE)
{
SFactor[mpsFC] = 1.0 -
(((J->Cred.C->F.FSUsage[0] + J->Cred.C->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0)/FSTargetUsage);
}
else
{
SFactor[mpsFC] = FSTargetUsage -
(J->Cred.C->F.FSUsage[0] + J->Cred.C->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0;
}
SFactor[mpsFC] = FSTargetUsage -
(J->Cred.C->F.FSUsage[0] + J->Cred.C->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0;
}
else
{
@@ -949,18 +911,9 @@ int MJobGetStartPriority(
{
if (J->Cred.Q != NULL)
{
if (MSched.PercentBasedFS == TRUE)
{
SFactor[mpsFQ] = 1.0 -
(((J->Cred.Q->F.FSUsage[0] + J->Cred.Q->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0)/FSTargetUsage);
}
else
{
SFactor[mpsFQ] = FSTargetUsage -
(J->Cred.Q->F.FSUsage[0] + J->Cred.Q->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0;
}
SFactor[mpsFQ] = FSTargetUsage -
(J->Cred.Q->F.FSUsage[0] + J->Cred.Q->F.FSFactor) /
(GP->F.FSUsage[0] + GP->F.FSFactor) * 100.0;
}
else
{
@@ -1122,7 +1075,7 @@ int MJobGetStartPriority(
APrio += ABS((double)CWeight[index] * CFactor[index]);
} /* END for (index) */
if ((BPtr != NULL) && (*BPtr != NULL))
if (Buffer != NULL)
{
TotalPriority += APrio;
@@ -1402,7 +1355,8 @@ int MJobGetStartPriority(
}
} /* END if (CWeight[mpcUsage] != 0) */
MUSNPrintF(BPtr,BSpace,"%-20s %10.0lf%c %*s%*s%*s%*s%*s%*s%*s\n",
sprintf(Buffer,"%s%-20s %10.0lf%c %*s%*s%*s%*s%*s%*s%*s\n",
Buffer,
J->Name,
Prio,
(J->SystemPrio > 0) ? '*' : ' ',
@@ -1420,7 +1374,7 @@ int MJobGetStartPriority(
CLine[mpcRes],
(int)strlen(CLine[mpcUsage]),
CLine[mpcUsage]);
} /* END if (BPtr != NULL) */
} /* END if (Buffer != NULL) */
/* clip prio at min value */
+1 -2
View File
@@ -17,7 +17,6 @@ extern mgcred_t *MUser[];
extern mgcred_t MGroup[];
extern mgcred_t MAcct[];
extern mclass_t MClass[];
extern m64_t M64;
extern const char *MQOSFlags[];
extern const char *MQALType[];
@@ -897,7 +896,7 @@ char *MQOSBMToString(
for (bindex = 0;bindex < MAX_MQOS;bindex++)
{
if (!(BM[bindex >> M64.INTLBITS] & (1 << (bindex % M64.INTBITS))))
if (!(BM[bindex >> MINTLBITS] & (1 << (bindex % MINTBITS))))
continue;
Q = &MQOS[bindex];
+5 -16
View File
@@ -91,7 +91,7 @@ int MQueuePrioritizeJobs(
{
J = MJob[JobIndex[jindex]];
MJobGetStartPriority(J,0,&tmpD,0,NULL,NULL);
MJobGetStartPriority(J,0,&tmpD,0,NULL);
J->StartPriority = (unsigned long)tmpD;
@@ -113,7 +113,7 @@ int MQueuePrioritizeJobs(
for (J = Q[0]->Next;J != Q[0];J = J->Next)
{
MJobGetStartPriority(J,0,&tmpD,0,NULL,NULL);
MJobGetStartPriority(J,0,&tmpD,0,NULL);
J->StartPriority = (unsigned long)tmpD;
@@ -338,7 +338,6 @@ int MQueueBackFill(
AdjBFTime,
P->Index,
NULL,
FALSE,
FALSE) == FAILURE)
{
DBG(5,fSCHED) DPrint("INFO: no jobs meet BF window criteria in partition %s\n",
@@ -926,8 +925,7 @@ int MQueueDiagnose(
int *NBJobList,
int PLevel,
mpar_t *PS,
char *Buffer,
int BufSize)
char *Buffer)
{
int pindex;
@@ -979,9 +977,6 @@ int MQueueDiagnose(
for (J = FullQ[0]->Next;J != FullQ[0];J = J->Next)
{
if (strlen(Buffer) + 256 >= BufSize)
break;
if ((PS->Index > 0) && (MUBMCheck(PS->Index,J->PAL) == FAILURE))
continue;
@@ -1188,7 +1183,7 @@ int MQueueDiagnose(
if (IsBlocked == FALSE)
{
switch (J->BlockReason)
switch(J->BlockReason)
{
case mjneIdlePolicy:
@@ -1210,12 +1205,7 @@ int MQueueDiagnose(
break;
} /* END switch(J->BlockReason) */
}
}
if (J != FullQ[0])
{
strcat(Buffer,"\nlist truncated\n");
}
} /* END for (jindex) */
return(SUCCESS);
} /* END MQueueDiagnose() */
@@ -1409,7 +1399,6 @@ int MQueueCheckStatus()
MAX_MTIME,
-1,
ReasonList,
FALSE,
FALSE) == FAILURE)
{
strcpy(DeferMessage,"SCHED_INFO: job cannot run. Reason: cannot select job\n");
+20 -53
View File
@@ -754,6 +754,11 @@ int MRMJobCancel(
break;
} /* END switch(MSched.Mode) */
if (J->IFlags & (1 << mjifIsExiting))
{
return(SUCCESS);
}
memset(RMList,0,sizeof(RMList));
rmcount = 0;
@@ -1771,7 +1776,7 @@ int MRMLoadConfig(
MRMSetDefaults(R);
MOLoadPvtConfig((void **)R,mxoRM,NULL,NULL,NULL);
MOLoadPvtConfig((void **)R,mxoRM,NULL,NULL,NULL);
}
/* load RM specific attributes */
@@ -2032,8 +2037,6 @@ int MRMSetDefaults(
R->JobCounter = 0;
R->ASyncJobStart = FALSE;
return(SUCCESS);
}
@@ -2244,7 +2247,7 @@ int MRMProcessConfig(
ptr,
(const char **)MRMAttr,
&aindex,
NULL,
NULL,
TRUE,
NULL,
ValLine,
@@ -2268,12 +2271,6 @@ int MRMProcessConfig(
break;
case mrmaASyncJobStart:
R->ASyncJobStart = MUBoolFromString(ValLine,FALSE);
break;
case mrmaConfigFile:
MUStrCpy(R->U.LL.ConfigFile,ValLine,sizeof(R->U.LL.ConfigFile));
@@ -2310,12 +2307,6 @@ int MRMProcessConfig(
MUStrDup(&R->P[1].HostName,ValLine);
break;
case mrmaEPort:
R->EPort = (int)strtol((char *)Value,NULL,0);
break;
case mrmaPort:
@@ -2928,12 +2919,6 @@ int MRMSetAttr(
break;
case mrmaEPort:
R->EPort = (int)strtol((char *)Value,NULL,0);
break;
case mrmaHost:
if (Value != NULL)
@@ -3580,6 +3565,10 @@ int MRMJobPreLoad(
/* NOTE: handling of tasklist information */
/* TaskList[] contains updated task ordering information */
/* must update both J->NodeList and J->Req[X]->NodeList */
/* this call should override, not add to existing info */
int MRMJobPostLoad(
@@ -3604,7 +3593,6 @@ int MRMJobPostLoad(
char ErrMsg[MAX_MLINE];
char tmpLine[MAX_MLINE];
char tmpFBAccount[MAX_MLINE];
const char *FName = "MRMJobPostLoad";
@@ -3661,10 +3649,6 @@ int MRMJobPostLoad(
RQ = J->Req[0];
MUBMOR(RQ->ReqFBM,J->Cred.C->DefFBM,MAX_MATTR);
if (J->Cred.C->NAPolicy != 0)
RQ->NAccessPolicy = J->Cred.C->NAPolicy;
} /* END for (rqindex) */
}
@@ -3831,31 +3815,14 @@ int MRMJobPostLoad(
J->Name,
MDefReason[Reason]);
/* Bug in the maui-gold interaction when FALLBACKACCOUNT is enabled
neccessitates this double check */
if (Reason == mhrNoFunds || Reason == mhrAMFailure)
if (Reason == mhrNoFunds)
{
/* If the fallbackaccount starts with a + then append it to the
primary accountname */
if (MAM[0].FallbackAccount[0] == '+')
{
snprintf(tmpFBAccount,sizeof(tmpFBAccount),"%s%s",
J->Cred.A->Name,
MAM[0].FallbackAccount + 1);
}
else
{
strcpy(tmpFBAccount,MAM[0].FallbackAccount);
}
DBG(3,fRM) DPrint("WARNING: insufficient allocation in account '%s' to run job '%s' (attempting fallback account '%s')\n",
J->Cred.A->Name,
J->Name,
tmpFBAccount);
MAM[0].FallbackAccount);
if (MAcctFind(tmpFBAccount,&A) == SUCCESS)
if (MAcctFind(MAM[0].FallbackAccount,&A) == SUCCESS)
{
J->Cred.A = A;
@@ -3864,7 +3831,7 @@ int MRMJobPostLoad(
else
{
DBG(2,fRM) DPrint("ALERT: cannot locate fallback account '%s'\n",
tmpFBAccount);
MAM[0].FallbackAccount);
}
}
}
@@ -4241,11 +4208,11 @@ int MRMJobPostUpdate(
{
mreq_t *RQ;
int index = 0;
int nindex = 0;
int rqindex = 0;
int tindex = 0;
int jnindex = 0;
int index;
int nindex;
int rqindex;
int tindex;
int jnindex;
int TC;
+41 -73
View File
@@ -166,10 +166,8 @@ int MResCreate(
strcmp(CAName,NONE))
{
MAcctAdd(CAName,&R->A);
/* prevent checkpointed rsv's from double creating AM reservations */
if (MSched.Iteration >= 0)
if (MSched.Iteration > 0)
{
if (StartTime > MSched.Time)
WallTime = MIN(MAM[0].FlushInterval,EndTime - StartTime);
@@ -1239,7 +1237,7 @@ int MResToXML(
int *AList;
char tmpString[MAX_MBUFFER];
char tmpString[MAX_MLINE];
if ((R == NULL) || (E == NULL))
{
@@ -2900,19 +2898,11 @@ int MNodeBuildRE(
memset(&ZRes,0,sizeof(ZRes));
CRE = (mre_t *)calloc(((MAX_MRES_DEPTH << 1) + 1), sizeof(mre_t));
ORE = (mre_t *)calloc(((MAX_MRES_DEPTH << 1) + 1), sizeof(mre_t));
NRE = (mre_t *)calloc(((MAX_MRES_DEPTH << 1) + 1), sizeof(mre_t));
JRE = (mre_t *)calloc(((MAX_MRES_DEPTH << 1) + 1), sizeof(mre_t));
CRE = (mre_t *)malloc(sizeof(mre_t) * ((MAX_MRES_DEPTH << 1) + 1));
ORE = (mre_t *)malloc(sizeof(mre_t) * ((MAX_MRES_DEPTH << 1) + 1));
NRE = (mre_t *)malloc(sizeof(mre_t) * ((MAX_MRES_DEPTH << 1) + 1));
JRE = (mre_t *)malloc(sizeof(mre_t) * ((MAX_MRES_DEPTH << 1) + 1));
if (CRE == NULL || ORE == NULL || NRE == NULL || JRE == NULL )
{
DBG(4,fCORE) DPrint("ALERT: cannot allocate memory in %s\n",
FName);
return(FAILURE);
}
CRI[0] = -1;
ResFound = FALSE;
@@ -4322,19 +4312,16 @@ int MResCheckJAccess(
}
} /* END for (aindex) */
if (aindex < MAX_MACL)
if (J->Cred.CL[aindex].Type == maNONE)
{
if (J->Cred.CL[aindex].Type == maNONE)
{
/* create new time CL */
/* create new time CL */
J->Cred.CL[aindex].Type = maDuration;
J->Cred.CL[aindex].Value = Overlap;
J->Cred.CL[aindex].Cmp = mcmpEQ;
J->Cred.CL[aindex].Affinity = nmPositiveAffinity;
J->Cred.CL[aindex].Type = maDuration;
J->Cred.CL[aindex].Value = Overlap;
J->Cred.CL[aindex].Cmp = mcmpEQ;
J->Cred.CL[aindex].Affinity = nmPositiveAffinity;
OTime = -1;
}
OTime = -1;
}
/* NOTE: res wrappers gain access if R(job) is inclusive on J(res) */
@@ -4344,15 +4331,12 @@ int MResCheckJAccess(
else
MACLCheckAccess(R->ACL,J->Cred.CL,Affinity,&IsInclusive);
if (aindex < MAX_MACL)
{
/* restore time CL */
/* restore time CL */
if (OTime == -1)
J->Cred.CL[aindex].Type = maNONE;
else
J->Cred.CL[aindex].Value = OTime;
}
if (OTime == -1)
J->Cred.CL[aindex].Type = maNONE;
else
J->Cred.CL[aindex].Value = OTime;
} /* END if ((R->ExpireTime <= 0) || (R->ExpireTime == MAX_MTIME)) */
return(IsInclusive);
@@ -5877,28 +5861,25 @@ int MRLMerge(
if (IsCorrupt == TRUE)
{
DBG(3,fALL)
for (index1 = 0;R1[index1].EndTime != 0;index1++)
{
for (index1 = 0;R1[index1].EndTime != 0;index1++)
{
DPrint("INFO: R1[%d] S: %ld E: %ld T: %d N: %d\n",
index1,
R1[index1].StartTime,
R1[index1].EndTime,
R1[index1].TaskCount,
R1[index1].NodeCount);
}
for (index1 = 0;R2[index1].EndTime != 0;index1++)
{
DPrint("INFO: R2[%d] S: %ld E: %ld T: %d N: %d\n",
index1,
R2[index1].StartTime,
R2[index1].EndTime,
R2[index1].TaskCount,
R2[index1].NodeCount);
} /* END for (index1) */
DPrint("INFO: R1[%d] S: %ld E: %ld T: %d N: %d\n",
index1,
R1[index1].StartTime,
R1[index1].EndTime,
R1[index1].TaskCount,
R1[index1].NodeCount);
}
for (index1 = 0;R2[index1].EndTime != 0;index1++)
{
DPrint("INFO: R2[%d] S: %ld E: %ld T: %d N: %d\n",
index1,
R2[index1].StartTime,
R2[index1].EndTime,
R2[index1].TaskCount,
R2[index1].NodeCount);
} /* END for (index1) */
} /* END if (IsCorrupt == TRUE) */
memcpy(R1,C,sizeof(mrange_t) * (cindex + 1));
@@ -7141,29 +7122,19 @@ int MResAdjustDRes(
/* where possible using memcmp. Insert all container reservation */
/* events at BRes calculation completion */
if (CRE == NULL || ORE == NULL || NRE == NULL || JRE == NULL )
if (CRE == NULL)
{
memset(&ZRes,0,sizeof(ZRes));
/* changed the mallocs to callocs because there is code below */
/* that requires things to be zero'ed */
if (CRE == NULL ) {
CRE = (mre_t *)calloc((MSched.ResDepth << 1),sizeof(mre_t));
}
if (ORE == NULL ){
ORE = (mre_t *)calloc((MSched.ResDepth << 1),sizeof(mre_t));
}
if (NRE == NULL ){
NRE = (mre_t *)calloc((MSched.ResDepth << 1),sizeof(mre_t));
}
if (JRE == NULL ){
JRE = (mre_t *)calloc((MSched.ResDepth << 1),sizeof(mre_t));
}
CRE = (mre_t *)malloc(sizeof(mre_t) * (MSched.ResDepth << 1));
ORE = (mre_t *)malloc(sizeof(mre_t) * (MSched.ResDepth << 1));
NRE = (mre_t *)malloc(sizeof(mre_t) * (MSched.ResDepth << 1));
JRE = (mre_t *)malloc(sizeof(mre_t) * (MSched.ResDepth << 1));
DRSize = sizeof(mcres_t);
} /* END if (CRE == NULL) */
if (CRE == NULL || ORE == NULL || NRE == NULL || JRE == NULL )
if (CRE == NULL)
{
DBG(4,fCORE) DPrint("ALERT: cannot allocate memory in %s\n",
FName);
@@ -7200,9 +7171,6 @@ int MResAdjustDRes(
if (jreindex >= (MSched.ResDepth << 1) - 1)
break;
if ((N->R[N->RE[nreindex].Index] == NULL) || (N->R[N->RE[nreindex].Index] == (mrsv_t *)1))
continue;
if (N->R[N->RE[nreindex].Index]->Type == mrtJob)
{
JRETime = N->RE[nreindex].Time;
+1 -1
View File
@@ -2706,7 +2706,7 @@ int MSRProcessOConfig(
char *TokPtr;
int index;
int FMap[(MAX_MATTR >> 5) + 1];
int FMap[MAX_MATTR >> 5];
MUBMClear(FMap,MAX_MATTR);
+67 -166
View File
@@ -19,7 +19,6 @@ extern msys_t MSystem;
extern mframe_t MFrame[];
extern mckpt_t MCP;
extern mres_t *MRes[];
extern m64_t M64;
extern int MAQ[];
extern int MUIQ[];
@@ -393,7 +392,6 @@ int MJobAllocMNL(
if (MJobSelectResourceSet(
J,
RQ,
(RQ->SetType != mrstNONE) ? RQ->SetType : MPar[0].NodeSetAttribute,
(tmpRSS != mrssOneOf) ? tmpRSS : mrssFirstOf,
(RQ->SetList[0] != NULL) ? RQ->SetList : MPar[0].NodeSetList,
@@ -603,7 +601,6 @@ int MJobAllocMNL(
if ((nsindex == 0) && (MJobSelectResourceSet(
J,
RQ,
(RQ->SetType != mrstNONE) ? RQ->SetType : MPar[0].NodeSetAttribute,
(tmpRSS != mrssOneOf) ? tmpRSS : mrssFirstOf,
(RQ->SetList[0] != NULL) ? RQ->SetList : MPar[0].NodeSetList,
@@ -1303,13 +1300,13 @@ int MJobSelectMNL(
int AvailableTaskCount[MAX_MREQ_PER_JOB];
int TotalAvailINC = 0;
int TotalAvailITC = 0;
int TotalAvailIPC = 0;
int TotalAvailINC;
int TotalAvailITC;
int TotalAvailIPC;
int TotalAvailPNC = 0;
int TotalAvailPTC = 0;
int TotalAvailPPC = 0;
int TotalAvailPNC;
int TotalAvailPTC;
int TotalAvailPPC;
int PreempteeTCList[MAX_MJOB];
int PreempteeNCList[MAX_MJOB];
@@ -1352,7 +1349,7 @@ int MJobSelectMNL(
int SC;
int AllowPreemption = FALSE;
int AllowPreemption;
int PIsConditional = FALSE;
const char *FName = "MJobSelectMNL";
@@ -1786,7 +1783,7 @@ int MJobSelectMNL(
nindex = TotalAvailINC; /* HACK */
NodeList = (mnalloc_t *)tmpMNL[0];
NodeList = (mnalloc_t *)MNodeList[0];
for (jindex = 0;PreempteeJobList[jindex] != NULL;jindex++)
{
@@ -2026,7 +2023,6 @@ int MSchedTest()
int MJobSelectResourceSet(
mjob_t *J, /* I */
mreq_t *RQ, /* I */
int SetType, /* I */
int SetSelection, /* I */
char **SetList, /* I */
@@ -2069,6 +2065,8 @@ int MJobSelectResourceSet(
mnode_t *N;
mreq_t *RQ;
const char *FName = "MJobSelectResourceSet";
DBG(4,fSCHED) DPrint("%s(%s,%d,%d,SetList,NodeList,%d)\n",
@@ -2095,7 +2093,9 @@ int MJobSelectResourceSet(
return(SUCCESS);
}
TasksRequired = RQ->TaskCount;
RQ = J->Req[0];
TasksRequired = J->Request.TC;
NodesRequired = RQ->NodeCount;
memset(SetCount,0,sizeof(SetCount));
@@ -2257,8 +2257,8 @@ int MJobSelectResourceSet(
for (sindex = 0;sindex < MaxSet;sindex++)
{
if (N->FBM[SetIndex[sindex] >> M64.INTLBITS] &
(1 << (SetIndex[sindex] % M64.INTBITS)))
if (N->FBM[SetIndex[sindex] >> MINTLBITS] &
(1 << (SetIndex[sindex] % MINTBITS)))
{
SetCount[sindex] += TC;
SetNC[sindex] ++;
@@ -2423,8 +2423,8 @@ int MJobSelectResourceSet(
{
case mrstFeature:
if (N->FBM[SetIndex[sindex] >> M64.INTLBITS] &
(1 << (SetIndex[sindex] % M64.INTBITS)))
if (N->FBM[SetIndex[sindex] >> MINTLBITS] &
(1 << (SetIndex[sindex] % MINTBITS)))
{
/* node is feasible */
@@ -2577,8 +2577,8 @@ int MJobSelectResourceSet(
{
case mrstFeature:
if (N->FBM[SetIndex[BestSet] >> M64.INTLBITS] &
(1 << (SetIndex[BestSet] % M64.INTBITS)))
if (N->FBM[SetIndex[BestSet] >> MINTLBITS] &
(1 << (SetIndex[BestSet] % MINTBITS)))
{
/* node is in set */
@@ -3565,6 +3565,8 @@ int MSchedSetDefaults(
msched_t *S) /* I */
{
struct timezone tzp;
char *ptr;
int count;
@@ -3661,8 +3663,13 @@ int MSchedSetDefaults(
S->Schedule = TRUE;
S->Interval = 0;
gettimeofday(&S->SchedTime,NULL);
S->FBPollInterval = MDEF_FBPOLLINTERVAL;
S->FBFailureCount = MDEF_FBFAILURECOUNT;
gettimeofday(&S->SchedTime,&tzp);
S->GreenwichOffset = - (tzp.tz_minuteswest * 60);
strcpy(S->Admin1User[0],DEFAULT_SchedADMIN);
S->Admin1User[1][0] = '\0';
@@ -4969,61 +4976,13 @@ int MSchedProcessOConfig(
case mcoDirectoryServer:
{
int tmpI;
char *ptr;
char *TokPtr;
/* FORMAT: <HOST>[:<PORT>] */
TokPtr = NULL;
ptr = MUStrTok(SVal,": \t\n",&TokPtr);
if (ptr != NULL)
MUStrDup(&MSched.DS.HostName,ptr);
ptr = MUStrTok(NULL,": \t\n",&TokPtr);
if (ptr != NULL)
{
tmpI = (int)strtol(ptr,NULL,10);
if (tmpI > 0)
MSched.DS.Port = tmpI;
}
} /* END BLOCK */
/* NYI */
break;
case mcoEventServer:
{
int tmpI;
char *ptr;
char *TokPtr;
/* FORMAT: <HOST>[:<PORT>] */
TokPtr = NULL;
ptr = MUStrTok(SVal,": \t\n",&TokPtr);
if (ptr != NULL)
MUStrDup(&MSched.EM.HostName,ptr);
ptr = MUStrTok(NULL,": \t\n",&TokPtr);
if (ptr != NULL)
{
tmpI = (int)strtol(ptr,NULL,10);
if (tmpI > 0)
MSched.EM.Port = tmpI;
}
} /* END BLOCK */
/* NYI */
break;
@@ -5465,12 +5424,6 @@ int MSchedProcessOConfig(
break;
case pNAMaxPS:
S->NodeAllocMaxPS = MUBoolFromString(SVal,FALSE);
break;
case pSchedMode:
S->Mode = MUGetIndex(SVal,MSchedMode,FALSE,S->Mode);
@@ -6240,9 +6193,6 @@ int MJobDistributeTasks(
for (nindex = 0;RQ->NodeList[nindex].N != NULL;nindex++)
{
if (nindex >= MAX_MNODE_PER_JOB)
break;
MaxTPN = MAX(MaxTPN,RQ->NodeList[nindex].TC);
}
@@ -6254,9 +6204,6 @@ int MJobDistributeTasks(
for (nindex = 0;RQ->NodeList[nindex].N != NULL;nindex++)
{
if (nindex >= MAX_MNODE_PER_JOB)
break;
if (Overflow == 0)
break;
@@ -6283,9 +6230,6 @@ int MJobDistributeTasks(
for (nindex = 0;RQ->NodeList[nindex].N != NULL;nindex++)
{
if (nindex >= MAX_MNODE_PER_JOB)
break;
if (index == RQ->NodeCount)
{
DBG(6,fSCHED) DPrint("INFO: nodecount %d reached\n",
@@ -6353,9 +6297,6 @@ int MJobDistributeTasks(
for (nindex = sindex;RQ->NodeList[nindex].N != NULL;nindex++)
{
if (nindex >= MAX_MNODE_PER_JOB)
break;
if ((int)RQ->NodeList[nindex].TC > MaxTPN)
{
MaxTPN = RQ->NodeList[nindex].TC;
@@ -6380,9 +6321,6 @@ int MJobDistributeTasks(
for (nindex = 0;nindex < AllocIndex;nindex++)
{
if (nindex >= MAX_MNODE_PER_JOB)
break;
if (RQ->BlockingFactor != 1)
{
/* blocking factor specification removes single step constraint */
@@ -6420,9 +6358,6 @@ int MJobDistributeTasks(
for (nindex = AllocIndex - 1;nindex > 0;nindex--)
{
if (nindex >= MAX_MNODE_PER_JOB)
break;
if (tmpNodeList[nindex].TC != tmpNodeList[nindex - 1].TC)
{
tmpNodeList[nindex - 1].TC--;
@@ -6441,9 +6376,6 @@ int MJobDistributeTasks(
for (nindex = AllocIndex - 1;nindex >= 0;nindex--)
{
if (nindex >= MAX_MNODE_PER_JOB)
break;
tmpNodeList[nindex].TC--;
TasksAvail--;
@@ -6478,9 +6410,6 @@ int MJobDistributeTasks(
for (nindex = 0;RQ->NodeList[nindex].N != NULL;nindex++)
{
if (nindex >= MAX_MNODE_PER_JOB)
break;
if (RQ->NodeList[nindex].TC >= TPN)
{
tmpNodeCount --;
@@ -6510,9 +6439,6 @@ int MJobDistributeTasks(
for (nindex = 0;RQ->NodeList[nindex].N != NULL;nindex++)
{
if (nindex >= MAX_MNODE_PER_JOB)
break;
tmpNodeList[index].N = RQ->NodeList[nindex].N;
if (RQ->NodeCount > 0)
@@ -6596,6 +6522,8 @@ int MJobDistributeTasks(
} /* END else (R->Type == rmLL) */
} /* END for (rqindex) */
tmpNodeList[tmpNodeCount].N = NULL;
if (NodeList != NULL)
@@ -6705,9 +6633,6 @@ int MJobDistributeTasks(
for (nindex1 = 0;NodeList[nindex1].N != NULL;nindex1++)
{
if (nindex >= MAX_MNODE_PER_JOB)
break;
if (NodeList[nindex1].TC == 0)
continue;
@@ -6738,52 +6663,6 @@ int MJobDistributeTasks(
} /* END MJobDistributeTasks() */
/* Helper routine for MSchedProcessJobs() */
static void m_schedule_on_partitions(
int OnlyDefPart, /* I */
int DoBackfill, /* I */
int *CurrentQ) /* I */
{
int PIndex;
int tmpQ[MAX_MJOB];
for (PIndex = 0;PIndex < MAX_MPAR;PIndex++)
{
if (((PIndex == 0) && (MPar[2].ConfigNodes == 0)) ||
(MPar[PIndex].ConfigNodes == 0))
{
continue;
}
MOQueueInitialize(tmpQ);
if (MQueueSelectJobs(
CurrentQ,
tmpQ,
ptSOFT,
MAX_MNODE,
MAX_MTASK,
MAX_MTIME,
PIndex,
NULL,
TRUE,
OnlyDefPart) == SUCCESS)
{
MQueueScheduleIJobs(tmpQ,&MPar[PIndex]);
if (DoBackfill == TRUE && MPar[PIndex].BFPolicy != ptOFF)
{
/* backfill jobs using 'soft' policy constraints */
MQueueBackFill(tmpQ,ptSOFT,&MPar[PIndex]);
}
}
MOQueueDestroy(tmpQ,FALSE);
} /* END for (PIndex) */ \
} /* END m_schedule_on_partitions() */
int MSchedProcessJobs(
@@ -6888,7 +6767,6 @@ int MSchedProcessJobs(
MAX_MTIME,
-1,
NULL,
FALSE,
FALSE) == SUCCESS)
{
memcpy(MFQ,tmpQ,sizeof(MFQ));
@@ -6911,20 +6789,45 @@ int MSchedProcessJobs(
MAX_MTIME,
-1,
NULL,
TRUE,
FALSE);
TRUE);
/* schedule priority jobs */
if (CurrentQ[0] != -1)
{
/* schedule jobs on their default partitions; skip backfilling */
for (PIndex = 0;PIndex < MAX_MPAR;PIndex++)
{
if (((PIndex == 0) && (MPar[2].ConfigNodes == 0)) ||
(MPar[PIndex].ConfigNodes == 0))
{
continue;
}
m_schedule_on_partitions(TRUE, FALSE, CurrentQ);
MOQueueInitialize(tmpQ);
/* schedule jobs on all partitions; do backfilling */
if (MQueueSelectJobs(
CurrentQ,
tmpQ,
ptSOFT,
MAX_MNODE,
MAX_MTASK,
MAX_MTIME,
PIndex,
NULL,
TRUE) == SUCCESS)
{
MQueueScheduleIJobs(tmpQ,&MPar[PIndex]);
m_schedule_on_partitions(FALSE, TRUE, CurrentQ);
if (MPar[PIndex].BFPolicy != ptOFF)
{
/* backfill jobs using 'soft' policy constraints */
MQueueBackFill(tmpQ,ptSOFT,&MPar[PIndex]);
}
}
MOQueueDestroy(tmpQ,FALSE);
} /* END for (PIndex) */
} /* END if (GlobalSQ[0] != -1) */
MOQueueDestroy(CurrentQ,TRUE);
@@ -6938,8 +6841,7 @@ int MSchedProcessJobs(
MAX_MTIME,
-1,
NULL,
TRUE,
FALSE);
TRUE);
if (CurrentQ[0] != -1)
{
@@ -6971,8 +6873,7 @@ int MSchedProcessJobs(
MAX_MTIME,
PIndex,
NULL,
TRUE,
FALSE) == SUCCESS)
TRUE) == SUCCESS)
{
MQueueBackFill(tmpQ,ptHARD,&MPar[PIndex]);
}
@@ -7014,8 +6915,7 @@ int MSchedProcessJobs(
MAX_MTIME,
-1,
NULL,
TRUE,
FALSE);
TRUE);
/* must sort/order MUIQ */
@@ -7031,6 +6931,7 @@ int MSchedUpdateStats()
{
struct timeval tvp;
struct timezone tzp;
long schedtime;
double efficiency;
@@ -7047,7 +6948,7 @@ int MSchedUpdateStats()
DBG(2,fCORE) DPrint("%s()\n",
FName);
gettimeofday(&tvp,NULL);
gettimeofday(&tvp,&tzp);
schedtime = (tvp.tv_sec - MSched.SchedTime.tv_sec) * 1000 +
(tvp.tv_usec - MSched.SchedTime.tv_usec) / 1000;
+23 -114
View File
@@ -844,10 +844,6 @@ int MStatUpdateActiveJobUsage(
double psdedicated;
double psutilized;
/* HvB */
double psutilized_cpu;
double psutilized_load;
double msdedicated;
double msutilized;
@@ -881,10 +877,6 @@ int MStatUpdateActiveJobUsage(
mreq_t *RQ;
mpar_t *P;
double averagenodespeed = 0.0;
double totalnodespeed = 0.0;
int speedcounter = 0;
const char *FName = "MStatUpdateActiveJobUsage";
@@ -906,16 +898,7 @@ int MStatUpdateActiveJobUsage(
called from: MQueueAddAJob()
*/
if ((J->Req[0] != NULL) &&
(J->Req[0]->NAccessPolicy == mnacSingleJob) &&
(MSched.NodeAllocMaxPS == TRUE))
{
TotalProcs = J->NodesRequested;
}
else
{
TotalProcs = MJobGetProcCount(J);
}
TotalProcs = MJobGetProcCount(J);
if (TotalProcs == 0)
{
@@ -931,34 +914,17 @@ int MStatUpdateActiveJobUsage(
(double)MSched.Interval / 100.0,
(double)MSched.Time - J->StartTime);
if ((J->Req[0] != NULL) &&
(J->Req[0]->NAccessPolicy == mnacSingleJob) &&
(MSched.NodeAllocMaxPS == TRUE))
{
pesdedicated = TotalProcs * interval;
}
else
{
pesdedicated = PE * interval;
}
pesdedicated = PE * interval;
for (rqindex = 0;J->Req[rqindex] != NULL;rqindex++)
{
RQ = J->Req[rqindex];
P = &MPar[RQ->PtIndex];
totalnodespeed = 0.0;
speedcounter = 0;
psdedicated = 0.0;
psutilized = 0.0;
/* HvB */
psutilized_cpu = 0.0;
psutilized_load = 0.0;
msdedicated = 0.0;
msutilized = 0.0;
@@ -969,7 +935,7 @@ int MStatUpdateActiveJobUsage(
if ((J->StartTime != MSched.Time) && (J->CTime != MSched.Time))
{
psdedicated = interval * TotalProcs;
psdedicated = interval * MJobGetProcCount(J);
for (nindex = 0;nindex < MAX_MNODE_PER_JOB;nindex++)
{
@@ -980,74 +946,34 @@ int MStatUpdateActiveJobUsage(
{
break;
}
speedcounter++;
totalnodespeed += N->Speed;
msdedicated += (double)(interval * TC * RQ->DRes.Mem);
/*
* HvB: There is a difference between shared nodes and NodeAllocMaxPS (exclusive)
* exclusive : nodes * interval
* shared : total cores * interval
*
* Load and cpu time is calculated for all cores in a node. So we have to normalize
* for psutilized. if singlejob per node is set
*/
if ( (J->Req[0]->NAccessPolicy == mnacSingleJob) &&
(MSched.NodeAllocMaxPS == TRUE))
if (RQ->URes.Procs > 0)
{
psutilized_cpu += interval * RQ->URes.Procs / (100.0 * TotalProcs * N->CRes.Procs) ;
psutilized_load += interval * (double)N->Load / N->CRes.Procs;
}
else
/* Old calculation */
{
if (RQ->URes.Procs > 0)
{
psutilized += interval * TC * RQ->URes.Procs / 100.0;
RQ->MURes.Procs = MAX(RQ->MURes.Procs,RQ->URes.Procs);
}
else if (N->CRes.Procs > 1)
{
/* cannot properly determine efficiency with available information */
/* make job 100% efficient */
psutilized += (interval * TC * RQ->DRes.Procs);
psutilized += interval * TC * RQ->URes.Procs / 100.0;
RQ->MURes.Procs = MAX(RQ->MURes.Procs,RQ->URes.Procs);
}
else if (N->CRes.Procs > 1)
{
/* cannot properly determine efficiency with available information */
/* make job 100% efficient */
psutilized += (interval * TC * RQ->DRes.Procs);
}
else
{
if (N->Load >= 1.0)
{
psutilized += (interval * 1.0);
}
else
{
if (N->Load >= 1.0)
{
psutilized += (interval * 1.0);
}
else
{
psutilized += (interval * (double)N->Load);
}
}
}
{
psutilized += (interval * (double)N->Load);
}
}
} /* END for (nindex) */
/* HvB
* Some Jobs do not update the cputime properly , but the load is high. Then use this factor
* for jobs that uses a single node exclusive
*/
if ( (J->Req[0]->NAccessPolicy == mnacSingleJob) &&
(MSched.NodeAllocMaxPS == TRUE))
{
DBG(8,fSTAT) DPrint("INFO: psutilized_cpu = %f, psutilized_load = %f\n",
psutilized_cpu, psutilized_load);
if ( (psutilized_cpu * 10) < psutilized_load)
{
psutilized = psutilized_load;
}
else
{
psutilized = psutilized_cpu;
}
}
if (RQ->URes.Mem > 0)
{
msutilized = interval * RQ->URes.Mem;
@@ -1160,23 +1086,6 @@ int MStatUpdateActiveJobUsage(
MPolicyAdjustUsage(NULL,J,NULL,mlActive,NULL,-1,1,NULL);
if (speedcounter == 0)
averagenodespeed = 1.0;
else
averagenodespeed = totalnodespeed / speedcounter;
if (P->UseMachineSpeedForFS == TRUE)
{
fsusage *= averagenodespeed;
psdedicated *= averagenodespeed;
psutilized *= averagenodespeed;
msdedicated *= averagenodespeed;
msutilized *= averagenodespeed;
}
if ((J != NULL) && (J->Cred.C != NULL))
DBG(1,fSTAT) DPrint("INFO: Average nodespeed for Job %s is %f, %f, %i \n",J->Name,averagenodespeed,totalnodespeed,speedcounter);
U = J->Cred.U;
if (U != NULL)
+124 -263
View File
@@ -13,11 +13,10 @@ mjob_t *MJob[MAX_MJOB];
mnode_t *MNode[MAX_MNODE];
mgcred_t *MUser[MAX_MUSER + MAX_MHBUF];
mgcred_t MGroup[MAX_MGROUP + MAX_MHBUF];
int FSGroupKeys[MAX_MGROUP]; /* HvB holds the FairShare Group Keys */
mgcred_t MAcct[MAX_MACCT + MAX_MHBUF];
mres_t *MRes[MAX_MRES];
srsv_t SRes[MAX_MSRES];
srsv_t OSRes[MAX_MSRES];
sres_t SRes[MAX_MSRES];
sres_t OSRes[MAX_MSRES];
mjobl_t MJobName[MAX_MJOB + MAX_MHBUF];
mam_t MAM[MAX_MAM];
mrange_t MRange[MAX_MRANGE];
@@ -38,7 +37,6 @@ mjob_t *MJobTraceBuffer;
mrmfunc_t MRMFunc[MAX_MRMTYPE];
msim_t MSim;
msys_t MSys; /* cluster layout */
m64_t M64;
mx_t X;
int MFQ[MAX_MJOB]; /* terminated by '-1' value */
@@ -72,7 +70,7 @@ int __MSysTestRLMerge();
int MSysInitialize(mbool_t DoInit)
int MSysInitialize()
{
int index;
@@ -99,8 +97,6 @@ int MSysInitialize(mbool_t DoInit)
S->X = (void *)&X;
M64Init(&M64);
MOSSyslogInit(S);
MUBuildPList((mcfg_t *)MCfg,MParam);
@@ -166,7 +162,7 @@ int MSysInitialize(mbool_t DoInit)
S->E[mxoSched] = &MSched;
S->T[mxoSRes] = &SRes[0];
S->S[mxoSRes] = sizeof(srsv_t);
S->S[mxoSRes] = sizeof(sres_t);
S->M[mxoSRes] = MAX_MSRES;
S->E[mxoSRes] = &SRes[MAX_MSRES - 1];
@@ -280,11 +276,6 @@ int MSysInitialize(mbool_t DoInit)
MLocalInitialize();
/*
* HvB
*/
memset(FSGroupKeys,-1,sizeof(FSGroupKeys));
return(SUCCESS);
} /* END MSysInitialize() */
@@ -384,21 +375,21 @@ int MSysLoadConfig(
MCfgProcessBuffer(MSched.ConfigBuffer);
MCredLoadConfig(mxoSys,NULL,NULL,NULL);
MCredLoadConfig(mxoSys,NULL,NULL);
MCredLoadConfig(mxoQOS,"DEFAULT",NULL,NULL);
MCredLoadConfig(mxoQOS,NULL,NULL,NULL);
MCredLoadConfig(mxoQOS,"DEFAULT",NULL);
MCredLoadConfig(mxoQOS,NULL,NULL);
MCredLoadConfig(mxoUser,"DEFAULT",NULL,NULL);
MCredLoadConfig(mxoUser,NULL,NULL,NULL);
MCredLoadConfig(mxoUser,"DEFAULT",NULL);
MCredLoadConfig(mxoUser,NULL,NULL);
MCredLoadConfig(mxoGroup,"DEFAULT",NULL,NULL);
MCredLoadConfig(mxoAcct,"DEFAULT",NULL,NULL);
MCredLoadConfig(mxoClass,"DEFAULT",NULL,NULL);
MCredLoadConfig(mxoGroup,"DEFAULT",NULL);
MCredLoadConfig(mxoAcct,"DEFAULT",NULL);
MCredLoadConfig(mxoClass,"DEFAULT",NULL);
MCredLoadConfig(mxoGroup,NULL,NULL,NULL);
MCredLoadConfig(mxoAcct,NULL,NULL,NULL);
MCredLoadConfig(mxoClass,NULL,NULL,NULL);
MCredLoadConfig(mxoGroup,NULL,NULL);
MCredLoadConfig(mxoAcct,NULL,NULL);
MCredLoadConfig(mxoClass,NULL,NULL);
MSRLoadConfig(NULL);
@@ -441,12 +432,6 @@ int MSysLoadConfig(
MUCheckAuthFile(&MSched,MSched.DefaultCSKey,NULL,TRUE);
/*
* HvB: Find all hashkeys of Fairshare groups and save them
* in an array.
*/
MGroupGetFSGroups();
return(SUCCESS);
} /* END MSysLoadConfig() */
@@ -1418,44 +1403,32 @@ int MSysLaunchAction(
int MSysDSQuery(
char *SName, /* I service name */
char *CName, /* I cluster name */
char *HostName, /* O service hostname (minsize=MMAX_NAME) */
int *Port, /* O service port */
char *WProtocol, /* O service wire protocol (minsize=MMAX_NAME) */
char *SProtocol) /* O service socket protocol (minsize=MMAX_NAME) */
char *SName, /* I: service name */
char *CName, /* I: cluster name */
char *HostName, /* O: service hostname */
int *Port, /* O: service port */
char *WProtocol, /* O: service wire protocol */
char *SProtocol) /* O: service socket protocol */
{
char *RspPtr = NULL;
char CmdString[MMAX_LINE];
char CmdString[MAX_MLINE];
char tmpLine[MAX_MLINE];
mxml_t *E = NULL;
mxml_t *LE = NULL;
mxml_t *RE = NULL;
mxml_t *CE = NULL;
mxml_t *tE;
mxml_t *LE = NULL;
int ReqID;
#ifndef __MPROD
const char *FName = "MSysDSQuery";
MDB(4,fCORE) MLog("%s(%s,%s,HostName,Port,WProtocol,SProtocol)\n",
DBG(4,fCORE) DPrint("%s(%s,%s,HostName,Port,WProtocol,SProtocol)\n",
FName,
(SName != NULL) ? SName : "NULL",
(CName != NULL) ? CName : "NULL");
#endif /* !__MPROD */
if (HostName != NULL)
HostName[0] = '\0';
if (Port != NULL)
*Port = -1;
if (WProtocol != NULL)
WProtocol[0] = '\0';
if (SProtocol != NULL)
SProtocol[0] = '\0';
if (SName == NULL)
{
@@ -1464,37 +1437,19 @@ int MSysDSQuery(
/* create request string */
/* FORMAT:
MXMLCreateE(&E,"DirectoryRequests");
MXMLCreateE(&RE,"DirectoryRequest");
<get-location><location><component>$SNAME</component>
<host match="false"></host><port match="false"></port>
<protocol match="false"></protocol></location></get-location>
MXMLSetAttr(RE,"service",(void *)SName,mdfString);
*/
if (CName != NULL)
MXMLSetAttr(RE,"cluster",(void *)CName,mdfString);
MXMLCreateE(&E,"add-location");
MXMLCreateE(&LE,"location");
MXMLAddE(E,LE);
ReqID = 1;
CE = NULL;
MXMLCreateE(&tE,"component");
MXMLSetVal(tE,(void *)SName,mdfString);
MXMLAddE(LE,CE);
MXMLSetAttr(RE,"reqid",(void *)&ReqID,mdfInt);
tE = NULL;
MXMLCreateE(&tE,"host");
MXMLSetAttr(tE,"match",(void *)"false",mdfString);
MXMLAddE(CE,tE);
tE = NULL;
MXMLCreateE(&tE,"port");
MXMLSetAttr(tE,"match",(void *)"false",mdfString);
MXMLAddE(CE,tE);
tE = NULL;
MXMLCreateE(&tE,"protocol");
MXMLSetAttr(tE,"match",(void *)"false",mdfString);
MXMLAddE(CE,tE);
MXMLAddE(E,RE);
MXMLToString(E,CmdString,sizeof(CmdString),NULL,TRUE);
@@ -1502,57 +1457,28 @@ int MSysDSQuery(
if (MS3DoCommand(&MSched.DS,CmdString,&RspPtr,NULL,NULL,NULL) == FAILURE)
{
MDB(2,fCORE) MLog("ALERT: cannot query service '%s'\n",
DBG(2,fCORE) DPrint("ALERT: cannot query service '%s'\n",
SName);
return(FAILURE);
}
if (MXMLFromString(&E,RspPtr,NULL,NULL) == FAILURE)
if ((MXMLFromString(&E,RspPtr,NULL,NULL) == FAILURE) ||
(MXMLGetChild(E,"DirectoryResponse",NULL,&RE) == FAILURE) ||
(MXMLGetChild(RE,"Location",NULL,&LE) == FAILURE))
{
MDB(2,fCORE) MLog("ALERT: cannot parse DS query response '%s'\n",
DBG(2,fCORE) DPrint("ALERT: cannot process DS response '%s'\n",
RspPtr);
return(FAILURE);
}
/* process LR3 response */
if (MXMLGetChild(E,"error",NULL,&tE) == SUCCESS)
if ((MXMLGetAttr(RE,"outcome",NULL,tmpLine,0) == FAILURE) ||
strcmp(tmpLine,"success"))
{
char EType[MMAX_LINE];
char Msg[MMAX_LINE];
MXMLGetAttr(tE,"type",NULL,EType,sizeof(EType));
MXMLGetAttr(tE,"msg",NULL,Msg,sizeof(Msg));
MDB(2,fCORE) MLog("ALERT: cannot process DS query response '%s' (FailureType: %s Msg: '%s'\n",
RspPtr,
EType,
Msg);
MXMLDestroyE(&E);
return(FAILURE);
}
if (MXMLGetChild(E,"locations",NULL,&RE) == FAILURE)
{
MDB(2,fCORE) MLog("ALERT: cannot process DS query response '%s'\n",
DBG(2,fCORE) DPrint("ALERT: DS query failed '%s'\n",
RspPtr);
MXMLDestroyE(&E);
return(FAILURE);
}
if (MXMLGetChild(RE,"location",NULL,&LE) == FAILURE)
{
MDB(2,fCORE) MLog("ALERT: cannot process DS query response '%s'\n",
RspPtr);
MXMLDestroyE(&E);
return(FAILURE);
}
@@ -1560,29 +1486,37 @@ int MSysDSQuery(
if (HostName != NULL)
{
if ((MXMLGetChild(LE,"host",NULL,&tE) == SUCCESS) && (tE->Val != NULL))
if (MXMLGetAttr(LE,"host",NULL,tmpLine,0) == SUCCESS)
{
MUStrCpy(HostName,tE->Val,MMAX_NAME);
MUStrCpy(HostName,tmpLine,MAX_MNAME);
}
else
{
HostName[0] = '\0';
}
}
if (Port != NULL)
{
if ((MXMLGetChild(LE,"port",NULL,&tE) == SUCCESS) && (tE->Val != NULL))
if (MXMLGetAttr(LE,"port",NULL,tmpLine,0) == SUCCESS)
{
*Port = (int)strtol(tE->Val,NULL,10);
*Port = (int)strtol(tmpLine,NULL,0);
}
else
{
*Port = -1;
}
}
if (SProtocol != NULL)
{
if ((MXMLGetChild(LE,"host",NULL,&tE) == SUCCESS) && (tE->Val != NULL))
if (MXMLGetAttr(LE,"protocol",NULL,tmpLine,0) == SUCCESS)
{
/* NOTE: directory service protocol must be translated between S3 and local protocols */
/* NYI */
/* MUStrCpy(SProtocol,tE->Val,MMAX_NAME); */
MUStrCpy(SProtocol,tmpLine,MAX_MNAME);
}
else
{
SProtocol[0] = '\0';
}
}
@@ -1590,9 +1524,9 @@ int MSysDSQuery(
MXMLDestroyE(&E);
MDB(2,fCORE) MLog("INFO: information for service '%s' successfully queried\n",
DBG(2,fCORE) DPrint("INFO: information for service '%s' successfully queried\n",
SName);
return(SUCCESS);
} /* END MSysDSQuery() */
@@ -1862,21 +1796,22 @@ int MSysDSUnregister(
{
char *RspPtr = NULL;
char CmdString[MMAX_LINE];
char CmdString[MAX_MLINE];
mxml_t *E = NULL;
char tmpLine[MAX_MLINE];
mxml_t *E = NULL;
mxml_t *RE = NULL;
mxml_t *tE = NULL;
#ifndef __MPROD
int ReqID;
const char *FName = "MSysDSUnregister";
MDB(4,fCORE) MLog("%s(%s,%s,%s,Port,WProtocol,SProtocol)\n",
DBG(4,fCORE) DPrint("%s(%s,%s,%s,Port,WProtocol,SProtocol)\n",
FName,
(SName != NULL) ? SName : "NULL",
(CName != NULL) ? CName : "NULL",
(HostName != NULL) ? HostName : "NULL");
#endif /* !__MPROD */
if (SName == NULL)
{
@@ -1887,31 +1822,37 @@ int MSysDSUnregister(
{
/* DS disabled */
MDB(6,fCORE) MLog("INFO: DS disabled\n");
DBG(6,fCORE) DPrint("INFO: DS disabled\n");
return(SUCCESS);
}
/* create request string */
/* FORMAT */
MXMLCreateE(&E,"DirectoryRequests");
MXMLCreateE(&RE,"DirectoryRemove");
/* <del-location><location><component>$SNAME</component></location></del-location> */
MXMLSetAttr(RE,"service",(void *)SName,mdfString);
MXMLCreateE(&E,"del-location");
MXMLCreateE(&RE,"location");
if (CName != NULL)
MXMLSetAttr(RE,"cluster",(void *)CName,mdfString);
if (SProtocol)
MXMLSetAttr(RE,"protocol",(void *)SProtocol,mdfString);
ReqID = 1;
MXMLSetAttr(RE,"reqid",(void *)&ReqID,mdfInt);
MXMLAddE(E,RE);
MXMLCreateE(&tE,"component");
MXMLAddE(RE,tE);
MXMLToString(E,CmdString,sizeof(CmdString),NULL,TRUE);
MXMLDestroyE(&E);
if (MS3DoCommand(&MSched.DS,CmdString,&RspPtr,NULL,NULL,NULL) == FAILURE)
{
MDB(2,fCORE) MLog("ALERT: cannot un-register service '%s'\n",
DBG(2,fCORE) DPrint("ALERT: cannot un-register service '%s'\n",
CName);
return(FAILURE);
@@ -1919,35 +1860,15 @@ int MSysDSUnregister(
if (MXMLFromString(&E,RspPtr,NULL,NULL) == FAILURE)
{
MDB(2,fCORE) MLog("ALERT: cannot process DS response '%s'\n",
DBG(2,fCORE) DPrint("ALERT: cannot process DS response '%s'\n",
RspPtr);
return(FAILURE);
}
/* NOTE: processing LR3 response */
if (MXMLGetChild(E,"error",NULL,&RE) == SUCCESS)
if (MXMLGetChild(E,"DirectoryStatus",NULL,&RE) == FAILURE)
{
char EType[MMAX_LINE];
char Msg[MMAX_LINE];
MXMLGetAttr(RE,"type",NULL,EType,sizeof(EType));
MXMLGetAttr(RE,"msg",NULL,Msg,sizeof(Msg));
MDB(2,fCORE) MLog("ALERT: cannot process DS response '%s' (FailureType: %s Msg: '%s'\n",
RspPtr,
EType,
Msg);
MXMLDestroyE(&E);
return(FAILURE);
}
if (MXMLGetChild(E,"locations",NULL,&RE) == FAILURE)
{
MDB(2,fCORE) MLog("ALERT: cannot process DS unregistration response '%s'\n",
DBG(2,fCORE) DPrint("ALERT: cannot process DS response '%s'\n",
RspPtr);
MXMLDestroyE(&E);
@@ -1955,9 +1876,10 @@ int MSysDSUnregister(
return(FAILURE);
}
if (MXMLGetChild(RE,"location",NULL,&tE) == FAILURE)
if ((MXMLGetAttr(RE,"outcome",NULL,tmpLine,0) == FAILURE) ||
strcmp(tmpLine,"success"))
{
MDB(2,fCORE) MLog("ALERT: cannot process DS unregistration response '%s'\n",
DBG(2,fCORE) DPrint("ALERT: un-register request failed '%s'\n",
RspPtr);
MXMLDestroyE(&E);
@@ -1965,11 +1887,9 @@ int MSysDSUnregister(
return(FAILURE);
}
/* NOTE: must extract and record deregistration failure message (NYI) */
MXMLDestroyE(&E);
MDB(2,fCORE) MLog("INFO: service '%s' successfully registered\n",
DBG(2,fCORE) DPrint("INFO: service '%s' successfully registered\n",
SName);
return(SUCCESS);
@@ -1978,7 +1898,6 @@ int MSysDSUnregister(
int MSysDSRegister(
char *SName, /* I: service name */
@@ -1991,23 +1910,22 @@ int MSysDSRegister(
{
char *RspPtr = NULL;
char CmdString[MMAX_LINE];
char CmdString[MAX_MLINE];
mxml_t *E = NULL;
mxml_t *RE = NULL;
mxml_t *tE;
char tmpLine[MAX_MLINE];
char *Version = NULL;
mxml_t *E = NULL;
mxml_t *RE = NULL;
int ReqID;
#ifndef __MPROD
const char *FName = "MSysDSRegister";
MDB(4,fCORE) MLog("%s(%s,%s,%s,Port,WProtocol,SProtocol)\n",
DBG(4,fCORE) DPrint("%s(%s,%s,%s,Port,WProtocol,SProtocol)\n",
FName,
(SName != NULL) ? SName : "NULL",
(CName != NULL) ? CName : "NULL",
(HostName != NULL) ? HostName : "NULL");
#endif /* !__MPROD */
if (SName == NULL)
{
@@ -2018,68 +1936,33 @@ int MSysDSRegister(
{
/* DS disabled */
MDB(6,fCORE) MLog("INFO: DS disabled\n");
DBG(6,fCORE) DPrint("INFO: DS disabled\n");
return(SUCCESS);
}
/* FORMAT:
<?xml version="1.0" encoding="UTF-8"?><add-location><location>
<component>$SName</component>
<host>$HostName</host>
<port>$Port</port>
<protocol>challenge</protocol>
<schema_version>1234</schema_version>
<tier>1</tier>
</location></add-location>
*/
/* create request string */
MXMLCreateE(&E,"add-location");
MXMLCreateE(&RE,"location");
MXMLCreateE(&E,"DirectoryRequests");
MXMLCreateE(&RE,"DirectoryRegister");
tE = NULL;
MXMLCreateE(&tE,"component");
MXMLSetVal(tE,(void *)SName,mdfString);
MXMLAddE(RE,tE);
MXMLSetAttr(RE,"service",(void *)SName,mdfString);
if (CName != NULL)
{
/* MXMLSetAttr(RE,"cluster",(void *)CName,mdfString); */
}
MXMLSetAttr(RE,"cluster",(void *)CName,mdfString);
if (HostName != NULL)
{
tE = NULL;
MXMLCreateE(&tE,"host");
MXMLSetVal(tE,(void *)HostName,mdfString);
MXMLAddE(RE,tE);
}
MXMLSetAttr(RE,"host",(void *)HostName,mdfString);
if (Port != -1)
{
tE = NULL;
MXMLCreateE(&tE,"port");
MXMLSetVal(tE,(void *)&Port,mdfInt);
MXMLAddE(RE,tE);
}
MXMLSetAttr(RE,"port",(void *)&Port,mdfInt);
if (SProtocol != NULL)
{
tE = NULL;
MXMLCreateE(&tE,"protocol");
MXMLSetVal(tE,(void *)SProtocol,mdfString);
MXMLAddE(RE,tE);
}
if (SProtocol)
MXMLSetAttr(RE,"protocol",(void *)SProtocol,mdfString);
if (Version != NULL)
{
tE = NULL;
MXMLCreateE(&tE,"schema_version");
MXMLSetVal(tE,(void *)Version,mdfString);
MXMLAddE(RE,tE);
}
ReqID = 1;
MXMLSetAttr(RE,"reqid",(void *)&ReqID,mdfInt);
MXMLAddE(E,RE);
@@ -2089,7 +1972,7 @@ int MSysDSRegister(
if (MS3DoCommand(&MSched.DS,CmdString,&RspPtr,NULL,NULL,NULL) == FAILURE)
{
MDB(2,fCORE) MLog("ALERT: cannot register service '%s'\n",
DBG(2,fCORE) DPrint("ALERT: cannot register service '%s'\n",
CName);
return(FAILURE);
@@ -2097,35 +1980,15 @@ int MSysDSRegister(
if (MXMLFromString(&E,RspPtr,NULL,NULL) == FAILURE)
{
MDB(2,fCORE) MLog("ALERT: cannot process DS registration response '%s'\n",
DBG(2,fCORE) DPrint("ALERT: cannot process DS response '%s'\n",
RspPtr);
return(FAILURE);
}
/* NOTE: processing LR3 response */
if (MXMLGetChild(E,"error",NULL,&RE) == SUCCESS)
if (MXMLGetChild(E,"DirectoryStatus",NULL,&RE) == FAILURE)
{
char EType[MMAX_LINE];
char Msg[MMAX_LINE];
MXMLGetAttr(RE,"type",NULL,EType,sizeof(EType));
MXMLGetAttr(RE,"msg",NULL,Msg,sizeof(Msg));
MDB(2,fCORE) MLog("ALERT: cannot process DS registration response '%s' (FailureType: %s Msg: '%s'\n",
RspPtr,
EType,
Msg);
MXMLDestroyE(&E);
return(FAILURE);
}
if (MXMLGetChild(E,"locations",NULL,&RE) == FAILURE)
{
MDB(2,fCORE) MLog("ALERT: cannot process DS registration response '%s'\n",
DBG(2,fCORE) DPrint("ALERT: cannot process DS response '%s'\n",
RspPtr);
MXMLDestroyE(&E);
@@ -2133,9 +1996,10 @@ int MSysDSRegister(
return(FAILURE);
}
if (MXMLGetChild(RE,"location",NULL,&tE) == FAILURE)
if ((MXMLGetAttr(RE,"outcome",NULL,tmpLine,0) == FAILURE) ||
strcmp(tmpLine,"success"))
{
MDB(2,fCORE) MLog("ALERT: cannot process DS registration response '%s'\n",
DBG(2,fCORE) DPrint("ALERT: registation request failed '%s'\n",
RspPtr);
MXMLDestroyE(&E);
@@ -2143,17 +2007,13 @@ int MSysDSRegister(
return(FAILURE);
}
/* NOTE: do not know how failure messages are encapsulated */
/* must extract and record actual failure (NYI) */
MXMLDestroyE(&E);
MDB(2,fCORE) MLog("INFO: service '%s' successfully registered\n",
DBG(2,fCORE) DPrint("INFO: service '%s' successfully registered\n",
SName);
return(SUCCESS);
} /* END MSysDSRegister() */
} /* END MSysDSUnregister() */
@@ -2206,10 +2066,11 @@ int MSysUpdateTime(
{
struct timeval tvp;
struct timezone tzp;
long interval;
gettimeofday(&tvp,NULL);
gettimeofday(&tvp,&tzp);
/* determine time interval in 1/100's of a second */
+1 -2
View File
@@ -25,7 +25,6 @@ extern mnode_t *MNode[];
extern mqos_t MQOS[];
extern mpar_t MPar[];
extern mrm_t MRM[];
extern m64_t M64;
extern mframe_t MFrame[];
@@ -1220,7 +1219,7 @@ int MTraceLoadWorkload(
J->SpecFlags |= MSim.TraceDefaultJobFlags;
for (index = 0;index < M64.INTBITS;index++)
for (index = 0;index < MINTBITS;index++)
{
if (!(MSim.TraceIgnoreJobFlags & (1 << index)))
continue;
+2
View File
@@ -84,6 +84,8 @@ int MUserLoadCP(
return(FAILURE);
}
MXMLCreateE(&E,(char *)MXO[mxoUser]);
MXMLFromString(&E,ptr,NULL,NULL);
MOFromXML((void *)U,mxoUser,E);
+27 -46
View File
@@ -23,7 +23,6 @@ extern const char *MComp[];
extern const char *MNodeState[];
extern const char *MHRObj[];
extern const char *MResourceType[];
extern m64_t M64;
extern mx_t X;
@@ -101,9 +100,6 @@ int MUGetPair(
for (index = 0;index < MAX_MNAME;index++)
{
if (ptr[index] == '\0')
break;
if (CmpRelative == TRUE)
{
if (isspace(ptr[index]) ||
@@ -135,7 +131,7 @@ int MUGetPair(
for (index = index + 1;index < MAX_MNAME;index++)
{
if ((ptr[index] == ']') || (ptr[index] == '\0'))
if (ptr[index] == ']')
break;
if (AttrArray != NULL)
@@ -392,6 +388,7 @@ int MUGetMS(
{
struct timeval tvp;
struct timezone tzp;
if (MS == NULL)
{
@@ -400,7 +397,7 @@ int MUGetMS(
if (TV == NULL)
{
gettimeofday(&tvp,NULL);
gettimeofday(&tvp,&tzp);
/* determine millisecond offset in current time interval */
@@ -789,7 +786,7 @@ int MUGetMAttr(
return(SUCCESS);
}
if ((AttrValue == NULL) || (MapSize < M64.INTSIZE))
if ((AttrValue == NULL) || (MapSize < MINTSIZE))
{
return(FAILURE);
}
@@ -806,7 +803,7 @@ int MUGetMAttr(
if (!strcmp(MAList[AttrIndex][index],AttrValue))
{
if (AttrMap != NULL)
AttrMap[index >> M64.INTLBITS] |= 1 << (index % M64.INTBITS);
AttrMap[index >> MINTLBITS] |= 1 << (index % MINTBITS);
return(SUCCESS);
}
@@ -823,7 +820,7 @@ int MUGetMAttr(
MUStrCpy(MAList[AttrIndex][index],AttrValue,sizeof(MAList[0][0]));
AttrMap[index >> M64.INTLBITS] |= 1 << (index % M64.INTBITS);
AttrMap[index >> MINTLBITS] |= 1 << (index % MINTBITS);
DBG(5,fSTRUCT) DPrint("INFO: added MAList[%s][%d]: '%s'\n",
MAttrType[AttrIndex],
@@ -1070,7 +1067,7 @@ char *MUListAttrs(
Line[0] = '\0';
for (i = 1;i < M64.INTBITS;i++)
for (i = 1;i < MINTBITS;i++)
{
if ((Value & (1 << i)) && (MAList[Attr][i][0] != '\0'))
{
@@ -1098,7 +1095,7 @@ char *MUMAList(
int index;
int findex;
if ((ValueMap == NULL) || (MapSize < M64.INTSIZE))
if ((ValueMap == NULL) || (MapSize < MINTSIZE))
{
strcpy(Line,NONE);
@@ -1107,16 +1104,16 @@ char *MUMAList(
Line[0] = '\0';
for (findex = 0;findex < (MapSize >> M64.INTSHIFT);findex++)
for (findex = 0;findex < (MapSize >> MINTSHIFT);findex++)
{
for (index = 0;index < M64.INTBITS;index++)
for (index = 0;index < MINTBITS;index++)
{
if ((ValueMap[findex] & (1 << index)) &&
(MAList[AttrIndex][index][0] != '\0'))
{
sprintf(Line,"%s[%s]",
Line,
MAList[AttrIndex][index + findex * M64.INTBITS]);
MAList[AttrIndex][index + findex * MINTBITS]);
}
} /* END for (index) */
} /* END for (findex) */
@@ -1153,7 +1150,7 @@ char *MAttrFind(
return(NULL);
}
if ((ValueMap == NULL) || (MapSize < M64.INTSIZE))
if ((ValueMap == NULL) || (MapSize < MINTSIZE))
{
return(NULL);
}
@@ -1163,7 +1160,7 @@ char *MAttrFind(
for (findex = 0;findex < (MapSize >> 2);findex++)
{
for (index = 0;index < M64.INTBITS;index++)
for (index = 0;index < MINTBITS;index++)
{
if ((ValueMap[findex] & (1 << index)) &&
(MAList[AttrIndex][index][0] != '\0'))
@@ -1218,7 +1215,7 @@ char *MUBListAttrs(
return(Line);
}
for (i = 1;i < M64.INTBITS;i++)
for (i = 1;i < MINTBITS;i++)
{
if ((Value & (1 << i)) && (MAList[Attr][i][0] != '\0'))
{
@@ -3923,9 +3920,9 @@ int MUDStatInitialize(
D->DSize = DSize;
D->Count = 0;
if ((D->Data = (char *)calloc(DSTAT_STEPSIZE, DSize)) == NULL)
if ((D->Data = (char *)malloc(DSize * DSTAT_STEPSIZE)) == NULL)
{
DBG(0,fCORE) DPrint("ALERT: cannot calloc memory for dstat\n");
DBG(0,fCORE) DPrint("ALERT: cannot malloc memory for dstat\n");
return(FAILURE);
}
@@ -4122,7 +4119,7 @@ char *MUBMToString(
ptr[0] = '\0';
for (i = 1;i < M64.INTBITS;i++)
for (i = 1;i < MINTBITS;i++)
{
if ((BM & (1 << i)) && (AList[i] != NULL) && (AList[i][0] != '\0'))
{
@@ -4253,7 +4250,7 @@ int MUBMOR(
int mindex;
int len;
len = MAX(1,(MapSize >> M64.INTLBITS));
len = MAX(1,(MapSize >> MINTLBITS));
for (mindex = 0;mindex < len;mindex++)
{
@@ -4276,7 +4273,7 @@ int MUBMAND(
int mindex;
int len;
len = MAX(1,(MapSize >> M64.INTLBITS));
len = MAX(1,(MapSize >> MINTLBITS));
for (mindex = 0;mindex < len;mindex++)
{
@@ -4902,7 +4899,7 @@ int MUShowCopy()
fprintf(stderr,"This software utilizes the Moab Scheduling Library, version %s\n",
MOAB_VERSION);
fprintf(stderr,"Copyright 2000-2010 Cluster Resources, Inc, All Rights Reserved\n");
fprintf(stderr,"Copyright 2000-2005 Cluster Resources, Inc, All Rights Reserved\n");
return(SUCCESS);
} /* END MUShowCopy() */
@@ -5089,7 +5086,7 @@ int MUSNPrintF(
{
int len;
const char *FName = "MUSNPrintF";
va_list Args;
if ((BPtr == NULL) ||
@@ -5097,8 +5094,6 @@ int MUSNPrintF(
(Format == NULL) ||
(*BSpace <= 0))
{
DBG(4,fCORE) DPrint("ALERT: Memory Error in %s\n",
FName);
return(FAILURE);
}
@@ -5110,23 +5105,9 @@ int MUSNPrintF(
if (len <= 0)
{
DBG(4,fCORE) DPrint("ALERT: vsnprintf Error in %s\n",
FName);
return(FAILURE);
}
#if __GLIBC__ >= 2 && __GLIBC_MINOR__ >= 1
/* XXX: The following is true for glibc > 2.1 */
/* if vsnprintf returns the same value as size or greater */
/* then the output is truncated. see man vsnprintf. */
if (len == *BSpace || len > *BSpace) {
DBG(1,fCORE) DPrint("ALERT: Possible vsnprintf truncation in %s\n",
FName);
return(FAILURE);
}
#endif
*BPtr += len;
*BSpace -= len;
@@ -5135,7 +5116,7 @@ int MUSNPrintF(
int MUSNCat(char **BPtr,int *BSpace,char *Src) { return(MUStrNCat(BPtr,BSpace,Src)); }
int MUSNCat(char **BPtr,int *BSpace,char *Src) { return(MUStrNCat(BPtr,BSpace,Src)); };
int MUStrNCat(
@@ -5285,7 +5266,7 @@ char *MUURLCreate(
BPtr = Buf;
BSpace = BufSize;
}
else if ((BPtr = calloc(MAX_MLINE, 1)) != NULL)
else if ((BPtr = malloc(MAX_MLINE)) != NULL)
{
BSpace = BufSize;
}
@@ -5430,7 +5411,7 @@ char *MUMAToString(
char *ptr;
if ((ValueMap == NULL) || (MapSize < M64.INTSIZE))
if ((ValueMap == NULL) || (MapSize < MINTSIZE))
{
strcpy(Line,NONE);
@@ -5439,14 +5420,14 @@ char *MUMAToString(
Line[0] = '\0';
for (findex = 0;findex < (MapSize >> M64.INTSHIFT);findex++)
for (findex = 0;findex < (MapSize >> MINTSHIFT);findex++)
{
for (index = 0;index < M64.INTBITS;index++)
for (index = 0;index < MINTBITS;index++)
{
if ((ValueMap[findex] & (1 << index)) &&
(MAList[AttrIndex][index][0] != '\0'))
{
ptr = MAList[AttrIndex][index + findex * M64.INTBITS];
ptr = MAList[AttrIndex][index + findex * MINTBITS];
if (Delim != '\0')
{
+5 -5
View File
@@ -1,5 +1,5 @@
# Makefile for Moab 2.2.3
# Copyright 1999 - 2010 Cluster Resources Inc, All Rights Reserved
# Copyright 1999 - 2004 Supercluster Development Group, All Rights Reserved
TOP =../..
BIN =$(TOP)/bin/
@@ -14,11 +14,11 @@
SCHEDIP=-I$(INC) -I$(MSCHED_HOME)/include
SHELL =/bin/sh
LP =-L$(LIB) $(SCHEDLP) $(LLLP) $(MXLP) $(REGEXLP) $(PBSLDFLAGS)
IP =$(SCHEDIP) $(LLIP) $(REGEXIP) $(MXIP) $(PBSCFLAGS)
LP =-L$(LIB) $(SCHEDLP) $(LLLP) $(PBSLP) $(MXLP) $(REGEXLP)
IP =$(SCHEDIP) $(LLIP) $(PBSIP) $(REGEXIP) $(MXIP)
INCS =$(INC)moab.h $(INC)msched.h
DEFS =-D$(OPSYS) $(LLDEF) $(SDRDEF) $(PBSDEF) $(OSDEF) $(MXDEF) $(REGEXDEF) \
$(SECDEF) $(RMSDEF) $(THREADDEF) $(DAEMONDEF)
$(SECDEF) $(RMSDEF) $(THREADDEF)
MOAB =libmoab.a
LOBJECTS =MFile.o MConfig.o MQOS.o MLog.o MCred.o MSched.o MAM.o MSR.o MRes.o \
@@ -31,7 +31,7 @@ LOBJECTS =MFile.o MConfig.o MQOS.o MLog.o MCred.o MSched.o MAM.o MSR.o MRes.o \
CP =cp
RM =rm -f
SOURCE =
SOURCE = -g
CFLAGS = $(OSCCFLAGS)
all: $(MOAB)
+3 -3
View File
@@ -1,10 +1,10 @@
VERSION 3.3.1
VERSION 3.2.6p14
PACKAGE moab
AUTHOR Cluster Resources, Inc
FILETYPE Module
COPYRIGHT Copyright (C) 1999-2010 Cluster Resources, Inc
COPYRIGHT Copyright (C) 1999-2005 Cluster Resources, Inc
DISCLAIMER
-----------------------------------------------------------------------------
@@ -13,7 +13,7 @@ Moab Scheduling System - End User Open Source License
This software is based on the Moab Scheduling System which was created by
Cluster Resources, Inc.
Copyright (C) 1999-2010 Cluster Resources, Inc., all rights reserved.
Copyright (C) 1999-2005 Cluster Resources, Inc., all rights reserved.
Moab Scheduling System is a trademark of Cluster Resources, Inc.
+1 -1
View File
@@ -13,7 +13,7 @@ Moab Workload Manager - End User License
This product was created by Cluster Resources, Inc. and is protected by
copyright and patent law.
Copyright (C) 1999-2010 Cluster Resources, Inc., all rights reserved.
Copyright (C) 1999-2005 Cluster Resources, Inc., all rights reserved.
Moab Workload Manager, Moab Cluster Scheduler and Moab Scheduler
are trademarks of Cluster Resources, Inc.
+13 -16
View File
@@ -1,5 +1,5 @@
# Makefile for Maui 3.3.1
# Copyright 1999 - 2010 Cluster Resources, Inc, All Rights Reserved
# Makefile for Maui v3.2
# Copyright 1999 - 2004 Cluster Resources, Inc, All Rights Reserved
TOP =../..
BIN =$(TOP)/bin
@@ -14,11 +14,11 @@
SCHEDIP=-I$(INC) -I$(TOP)/include
SHELL =/bin/sh
LP =-L$(LIB) $(SCHEDLP) $(LLLP) $(MXLP) $(REGEXLP) $(PBSLDFLAGS)
IP =$(SCHEDIP) $(LLIP) $(SGEIP) $(REGEXIP) $(MXIP) $(PBSCFLAGS)
LP =-L$(LIB) $(SCHEDLP) $(LLLP) $(PBSLP) $(MXLP) $(REGEXLP)
IP =$(SCHEDIP) $(LLIP) $(PBSIP) $(SGEIP) $(REGEXIP) $(MXIP)
INCS =$(INC)moab.h $(INC)msched-proto.h $(INC)msched-common.h
DEFS =-D$(OPSYS) $(LLDEF) $(SDRDEF) $(PBSDEF) $(OSDEF) $(MXDEF) \
$(REGEXDEF) $(RMSDEF) $(SECDEF) $(THREADDEF) $(DAEMONDEF)
$(REGEXDEF) $(RMSDEF) $(SECDEF) $(THREADDEF)
SERVER =maui
SCHEDLIB =moab
@@ -26,7 +26,7 @@ COMLIB =mcom
MBINS =$(SERVER) mclient mprof
LIBS =-l$(SCHEDLIB) -l$(COMLIB) $(THREADLIB) $(MXLIB) $(LLLIB) $(SDRLIB) \
$(REGEXLIB) $(SECLIB) -lm
$(PBSLIB) $(REGEXLIB) $(SECLIB) -lm
MCLIENTS =canceljob changeparam checkjob checknode diagnose releasehold \
releaseres resetstats runjob schedctl sethold setqos setres setspri \
@@ -41,14 +41,14 @@ POBJECTS =mprof.o
CP =cp
LN =ln
SOURCE =
SOURCE = -g
CFLAGS = $(OSCCFLAGS)
all: $(MBINS)
install: all
mkdir -p $(INST_DIR)/bin $(INST_DIR)/sbin $(INST_DIR)/include $(INST_DIR)/lib
mkdir -p $(MSCHED_HOME)/log $(MSCHED_HOME)/traces $(MSCHED_HOME)/stats $(MSCHED_HOME)/spool $(MSCHED_HOME)/tools
mkdir -p $(INST_DIR)/{bin,sbin,include,lib}
mkdir -p $(MSCHED_HOME)/{log,traces,stats,spool,tools}
chmod 1777 $(MSCHED_HOME)/spool
@@ -74,7 +74,7 @@ install: all
then cp $(TOP)/maui-private.cfg.dist $(MSCHED_HOME)/maui-private.cfg; \
fi
# (cd ../..;ln -sf etc/maui.cfg;ln -sf etc/maui-private.cfg)
(cd ../..;ln -sf etc/maui.cfg;ln -sf etc/maui-private.cfg)
uninstall:
rm -f $(INST_DIR)/include/moab.h
@@ -87,14 +87,12 @@ setup:
.c.o: $(INCS)
$(CC) $(IP) $(DEFS) $(CFLAGS) $(SOURCE) -c $<
UserI.o: OUserI.c
$(SERVER): $(SOBJECTS)
$(LD) $(SOBJECTS) -o $(BIN)/$@ $(LIBS) $(OSLDFLAGS) $(LP)
$(LD) $(SOBJECTS) -o $(BIN)/$@ $(LP) $(LIBS) $(OSLDFLAGS)
chmod 711 $(BIN)/$@ || true
mclient: mclient.o
$(LD) mclient.o -o $(BIN)/$@ $(OSLDFLAGS) $(LIBS) $(LP)
$(LD) mclient.o -o $(BIN)/$@ $(OSLDFLAGS) $(LP) $(LIBS)
chmod 751 $(BIN)/$@
for i in $(MCLIENTS); do \
ln -f $(BIN)/$@ $(BIN)/$$i; \
@@ -102,12 +100,11 @@ mclient: mclient.o
done
mprof: $(POBJECTS)
$(LD) $(POBJECTS) -o $(BIN)/$@ $(OSLDFLAGS) $(LIBS) $(LP)
$(LD) $(POBJECTS) -o $(BIN)/$@ $(OSLDFLAGS) $(LP) $(LIBS)
chmod 751 $(BIN)/$@
clean:
rm -f *.o $(BIN)/maui $(BIN)/mclient $(BIN)/mprof
cd $(BIN) && rm -f $(MCLIENTS)
remove:
rm $(INST_DIR)/bin/mclient
+12 -40
View File
@@ -5,7 +5,7 @@ int ServerSetSignalHandlers()
{
/* trap TERM(15) QUIT(3) INT(2) HUP(1) */
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__AIX51) || defined(__IRIX) || defined(__LINUX) || defined(__CYGWIN) || defined(__HPUX) || defined(__SOLARIS) || defined(__OSF) || defined(__FREEBSD)
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__AIX51) || defined(__IRIX) || defined(__LINUX) || defined(__HPUX) || defined(__SOLARIS) || defined(__OSF) || defined(__FREEBSD) || defined(LINUX)
signal(SIGINT, SIG_IGN);
signal(SIGTERM, (void(*)(int))MSysShutdown);
@@ -57,15 +57,15 @@ int ServerSetSignalHandlers()
{
act.sa_handler = (void(*)(int))SIG_DFL;
}
else if (!strcasecmp(ptr,"trap"))
else if (!strcmp(ptr,"TRAP") || !strcmp(ptr,"trap"))
{
act.sa_handler = (void(*)(int))CrashMode;
}
else if (!strcasecmp(ptr,"ignore"))
else if (!strcmp(ptr,"IGNORE") || !strcmp(ptr,"ignore"))
{
act.sa_handler = (void(*)(int))SIG_IGN;
}
else if (!strcasecmp(ptr,"die"))
else if (!strcmp(ptr,"DIE") || !strcmp(ptr,"die"))
{
act.sa_handler = (void(*)(int))SIG_DFL;
}
@@ -93,15 +93,15 @@ int ServerSetSignalHandlers()
{
act.sa_handler = (void(*)(int))SIG_DFL;
}
else if (!strcasecmp(ptr,"trap"))
else if (!strcmp(ptr,"TRAP") || !strcmp(ptr,"trap"))
{
act.sa_handler = (void(*)(int))CrashMode;
}
else if (!strcasecmp(ptr,"ignore"))
else if (!strcmp(ptr,"IGNORE") || !strcmp(ptr,"ignore"))
{
act.sa_handler = (void(*)(int))SIG_IGN;
}
else if (!strcasecmp(ptr,"die"))
else if (!strcmp(ptr,"DIE") || !strcmp(ptr,"die"))
{
act.sa_handler = (void(*)(int))SIG_DFL;
}
@@ -120,7 +120,7 @@ int ServerSetSignalHandlers()
}
} /* END BLOCK */
#elif defined(__LINUX) || defined(__CYGWIN) || defined(__IRIX) || defined(__HPUX) || defined(__SOLARIS) || defined(__OSF)
#elif defined(__LINUX) || defined(__IRIX) || defined(__HPUX) || defined(__SOLARIS) || defined(__OSF) || defined(LINUX)
ServerLoadSignalConfig();
@@ -143,15 +143,12 @@ int ServerSetSignalHandlers()
int ServerDemonize()
{
#ifndef __CYGRUNSRV
{
#ifndef __NT
int pid;
#endif /* __NT */
FILE *fp;
const char *FName = "ServerDemonize";
DBG(2,fALL) DPrint("%s()\n",
@@ -182,8 +179,6 @@ int ServerDemonize()
{
/* only background if not in debug mode */
/* NOTE: setsid() disconnects from controlling-terminal */
#ifndef __NT
if ((pid = fork()) == -1)
@@ -210,33 +205,10 @@ int ServerDemonize()
DBG(3,fALL) DPrint("INFO: child process in background\n");
}
if (setsid() == -1)
{
MDB(3,fALL) MLog("INFO: could not disconnect from controlling-terminal, errno=%d - %s\n",
errno,
strerror(errno));
}
/* disconnect stdin */
fclose(stdin);
fp = fopen("/dev/null","r");
/* disconnect stdout */
fclose(stdout);
fp = fopen("/dev/null","w");
/* disconnect stderr */
fclose(stderr);
fp = fopen("/dev/null","w");
#endif /* __NT */
}
} /* END if (MSched.Mode != msmSim) */
#endif /* __CYGRUNSRV */
return(SUCCESS);
} /* END ServerDemonize() */
@@ -307,7 +279,7 @@ int CrashMode(
if (signo == SIGSEGV)
{
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__AIX51) || defined(__LINUX) || defined(__CYGWIN) || defined(__CYGWIN) || defined(__HPUX) || defined(__IRIX) || defined(__SOLARIS) || defined(__OSF) || defined(__FREEBSD)
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__AIX51) || defined(__LINUX) || defined(__HPUX) || defined(__IRIX) || defined(__SOLARIS) || defined(__OSF) || defined(__FREEBSD) || defined(LINUX)
signal(SIGSEGV,(void(*)(int))CrashMode);
@@ -319,7 +291,7 @@ int CrashMode(
}
else if (signo == SIGILL)
{
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__AIX51) || defined(__LINUX) || defined(__CYGWIN) || defined(__HPUX) || defined(__IRIX) || defined(__SOLARIS) || defined(__OSF) || defined(__FREEBSD)
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__AIX51) || defined(__LINUX) || defined(__HPUX) || defined(__IRIX) || defined(__SOLARIS) || defined(__OSF) || defined(__FREEBSD) || defined(LINUX)
signal(SIGILL,(void(*)(int))CrashMode);
@@ -380,7 +352,7 @@ int ReloadConfig(
MSched.Reload = TRUE;
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__AIX51) || defined(__LINUX) || defined(__CYGWIN) || defined(__HPUX) || defined(__IRIX) || defined(__SOLARIS) || defined(__OSF) || defined(__FREEBSD)
#if defined(__AIX41) || defined(__AIX42) || defined(__AIX43) || defined(__AIX51) || defined(__LINUX) || defined(__HPUX) || defined(__IRIX) || defined(__SOLARIS) || defined(__OSF) || defined(__FREEBSD) || defined(LINUX)
signal(SIGHUP,(void(*)(int))ReloadConfig);
+20 -20
View File
@@ -33,8 +33,6 @@ int UIProcessCommand(
long tmpL;
char tmpLine[MMAX_LINE];
const char *FName = "UIProcessCommand";
DBG(3,fUI) DPrint("%s(S)\n",
@@ -286,19 +284,19 @@ int UIProcessCommand(
hostcheck = FALSE;
for (index = 0;index < MAX_MADMINHOSTS;index++)
for (index = 0;index < MAX_MADMINUSERS;index++)
{
if (MSched.AdminHost[index][0] == '\0')
break;
if (!strcasecmp(MSched.AdminHost[index],S->Host))
if (!strcmp(MSched.AdminHost[index],S->Host))
{
hostcheck = TRUE;
break;
}
if (!strcasecmp(MSched.AdminHost[index],"ALL"))
if (!strcmp(MSched.AdminHost[index],"ALL"))
{
hostcheck = TRUE;
@@ -413,31 +411,33 @@ int UIProcessCommand(
S->SBufSize = (long)sizeof(SBuffer);
sprintf(tmpLine,"%s%d ",
MCKeyword[mckStatusCode],
scFAILURE);
sprintf(S->SBuffer,"%s%d ",
MCKeyword[mckStatusCode],
scFAILURE);
Align = (int)strlen(tmpLine) + (int)strlen(MCKeyword[mckArgs]);
Align = (int)strlen(S->SBuffer) + (int)strlen(MCKeyword[mckArgs]);
sprintf(S->SBuffer,"%s%*s%s",
tmpLine,
16 - (Align % 16),
" ",
S->SBuffer,
16 - (Align % 16),
" ",
MCKeyword[mckArgs]);
HeadSize = (int)strlen(SBuffer);
S->SBufSize -= HeadSize + 1;
if (Function[sindex] != NULL)
scode = (*Function[sindex])(args,S->SBuffer + HeadSize,FLAGS,Auth,&S->SBufSize);
else
scode = FAILURE;
scode = FAILURE;
ptr = S->SBuffer + strlen(MCKeyword[mckStatusCode]);
*ptr = scode + '0';
S->SBufSize = (long)strlen(S->SBuffer);
if (S->SBufSize != sizeof(SBuffer))
S->SBufSize += (long)HeadSize;
else
S->SBufSize = (long)strlen(S->SBuffer);
MSUSendData(S,MAX_SOCKETWAIT,TRUE,TRUE);
@@ -565,7 +565,7 @@ int SetJobUserPrio(
if (!(FLAGS & ((1 << fAdmin1) | (1 << fAdmin2))))
{
if (strcasecmp(J->Cred.U->Name,Auth) != 0)
if (strcmp(J->Cred.U->Name,Auth) != 0)
{
DBG(2,fUI) DPrint("INFO: user %s is not authorized to set user priority on job %s\n",
Auth,
@@ -618,7 +618,7 @@ int UIShowGrid(
for (sindex = 0;MStatType[sindex] != 0;sindex++)
{
if (!strcasecmp(MStatType[sindex],GStat))
if (!strcmp(MStatType[sindex],GStat))
break;
} /* END for (sindex) */
@@ -777,7 +777,7 @@ int ShowBackfillWindow(
{
for (mindex = 0;MComp[mindex] != NULL;mindex++)
{
if (!strcasecmp(MComp[mindex],MemCmp))
if (!strcmp(MComp[mindex],MemCmp))
break;
}
@@ -858,9 +858,9 @@ int ShowBackfillWindow(
(BFNodeCount >= RequiredNodes) &&
(BFProcCount >= RequiredProcs))
{
if (strcasecmp(P->Name,CurrentPName) != 0)
if (strcmp(P->Name,CurrentPName) != 0)
{
if ((strcasecmp(CurrentPName,GLOBAL_MPARNAME)) && (index == 0))
if ((strcmp(CurrentPName,GLOBAL_MPARNAME)) && (index == 0))
{
sprintf(Buffer,"%sno %s available\n",
Buffer,
+7 -34
View File
@@ -82,10 +82,6 @@ int main(
int GlobalSQ[MAX_MJOB];
int GlobalHQ[MAX_MJOB];
char *tmpArgV[1024 + 1];
int aindex;
const char *FName = "main";
#ifdef __MPURIFY
@@ -107,23 +103,11 @@ int main(
FName,
ArgC);
MSysInitialize(TRUE);
MSysInitialize();
ServerSetSignalHandlers();
for (aindex = 0;aindex < ArgC;aindex++)
{
if ((ArgV[aindex] == NULL) || (aindex >= 1024))
break;
tmpArgV[0] = NULL;
MUStrDup(&tmpArgV[aindex],ArgV[aindex]);
}
tmpArgV[aindex] = NULL;
ServerProcessArgs(ArgC,tmpArgV,TRUE);
ServerProcessArgs(ArgC,ArgV,TRUE);
if (MSysLoadConfig(MSched.HomeDir,MSched.ConfigFile,(1 << mcmForce)) == FAILURE)
{
@@ -139,18 +123,7 @@ int main(
MSysDoTest();
ServerProcessArgs(ArgC,tmpArgV,FALSE);
/* walk to end of ArgV[] because ServerProcessArgs() may free portions of tmpArgV[]
as side-affect */
for (aindex = 0;aindex < ArgC;aindex++)
{
if (ArgV[aindex] == NULL)
break;
MUFree(&tmpArgV[aindex]);
}
ServerProcessArgs(ArgC,ArgV,FALSE);
if (MSched.Mode != msmSim)
{
@@ -593,7 +566,7 @@ int MServerConfigShow(
int ServerProcessArgs(
int ArgC,
char **ArgV, /* I (potentially modified) */
char **ArgV,
int PreLoad) /* I (boolean) */
{
@@ -625,7 +598,7 @@ int ServerProcessArgs(
if (ArgV[index] == NULL)
break;
MUStrDup(&MSched.Argv[index],ArgV[index]);
MSched.Argv[index] = ArgV[index];
} /* END for (index) */
MSched.Argv[index] = NULL;
@@ -1062,7 +1035,7 @@ int ServerProcessArgs(
int ServerShowCopy()
{
fprintf(stderr,"Copyright 2000-2010 Cluster Resources, Inc, All Rights Reserved\n");
fprintf(stderr,"Copyright 2000-2005 Cluster Resources, Inc, All Rights Reserved\n");
fprintf(stderr," for the latest release, see http://clusterresources.com/maui\n");
fprintf(stderr,"This software includes the Maui Server Module, Copyright 1996 MHPCC, All Rights Reserved\n");
@@ -1242,7 +1215,7 @@ int ServerProcessRequests()
MSysDestroyObjects();
MSysInitialize(TRUE);
MSysInitialize();
ServerSetSignalHandlers();
+19 -70
View File
@@ -1775,7 +1775,6 @@ int UIJobShow(
MAX_MTIME,
P->Index,
Reason,
FALSE,
FALSE) == FAILURE) || (DstQ[0] == -1))
{
for (index = 0;index < MAX_MREJREASON;index++)
@@ -3740,7 +3739,7 @@ int UIQueueDiagnose(
MPolicyMode[PLevel],
MAList[ePartition][PIndex]);
if (MQueueDiagnose(MJob,MUIQ,PLevel,&MPar[PIndex],Buffer,*BufSize) == FAILURE)
if (MQueueDiagnose(MJob,MUIQ,PLevel,&MPar[PIndex],Buffer) == FAILURE)
{
sprintf(Buffer,"cannot evaluate blocked jobs\n");
@@ -3925,12 +3924,12 @@ int UIChangeParameter(
/* evaluate cred config */
MCredLoadConfig(mxoSys,NULL,RBuffer,NULL);
MCredLoadConfig(mxoQOS,NULL,RBuffer,NULL);
MCredLoadConfig(mxoUser,NULL,RBuffer,NULL);
MCredLoadConfig(mxoGroup,NULL,RBuffer,NULL);
MCredLoadConfig(mxoAcct,NULL,RBuffer,NULL);
MCredLoadConfig(mxoClass,NULL,RBuffer,NULL);
MCredLoadConfig(mxoSys,NULL,RBuffer);
MCredLoadConfig(mxoQOS,NULL,RBuffer);
MCredLoadConfig(mxoUser,NULL,RBuffer);
MCredLoadConfig(mxoGroup,NULL,RBuffer);
MCredLoadConfig(mxoAcct,NULL,RBuffer);
MCredLoadConfig(mxoClass,NULL,RBuffer);
/* MNodeLoadConfig(NULL,RBuffer); */
@@ -4084,12 +4083,12 @@ int UIClusterShow(
{
F = &MFrame[findex];
if ((F == NULL) || (F->Name[0] == '\0') || (F->NodeCount <= 0))
continue;
DBG(5,fUI) DPrint("INFO: collecting status for frame %s\n",
F->Name);
if (F->NodeCount <= 0)
continue;
switch(DisplayMode)
{
case mwpXML:
@@ -4133,11 +4132,6 @@ int UIClusterShow(
if (N->Name[0] == '\1')
continue;
if (!strcmp(N->Name,"GLOBAL"))
continue;
DBG(5,fUI) DPrint("INFO: checking node %s\n", N->Name);
/* display failure information */
if ((N->CRes.Disk > 0) && (N->ARes.Disk <= 0))
@@ -5217,8 +5211,6 @@ int UIDiagnosePriority(
int JobCount;
double tmpD;
char *BPtr;
int BSpace;
mjob_t *J;
@@ -5228,14 +5220,15 @@ int UIDiagnosePriority(
FName,
(P != NULL) ? P->Name : "NULL");
MUSNInit(&BPtr,&BSpace,Buffer,(int)*BufSize);
MUSNPrintF(&BPtr, &BSpace, "diagnosing job priority information (partition: %s)\n\n",
Buffer[0] = '\0';
sprintf(Buffer,"%sdiagnosing job priority information (partition: %s)\n\n",
Buffer,
P->Name);
/* initialize priority statistics */
MJobGetStartPriority(NULL,P->Index,NULL,1,&BPtr,&BSpace);
MJobGetStartPriority(NULL,P->Index,NULL,1,Buffer);
JobCount = 0;
@@ -5249,7 +5242,7 @@ int UIDiagnosePriority(
DBG(5,fUI) DPrint("INFO: diagnosing priority for job '%s'\n",
J->Name);
MJobGetStartPriority(J,P->Index,&tmpD,0,&BPtr,&BSpace);
MJobGetStartPriority(J,P->Index,&tmpD,0,Buffer);
J->StartPriority = (long)tmpD;
@@ -5258,7 +5251,7 @@ int UIDiagnosePriority(
if (JobCount > 0)
{
MJobGetStartPriority(NULL,P->Index,NULL,2,&BPtr,&BSpace);
MJobGetStartPriority(NULL,P->Index,NULL,2,Buffer);
}
else
{
@@ -5521,14 +5514,7 @@ int MUIJobSetAttr(
{
long tmpPrio;
if (!(CFlags & ((1 << fAdmin1) | (1 << fAdmin2))))
{
sprintf(Msg,"ERROR: not authorized to run this command");
return(FAILURE);
}
tmpPrio = strtol(Val,NULL,0);
tmpPrio = strtol(Val,NULL,0);
if ((tmpPrio < 0) || (tmpPrio > 1000))
{
@@ -5564,7 +5550,7 @@ int MUIJobSetAttr(
{
mqos_t *Q;
int QAL[(MAX_MQOS >> 5) + 1];
int QAL[MAX_MQOS >> 5];
if (!(CFlags & ((1 << fAdmin1) | (1 << fAdmin2))) &&
(JobOwner == FALSE))
@@ -6309,8 +6295,6 @@ int UIResCreate(
int index;
char Pattern[MAX_MBUFFER];
char *PatPtr;
int PatSize;
char *ptr;
char *TokPtr;
@@ -6673,38 +6657,6 @@ int UIResCreate(
NodeCount = NIndex;
}
/* When the feature list is set, and a HOST_REGEX or "ALL"
* is used, we replace the Pattern with the resulting nodelist.
* This ensures the reservation is checkpointed properly */
if ((strcmp(FeatureList,NONE) != 0) && (strstr(Pattern,"TASKS") == NULL))
{
PatPtr = Pattern;
PatSize = sizeof(Pattern);
PatPtr[0] = '\0';
for (nindex = 0;nindex < NodeCount;nindex++)
{
if (PatSize < 100)
{
DBG(0,fSCHED) DPrint("ERROR: regex buffer overflow creating reservation '%s'\n", ResID);
return(FAILURE);
}
if (nindex != 0)
{
MUSNPrintF(&PatPtr,&PatSize,"|%s",
NodeList[nindex].N->Name);
}
else
{
MUSNPrintF(&PatPtr,&PatSize,"%s",
NodeList[nindex].N->Name);
}
}
}
/* translate dedicated proc request to per node proc request */
SPC = tmpRQ.DRes.Procs;
@@ -9511,9 +9463,6 @@ int ConfigShow(
{
Q = &MQOS[qindex];
if (Q->Name[0] == '\0')
break;
MQOSConfigShow(Q,Vflag,PIndex,ptr,MAX_MBUFFER);
} /* END for (qindex) */
+2 -2
View File
@@ -1,10 +1,10 @@
VERSION 3.3.1
VERSION 3.2.6p14
PACKAGE maui
AUTHOR Cluster Resources, Inc
FILETYPE Module
COPYRIGHT Copyright (C) 1999-2010 Cluster Resources, Inc
COPYRIGHT Copyright (C) 1999-2005 Cluster Resources, Inc
DISCLAIMER
------------------------------------------------------------------------------
+11 -16
View File
@@ -2,7 +2,6 @@
#include "mclient.h"
#include "mclient-proto.h"
#include "msched-version.h"
#include "moab.h"
#include "msched-proto.h"
@@ -10,7 +9,6 @@
#define MAX_MCARGS 128
extern mattrlist_t MAList;
extern m64_t M64;
int MCResCreate(char *);
int MCJobShow(char *);
@@ -564,8 +562,6 @@ int __MCInitialize()
DBG(2,fALL) DPrint("%s()\n",
FName);
M64Init(&M64);
MUBuildPList(MCfg,MParam);
strcpy(C.ServerHost,DEFAULT_MSERVERHOST);
@@ -684,8 +680,7 @@ int __MCInitialize()
if ((buf = MFULoad(MASTER_CONFIGFILE,1,macmRead,&count,&SC)) != NULL)
{
if (((ptr = strstr(buf,MParam[pMServerHomeDir])) != NULL) ||
((ptr = strstr(buf,"MAUIHOMEDIR")) != NULL))
if ((ptr = strstr(buf,MParam[pMServerHomeDir])) != NULL)
{
MUSScanF(ptr,"%x%s %x%s",
sizeof(tmpLine),
@@ -2539,11 +2534,11 @@ int MCShowCStats(
mgcred_t *tmpUP[MAX_MUSER];
mgcred_t *tmpU = NULL;
mgcred_t *tmpG = NULL;
mgcred_t *tmpA = NULL;
mqos_t *tmpQ = NULL;
mclass_t *tmpC = NULL;
mgcred_t *tmpU;
mgcred_t *tmpG;
mgcred_t *tmpA;
mqos_t *tmpQ;
mclass_t *tmpC;
char *NameP;
@@ -2598,7 +2593,7 @@ int MCShowCStats(
case mxoUser:
if (OCount == 0)
tmpU = (mgcred_t *)calloc(MAX_MUSER, sizeof(mgcred_t));
tmpU = (mgcred_t *)malloc(sizeof(mgcred_t) * MAX_MUSER);
O = &tmpU[OCount + 1];
@@ -2609,7 +2604,7 @@ int MCShowCStats(
case mxoGroup:
if (OCount == 0)
tmpG = (mgcred_t *)calloc(MAX_MGROUP,sizeof(mgcred_t));
tmpG = (mgcred_t *)malloc(sizeof(mgcred_t) * MAX_MGROUP);
O = &tmpG[OCount + 1];
@@ -2618,7 +2613,7 @@ int MCShowCStats(
case mxoAcct:
if (OCount == 0)
tmpA = (mgcred_t *)calloc(MAX_MACCT, sizeof(mgcred_t));
tmpA = (mgcred_t *)malloc(sizeof(mgcred_t) * MAX_MACCT);
O = &tmpA[OCount + 1];
@@ -2627,7 +2622,7 @@ int MCShowCStats(
case mxoClass:
if (OCount == 0)
tmpC = (mclass_t *)calloc(MAX_MCLASS, sizeof(mclass_t));
tmpC = (mclass_t *)malloc(sizeof(mclass_t) * MAX_MCLASS);
O = &tmpC[OCount + 1];
@@ -2636,7 +2631,7 @@ int MCShowCStats(
case mxoQOS:
if (OCount == 0)
tmpQ = (mqos_t *)calloc(MAX_MQOS, sizeof(mqos_t));
tmpQ = (mqos_t *)malloc(sizeof(mqos_t) * MAX_MQOS);
O = &tmpQ[OCount + 1];
+4 -5
View File
@@ -1501,7 +1501,7 @@ int Mode)
}
else
{
fprintf(stdout,"%s",
fprintf(stdout,
(Mode & (1 << mMatrix)) ? MNull : Null);
}
}
@@ -1517,7 +1517,7 @@ int Mode)
}
else
{
fprintf(stdout,"%s",
fprintf(stdout,
(Mode & (1 << mMatrix)) ? MNull : Null);
fprintf(stdout,"\n");
@@ -1541,7 +1541,7 @@ int Mode)
}
else
{
fprintf(stdout,"%s",
fprintf(stdout,
(Mode & (1 << mMatrix)) ? MNull : Null);
}
}
@@ -2302,7 +2302,6 @@ int MPLoadTrace(
while (ptr < tail)
{
LineCount++;
Offset = 0;
if (MTraceLoadWorkload(ptr,&Offset,&tmpJ,msmProfile,&Version) == SUCCESS)
{
@@ -2325,7 +2324,7 @@ int MPLoadTrace(
if ((Profile.Host[0] != '\0') && (strcmp(Profile.Host,J->MasterHostName)))
continue;
if ((J->Cred.Q != NULL) && (Profile.QOSList[0] != '\0') && !strstr(Profile.QOSList,J->Cred.Q->Name))
if ((J->Cred.Q != NULL) && !strstr(Profile.QOSList,J->Cred.Q->Name))
continue;
if (Profile.UserNameList[0][0] != '\0')
+2 -2
View File
@@ -3282,7 +3282,7 @@ int MCShowBlocked(
char *ptr;
char name[MAX_MNAME];
char Reason[MAX_MBUFFER];
int TotalProcs;
char TotalProcs[MAX_MNAME];
char UserName[MAX_MNAME];
@@ -3756,7 +3756,7 @@ int MCShowSchedulerStatistics(
/* STT INT RT IQ RJ RJ AN AP AM IN IP IM TC SJ TPH DPH SPH MSA MSD QPS AQN WCA CAC PSX IT RPI MEF ME MXF ABP MB AQT MQT PSR PSD PSU MSA MSD JE */
sscanf(ptr,"%ld %ld %d %d %d %d %d %d %d %d %d %d %d %d %lf %lf %lf %lf %lf %ld %lu %lf %lf %lf %d %ld %lf %d %lf %lf %d %lf %lf %lf %lf %lf %lf %lf %d %d %lf",
sscanf(ptr,"%ld %ld %d %d %d %d %d %d %d %d %d %d %d %d %lf %lf %lf %lf %lf %lu %lu %lf %lf %lf %d %ld %lf %d %lf %lf %d %lf %lf %lf %lf %lf %lf %lf %d %d %lf",
&StartTime,
&InitializationTime,
&SchedRunTime, /* Time in Hundredth of a Second */