Apple Mac OS X Server Network Card User Manual


 
142 Chapter 9 Working with File Services
Sending a Message to AFP Users
You can use the sendMessage command with the serveradmin tool to send a text
message to connected AFP users. Users are specified by session ID.
To send a message:
$ sudo serveradmin command
afp:command = sendMessage
afp:message = "
message-text
"
afp:sessionIDsArray:_array_index:0 =
sessionid1
afp:sessionIDsArray:_array_index:1 =
sessionid2
afp:sessionIDsArray:_array_index:2 =
sessionid3
[...]
Control-D
Disconnecting AFP Users
You can use the disconnectUsers command with the serveradmin tool to disconnect
AFP users. Users are specified by session ID. You can specify a delay time before
disconnect and a warning message.
To disconnect users:
$ sudo serveradmin command
afp:command = disconnectUsers
afp:message = "
message-text
"
afp:minutes =
minutes-until
afp:sessionIDsArray:_array_index:0 =
sessionid1
afp:sessionIDsArray:_array_index:1 =
sessionid2
afp:sessionIDsArray:_array_index:2 =
sessionid3
[...]
Control-D
<serviceType>
The share point the user is accessing.
<sessionID> An integer that identifies the user session.
<state> State of the service.
Value returned by getConnectedUsers
(afp:usersArray:_array_index:<
n
>:) Description
Parameter Description
message-text The message that appears on client computers.
sessionidn The session ID of a user you want to receive the message. To list the
session IDs of connected users, use the
getConnectedUsers
command. See “Listing Connected Users” on page 141.
Parameter Description
message-text
The text of a message that appears on client computers in the
disconnect announcement dialog.