<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://wiki.define-technology.com/mediawiki-1.35.0/index.php?action=history&amp;feed=atom&amp;title=Using_egroup_in_LSF</id>
	<title>Using egroup in LSF - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://wiki.define-technology.com/mediawiki-1.35.0/index.php?action=history&amp;feed=atom&amp;title=Using_egroup_in_LSF"/>
	<link rel="alternate" type="text/html" href="http://wiki.define-technology.com/mediawiki-1.35.0/index.php?title=Using_egroup_in_LSF&amp;action=history"/>
	<updated>2026-05-05T02:44:06Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.35.0</generator>
	<entry>
		<id>http://wiki.define-technology.com/mediawiki-1.35.0/index.php?title=Using_egroup_in_LSF&amp;diff=2300&amp;oldid=prev</id>
		<title>Michael: Created page with &quot;Use egroup to generate a list of users in LSF.   Useful for when admin have large groups of users and cant be bother to program each user manually.  ===== Create the egroup fi...&quot;</title>
		<link rel="alternate" type="text/html" href="http://wiki.define-technology.com/mediawiki-1.35.0/index.php?title=Using_egroup_in_LSF&amp;diff=2300&amp;oldid=prev"/>
		<updated>2013-05-01T09:22:36Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;Use egroup to generate a list of users in LSF.   Useful for when admin have large groups of users and cant be bother to program each user manually.  ===== Create the egroup fi...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Use egroup to generate a list of users in LSF. &lt;br /&gt;
&lt;br /&gt;
Useful for when admin have large groups of users and cant be bother to program each user manually.&lt;br /&gt;
&lt;br /&gt;
===== Create the egroup file =====&lt;br /&gt;
* in $LSF_SERVERDIR/egroup [chmod +x]&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;-m&amp;quot; ]; then                             #host group&lt;br /&gt;
    if  [ &amp;quot;$2&amp;quot; == &amp;quot;linux_grp&amp;quot; ]; then                 #Linux hostgroup&lt;br /&gt;
        echo &amp;quot;linux01 linux02 linux03 linux04&amp;quot;&lt;br /&gt;
    elif [ &amp;quot;$2&amp;quot; == &amp;quot;sol_grp&amp;quot; ]; then                  #Solaris hostgroup&lt;br /&gt;
        echo &amp;quot;Sol02 Sol02 Sol03 Sol04&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
else                                                 #user group&lt;br /&gt;
 if [ &amp;quot;$2&amp;quot; == &amp;quot;srv_grp&amp;quot; ]; then                       #srvgrp user group&lt;br /&gt;
        echo &amp;quot;userA userB userC userD&amp;quot;&lt;br /&gt;
    elif [ &amp;quot;$2&amp;quot; == &amp;quot;dev_grp&amp;quot; ]; then                  #devgrp user group&lt;br /&gt;
        echo &amp;quot;user1 user2 user3 user4&amp;quot;&lt;br /&gt;
 fi&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Edit lsb.users (or lsb.hosts) =====&lt;br /&gt;
egroup will be called when the GROUP_MEMBER flag contains a (!)&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
Begin UserGroup&lt;br /&gt;
GROUP_NAME       GROUP_MEMBER              USER_SHARES            #GROUP_ADMIN&lt;br /&gt;
ugroup1         (atlasprod) ()   #()&lt;br /&gt;
ugroup2         (lhcbusers) ()   #()&lt;br /&gt;
# The following are generated from the egroup script&lt;br /&gt;
srv_grp         (!) ()&lt;br /&gt;
dev_grp         (!) ()&lt;br /&gt;
End UserGroup&lt;br /&gt;
&lt;br /&gt;
Begin User&lt;br /&gt;
USER_NAME        MAX_JOBS    MAX_PEND_JOBS&lt;br /&gt;
default          400         -              # default, any user/group has threshold of 100&lt;br /&gt;
#david           5           -&lt;br /&gt;
ugroup1@          100           -&lt;br /&gt;
ugroup2@          200           -&lt;br /&gt;
# The following are groups defined are above called from egroup&lt;br /&gt;
srv_grp@          800           -&lt;br /&gt;
dev_grp@          50            -&lt;br /&gt;
End User&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Reconfig =====&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
addhost -u &lt;br /&gt;
OR&lt;br /&gt;
badmin reconfig&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Check users are added correctly =====&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
[root@vhpchead etc]# busers all&lt;br /&gt;
USER/GROUP          JL/P    MAX  NJOBS   PEND    RUN  SSUSP  USUSP    RSV&lt;br /&gt;
atlasprod              -    100      0      0      0      0      0      0&lt;br /&gt;
david                  -    400      0      0      0      0      0      0&lt;br /&gt;
default                -    400      -      -      -      -      -      -&lt;br /&gt;
dev_grp                -    400      0      0      0      0      0      0&lt;br /&gt;
echin                  -    400      0      0      0      0      0      0&lt;br /&gt;
kcl                    -    400      0      0      0      0      0      0&lt;br /&gt;
lancaster2             -    400      0      0      0      0      0      0&lt;br /&gt;
lhcbusers              -    200      0      0      0      0      0      0&lt;br /&gt;
srv_grp                -    400      0      0      0      0      0      0&lt;br /&gt;
ugroup1                -    400      0      0      0      0      0      0&lt;br /&gt;
ugroup2                -    400      0      0      0      0      0      0&lt;br /&gt;
user1                  -     50      0      0      0      0      0      0&lt;br /&gt;
user2                  -     50      0      0      0      0      0      0&lt;br /&gt;
user3                  -     50      0      0      0      0      0      0&lt;br /&gt;
user4                  -     50      0      0      0      0      0      0&lt;br /&gt;
user5                  -    400      0      0      0      0      0      0&lt;br /&gt;
userA                  -    800      0      0      0      0      0      0&lt;br /&gt;
userB                  -    800      0      0      0      0      0      0&lt;br /&gt;
userC                  -    800      0      0      0      0      0      0&lt;br /&gt;
userD                  -    800      0      0      0      0      0      0&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Michael</name></author>
	</entry>
</feed>