Page Index Toggle Pages: 1
Topic Tools
Normal Topic Paths problem (Read 4,390 times)
Captain John
Ex Member


Re: Paths problem
Reply #8 - Nov 4th, 2010 at 7:19pm
Post Tools
Great ... Glad you found it ... and the "little" help I provided your Welcome.
  
Back to top
 
IP Logged
 
Athalis
YaBB Newcomer
*
Offline



Posts: 5

None
Re: Paths problem
Reply #7 - Nov 4th, 2010 at 6:47pm
Post Tools
Quote:
mmmmm an html page that is not displayed, is typed to the browser ... even I have never seen that.

Okay ! Took me couple of days but I found the reason (even if I don't understand what's happening). The error occurs with this snippet in my apache conf file :
Code
Select All
       <Directory "/var/www/forum">
               AllowOverride None
               Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
               AddHandler perl-script .cgi .pl
               Order allow,deny
               Allow from all
               PerlHandler ModPerl::Registry
       </Directory>
 

Which basically tells apache to use mod_perl to interpret .pl and .cgi files.

If I remove the "PerlHandler ModPerl::Registry" line, it works. No idea why handling YaBB scripts with mod_perl screws everything up; but it does... I'll look into that.

Quote:
Another question (just for interest) why mod_perl ?  The installation of Perl 5.10.0 should handle the needed interpreter.

mod_perl speeds up the interpretation of perl scripts. Roughly, If you don't use mod_perl then, for each incomming http request apache starts the perl interpreter which is kinda heavy operation. With mod_perl it doesn't.

I did some benchmarking on my crappy computer (using "apache benchmark") without perl_mod my computer can handle 24 request / second. With mod_perl enabled it's 150. 6 time faster... Not bad huh ?
And as I am working on a huge project to take over the world and make billions of $... I need mod_perl and YaBB  Wink

... But before I gotta fixe this path problem  Grin


Edit :

Okay problem solved; I had a bad directive in my httpd.conf file (       ScriptAlias /cgi-bin/ /var/www/ ). I'm not a bad perl scripter, but I really suck when dealing with system administration problems.

Thank you for your help and time !
« Last Edit: Nov 4th, 2010 at 6:59pm by Athalis »  
Back to top
 
IP Logged
 
Captain John
Ex Member


Re: Paths problem
Reply #6 - Nov 4th, 2010 at 2:53pm
Post Tools
mmmmm an html page that is not displayed, is typed to the browser ... even I have never seen that.  You are using FF as your browser, correct?  Your OS (windows/Mac) ?
 Another question (just for interest) why mod_perl ?  The installation of Perl 5.10.0 should handle the needed interpreter.

Have you referred to the Codex ?

Setting Up a Home based Server
http://www.yabbforum.com/codex/YaBB.pl?num=1226450192

Apache on XP
http://www.yabbforum.com/codex/YaBB.pl?num=1218602491

Setup Perl on Apache
http://www.yabbforum.com/codex/YaBB.pl?num=1200163266

Understanding Paths
http://www.yabbforum.com/codex/YaBB.pl?num=1190678313
« Last Edit: Nov 4th, 2010 at 3:48pm by »  
Back to top
 
IP Logged
 
Athalis
YaBB Newcomer
*
Offline



Posts: 5

None
Re: Paths problem
Reply #5 - Nov 3rd, 2010 at 6:12am
Post Tools
It is NOT the .pl script that is downloaded, it's the result of the script. If you look at the downloadedd file, it is an HTTP header + regular HTML page; Can't figure out why it's not displaying it
  
Back to top
 
IP Logged
 
Captain John
Ex Member


Re: Paths problem
Reply #4 - Nov 2nd, 2010 at 8:46pm
Post Tools
Athalis wrote on Nov 1st, 2010 at 4:20pm:
BUT my Firefox browser asked me to download a file instead of displaying it.

  The above error (displaying the file, instead of running the script) happens when the operating system (Pearl) is not found.
  Setup.pl script must be run to fill in Paths.pl and several *.txt files within the ./Variables folder before YaBB.pl can be run.
  
Back to top
 
IP Logged
 
Athalis
YaBB Newcomer
*
Offline



Posts: 5

None
Re: Paths problem
Reply #3 - Nov 2nd, 2010 at 7:17pm
Post Tools
Hi Jon,

My Path.pl file is empty :
Code
Select All
# Blank Paths.pl file

1;
 


I've seen nowhere that I am suppose to fill it up. It is my understanding that the Setup.pl script will fill it up by itself depending of my answers to the questions it will ask me. Did I miss something ?

The shebang line is fine /usr/bin/perl is the right path on debian.

Thank you for your help Smiley
  
