'ping' is not recognized as an internal or external command operable program or batch file error [closed]
Asked Answered
A

2

11

When I do ping www.google.com I get the error message

'ping' is not recognized as an internal or external command operable program or batch file.

Here is an example:

Command Prompt Ping

Then:

Error Command Prompt

What could I be doing wrong?

I'm using Windows 7, 64 bit

There was some tutorial online that said to look up Systems32. And that didnt even show up. In the search at the image there

Windows menu button

I have also restarted my computer

I've had this for over 6 months and its really beginning to cause me problems.

Also if you believe this is off topic please explain first :P

Aquamanile answered 7/10, 2014 at 23:24 Comment(7)
What does dir c:\windows\system32\ping* /b say? And, by the way, copy/paste the test from the console window, don't paste screenshots.Gobi
I cant copy paste in command promptAquamanile
@Luiz187 right click paste. right click select all and hit shift keyAspirant
Yes, you can. Click the little icon in the upper left corner, choose Edit->Mark, select the text in the command window, and hit Enter (or go back to the same menu and choose Edit->Copy). Perhaps you need to find a tutorial that shows you how to use Windows before you try writing batch files. :-)Transonic
there is no \ping* /b is that the issue?Aquamanile
most likely it is getting deleted by your lovely anti-virus. Time to yell @ them for itAspirant
Try running sfc.exe /scanfile=c:\windows\system32\ping.exe to see if Windows will restore the protected system file.Gobi
K
29

Most likely something has removed the system32 directory from your path. Have you installed the Java SDK? It has a reputation for doing that.

To check this, at the command prompt type path (followed by enter)

If c:\windows\system32 isn't there, it needs to be added back in. To do this:

From the desktop, Right click 'Computer', click 'Properties'
     then click 'Advanced system settings' 
            - this should bring up the System Properties - Advanced tab
Click 'Enviornment Variables'
Select the system variables 'PATH'
Edit PATH and add this line to the front
        c:\windows\system32;
or to be generic (in case you've installed windows on a different drive)
        %SystemRoot%\system32
Start a new command window to check if this has worked (or reboot)
      existing command windows will use the old path
Kelpie answered 7/10, 2014 at 23:37 Comment(6)
I think i have installed it.Aquamanile
This will probably be the problem - and if the path has been changed then other folders are probably missing as well.Impermanent
On your desktop, you should have an icon labelled "Computer" ("My Computer" was older operating systems) Updated my instructions above, including a final step.Kelpie
Is this it? i.imgur.com/ipuJPGF.pngAquamanile
No, that's a long way from the Computer icon on the desktop... Have a read of some instructions on setting environment variables. computerhope.com/issues/ch000549.htm An alternative would be to press the Windows key+Pause (break) and go to the advanced tab. Good luckKelpie
Once you have updated the PATH variables, you have to exit the command prompt and then execute ping again.Koel
A
6

Assuming you are using Win 64bit version of windows. Go under C:\Windows\SysWOW64 and see if you can find PING.EXE under the folder. If not, go download one. Someone or something(virus) might have deleted it

Edited: Go under C:\Windows\System32 to find PING.EXE if you are using 32 bit.

Aspirant answered 7/10, 2014 at 23:28 Comment(10)
What do you mean DL one?Aquamanile
@Luiz187 download oneAspirant
@Luiz187 go download a program called PING.EXE . it is a built in program for windows but apparently it has gone missing on your systemAspirant
Could it be this? microsoft.com/en-us/download/details.aspx?id=2868 or is it whatisdll.com/ping-exe-repair-free-download-windows-78xpvistaAquamanile
@Luiz187 nope....its called PING.EXE. I don't know if Microsoft provides it...if not you have to look for other sitesAspirant
cant find where to dowloadAquamanile
"Go download a file from some arbitrary site called ping.exe" is quite possibly the worst advice ever.Ouch
@Luiz187 or if you got the install disk you can copy from the diskAspirant
i lost that is there a online version?Aquamanile
@Luiz187 you have to look for it yourself thenAspirant

© 2022 - 2024 — McMap. All rights reserved.