FREE THOUGHT · FREE SOFTWARE · FREE WORLD

A souped-up version of the Apache printenv script for hard-core server environment debuggery.

#!/bin/sh
echo -e "Content-type: text/plainnn"
...
  __T "CURRENT PROCESS CMDLINE"
  {
   for p in `echo /proc/[0-9]*/cmdline`;
   do
    pid=${p:6:$((${#p}-13))}
    [[ $pid == $PPID || $pid == $$ ]] && continue;
    __M "[ /proc/$pid ]";
    sed 's/x00/ /g;G' $p 2>/dev/null
   done
  }
 fi

Hosting