Windows cannot find '-n' error installing AMPP Vers 5.6.23

Problems with the Windows version of XAMPP, questions, comments, and anything related.

Windows cannot find '-n' error installing AMPP Vers 5.6.23

Postby fyiman » 30. June 2016 00:23

I just uninstalled an old version of XAMPP and installed a new version (5.6.23):

Code: Select all
4:27:20 PM  [main]    Windows Version: Windows 7 Home Premium SP1 64-bit
4:27:20 PM  [main]    XAMPP Version: 5.6.23
4:27:20 PM  [main]    XAMPP Control Panel Version: 3.2.2  [ Compiled: Nov 12th 2015 ]
4:27:20 PM  [main]    XAMPP Installation Directory: "f:\standalone\xampp\"
4:27:20 PM  [main]    Checking for prerequisites
4:27:20 PM  [main]    All prerequisites found
4:27:20 PM  [main]    Initializing Modules
4:27:20 PM  [main]    Starting Check-Timer
4:27:20 PM  [main]    Control Panel Ready


The XAMPP Installation file was downloaded from apachefriends.org, earlier today:
Code: Select all
https://www.apachefriends.org/xampp-files/5.6.23/xampp-win32-5.6.23-0-VC11-installer.exe


Near the end of the installation, I see an error dialog box:
Code: Select all
[Window Title]: -n
[Content]: Windows cannot find '-n'. Make sure you typed the name correctly, and then try again.


When I click OK to close this dialog box, I see another error dialog box:
Code: Select all
[Window Title]: Warning
[Content]: Problem running post-install step. Installation may not complete correctly
Installation failed (php.exe). Perhaps you have to install the Microsoft
Visual C++ 2008 Redistributable package. After that please execute the
setup_xampp.bat in the xampp folder manually.


I am then (later) recommended to install:
http://www.microsoft.com/en-us/download/details.aspx?id=5582
https://download.microsoft.com/download/d/d/9/dd9a82d0-52ef-40db-8dab-795376989c03/vcredist_x86.exe

File properties/Details for the downloaded file (vcredist_x86.exe) is:
Code: Select all
Description: Microsoft Visual C++ 2008 Redistributable
File version: 9.0.30729.17
Product name: Microsoft Visual C++ 2008 Redistributable
Product version: 9.0.30729.17
Size: 4.02 MB


I find that I already have this Microsoft Visual C++ 2008 Redistributable package installed.

From Windows Control Panel, Programs and Features, I find these are installed:
Code: Select all
Microsoft Visual C++ 2008 Redistributable x64 9.0.30729.5570    KB2467174
Microsoft Visual C++ 2008 Redistributable x86 9.0.30729.5570    KB2467174
Microsoft Visual C++ 2008 Redistributable x64 9.0.30729.17
Microsoft Visual C++ 2008 Redistributable x64 9.0.30729.4148
Microsoft Visual C++ 2008 Redistributable x64 9.0.30729.6161
Microsoft Visual C++ 2008 Redistributable x86 9.0.21022
Microsoft Visual C++ 2008 Redistributable x86 9.0.30729
Microsoft Visual C++ 2008 Redistributable x86 9.0.30729.4148
Microsoft Visual C++ 2008 Redistributable x86 9.0.30729.6161


I could reinstall the Microsoft Visual C++ 2008 Redistributable version x64 9.0.30729.17, but there are newer versions of it installed already.

When I try to start Apache from the XAMPP Control Panel, I get an error message in the XAMPP Control Panel progress box:
Code: Select all
5:26:32 PM  [Apache]    Attempting to start Apache app...
5:26:33 PM  [Apache]    Status change detected: running
5:26:34 PM  [Apache]    Status change detected: stopped
5:26:34 PM  [Apache]    Error: Apache shutdown unexpectedly.
5:26:34 PM  [Apache]    This may be due to a blocked port, missing dependencies,
5:26:34 PM  [Apache]    improper privileges, a crash, or a shutdown by another method.
5:26:34 PM  [Apache]    Press the Logs button to view error logs and check
5:26:34 PM  [Apache]    the Windows Event Viewer for more clues
5:26:34 PM  [Apache]    If you need more help, copy and post this
5:26:34 PM  [Apache]    entire log window on the forums


When I click the Logs button to view the Apache error log (error.log), I get this dialog message:
Code: Select all
[Window Title]: Notepad
[Content]: Cannot find the f:\standalone\xampp\apache\logs\error.log file.
Do you want to create a new file?

