. CHOWN, Utilities, Unix-like VMS chown Facility  & CHOWN - Unix-like VMS 'chown' Facility$ (c) Copyright 1991-1996, Chris OliveN ------------------------------------------------------------------------------  N As with most utilities, CHOWN was created  out  of  necessity.   I  wanted  toN change the ownership of INDEXF.SYS and QUOTA.SYS once, and wouldn't take 'No!'N for an answer.   So  CHOWN  was  born.   Since  these  files,  INDEXF.SYS  andN QUOTA.SYS,  are  locked, SET FILE/OWNER= won't cut it -- CHOWN works in placesN where SET FILE/OWNER just won't.  And not wanting to write a hack when I mightN need the same functionality on something else down the line, I generalized theN functionality into this utility.  It's called 'chown' not because I like  UnixN (but  if  I  weren't  running  VMS, I'd probably run Unix -- anything but thatN pretender Windoze and MS-DUM...) but  that's  just  what  I  named  it,  okay?G Actually, the parameters CHOWN requires are much like Unix, that's why:   ( Syntax:  CHOWN rights-id-string filespec  N The 'rights-id-string' is the name of  a  rights  identifier  on  the  system.N Since  every  user  has (should have!) a rights identifier associated with hisN name, CHOWN can be used to set the ownership of a file(s) to any user  on  theN system.  If you have by chance *removed* the associated rights id string for aN user, then this utility makes you pay for such an ignorant move --  you  won'tN be  able to use CHOWN!  Base resource numbers inside brackets (i.e.  [1,4] forN SYSTEM) and bracket delimited rights id strings (i.e.   [SYSTEM]  for  SYSTEM)N WILL  NOT  WORK!   DON'T  USE  BRACKETS!  Also, CHOWN handles what 'chown' andN 'chgrp' do on Uglix since VMS doesn't allow the same rights id  string  to  beN granted  to  two  different  group  UIC  strings  (e.g.   you  can't  have  anN [ORDER,FOO] and a [SALES,FOO] in VMS).  So the 'rights-id=string' is all  that8 is needed and it doesn't need brackets, just like Uglix.  N The 'filespec' is exactly what a filespec is in  any  other  VMS  facility  orN utility.  CHOWN can change to the ownership of all files that match a wildcard filespec, including [...]*.*;*  N For you curious more technical types out there, CHOWN works using the  ACP-QION interface.   You need a FIB and an ATR (attribute) item list; you fill the FIBN with a file's file id (FID); and,  with  a  channel  assigned  to  the  file'sN device,  $QIO using IO$MODIFY.  Magic.  Poof.  New owner.  Locks?  What locks?N (The ATR item list tells $QIO to change  the  file's  owner  to  the  UIC  you	 specify).   % That's about it.  Happy 'chown'ing... N ------------------------------------------------------------------------------ Chris Olive % ...still a VMS programmer at heart...  73740.1636@compuserve.com 