Is it possible to use use Nginx 32bit with php 64bit? - php

Am new to PHP and Nginx web server. I want to setup a 64bit Nginx web server with PHP 5.6 64bit on Windows 64bit system, but only 32bit Nginx build is available for windows officially. Is it possible to use PHP 64bit with Nginx 32bit web server?
If it is possible to use it, is there any performance impact?
There are 64bit Nginx builds available from unofficial sources, but they advice not to use this for production, so I need to stick with official 32bit Nginx build for windows.
Thanks in advance.

PHP with nginx would normally be run as a fastcgi application (https://www.nginx.com/resources/wiki/start/topics/examples/phpfcgi/ ).
This would communicate over a TCP socket on windows - and therefore it doesn't matter whether it's 64bit or 32bit php at the far end.
In terms of PHP, if performance is a key driver, and your new - you mind want to consider looking at php 7 as that has a number of performance improvements over the php5 series. The development of php 7 has some benchmarks on a google docs spreadsheet at the bottom of their page https://wiki.php.net/phpng which indicates the differences

Related

which web server would you suggest me to use IIS 8.5 Apache server Nginx for PHP

I have a production server running on windows 2012 r2.
Which web server would you suggest me to use
IIS 8.5,
Apache server, or
Nginx ?
(install separately)
I'm PHP developer (so, my code is written in PHP)
I was used to Apache 2 and didn't use anything else. But sinds I'm using Laravel, which supports HHVM, I use Nginx in combination with HHVM. The sites running on that server have more than 40% faster response time.
If you don't use Laravel, I don't know if your project fully supports HHVM, if so i really would consider using it!
I would suggest to go with Nginx or Apache

Can i use Mongo NoSQL Database with PHP?

I want to use NOSQL database for my mobile application back end web services. I have gone through the MongoDB document.But i am not sure will it be suitable with PHP?
And I have below queries related to the same.
Can i use Mysql and NoSQL(MongoDB) databases on the same server?
Can i use MongoDB with PHP and apache? If yes then which version of MongoDB should i use for PHP?
Is it possible to install NoSQL database if LAMP is already installed on the same machine?
Regards,
Pratibha
In following lines few short answer:
Yes. You should only install PHP Mongodb driver for your PHP version. The MongoDB PHP driver should work on nearly any system: Windows, Mac OS X, Unix, and Linux; little- and big-endian machines; 32- and 64-bit machines; PHP 5.2, 5.3, 5.4 and 5.5.
Yes. Latest version should be the best choice.
Yes. As far as I know Mongodb server relies on different ports and in standard condition there is no conflict.
Your server should have only enough resources (basically enough memory) to run everything.

Convert 64bit PHP to 32bit on WAMP 64bit

I now have a scenario where I need PHP to be 32bit (I need to connect to a 32bit COM object, no 64bit version is available for this particular one (Sage SDO)).
I want to keep MySQL as it is, 64bit, but how would I go about changing just PHP to 32bit without wrecking everything?
I have tried to simply drop in 32bit PHP in place of the 64bit, copying the php.ini file so the config is the same, but this doesn't work and the server won't start.
I am using WAMP 2.4 with PHP 5.4.12.
Am I better off ditching WAMP completely and doing my own custom build so that everything is the latest version?
I am afraid you would have to change Apache to 32bit as well as PHP. This is because Apache basically runs PHP as a subroutine in the WAMP setup so they both have to be compiled using the same compiler version and bit count.
MySQL you could keep as a 64bit version as PHP talks to MySQL through a TCP port and not directly.
However there is no great advantage to keeping MYSQL as 64bit as the 32 and 64 bit databases are interchangable as far as I know.
I would suggest you save your databases and site code and then uninstall the 64bit WAMP and the install the 32bit WAMP.
It is still the case that there are more extension available in the 32bit arena than there are in the 64bit, so this will also make your environement more flexible for the next time you need a less mainstream extension in your websites.

Setting up SVN Server to work on Apache 2.2.22 (64 bits - already installed) and Windows 7 (64 bits)

I'm trying to setup a SVN Server 1.7.5 on my development workstation which has the following tools already working:
Apache Server 2.2.22 (64 bits) - VC10 from Apache Lounge
PHP 5.4.3 VC9-TS (64 bits) from Anindya's Blog
XDebug 2.2.0 VC9 for PHP 5.4.x TS (64 bits) from Xdebug.org
MySQL CE 5.5.24 (64 bits) MSI installer from MySQL Dev. Web Site
NetBeans IDE 7.2 RC1 with JRE 7 update 5 (64 bits) from NetBeans Web Site
Windows 7 Professional Edition (64 bits)
As you can see, all used tools are 64 bits.
My headache starts when I try to include SVN server to the toolset.
Well, before posting this message in this forum, I found many very good SVN solutions for Windows 64 bits such as Visual SVN Server, Subversion Edge from CollabNet and uberSVN from WanDisco. However, all of them install an embedded Apache Server along with SVN Server.
So, as I already have an Apache server working and well configured with all my personal needs, I would totally avoid having two different Apache servers just because of SVN.
I have also searched on the web in order to know whether I could install either VisualSVN or Subversion Edge without their embedded Apache server, but it seems it's not an option.
In my opinion, the only way to use my currently working Apache server is if I could find the SVN binaries for Apache 2.2.22 64bits.
As additional information, also searching many forums on the web, it seems that no SVN 64 bits libraries are released just because there are already good enough free tools in the market for this purpose such as the aforementioned ones. The price is that they also come with the Apache server which I really don't want.
I would fully apreeciate your help in this regard.
Best Regards.
SOLUTION UPDATE
Well, fortunately I managed to find Apache Haus web site. They have available Subversion 64 bits binaries ready to integrate with Apache 64 bits.
The setup process is really simple: Just extract the zip file, copy all contents to bin and modules folders inside Apache folder and configure htdocs.conf properly that you are all set.
As additional information, I also found that in order to have a local SVN setup, I really don't need to have a SVN server at all. The only thing I need in this case is to install a 64 bits client.
FINAL WORD
Although I don't need SVN server to install subversion on my local environment, I believe it's still worth the lessons learned with this setup and it's still worth to share here on StackOverflow as other guys may need to configure a SVN Server in a Windows 64 bits environment with Apache 64 bits.
Thanks a lot.
FWIW - Apache in uberSVN is self-contained so you should be fine to use uberSVN and still have your newer version of Apache installed for all your other needs.

What web server should I install?

I have Windows 7 Enterprise and I want to run a web server on this computer and I wander what is the best web server would be in my case. I have several requirements to the web server.
It should be easy to install and set up the server. Just "click", "accept" and that's it.
It should support MySQL and PHP (with GET, POST, SESSION, and cookies).
I want to be able to install the server from CD or memory stick. In other words, I want to be able to download something on my CD and than use this CD to install the web server.
The server (software) should not occupy a lot of memory.
It should be possible to install the web server on Linux, Windows and MAC.
Install Z-WAMP. It has the latest versions of Apache, MySQL and PHP (with APC and phyMyAdmin). It's also portable so you can have it installed on a mem stick.
XAMPP is very simple to install and use.
Quoting:
Zend Server Community Edition is a fast and reliable PHP application stack. It is completely free, and you can use it in development, testing and production.
Further:
Eliminate wasted time spent on putting together your PHP stack piece by piece. Zend Server Community Edition includes everything you need, whether you’re using Windows, Linux or Mac OS X. The simple, native installers will set you up in minutes with:
Bytecode accelerator (Optimizer+)
Zend Data Cache
A certified PHP distribution
Zend Framework
Apache (or IIS integration)
MySQL (on Windows and Mac OS X)
Out-of-the-box connectivity to all common databases
Java code connectivity
Web-based PHP administrator console
Not quite sure if this is what you mean but take a look at AppServ it installs Apache, PHP and MySQL for you with one installation file.
If you combine requirement 1, 3 and 5 you make it extremely difficult.
There is not just one package that you can install on boot *nix and windows. Simply because they use a different Operating System with other drive mappings, libraries, etc.
But for Windows I recommend one of the XAMP/WAMP implementation (I'm not a Windows User). For Mac there is MAMP. On other *nix based systems I always used predefined packages or a manualy compiled amount of packages which does not meet your requirements.
Latest OSX has buildin PHP and Apache. You only have to enable Apache in your system pref panel. MySQL can be installed.
It's also possible to use XAMPP for osx. Can be installed from CD
As for Windows you can use WAMP or XAMPP. This package includes Apache, PHP and MySQL. Can be installed from CD.
Most Linux distro's have apache build in. And it's easy to configure PHP and MySQL for it. You can also use XAMPP for linux:
LAMP for linux
XAMPP for mac
and WAMP for win
Different gui almost the same thing easy to setup and configure.
The big advantages with WAMP are that you can easily switch PHP/Apache/MySQL version and toggle PHP settings + extensions, directly from the taskbar.
That's why I'm using it.
Note: Even though you can't download the latest PHP version from their site, it's very easy to install it yourself.

Categories