logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Other Software View previous topic :: View next topic
Reply to topic   Topic: Win2008 + Apache 2.2 x64 + PHP 5.3 TS = NoGo [Solved]
Author
bjaergager



Joined: 20 Dec 2011
Posts: 5
Location: Denmark

PostPosted: Tue 20 Dec '11 16:32    Post subject: Win2008 + Apache 2.2 x64 + PHP 5.3 TS = NoGo [Solved] Reply with quote

OK the subject kind of says it all...

On a Windows Server 2008 R2 SP1, I have downloaded httpd-2.2.21-win64.zip and installed it - it works fine Apache is answering my requests.

Then I downloaded PHP 5.3.8 VC9 x86 Thread Safe (2011-Aug-23 12:01:10) from http://windows.php.net/download/

Also I did install Microsoft 2008 C++ Runtime (x64)

When ever I change httpd.conf to load PHP, Apache refuse to start. If I uncomment the code, everything is working just fine.

I added the following to httpd.conf

#LoadModule php5_module "c:/php/php5apache2_2.dll"
#AddHandler application/x-httpd-php .php

# configure the path to php.ini
#PHPIniDir "C:/php"

The path to PHP is correct.

Any help will be greatly appreciated.

Best regards and a merry christmas,
Mark
Back to top
bjaergager



Joined: 20 Dec 2011
Posts: 5
Location: Denmark

PostPosted: Tue 20 Dec '11 17:22    Post subject: Re: Win 2008 R2 SP1 + Apache 2.2.1 x64 + PHP 5.3.8 VC9 TS = Reply with quote

bjaergager wrote:

When ever I change httpd.conf to load PHP, Apache refuse to start. If I uncomment the code, everything is working just fine.


Naturally I meant to write if I uncomment the code, Apache fails to start - when commented out, Apache runs just fine (obviously without PHP)

Sorry for the confusion Smile
Back to top
Steffen
Moderator


Joined: 15 Oct 2005
Posts: 3092
Location: Hilversum, NL, EU

PostPosted: Tue 20 Dec '11 20:11    Post subject: Reply with quote

That does not work, mixing 32 and 64, php.net is not supporting 64 bit yet.

A way to go is using fastcgi (mod_fcgid) with the Non Thread Safe (NTS) version at php.net. Has also advantages over the php handler, lot of posts here about it.

Apache Lounge is also running Windows Server 2008 R2 SP1 with mod_fcgid, nowadays Apache 2.4.

Steffen and also Merry Chrismas

ps.
You made a good post to address your issue, example for others Smile
Back to top
bjaergager



Joined: 20 Dec 2011
Posts: 5
Location: Denmark

PostPosted: Mon 26 Dec '11 22:31    Post subject: Reply with quote

Hello Steffen,

Thank you for your reply, sorry for note getting back sooner Smile

So I need to use a x86 version of Apache (2.4) and VC9 NTS version of PHP 5.3.8 to get things working ?? Or can I, using fastcgi, use x64 Apache and x86 PHP ?

Regards and a Happy New Year,
Mark


Steffen wrote:
That does not work, mixing 32 and 64, php.net is not supporting 64 bit yet.

A way to go is using fastcgi (mod_fcgid) with the Non Thread Safe (NTS) version at php.net. Has also advantages over the php handler, lot of posts here about it.

Apache Lounge is also running Windows Server 2008 R2 SP1 with mod_fcgid, nowadays Apache 2.4.

Steffen and also Merry Chrismas

ps.
You made a good post to address your issue, example for others Smile
Mr. Green Mr. Green Mr. Green Cool
Back to top
Steffen
Moderator


Joined: 15 Oct 2005
Posts: 3092
Location: Hilversum, NL, EU

PostPosted: Mon 26 Dec '11 22:45    Post subject: Reply with quote

Recap, we have 5 flavours:

1. Apache64 with TS PHP64 and php5_module (but there is no official PHP64)
2. Apache32 with TS PHP32 and php5_module

