perl -e ' $apache = qx(ps -ef | grep httpd); @fields=split /\s+/, $apache; exec ("chown $fields[0] /path/to/flat/file/directory");'