home *** CD-ROM | disk | FTP | other *** search
- [ This has been ported to SCO Xenix for the Intel 80386. There are
- two versions of the program. The differences were large than the
- entire sharchive, so I saw no point in including context diffs.
- The Makefile should explain everything. Ideally, the machine
- dependencies would be separated into different files. - john. ]
-
- [ This program takes a filename, searches the kernel's open file
- table, and determines who has that file open. You can to kill the
- offending process(es). This is useful for backups, e.g. A port of
- this to BSD and other Unices would be nice. --r$ ]
-
- Here is the latest source to my version of the fuser(1M) command, written
- and running on the Unix PC. A man page and makefile are included.
-
- Verify that the macros in "Makefile" are correct for you (LBIN, for example
- should be where you want the program to be installed), and run make AS ROOT.
- It is important to do the make as root so that the resulting program will
- have the set-uid bit set, allowing it to read the kernel's memory.
-
-
- Some notes to anyone who wants to port this program to something other
- than the Unix PC:
-
- The Unix PC has "tunable kernel parameters", which mean that things that
- are constants on most older Unix systems are variable. This version of
- fuser reads the values of these variables from the kernel's memory. I have
- tried to make most of this transparent, for ease of porting to a more plain-
- vanilla Unix. For example, I have 'int' varialbes called 'NOFILE', 'NPROC',
- etc., which emulate the #defines present in 'standard' Unix. To make it
- run on such systems, it should be possible to remove these variables and
- the code that sets them, and the program will use the #defines from
- <sys/*.h>. The only other significant change is that because NOFILE is
- variable, the u_ofile field in the user structure is a pointer rather than
- an array. This means that you can delete the code that copies the u_ofile
- list since it is already right in the user structure.
-
-
- -=] Ford [=-
-
- "GNU does not eliminate (In Real Life: Michael Ditto)
- all the world's problems, kenobi!ford@crash.CTS.COM
- only some of them." -rms ...!crash!kenobi!ford
-
-
- Here's the shar file:
-