home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Professional / OS2PRO194.ISO / os2 / network / chkstore / chksto.inf (.txt) < prev    next >
OS/2 Help File  |  1993-12-16  |  12KB  |  433 lines

  1.  
  2. ΓòÉΓòÉΓòÉ 1. Copyright and Author ΓòÉΓòÉΓòÉ
  3.  
  4. (c) Copyright International Business Machines Corporation 1993. 
  5.  
  6. All rights Reserved 
  7.  
  8. The Author of this package is David Kelsey. 
  9.  
  10.  
  11. ΓòÉΓòÉΓòÉ 2. Change History ΓòÉΓòÉΓòÉ
  12.  
  13.  o 10th May 1993  11:05 - D.Kelsey 
  14.  
  15.    Added the section about the inform flag and the exclude list flag. changes 
  16.    also made to the dependency list and the new files for the recent update. 
  17.  
  18.  o 17th Sept 1993  09:55 - D.Kelsey 
  19.  
  20.    changed description of what CHKSTORE.CMD is, added note that to monitor you 
  21.    need to run this program at frequent intervals. minor update about CHKHOME 
  22.    program. 
  23.  
  24.  o 14th Dec 1993  14:00 - D.Kelsey 
  25.  
  26.    Corrected to descibe new version. 
  27.  
  28.  
  29. ΓòÉΓòÉΓòÉ 3. Acknowledgements ΓòÉΓòÉΓòÉ
  30.  
  31. I would like to thanks the following people who helped in one way or another in 
  32. the creation of this package 
  33.  
  34.  o Larry Snyder 
  35.  
  36.  o David Morrill 
  37.  
  38.  o Robin McInnes 
  39.  
  40.  o Richard Lam 
  41.  
  42.  There has also been help from many other people in small ways and although 
  43.  they are not mentioned here, I thanks those people as well. 
  44.  
  45.  
  46. ΓòÉΓòÉΓòÉ 4. The CHKSTORE system. ΓòÉΓòÉΓòÉ
  47.  
  48.  This system was designed to be able to perform the following actions :- 
  49.  
  50.  o Check the storage used on a user's home directory and compare it to the 
  51.    MAXSTORAGE limit for that user. If it exceeds it, then "revoke" the user. If 
  52.    it is greater than a certain threshold, then mark that user as needing a 
  53.    warning. Also to "unrevoke" a revoked user if they go under their limit. 
  54.  
  55.  o Provide a function to "unrevoke" a user if they have been revoked. 
  56.  
  57.  o Provide a function for the user to check how much space they have used and 
  58.    how much they are allowed 
  59.  
  60.  o Provide a means of informing the user at logon time if they have been 
  61.    revoked or they are passed the warning limit. 
  62.  
  63.  The concept of being revoked access to your home directory is making the home 
  64.  directory and all it's subdirectories available as to that user with only the 
  65.  read, delete and attribute permissions available. This means a user can read, 
  66.  delete or change the attributes of files but cannot create files, nor write to 
  67.  a file. 
  68.  
  69.  
  70. ΓòÉΓòÉΓòÉ 4.1. Software levels ΓòÉΓòÉΓòÉ
  71.  
  72. The code run on the LAN server machine must be OS/2 v2.0 or higher and LAN 
  73. server v2.0 or higher. The code running on the requesters must be OS/2 v2.0 or 
  74. higher and LAN requester v2.0 or higher. 
  75.  
  76.  
  77. ΓòÉΓòÉΓòÉ 4.2. Installation ΓòÉΓòÉΓòÉ
  78.  
  79. The following sections describe how to install the 4 components. 
  80.  
  81.  o CHKSTORE space checking program 
  82.  
  83.  o UNREVOKE command 
  84.  
  85.  o CHKHOME command 
  86.  
  87.  o User Warning system 
  88.  
  89.  
  90. ΓòÉΓòÉΓòÉ 4.2.1. CHKSTORE space checking program ΓòÉΓòÉΓòÉ
  91.  
  92. This program is used to check the space used and will "revoke" and "unrevoke" 
  93. users as necessary. 
  94.  
  95. To install the space checking package :- 
  96.  
  97.  o Create a Subdirectory on your server (preferbly the domain controller but it 
  98.    should work on any server in the domain) for example 
  99.  
  100.       D:\CHKSTORE
  101.  
  102.  o Install on this directory the following files 
  103.  
  104.       CHKSTORE.EXE
  105.       UNREVOKE.MSG   (this file must be in the same directory as CHKSTORE.CMD)
  106.       REVOKE.MSG     (this file must be in the same directory as CHKSTORE.CMD)
  107.  
  108.  o Install CHKSTDLL.DLL in a subdirectory in the LIBPATH of the server. 
  109.    Alternatively install it in a new subdirectory, add this subdirectory to the 
  110.    LIBPATH and reboot the server. 
  111.  
  112.  o Create a subdirectory off the root of a chosen drive called LOGON for 
  113.    example 
  114.  
  115.       D:\LOGON
  116.  
  117.  o Create an Alias called LOGON which points to this newly created subdirectory 
  118.  
  119.  
  120. ΓòÉΓòÉΓòÉ 4.2.2. UNREVOKE command ΓòÉΓòÉΓòÉ
  121.  
  122. This describes how to install the UNREVOKE command on a server which an 
  123. administrator can use to "unrevoke" a user. Only administrators can use this 
  124. program. 
  125.  
  126. To install UNREVOKE on the server and make it a public application 
  127.  
  128.  o Install on a subdirectory (the same directory used to store CHKSTORE is 
  129.    recommended) the following files 
  130.  
  131.       UNREVOKE.EXE
  132.       UNREVOKE.MSG   (this file must be in the same directory as UNREVOKE.CMD)
  133.  
  134.  o Ensure that administrators who have will use this program have access to 
  135.    CHKSTDLL.DLL. This could be done by 
  136.  
  137.     - defining the public application working directory to point to a copy of 
  138.       CHKSTDLL.DLL on the server (could use the copy used by the chkstore 
  139.       checking space) and ensure the requester has .; in the LIBPATH. 
  140.  
  141.     - give a requester access to the directory where CHKSTDLL.DLL is installed 
  142.       on the server in it's LIBPATH. for example :- 
  143.  
  144.             LIBPATH=.........;\\GBM00141\EUAPPLS\DLLS;
  145.  
  146.               or
  147.  
  148.             LIBPATH=.........;W:\DLLS;
  149.  
  150.               and the requester does a NET USE W: to an alias which has
  151.               a subdirectory DLLS containing CHKSTDLL.DLL
  152.  
  153.  o define an alias for the subdirectory where UNREVOKE is installed 
  154.  
  155.  o Define a public application for UNREVOKE.EXE, with prompt for parameters 
  156.    (see later for invocation on UNREVOKE.EXE) 
  157.  
  158.  
  159. ΓòÉΓòÉΓòÉ 4.2.3. CHKHOME command ΓòÉΓòÉΓòÉ
  160.  
  161. This program can be stored on the server and the users access it to determine 
  162. how much space they have used on their home directory and how much space they 
  163. are allowed. 
  164.  
  165. To install :- 
  166.  
  167.  o create a subdirectory for example 
  168.  
  169.       D:\CHKHOME
  170.    or use an existing one, but not the one where CHKSTORE or UNREVOKE are 
  171.    installed. 
  172.  
  173.  o define an alias for this subdirectory 
  174.  
  175.  o Give every user READ ONLY access to this subdirectory 
  176.  
  177.  o install CHKHOME.CMD on this subdirectory 
  178.  
  179.  o ensure that all users have access to CHKSTDLL.DLL as described for 
  180.    administrators in the section on installing UNREVOKE.EXE 
  181.  
  182.  o define a public application with working directory as this subdirectory 
  183.    (there are no parameters for the CHKHOME program) 
  184.  
  185.  
  186. ΓòÉΓòÉΓòÉ 4.2.4. Installing the User warning system ΓòÉΓòÉΓòÉ
  187.  
  188. This system will display messages to the user if the CHKSTORE checking program 
  189. revokes a user or the user is over a warning limit. 
  190.  
  191.  o Create a PROFILE.CMD based on the PROFILE.SMP supplied 
  192.  
  193.  o Create a LOGONPRF.CMD based on the LOGONPRF.SMP supplied 
  194.  
  195.  o Install PROFILE.CMD in the DCDB\USERS\userid directory for each user 
  196.  
  197.  o Give all users READ ONLY access to Alias LOGON. 
  198.  
  199.  o install LOGONPRF.CMD and CHKUSED.CMD in the subdirectory pointed to by the 
  200.    LOGON alias (D:\LOGON in the CHKSTORE space checking package installation 
  201.    example) 
  202.  
  203.  
  204. ΓòÉΓòÉΓòÉ 4.3. Setup and User guide. ΓòÉΓòÉΓòÉ
  205.  
  206. This section gives information on how to execute the space checking program 
  207. CHKSTORE and also how to register users to be checked. It also describes the 
  208. other functions provided such as the UNREVOKE command and the CHKHOME command. 
  209.  
  210.  
  211. ΓòÉΓòÉΓòÉ 4.3.1. Defining a user to the Monitor. ΓòÉΓòÉΓòÉ
  212.  
  213. To define a user so that their home directory storage is checked you have to do 
  214. 3 actions. 
  215.  
  216.  o Define a home directory for that user 
  217.  
  218.  o Allocate to the user a MAXSTORAGE size 
  219.  
  220.       To define the MAXSTORAGE size of 100Kb for user FRED you would type
  221.       while logged on to an administrator the command
  222.  
  223.       NET USER FRED /MAXSTORAGE:100
  224.  
  225.       in an OS/2 window or OS/2 Full Screen.
  226.  
  227.  o ensure a copy of PROFILE.CMD exists in the DCDB\USER\userid subdirectory for 
  228.    that user. For example user FRED would require a copy of PROFILE.CMD on 
  229.  
  230.       C:\IBMLAN\DCDB\USER\FRED
  231.  
  232.  If you want the user to be checked for a default amount of storage allowed, 
  233.  then specify a MAXSTORAGE of 1. The default is then supplied when the CHKSTORE 
  234.  space checking program is executed as described in the next section. If You do 
  235.  this however you must not use the alert function of CHKSTORE. It will generate 
  236.  alerts which are not true for that user. 
  237.  
  238.  
  239. ΓòÉΓòÉΓòÉ 4.3.2. check and restrict the space used. ΓòÉΓòÉΓòÉ
  240.  
  241. You can now check the space used, restricting users as necessary. To do this 
  242. manually you need to do 
  243.  
  244.  o Go to the Server and Logon as an administrator 
  245.  
  246.  o change to the directory where CHKSTORE.CMD is installed 
  247.  
  248.  o invoke CHKSTORE with required parameters. 
  249.  
  250.  To perform any subsequent checks you need to invoke CHKSTORE again. It is 
  251.  suggested that you define specific times to run CHKSTORE or run it at regular 
  252.  intervals in order to continuously track the space used on the home 
  253.  directories 
  254.  
  255.  
  256. ΓòÉΓòÉΓòÉ 4.3.2.1. CHKSTORE invocation ΓòÉΓòÉΓòÉ
  257.  
  258. CHKSTORE call format is as follows :- 
  259.  
  260. CHKSTORE /D:xxxx /W:yy /I:z /A /N /R
  261.  
  262. where
  263. /D: xxxx - is the default disk size limit in Kb for all users who have
  264.                  been given 1 Kb in their MAXSTORAGE entry
  265. /W:   yy - is the warning percentage for which if a user exceeds this for
  266.            their home directory storage use, a warning is issued.
  267. /I:    z - this allows you to send a net popup message to a user where
  268.                  z can be :-
  269.                  R = issue message to user when they are revoked only
  270.                  U = issue message to user when they are unrevoked only
  271.                  B = ussie message to user if they are revoked or unrevoked.
  272. /A       - specifies that LAN alerts are generated for any user
  273.            who has exceeded their storage limit.
  274. /N       - specifies that CHKSTORE runs in noisy mode. This generates some
  275.            output about what chkstore is doing when it is run.
  276. /R       - specifies that CHKSTORE will revoke a user again even if
  277.            they have already been revoked. (ie change their directory accesses
  278.            but not add another entry to the revoked user list)
  279.  
  280. If no values are given then the following defaults apply 
  281.  
  282. Default disk size limit = 1Mb
  283. warning percentage      = 80 %
  284. no informing will be done
  285. no alerts are generated
  286. chkstore runs in quiet mode, ie no output is displayed
  287. chkstore only revokes a user once.
  288.  
  289. The inform flag will inform a user if they have been revoked. It only informs 
  290. those users that have been revoked for the first time. Even if you specify 
  291. revoke always option the user will not get another popup message. 
  292.  
  293.  
  294. information is output by this program and 2 files are created on the LOGON 
  295. alias directory. These are 
  296.  
  297. CHKSTORE.OUT - information about all users who have home directories
  298. REVOKED.USR  - a list of all currently revoked users
  299.  
  300. The CHKSTORE.OUT file is the most useful one and provides the administrator 
  301. with information. It has the following form :- 
  302.  
  303. Last run: 10 May 1993 09:27
  304. comment    userid    allowed       used     percent    server      base directory
  305. --------  --------  ----------  ----------  --------  --------  ---------------------
  306. RESTORED  DRKELSEY    20000 Kb     2502 Kb       13%  GBM00141  E:\HD\DRKELSEY
  307. REVOKED   EROY           20 Kb    10702 Kb    53508%  GBM00141  E:\HD\EROY
  308. WARNING   PJONES         20 Kb       18 Kb       90%  GBM00141  E:\HD\PJONES
  309.           RMCINNES       10 Kb        0 Kb        0%  GBM00141  E:\HD\RMCINNES
  310.  
  311. The comment area can have 3 types of entry 
  312.  
  313. (blank) = user is ok
  314. REVOKED   = user has has their access revoked
  315. WARNING   = user will receive a warning at logon time
  316. RESTORED  = user has been unrevoked by an administrator or chkstore program
  317. EXCLUDE   = user is in the exclude list (see next section)
  318.  
  319.  
  320. ΓòÉΓòÉΓòÉ 4.3.2.2. Excluding Users ΓòÉΓòÉΓòÉ
  321.  
  322. It is possible to have users which you want to check on but not restrict. This 
  323. can be done by creating a file called EXCLUDE.LST in the same directory as the 
  324. CHKSTORE.CMD program. In there place each user to be excluded on a seperate 
  325. line eg. 
  326.  
  327. DRKELSEY
  328. ADMIN1
  329. MANAGER
  330.  
  331. These users will not have their home directories restricted when CHKSTORE is 
  332. run. 
  333.  
  334.  
  335. ΓòÉΓòÉΓòÉ 4.3.2.3. Automating the checking process ΓòÉΓòÉΓòÉ
  336.  
  337. To automate the checking process you will need to ensure that an administrator 
  338. id is logged on when the CHKSTORE program is run. You can do this by :- 
  339.  
  340.  o creating a Batch file to Logon an administrator, execute CHKSTORE then 
  341.    logoff. 
  342.  
  343.  o Ensure that an administrator id is logged on permanently (for example when 
  344.    the server is first brought up) 
  345.  
  346.  You can then use the AT command to schedule the CHKSTORE program by either 
  347.  calling your batch program or the CHKSTORE program whenever you want to check 
  348.  and restrict the storage. 
  349.  
  350.  
  351. ΓòÉΓòÉΓòÉ 4.3.3. unrevoking a user ΓòÉΓòÉΓòÉ
  352.  
  353. If a user requires to be unrevoked either because they have freed up some 
  354. storage or they have had the storage limit increased, and they cannot wait for 
  355. the next execution of CHKSTORE program, then an administrator can unrevoke a 
  356. user manually. 
  357.  
  358. UNREVOKE userid (/i)
  359. p.The user is checked for onthe  current domain of the administrator. If a 
  360. domain is specified and it is different to the administrator's current one then 
  361. that administrator id and password must exist and be the same as the current 
  362. logged on administrator on that domain. 
  363.  
  364. The /i parameter is optional and means that the user is informed by way of a 
  365. Net popup message when they have been unrevoked. This means that the user must 
  366. have the netpopup service started on their requester. 
  367.  
  368. It is possible that another administrator is trying to unrevoke a user or the 
  369. CHKSTORE program is running at the same time as you trying to use UNREVOKE. 
  370. Because of the nature of this system, this is not allowed and a warning will be 
  371. displayed and the command will terminate. If this is the case, try again a bit 
  372. later and you should be able to do the required action. 
  373.  
  374.  
  375. ΓòÉΓòÉΓòÉ 4.3.4. how a user checks their current space usage. ΓòÉΓòÉΓòÉ
  376.  
  377. The user runs the program CHKHOME which reports on the currently used space on 
  378. the home directory for the user who is logged on. It will also inform them of 
  379. their allowed limit as seen by the last run of CHKSTORE.CMD. If an 
  380. administrator has changed this value since the last run of CHKSTORE then the 
  381. user will not see the new value. It will also inform the user if they are 
  382. currently revoked or not. 
  383.  
  384. CHKHOME has no parameters and should really be setup as a public application 
  385. for the user to call 
  386.  
  387.  
  388. ΓòÉΓòÉΓòÉ 4.3.5. Usage Hints ΓòÉΓòÉΓòÉ
  389.  
  390. Below are some hints about this system. 
  391.  
  392.   1. If a user has been revoked and that user deletes files from their home 
  393.      directory, they will not be unrevoked until the next execution of the 
  394.      chkstore program or if unrevoked manually by an administrator. 
  395.  
  396.   2. If a user has been revoked and an administrator increases the user's home 
  397.      directory MAXSTORAGE value, then the user won't be unrevoked until the 
  398.      next execution of the chkstore program or if unrevoked manually by an 
  399.      administrator. 
  400.  
  401.   3. MAXSTORAGE set to 1Kb means use the default limit specified in the 
  402.      execution of CHKSTORE.CMD or the internal limit of 1Mb. If you do use this 
  403.      do NOT specify the /A option and turn alerts on otherwise a mass of alerts 
  404.      will be generated. 
  405.  
  406.   4. If a revoked user is NOT in the revoked user list (REVOKED.USR file) then 
  407.      that user will not be unrevoked. It would have to be done manually using 
  408.      the UNREVOKE command. 
  409.  
  410.   5. This system should run in a mixture of levels for Lan server within a 
  411.      domain. The chkstore program doesn't have to run on the domain controller. 
  412.  
  413.  
  414. ΓòÉΓòÉΓòÉ 5. program list ΓòÉΓòÉΓòÉ
  415.  
  416. The complete CHKSTORE system set of files is :- 
  417.  
  418. CHKSTORE.EXE    - checks space used, revokes and unrevokes
  419. UNREVOKE.EXE    - Administrator command to unrevoke a user
  420. REVOKE.MSG      - message sent to user when revoked
  421. UNREVOKE.MSG    - message sent to user when unrevoked
  422. CHKHOME.EXE     - user command to check space used
  423. CHKUSED.EXE     - logon message program (doesn't use the MSG files)
  424. LOGONPRF.SMP    - sample general logon program for all users
  425. PROFILE.SMP     - sample fixed PROFILE.CMD for all users
  426. CHKSTDLL.DLL    - provide required functions for the above programs
  427. SPACECNT.EXE    - used by CHKHOME.EXE
  428.  
  429.  
  430.  
  431.  
  432.  
  433. ********************* End Of Document **********************