3. Apache64 with NTS PHP64 and FCGID64 (again there is no official PHP64)
4. Apache64 with NTS PHP32 and FCGID64
5. Apache32 with NTS PHP32 and FCGID32

So 2, 4 or 5 is the way to go.

Steffen


Last edited by Steffen on Mon 26 Dec '11 22:59; edited 1 time in total
Back to top
bjaergager



Joined: 20 Dec 2011
Posts: 5
Location: Denmark

PostPosted: Mon 26 Dec '11 22:53    Post subject: Reply with quote

I think I'll go with option 4 then Smile

Is there a httpd.conf for fastcgi ? I googled - also the forums - but I didn't find any examples.

Could you point me in the right direction ?

Thanks again for your time Smile

Regards,
Mark

Steffen wrote:
Recap, we have 5 flavours:

1. Apache64 with TS PHP64 and php5_module (but there is no official PHP64)
2. Apache32 with TS PHP32 and php5_module

3. Apache64 with NTS PHP64 and FCGID64 (again there is no official PHP64)
4. Apache64 with NTS PHP32 and FCGID64
5. Apache32 with NTS PHP32 and FCGID32

So 2, 4 or 5 is the way to go.

Steffen
Back to top
Steffen
Moderator


Joined: 15 Oct 2005
Posts: 3092
Location: Hilversum, NL, EU

PostPosted: Mon 26 Dec '11 22:57    Post subject: Reply with quote

Yep, we are running that too. Download the Win64 version of mod_fcgid.

In the .zip is an start example and several config in the forum, lot of configs here.

Steffen
Back to top
bjaergager



Joined: 20 Dec 2011
Posts: 5
Location: Denmark

PostPosted: Mon 26 Dec '11 22:58    Post subject: Reply with quote

Thanks for all your help Smile

Steffen wrote:
Yep, we are running that too. Download the Win64 version of mod_fcgid.

In the .zip is an start example and several config in the forum, lot of configs here.

Steffen
Back to top
TimoP



Joined: 09 Jan 2012
Posts: 3
Location: Tarmstedt, Germany

PostPosted: Sun 15 Jan '12 15:41    Post subject: Reply with quote

thanks a lot, that helped me out too.

i use no. 4 as my favorite flavor.
Back to top
LorenzoP



Joined: 18 Mar 2012
Posts: 2
Location: Italy

PostPosted: Sun 18 Mar '12 21:46    Post subject: Reply with quote

I'trying choice 4 with Apache 2.4.1 64 bit and mod_fcgid-2.3.7- win64.

Apache starts with no error, but when I open:
http://localhost/info.php I got 403 error:

Forbidden

You don't have permission to access /info.php on this server.

Please help ...
Back to top
Steffen
Moderator


Joined: 15 Oct 2005
Posts: 3092
Location: Hilversum, NL, EU

PostPosted: Sun 18 Mar '12 22:21    Post subject: Reply with quote

I assume http://localhost/ is working.

What is your Directory directive ?

Try:

<Directory />
Options FollowSymLinks
AllowOverride none
Require all granted
</Directory>

Steffen
Back to top
LorenzoP



Joined: 18 Mar 2012
Posts: 2
Location: Italy

PostPosted: Sun 18 Mar '12 23:24    Post subject: Reply with quote

Solved ...!!

I added ExecCGI option:

DocumentRoot "d:/WWW/wwwroot"

<Directory "d:/WWW/wwwroot">
Options Indexes FollowSymLinks ExecCGI
AllowOverride None
Require all granted
</Directory>

Unfortunately mod_fcgid only works if the directory does not contain spaces, so I had to install PHP in "c:\PHP" instead of "C:\Program Files\PHP"

Thanks

Lorenzo
Back to top


Reply to topic   Topic: Win2008 + Apache 2.2 x64 + PHP 5.3 TS = NoGo [Solved] View previous topic :: View next topic
Post new topic   Forum Index -> Other Software