A CGI test program with a misterious error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello listers,

This is my first message. I am trying to walk the first steps in web development, so I am pleased to enter in Apache's world.

I have two test CGI programs writen in Pascal. The first one writes some input using "writeln". The second one uses specific CGI classes. The first runs, the second doesn't.

The natural conclusion would be: "Luciano, you are in the wrong list. The problem is in your Pascal code, not in Apache". This truth would seem logical if the error was produced in other machines. Yes, the first example runs in other machines; the second doesn't run only in mine.

Permissions? the problem can be lack of permissions in CGI folder. No, for each file in /usr/lib/cgi-bin, I did:

sudo chmod +x file

Apache is configured because the first example runs. All the files in cgi-bin has enough permission to be executed. There's no error in Pascal code because both examples run in other machine.

In browser, I have always the error 500: Internal exception server. In Apache's log, I have:

[Tue Oct 18 15:50:36 2011] [error] (8)Exec format error: exec of '/usr/lib/cgi-bin/test3' failed [Tue Oct 18 15:50:36 2011] [error] [client 127.0.0.1] Premature end of script headers: test3

Does someone have any idea what it can be done or witch is the nature of the problem?

Luciano

Attachment: cgi1.tar.gz
Description: GNU Zip compressed data

Attachment: cgi2.tar.gz
Description: GNU Zip compressed data

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx

[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux