From owner-freebsd-questions Sat Feb 1 19:06:23 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id TAA26532 for questions-outgoing; Sat, 1 Feb 1997 19:06:23 -0800 (PST) Received: from mail.crl.com (mail.crl.com [165.113.1.22]) by freefall.freebsd.org (8.8.5/8.8.5) with SMTP id TAA26527 for ; Sat, 1 Feb 1997 19:06:20 -0800 (PST) Received: from nanguo.chalmers.com.au by mail.crl.com with SMTP id AA25380 (5.65c/IDA-1.5 for ); Sat, 1 Feb 1997 19:05:40 -0800 Received: (from robert@localhost) by nanguo.chalmers.com.au (8.7.6/8.7.3) id MAA00628 for freebsd-questions@freebsd.org; Sun, 2 Feb 1997 12:46:59 +1000 (EST) From: Robert Chalmers Message-Id: <199702020246.MAA00628@nanguo.chalmers.com.au> Subject: apache and cgi's To: freebsd-questions@freebsd.org (bsd) Date: Sun, 2 Feb 1997 12:46:58 +1000 (EST) X-Mailer: ELM [version 2.4ME+ PL22 (25)] Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-questions@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Hi, I'm having trouble getting a shell script (sh) file to run under FreeBSD's Apache. It worked fine under NSCA though??? Is it a permissions, or what problem? This is the output to the error_log of the program in cgi-bin, that calls a bunch of other stuff? Perhaps it can no longer do that? If I run it form the command line, as user www, it works fine and does what it should, but called from the html file, it now does this? any clues anyone. Robert ------------------the program #! /bin/sh -x # # %W% (Berkeley) %E% # cd /usr/games/lib/ching.d PATH=.:$PATH case $1 in [6-9]*) H=$1;shift;; esac if test $H then phx $H | nroff $* macros - | more -s else cno > "/tmp/#$$" echo " " phx `cat "/tmp/#$$"` | nroff $* macros - | more -s rm "/tmp/#$$" fi ---------------- the output on apache. + PATH=.:/sbin:/bin:/usr/sbin:/usr/bin + test + cno + echo [Sun Feb 2 12:39:00 1997] access to /usr/local/etc/httpd/cgi-bin/ching failed for carbon.chalmers.com.au, reason: malformed header from script. Bad header= + cat /tmp/#595 + nroff macros - + more -s + phx 777697 + rm /tmp/#595 -- chalmers.com.au: P.O. Box 2003. Mackay. 4740 +61-0412-079025 robert@chalmers.com.au for Whirled Peas http://www.chalmers.com.au Location: The Great Australian Content Site. 21'7" S, 149'14" E.