Become superuser.
Invoke the fuser(1M) command.
The fuser command lists the processes that are currently accessing the CD that you specify.
# fuser -u [-k] pcmem0 |
-u |
Displays the user of the PCMCIA memory card. |
|
-k |
Kills the process accessing the PCMCIA memory card. |
In the following example, the processes 6400c and 6399c are accessing the /pcmem/pcmem0 directory, and the process owners are root and smith, respectively.
# fuser -u /pcmem/pcmem0 /pcmem/pcmem0: 6400c(root) 6399c(smith) |
You can kill the processes individually (as superuser), or you can use the fuser command with the -k option, which kills all the processes accessing that file system:
# fuser -u -k /pcmem/pcmem0 /pcmem/pcmem0: 6400c(root)Killed 6399c(smith)Killed |
The fuser command may not always identify all the killed processes. To be sure, run it again with the -u option.