Back to top
 
IP Logged
 
JonB
YaBB Administrator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Offline



Posts: 3,789
Location: Land of the Blazing Sun!

YaBB 2.6.0
Re: Paths problem
Reply #2 - Nov 2nd, 2010 at 6:14am
Post Tools
the thing we are missing here is the Paths.pl file.

If you would rather not expose the true urls, paste it into a PM and send it to me.

otherwise you can make it a .txt file and attach it or paste it in your reply and use Code tags.

The hardcoded route is likely a recipe for disaster.  Wink

One not necessarily completely relevant question
did you fix all the shebang lines?

Smiley
  

I find your lack of faith disturbing.
Back to top
IP Logged
 
Athalis
YaBB Newcomer
*
Offline



Posts: 5

None
Re: Paths problem
Reply #1 - Nov 1st, 2010 at 4:20pm
Post Tools
I have a debian (lenny) with apache2 (2.2.9) mod_perl (2.0.4) and Perl (5.10.0)

I believe everything is properly installed as I'm developing a web site in perl and it runs as expected.


I put all yabb perl scripts in /var/www/forum/yabb2/
and HTML files in /var/www/forum/yabbfiles/

I chmod -R 777 /var/www/forum

When I visit : htpp://localhost/forum/yabb2/Setup.pl I receive a HTPP error 500. Apache log says :

Code
Select All
[error] Can't locate ./Sources/Subs.pl in @INC (@INC contains:
/home/mgilbert/project/lib/perl
/var/www/forum/yabb2/
/etc/perl
/usr/local/lib/perl/5.10.0
/usr/local/share/perl/5.10.0
/usr/lib/perl5
/usr/share/perl5
/usr/lib/perl/5.10
/usr/share/perl/5.10
/usr/local/lib/site_perl
.
/etc/apache2
./Modules
) at /var/www/forum/yabb2/Setup.pl line 63.\n 



Which is totally weird as :
Code
Select All
ls -l /var/www/forum/yabb2/Sources/Subs.pl
-rwxrwxrwx 1 mgilbert mgilbert 81851 jui 10 13:32 /var/www/forum/yabb2/Sources/Subs.pl
 



I tried hardcoding the absolute path in Setup.pl, and it started working... BUT my Firefox browser asked me to download a file instead of displaying it. The file is the result of the Setup.pl script (the script is run, the perl interpreter is found) and looks like this :

Code
Select All
Status: 200 OK
Cache-Control: no-cache, must-revalidate
Pragma: no-cache
Content-Type: text/html


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>YaBB 2 Setup</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
</head>
<body>

<!-- Main Content -->
<div style="height: 40px;">&nbsp;</div>
<center>
	<br /><br /><br /><form action="Setup.pl?action=adminlogin2" method="post" name="loginform"><center>
	<table width="20%" border="0" bgcolor= "#000000" cellspacing="1" cellpadding="0">
	<tr><td>
	<table width="100%" border="0" bgcolor= "#FEFEFE" cellspacing="1" cellpadding="3">
	<tr>
		<td width="100%" align="center">
		<label for="password"><span style="font-family: Arial; font-size: 13px; color: #000000;">
		Enter the password for user <b>admin</b><br />to gain access to the Setup Utility
		</span></label>
		</td>
	</tr>
	<tr>
		<td width="100%" align="center">
		<span style="font-family: Arial; font-size: 13px; color: #000000;">
		<input type="password" name="password" id="password" size="30" />
		<input type="hidden" name="username" value="admin" />
		<input type="hidden" name="cookielength" value="1500" />
		</span>
		</td>
	</tr>
	<tr>
		<td width="100%" align="center">
		<span style="font-family: Arial; font-size: 13px; color: #000000;">
		<input type="submit" value="Submit" />
		</span>
		</td>
	</tr>
	</table>
	</td></tr>
	</table>
	</center></form>
	<script language="JavaScript1.2" type="text/javascript">
		<!--
			document.loginform.password.focus();
		//-->
	</script>
	</center>
</body>
</html>
 



And now, I just have no idea what to do. If anyone could help me understand what's happening here, it would be really really appreciated !

PS: Sorry for any mistakes in this post, I'm not english :p
« Last Edit: Nov 3rd, 2010 at 6:20am by Athalis »  
Back to top
 
IP Logged
 
Athalis
YaBB Newcomer
*
Offline



Posts: 5

None
Paths problem
Nov 1st, 2010 at 4:20pm
Post Tools
Hi everybody Smiley

I'm trying to install YaBB 2.5, on my own machine and run into paths problems.

I have to split this message in two as I'm not allowed to post links in my first message.
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Topic Tools
 
  « Board Index ‹ Board  ^Top