Re: Cannot Run Ping Command

From: Hammer Toe (HammerToe_at_online.com)
Date: 06/04/04


Date: Fri, 04 Jun 2004 02:21:31 GMT

On Wed, 2 Jun 2004 16:30:11 -0700, "Jeff" <bruinfanjb@hotmail.com>
wrote:

>I keep getting the error message that it is not
>recognized as an internal or external command, operable
>program or batch file. Does anyone know how to fix this
>or do I have to do a repair installation of XP?

'That's' VERY Interesting..... because for the first time EVER I've
started having very similar problems JUST TODAY trying to run ANY
External Commands from a Command PROMPT window..... (specifically
commands in C:\WINDOWS and C:\WINDOWS\SYSTEM32....)

Eg. open a 'Console' window and try to run IPCONFIG /ALL.

I always get a (not exact words here) 'command not found' message.....

NOW I know that the command does exist on my system and if I change to
the directory where it is (C:\Windows\System32) and run it, it
works...

So, what I then tried was to display the PATH (environment variable)
setting as it DISPLAYS at the command prompt and ah-ha!!!

Path displays as:
%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\Program
Files\ATI Technologies\ATI Control Panel;C:\Program Files\UltraEdit

Whereas it SHOULD display as:
C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program
Files\ATI Technologies\ATI Control Panel;C:\Program Files\UltraEdit

Funny (I suppose) the %SystemRoot% Environment Variable is NOT 'being
resolved' in the path statement (at least insofar as it is being
diplayed in the Console Window) ***YET*** - IF you type %SystemRoot%
at the prompt and hit 'enter'; it DOES get resolved as "C:\WINDOWS" so
why THERE but not in the path....???

Now. the path sytax DOES look right (I can see now errors. If you go
into System Properties->Advanced->Environment Variables it 'displays
correctly' (resolves) even though if you try to EDIT the value you can
SEE %SystemRoot% there in the 'source' so it's resolving THERE but
NOT in the console window/'further down the food chain....

I managed to fixc/work around the problem by changing (editing) all
occurances of %SystemRoot% in the path, 'hardcoding it' with
C:\WINDOWS and everything now works but I still don't know WHY it
didn't/doesn't work here in the first place.

ALSO strange/for what it's worth: I have four (three OTHER) XP
computers in the house so I decided to chech them out for comparison
and 'interesting':

1. Some have 'hardcoded' C:\WINDOWS values in the path and others use
%SystemRoot% and YET they ***ALL WORK*** except this last one with the
most recent 'buildup' with XP on it.....

Any ideas???

In anay even, I suggest changing %SystemRoot% to C:\Windows in the
PATH may solve your problem.

I would be very interested in any feedback/suggestions.....



Relevant Pages

  • Re: Need help with command prompt path
    ... entry that defines your path is of the wrong type. ... Check your %SystemRoot% and %System% settings by opening a command ... environment variables press Return to get next line, ...
    (microsoft.public.windowsxp.general)
  • Re: Priviledge escalation attack
    ... > I (who am logged in as Administrator) am having a network connectivity ... A batch file in the WINNT directory ... Ask yourself if you have ever made a typo at the Command ... happily run this instead of the one in %SYSTEMROOT% if 'cmd' is invoked from ...
    (Focus-Microsoft)
  • Re: "NET NOT RECOGNIZED AS A COMMAND" et al
    ... "NET NOT RECOGNIZED AS A COMMAND" ... So the system knows what %systemroot% is ... BUT typing NET STOP at the command prompt gets me the error. ... WHY & How to fix pplleeaasseeeee. ...
    (microsoft.public.windowsxp.general)
  • %SystemRoot% Environment Variable NOT resolving in PATH BUT does resolve at console command line???
    ... >recognized as an internal or external command, ... External Commands from a Command PROMPT window..... ... correctly' (resolves) even though if you try to EDIT the value you can ... SEE %SystemRoot% there in the 'source' so it's resolving THERE but ...
    (microsoft.public.windowsxp.general)
  • Re: could not execute psexec
    ... Funniest thing -- when I run psexc from the command line I get: ... 'psexec' is not recognized as an internal or external command, ... operable program or batch file. ... 'psexec.exe' is not recognized as an internal or external command, ...
    (perl.beginners)