home *** CD-ROM | disk | FTP | other *** search
/ ftp.orgchm.bas.bg / 2014.06.ftp.orgchm.bas.bg.tar / ftp.orgchm.bas.bg / bin / killftpclients.sh < prev    next >
Linux/UNIX/POSIX Shell Script  |  2002-05-06  |  237b  |  11 lines

  1. #!/bin/sh
  2. date 
  3. ps -ww -C wu.ftpd -o pid,start_time -o " %a" --noheading | while read pid date name 
  4.  do 
  5.   if [ `expr index $date \:` = 0 ] 
  6.     then  
  7.       echo Killing PID=$pid Date=$date Name=$name 
  8.       kill $pid 
  9.      fi  
  10.  done
  11.