Perl Script Help

webbasica

Verified User
Joined
Feb 21, 2005
Messages
69
I'm an old customer of the mailling list software dadamail. Runs with perl, using Mysql if you configure right.

Since everything worked well in my last server, I figured I would have to only change the absolute path var.

But then, the first error. . 500 Internal Server Error.

First I try installing DBI and DBD-mysql the way hostpc described here
Seemed right.

Anyway, I keep getting the 500 error.
I changed the public_html ownership (read somewhere it helped) and I had to change it back to apache, cause the whole domain gave me a permission denied error.

Rights are 755, double checked everything, and I keep getting the error.

My suexec log is full of lines like this:

[2005-03-11 02:51:05]: uid: (501/bacanal) gid: (501/501) cmd: mail.cgi
[2005-03-11 02:51:07]: uid: (501/bacanal) gid: (501/501) cmd: mail.cgi
[2005-03-11 02:51:09]: uid: (501/bacanal) gid: (501/501) cmd: mail.cgi
[2005-03-11 02:51:13]: uid: (501/bacanal) gid: (501/501) cmd: mail.cgi
[2005-03-11 02:52:54]: uid: (501/bacanal) gid: (501/501) cmd: mail.cgi

(mail.cgi beeing the script)

I need advice ppl, please ..
 
script is in the cgi-bin dir.

I tried changing the whole cgi-bin to bacanal:bacanal
(bacanal = my user)

Then suexec said "file is writable by others". Chmoded to 755.

Now i'm back to
[2005-03-11 11:39:03]: uid: (501/bacanal) gid: (501/501) cmd: mail.cgi
 
Is the perl interpreter called in the right why? At the top if the script it says something in the line of #!/usr/bin/perl is this also reflecting your system path and settings for perl?
 
Try changing the ownership to 501 instead (ie chown 501 mail.cgi). The id before the slash is what suexec expects (in this case 501 for user and group ownership) and the id after the slash is the actual value (in this case bacanal for uid and 501 for group).

maldito said:
script is in the cgi-bin dir.

I tried changing the whole cgi-bin to bacanal:bacanal
(bacanal = my user)

Then suexec said "file is writable by others". Chmoded to 755.

Now i'm back to
[2005-03-11 11:39:03]: uid: (501/bacanal) gid: (501/501) cmd: mail.cgi
 
It allready was bacanal:bacanal

ls -n shows:

-rwxr-xr-x 1 501 501 286708 Mar 11 12:24 mail.cgi
 
I tried chown to apache:apache

log:

target uid/gid (501/501) mismatch with directory (501/501) or program (48/48)


so I went back to user:user


I'm desperate now ... anybody??
 
The directory and file itself should be username:username
Once you get the "file is writable by others" message again, try a different value than 755 in your chmod command, such as 750.
 
Solved it. Apparently, the developer leaves the directory in small caps, so inexpirienced users pay him to install it.
The big solution was naming the dir in all Big caps .. DADA
 
Back
Top