Answered ==> No.



When I click the Logs button to view the PHP error log (php_error_log), I get this dialog message:
Code: Select all
[Window Title]: Notepad
[Content]: The system cannot find the path specified.


When I run setup_xampp.bat (non Administrator), it completes without any errors:
Code: Select all
########################################################################
# ApacheFriends XAMPP setup win32 Version                              #
#----------------------------------------------------------------------#
# Copyright (c) 2002-2016 Apachefriends 5.6.23                         #
#----------------------------------------------------------------------#
# Authors: Kay Vogelgesang <kvo@apachefriends.org>                     #
#          Carsten Wiedmann <webmaster@wiedmann-online.de>             #
########################################################################

Sorry, but ... nothing to do!
Press any key to continue . . .


After pressing a key, the command prompt window closes.

When I run setup_xampp.bat as Administrator (from Windows Explorer, Right-click=>"Run as Administrator), I see this error:
Code: Select all
################################# START XAMPP TEST SECTION #################################
[XAMPP]: Test php.exe with php\php.exe -n -d output_buffering=0 --version ...
The system cannot find the path specified.

[ERROR]: Test php.exe failed !!!
[ERROR]: Perhaps the Microsoft C++ 2008 runtime package is not installed.
[ERROR]: Please try to install the MS VC++ 2008 Redistributable Package from the Mircrosoft page first
[ERROR]: http://www.microsoft.com/en-us/download/details.aspx?id=5582
################################# END XAMPP TEST SECTION ###################################

Press any key to continue . . .


After pressing a key, the command prompt window closes.

Next I opened a (non Administrator) command prompt and ran a command:
Code: Select all
F:\Standalone\xampp>php\php.exe -n -d output_buffering=0 --version
PHP 5.6.23 (cli) (built: Jun 22 2016 12:15:20)
Copyright (c) 1997-2016 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies

F:\Standalone\xampp>


I get the same output if I open an Administrator command prompt and run the command.

Any help in proceeding from here would be appreciated.
fyiman
 
Posts: 7
Joined: 29. June 2016 23:04
XAMPP version: 5.6.23 / PHP 5.6.23
Operating System: Windows 7 Home Premiup x64 SP1

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby Fortiz » 08. July 2016 13:41

Hi,

I'm sorry, but we are not able to reproduce the issue. I just installed XAMPP in several Windows versions and it works properly. Could you please let us know what steps you followed during the installation? We will try to reproduce your issue.

Regards,
Fran
Fortiz
 
Posts: 2
Joined: 08. July 2016 13:37
XAMPP version: 5.6.23
Operating System: Linux

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby sleptwolf » 25. July 2016 07:26

hello there i came here searching solution for the same problem. I followed some of your steps.
But after running setup_xampp(w/o admin) apache ran w/o any errors.
my specs:
OS: Win 8
xampp ver : 7.0.8
sleptwolf
 
Posts: 1
Joined: 25. July 2016 04:11
XAMPP version: 5.6.23/7.0.8
Operating System: win 8

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby mach128x » 03. September 2016 19:34

Hi everyone.
I had the same problem and found a solution. I just registered to post what was happening, hoping it can help someone else!

I was trying to install XAMP ver 7.0.9 in a specific folder of my choosing (not the default).
I went to the Add/Remove Control Panel to uninstall/reinstall 7.0.9 a couple of times and always got the same error.

The problem was that I already had an older version of XAMPP installed to the default folder i.e. C:\xampp and I had completely forgotten about it.
Due to me installing 7.0.9, there was no trace of the older install in Control Panel Add/Remove anymore.

So I went to the older installation folder, ran the uninstall from there, re-installed 7.0.9, et voilà :D
mach128x
 
Posts: 4
Joined: 03. September 2016 19:19
XAMPP version: 7.0.9
Operating System: MS Windows 7 / 8 / 8.1 /10 Pro

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby bartmanskyi » 09. September 2016 20:57

I have this problem - windows cannot find '-n' Make sure
and i found how to solve them
when you see alert box with that text, you just need to open CMD.EXE with Administrator privilege, navigate to folder with xampp, and run setup_xampp.bat
After this, click "ok" on alert box and start xampp
he works fine :D
bartmanskyi
 
Posts: 1
Joined: 09. September 2016 20:50
XAMPP version: 5.6.24
Operating System: Win 10

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby fyiman » 26. September 2016 16:48

mach128x wrote:Hi everyone.
I had the same problem and found a solution. I just registered to post what was happening, hoping it can help someone else!

...

The problem was that I already had an older version of XAMPP installed to the default folder i.e. C:\xampp and I had completely forgotten about it.


Thanks for posting your solution, and I'm glad it worked for you.

Unfortunately, this is not the case for me. I did have an older version of XAMPP installed, but I removed (uninstalled) the older version before I tried installing the newer version of XAMPP. That's when I got the error(s) I described in my original post above.
fyiman
 
Posts: 7
Joined: 29. June 2016 23:04
XAMPP version: 5.6.23 / PHP 5.6.23
Operating System: Windows 7 Home Premiup x64 SP1

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby fyiman » 26. September 2016 16:58

bartmanskyi wrote:I have this problem - windows cannot find '-n' Make sure
and i found how to solve them
when you see alert box with that text, you just need to open CMD.EXE with Administrator privilege, navigate to folder with xampp, and run setup_xampp.bat
After this, click "ok" on alert box and start xampp
he works fine :D


Interesting, I did run "setup_xampp.bat" from a CMD.EXE window with Administrator privilege (the details are in my original post), and I still have the problem. But, I waited until I completed the installation (which failed) before I manually ran "setup_xampp.bat" (as Admin).

In your case, it seems you ran "setup_xampp.bat" (as Admin) while the XAMPP installation was still in progress, which could have made the difference. In the meantime, I have installed a much older version that does not have this problem (but has issues of it's own). I will have to try installing the newer version again, and I'll try your suggestion then.
fyiman
 
Posts: 7
Joined: 29. June 2016 23:04
XAMPP version: 5.6.23 / PHP 5.6.23
Operating System: Windows 7 Home Premiup x64 SP1

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby fyiman » 26. September 2016 17:03

Fortiz wrote:Hi,

I'm sorry, but we are not able to reproduce the issue. I just installed XAMPP in several Windows versions and it works properly. Could you please let us know what steps you followed during the installation? We will try to reproduce your issue.

Regards,
Fran


Hi Fran. Thanks for your reply.

I posted all the details I have in my original post. I plan on getting back to this and trying it again. When I do try it again, if I still have the same problem, what sort of additional details should I include in an update to my post?
fyiman
 
Posts: 7
Joined: 29. June 2016 23:04
XAMPP version: 5.6.23 / PHP 5.6.23
Operating System: Windows 7 Home Premiup x64 SP1

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby gsmith » 29. September 2016 00:03

If you happen to have Visual Studio 2012 Redistributable installed.
gsmith
 
Posts: 278
Joined: 29. November 2013 18:04
Location: San Diego
XAMPP version: 0.0.0
Operating System: Win 10/2012R VS 14,15,16

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby fyiman » 05. October 2016 21:46

gsmith wrote:If you happen to have Visual Studio 2012 Redistributable installed.


No I don't.

I have "Microsoft Visual C++ 2008 Redistributable - x64 9.0.30729.17" installed (installed on Sep/03/2012), as well as a few newer versions:
Microsoft Visual C++ 2008 Redistributable - KB2467174 - x64 9.0.30729.5570 (installed on Apr/24/2011)
Microsoft Visual C++ 2008 Redistributable - x64 9.0.30729.6161 (installed on Jun/16/2011)

Microsoft Visual C++ 2010 Runtime - x64 10.0.40219 (installed on Jun/17/2012)
Microsoft Visual C++ 2010 Redistributable - x64 10.0.40219 (installed on Oct/15/2014)
Microsoft Visual Studio 2010 Express Prerequisites x64 - ENU 10.0.40219 (installed on Jun/17/2012)
Microsoft Visual Studio 2010 Service Pack 1 10.0.40219 (installed on Jun/17/2012)

Plus x86 versions of some of these.

No installs for anything for "Visual Studio 2012".
fyiman
 
Posts: 7
Joined: 29. June 2016 23:04
XAMPP version: 5.6.23 / PHP 5.6.23
Operating System: Windows 7 Home Premiup x64 SP1

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby gsmith » 06. October 2016 16:02

Well, the reason I mention it is because PHP 5.5/5.6 is compiled with Visual Studio 2012, same with that Apache. In the past I have noticed (looking in the zip/7z packages) that msvcr110.dll was in both Apache's /bin folder and also in xampp/php. That should be enough to cover the Visual Studio 2012 (VC11) requirement. If you have those then it is something else completely.
gsmith
 
Posts: 278
Joined: 29. November 2013 18:04
Location: San Diego
XAMPP version: 0.0.0
Operating System: Win 10/2012R VS 14,15,16

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby vnathalye » 24. May 2017 06:22

I had exact same issue like @fyiman. As suggested by @sleptwolf I ran setup_xampp (w/o admin) and it did some configuration of XAMPP but even after that Apache was giving error.

When I ran setup_xampp.bat as Administrator it gave me message "Sorry, but ... nothing to do!". And the error while running Apache continued.

While looking at the config scripts I realized that Apache was trying to listen on port 80. And I had IIS service already listening on that port.
So I changed httpd.conf to use a different port 8765 (change was needed at 2 places)
Also changed httpd-ssl.conf to use port 8766 for SSL (change was needed at 3 places)
And also in XAMPP Control Panel > Config > Service and Port settings > specified same port numbers for Apache.

After that I Started Apache and its working !!!

Hope this helps someone.

@Fortiz probably you were not able to reproduce the issue because you didn't have any process listening on port 80 already?
vnathalye
 
Posts: 1
Joined: 24. May 2017 06:02
XAMPP version: 5.6.30
Operating System: Win 7

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby Babs101 » 15. June 2017 01:40

Hi all,
I am trying to run xampp on a windows 10 device with Kaspersky internet security running. I am having some problems. I tried turning of Kaspersky without any luck.
I downloaded the xampp 7.1.4 / PHP 7.1.4 122Mb 32bit.
First error I get is:
“Important! Because an activated User Account Control (UAC) on your system some functions of XAMPP are possibley restricted. With UAC please avoid to install XAMPP to C:/Program Files (x86) (missing write permissions). Or deactivate UAC with msconfig after this step.”
I had tried installing xampp on my HP Pavillion running windows 10 earlier and go the same error. My professor suggested trying different folders to save the xampp files to. I tried C:/ and Program Files and Program Files (x86). None of them worked. I uninstalled and re-installed xampp each time.
Next error message I get is: “Windows cannot find ‘-n’. Make sure you typed the name correctly, and try again.”
Name is typed correctly…even tried copying and pasting it in. This error happens with the files unpacking.
The I get error message “ Problem running post-install step. Installation may not complete correctly Installation failed (php.exe). Perhaps you have to install the Microsoft Visual C++ 2008 Redistribution package. After that please execute the setup_xampp.bat in the xampp folder manually.”
So I already had Microsoft Visual C++ 2013…. I went ahead and installed the 2008 too… and try executing the setup_xampp.bat manually…
I get error message “Error: Cannot create file “C:/Program Files (x86)\xampp\xampp-control.ini”. Access is denied.
Xampp opens with: “Problem detected. Port 443 in use by “C:\Program Files(x86)\VMware\VMware Workstation\vmware-h… Apache will not start without the configured ports free. ..”
I tried to change the port for apache from 80 to 8080… get a repeat of error message:
“Error: Cannot create file “C:/Program Files (x86)\xampp\xampp-control.ini”. Access is denied.
Any suggestions?
Babs101
 
Posts: 1
Joined: 15. June 2017 01:11
XAMPP version: 7.1.4 / PHP 7.1.4
Operating System: Windows 10 64-bit

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby intosh » 17. August 2017 19:05

Installing xampp-win32-7.1.7-0-VC14-installer.exe on Win10 for the very first time and getting this exact same error.

It was not about UAC, not about Visual C++ 2008 Redistribution, not about Firewall. It was simply about the install directory. I was trying to install it in c:\MyPrograms\xampp, twice. And it failed with the same error on both times.

Then, I finally caved in and installed it on the suggested default folder (c:\xampp) and the installation finally completed successfully. This is quite simply ridiculous! Not a good first impression. Not sure if I want to stick with this package now as I am no longer confident in the quality of this package.
intosh
 
Posts: 1
Joined: 17. August 2017 18:56
XAMPP version: 7.1.7
Operating System: Win10

Re: Windows cannot find '-n' error installing AMPP Vers 5.6.

Postby Nobbie » 17. August 2017 21:18

intosh wrote:Not sure if I want to stick with this package now as I am no longer confident in the quality of this package.


Simply install Apache / PHP / MySQL on yourself.
Nobbie
 
Posts: 13170
Joined: 09. March 2008 13:04

Next

Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 82 guests