Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emulab
emulab-devel
Commits
9dc93498
Commit
9dc93498
authored
Apr 13, 2004
by
Leigh B. Stoller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update the exports file when adding/deleting users.
parent
0a559704
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
0 deletions
+20
-0
account/tbacct.in
account/tbacct.in
+20
-0
No files found.
account/tbacct.in
View file @
9dc93498
...
...
@@ -52,6 +52,7 @@ my $SETGROUPS = "$TB/sbin/setgroups";
my
$GENELISTS
=
"
$TB
/sbin/genelists
";
my
$SFSUPDATE
=
"
$TB
/sbin/sfskey_update
";
my
$PBAG
=
"
$TB
/sbin/paperbag
";
my
$EXPORTSSETUP
=
"
$TB
/sbin/exports_setup
";
my
$NOLOGIN
=
"
/sbin/nologin
";
my
$SSH
=
"
$TB
/bin/sshtb
";
my
$SAVEUID
=
$UID
;
...
...
@@ -303,6 +304,18 @@ sub AddUser()
}
# Add to elists.
system
("
$GENELISTS
-n
$user
");
#
# Must update the exports file or else nodes will complain. There
# is a bit of race in here since this update happens after the
# user is marked "active", and in that time a node could suck over
# the account info, but not be able to mount the directory. Short
# window though. Do not worry about the exit value. Note that this
# could hang for a while if another update is in progress. Hmm, I
# do not like this.
#
print
"
Updating exports file.
\n
";
system
("
$EXPORTSSETUP
");
$EUID
=
0
;
# SFS key.
...
...
@@ -353,6 +366,13 @@ sub DelUser()
$UID
=
$SAVEUID
;
$EUID
=
$UID
;
#
# Must update the exports file or else nodes will complain. Note
# that this could hang for a while if another update is in progress.
#
print
"
Updating exports file.
\n
";
system
("
$EXPORTSSETUP
");
# Remove from elists.
system
("
$GENELISTS
-n
$user
");
$EUID
=
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment