serendipity_config_local.inc.php won't show up

Having trouble installing serendipity?
Post Reply
Lariel
Regular
Posts: 22
Joined: Sun May 06, 2007 12:55 am

serendipity_config_local.inc.php won't show up

Post by Lariel »

Hey guys,

I'm really puzzled with this, this time. I have installed S9Y before and it worked fine. Now I tried to install it on another server. Here's what's going on:
- I unpacked and uploaded all the files.
- I set all the right cmods.
- Then I made a expert installation, with no "url rewrite". It's installing and filling the database. (I checked, it's really filled.) But then it comes up with that it can't write the .htaccess. (Althought the blogs base directory is chmod 777)
- I copied that stuff in a .htaccess myself. But then I get an 500 error. So I deleted the .htaccess. It doesn't seem to be that important anyway.
- But now when I tried to enter my blog, I'm back at the installation page like I never installed. I checked the directory via ftp and the serendipity_config_local.inc.php is missing. It's seems it was never created. Alright, it won't write ... but why?
- So I created one myself with the right access data. But it doesn't work. It's still showing the installation page.

Could it have something to do with the database server which is not localhost this time?
S9Y: 1.2 lite
PHP: 4.4.2
MySQL: 4.1.18

Please help me! I don't even want to try WordPress again! :wink:
Thanks in advance
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: serendipity_config_local.inc.php won't show up

Post by garvinhicking »

Hi!

If both .htaccess and serendipity_config_local.inc.php are not written, then Serendipity/PHP has no write access to the core directory. You say you chmodded it 777, but are you really sure that was successful? I doubt it, because something is blocking access.
- So I created one myself with the right access data. But it doesn't work. It's still showing the installation page.
Please show what you entered there. S9y will only show the install screen if serendipity_config_local.inc.php contains no valid information or if the file is not readable. This again leads me to think that something is really messed up with your permissions. :-)

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Lariel
Regular
Posts: 22
Joined: Sun May 06, 2007 12:55 am

Post by Lariel »

