0
votes

i have the following server setup:

  • a DC with DNS [works perfect]
  • a webserver with GUI [works perfect]
  • a webserver Core [stuck at PHP installation]

I'm trying to install PHP on the core server. I have a simple site with a php file that shows the phpinfo();. From the GUI webserver I was able to manage to use the gui to do a lot of stuff, but now i'm stuck.

What did i do:

  • on the core server, i put a php folder and eddited the ini file
  • On the IIS of the GUI, i manage the Core server and added the module mapping for php. I could not browse (did not get the button witht the 3 points to browse) because its managing the coreserver so i just added the path manualy c:\php\php-cgi.exe
  • the next step would be to add that php path to the environment variables (path). I did this with powershell. When showing the $env:path, the path of php is added. Also after a reboot, it's still added
  • when following guides, now i should be able to let the cmd tool tell me what version of php i'm running. I tried php -v, php -m and php --version in command line and in terminal. What gave no errors, but also no other output.

Can someone help me debug this one? The core makes it harder for me because when i did this on a gui, it worked. But then i changed settings like the path environment in gui screens.

Thank you for your time!

Find a clean Windows Server with GUI, but use the same steps like PowerShell to set it up. That can reveal to you what's wrong and then you know how to fix that. BTW, tools like docs.jexusmanager.com/tutorials/php-diagnostics.html can show you what's missing, but they don't work on Windows Server Core. - Lex Li
For information about "Install PHP and FastCGI Support on Server Core", you can refer to this link: docs.microsoft.com/en-us/iis/application-frameworks/… - Ding Peng
@DingPeng Exact setup i followed. This method does not include information from the variables environment. Is that something that is not needed? - Onovar
@LexLi The problem is a) variables environment or b) php itself. For a) i do not have an alternative method. For b i tried different versions. If in command line the input is "php --version" and it won't show an error, also no version, just blank line, where would i be able to check some logs to know what's going wrong? - Onovar
You didn't even show how to configure environment variables (steps or PowerShell), so how can others guess what you really did (right or wrong)? Microsoft does have an article with sample steps, docs.microsoft.com/en-us/iis/application-frameworks/… but I doubt if that's still up-to-date. - Lex Li