Bitcoin Forum

Bitcoin => Bitcoin Technical Support => Topic started by: phr0stbyt3 on July 03, 2012, 10:08:14 PM



Title: [3 BTC BOUNTY] SimpleCoin PHP nightmare
Post by: phr0stbyt3 on July 03, 2012, 10:08:14 PM
So I have a ubuntu 12.04 vps running poolserverj flawlessly with LAMP installed.
I followed these instructions for installation of simplecoin listed on github:
Code:
Installation:
1. Extract files into web root directory
2. Create simplecoin database in you mysql instance
3. Run simplecoin.sql in your simplecoin database (This will be used for pushpool & simplcoin)
4. Edit includes/requiredFunctions.php and set the bitcoin & database login info
5. Edit all files in the cronjob folder, set $includesDirectory to the correct server path.
6. setup cronjobs on a staggered schedule. I recommend 10-30 minutes for most. I run payout twice daily.

I cloned simplecoin to /var/www and restarted apache.
After 4 days I am still getting the same error:
Code:
apache2: Syntax error on line 238 of /etc/apache2/apache2.conf: Syntax error on line 20 of /var/www/about.php: Could not open configuration file /etc/apache2/("includes/header.php");: No such file or directory

It is trying to look in /etc/apache2/("includes/header.php"); ... wtf is going on?
Please help before I pull my hair out.
3BTC Bounty

About.php:
Code:
<?php
$pageTitle 
"- About";
include (
"includes/header.php");
?>


<b><u>About Bitcoins</u></b><br/>
<iframe width="560" height="349" src="http://www.youtube.com/embed/Um63OQz3bjo" frameborder="0" allowfullscreen></iframe><br/><br/>
<b><u>About This Site</u></b><br/>
This site is run by completely opensource software.<br/>
Hosted on a Xen Virtual Machine<br/>
Running Ubuntu<br/>
PHP pages served by Apache webserver<br/>
Official Bitcoin server<br/>
Pushpool Bitcoin pool<br/>
Simplecoin front-end<br/>

<?php include("includes/footer.php"); ?>


Title: Re: [3 BTC BOUNTY] SimpleCoin PHP nightmare
Post by: phr0stbyt3 on July 03, 2012, 10:20:15 PM
Ok so I noticed in apache2.conf there was

Include sites-enabled
AND
Include /var/www

I commented out /var/www and restarted apache and the error is gone.

HOWEVER!
The page still wont display at all:
http://phr0stbyt3.com/index.php


Title: Re: [3 BTC BOUNTY] SimpleCoin PHP nightmare
Post by: Bitsky on July 03, 2012, 10:32:31 PM
Ok so I noticed in apache2.conf there was

Include sites-enabled
AND
Include /var/www

I commented out /var/www and restarted apache and the error is gone.

HOWEVER!
The page still wont display at all:
http://phr0stbyt3.com/index.php
Maybe you should post the errors from the error.log instead of letting everybody look at a blank page to guess what the error might be


Title: Re: [3 BTC BOUNTY] SimpleCoin PHP nightmare
Post by: yogi on July 03, 2012, 10:35:39 PM
undo changes to conf
use full path in the include


Title: Re: [3 BTC BOUNTY] SimpleCoin PHP nightmare
Post by: unfinishe on July 04, 2012, 12:30:56 AM
First, undo the change to apache.conf.

Next, take out the space between "include" and the left parenthesis.


Title: Re: [3 BTC BOUNTY] SimpleCoin PHP nightmare
Post by: phr0stbyt3 on July 04, 2012, 05:23:52 AM
Ok so I noticed in apache2.conf there was

Include sites-enabled
AND
Include /var/www

I commented out /var/www and restarted apache and the error is gone.

HOWEVER!
The page still wont display at all:
http://phr0stbyt3.com/index.php
Maybe you should post the errors from the error.log instead of letting everybody look at a blank page to guess what the error might be

Error in error.log is:
[error] [client xx.xx.xxx.xxx] [PHP Fatal error: Class 'Memcached' not found in /var/www/includes/requiredFunctions.php on line 57.

edit: until 30 minutes ago I didn't know where to look for errors.


Title: Re: [3 BTC BOUNTY] SimpleCoin PHP nightmare
Post by: unfinishe on July 04, 2012, 05:35:41 AM
Ok, sounds like we fixed the first error.

Now, it seems that simplecoin needs the memcache module, which is not installed on default. The best guide I could find to do that is here:

http://stevelove.org/2009/09/30/how-to-install-php-memcached-on-an-ubuntu-server/

Hopefully that works.


Title: Re: [3 BTC BOUNTY] SimpleCoin PHP nightmare
Post by: broken on July 04, 2012, 10:21:05 AM
There is a package for memcached:

Code:
sudo apt-get install php5-memcached


Title: Re: [3 BTC BOUNTY] SimpleCoin PHP nightmare
Post by: MarKusRomanus on April 24, 2013, 08:35:02 PM
install the php5_memcached and restart apache


Title: Re: [3 BTC BOUNTY] SimpleCoin PHP nightmare
Post by: Terk on April 24, 2013, 11:13:26 PM
As it was said, you're missing memcached. You might miss either only PHP module, or both memcached server and PHP module. To install both on Ubuntu:

Code:
sudo apt-get install memcached 
sudo apt-get install php5-memcached
sudo /etc/init.d/apache2 restart