I chmodded 777 and it was definitely successful. It seems to be a strange config where upper directories also have to be chmodded accordingly (PHP wouldn't run at all until chmodded my base directory 755). I tried to chmod everything I could 777 without any luck.

The information in serendipity_config_local.inc.php is all valid. I changed the server address and got an "Can't connect to database" error, which is not there with the right address in place. So I believe it connects fine.

Could it be because safe_mode is ON and register_globals is also ON? I'm on a university server and I believe the admin won't change these settings for me. Is there some workaround? Other cms (like MediaWiki and phpBB3) are functioning fine.

I already asked the admin to look into php's error log, he replied that he fixed it. Now the startpage shows up but the admin page is blank. :roll:
I'll ask him, what's the cause behind all this and what he has changed.
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Hi!

Yes, if you can ask him, that would be good. I'm sure on the admin panel, there's also a fatal PHP error showing up that prevents you from successfully using it.

Must be something with permissions or missing files, I'm sure.

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Lariel
Regular
Posts: 22
Joined: Sun May 06, 2007 12:55 am

Post by Lariel »

Hi again,
the admin said, he changed something so that it'll work but he couldn't promise that it wouldn't break again. :? The frontpage is accessable now but the admin login is not. No explanation what is wrong in the first place (they are all very busy ...) It has to be some permission problem. I also installed other systems. The new phpBB3 works fine, so does WordPress, which I'm using now. MediaWiki couldn't copy its settings itself but it also works now after I've copied it manually. So I believe S9Y needs some improvements here. Why would WordPress work and S9Y not?? I'm sorry that I can't give you additional infos. :oops: I can only tell you, I've tried to install it on a student's homepage account of uni-giessen.de They are using Apache 1.3.34 on a SunOS 5.9 with PHP 4.4.2. I could give you the phpinfos if that would help.
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Hi!

WP needs write privileges on different files. They have a compltely different, less automatted structure which doesn't require admin access.

I could help you, but without you giving me error logs or messages, I can't help. It's like when you say "I bought a Ford Cougar and it drives, but my Ferrari Testarossa doesn't drive! How can that be, they are both cars!!! Stupid car!".

As you can see, there are many causes, why a car can't drive. Now it's the s9y that has problems with your garage, but it very well might be that you will have different problems with the other car.

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
05282
Regular
Posts: 7
Joined: Tue Dec 05, 2006 10:46 am

Post by 05282 »

Hi,

I quickly wrote a really ugly script which trys to create a file and if it fails the script outputs some debug stuff, free space, owner of current dir etc.

Be sure the file test_994279137.txt doesn't exist before you run the script!

Just put it in the root dir of your s9y install and post the messages it spits out when you point your browser to it.

Code: Select all

<?php

function HumanSize($Bytes)
{
  $Type=array("", "kilo", "mega", "giga", "tera", "peta", "exa", "zetta", "yotta");
  $Index=0;
  while($Bytes>=1024)
  {
    $Bytes/=1024;
    $Index++;
  }
  return("".$Bytes." ".$Type[$Index]."bytes");
}

if (is_writable(".")){
$datei = fopen("test_994279137.txt","w+");
fwrite($datei, "Files can be created and can be filled with content.<br>\r\n");
fclose($datei);

  $abfrage = fopen("test_994279137.txt","r");
  $text = fgets($abfrage, 60);
  if(empty($text))
    {
    echo "Files cannot be filled with content<br>\r\n";
    }
  fclose($abfrage);
  unlink("test_994279137.txt");
  echo $text;
}
else{
echo "Current Directory is not writable.<br>\r\n";
$df = disk_free_space(".");
$df = HumanSize($df);
echo "Free Space in current directory: $df<br>\r\n";
if(chmod (".", 0777)){
	echo "Chmodded current directory to 777, trying again...<br>\r\n";
	if (is_writable(".")){
		$datei = fopen("test_994279137.txt","w+");
		fwrite($datei, "Files can be created and can be filled with content.<br>\r\n");
		fclose($datei);

		$abfrage = fopen("test_994279137.txt","r");
		$text = fgets($abfrage, 60);
	if(empty($text))
		{
		echo "Files cannot be filled with content<br>\r\n";
		}
	fclose($abfrage);
	unlink("test_994279137.txt");
	echo $text;
	}
	else{
	echo "Could chmod to 777, but still can't create any files! ...this should not happen.<br>\r\n";
	}
}
else{
	echo "No chmodding possible!<br>\r\n";
	$own = fileowner (".");
	$own = posix_getpwuid ($own);
	echo "Some info about the user to whom this folder belongs:<br><pre><br>\r\n";
	print_r($own);
	echo "</pre><br>\r\n";
}
}

//phpinfo();

?>
If you want to expose some additional info you can remove the two slashes from "//phpinfo();" in the script. But be careful, this can contain sensitive information and you should modify it before posting!!
Sorry for my bad english! :)
Oh, und wer Rechtschreibfehler findet darf sie gern korrigieren. ;)
Lariel
Regular
Posts: 22
Joined: Sun May 06, 2007 12:55 am

Post by Lariel »

Here it is ...

Current Directory is not writable.
Free Space in current directory: 34.558794975281 gigabytes
No chmodding possible!
Some info about the user to whom this folder belongs:

Array
(
[name] => g6[...]
[passwd] => x
[uid] => 39341
[gid] => 10071
[gecos] => fspsy
[dir] => /home/fb06a/g6[...]
[shell] => /usr/bin/ksh
)

I edited my username with [...]. If you need the phpinfo output, tell me.
Now, why isn't it functioning? Not writable, no chmodding, what can I do about it?
05282
Regular
Posts: 7
Joined: Tue Dec 05, 2006 10:46 am

Post by 05282 »

It looks like you simply have not the necessary rights to chmod your root directory.

Maybe you could install s9y into a subdirectory, chmod to 777 and then set this dir as your document root?
Sorry for my bad english! :)
Oh, und wer Rechtschreibfehler findet darf sie gern korrigieren. ;)
Lariel
Regular
Posts: 22
Joined: Sun May 06, 2007 12:55 am

Post by Lariel »

Well, I put the script inside a subdirectory in which I had also tried to install S9Y and the subdirectory is chmod 777.
Post Reply