PATH

N

Nobody Special

Would someone please direct me to a place where the boot sequence is described
in detail or alternately give me your best advise as to why my path is being
repeated (it shows path=c:\a;c:\b;c:\d;c:\a;c:\b;c:\d). Thanks.
 
W

Wesley Vogel

Guide to Boot Sequence
http://www.pcguru.plus.com/winguide/booting.html

PATH environment variable
The system finds the commands you type by searching in each of the
directories listed in the PATH environment variable (unless you specify the
entire absolute pathname of the command yourself).

Path
The complete location of where a computer, file, web, or other object is
located.

Where do you see c:\a;c:\b;c:\d;c:\a;c:\b;c:\d ??
From the set or path commands?

You should see something like...

PATH=C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem

What problem(s) are you having?

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
N

Nobody Special

Thanks Wesley

Guide to Boot Sequence
http://www.pcguru.plus.com/winguide/booting.html

PATH environment variable
The system finds the commands you type by searching in each of the
directories listed in the PATH environment variable (unless you specify the
entire absolute pathname of the command yourself).

Path
The complete location of where a computer, file, web, or other object is
located.
- - - - - -
Where do you see c:\a;c:\b;c:\d;c:\a;c:\b;c:\d ??
From the set or path commands?

Either shows the same, but of course set shows all the other variables. Here's
what it actually shows:

PATH=C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;c:\Python22;C:\Program
files\PC-Doctor for Windows
XP\WINDSAPI;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;c:\Python22;C:\Program
files\PC-Doctor for Windows XP\WINDSAPI;C:\utils;C:\batch

The last two (C:\utils & C:\batch) are being set by my autoexec.bat which is

@echo off
set OLDPATH=%PATH%
set PATH=%OLDPATH%;C:\utils;C:\batch
set OLDPATH=

- - - - - -
You should see something like...

PATH=C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem

What problem(s) are you having?

Well, the problem is just the repeated path. Not that it's necessarily messing
anything up, it's just that it's not right that it's repeated like that for no
reason. I could just let it be and ignore it, but I'd like to fix it if
possible.

Thanks again, Wes
- - - - - -
--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
W

Wesley Vogel

For what? What is/was the problem?

Incorrect PATH environment variable?


--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
N

Nobody Special

The incorrectness is that it's repeated,
for no reason,
that's all.
I'd like to correct that.

PATH=
C:\WINDOWS\system32;
C:\WINDOWS;
C:\WINDOWS\System32\Wbem;
c:\Python22;
C:\Program files\PC-Doctor for Windows XP\WINDSAPI;
C:\WINDOWS\system32;
C:\WINDOWS;
C:\WINDOWS\System32\Wbem;
c:\Python22;
C:\Program files\PC-Doctor for Windows XP\WINDSAPI;
C:\utils;C:\batch

Have you seen this before?
If so, what caused it?
Thanks again for your help.
- - - - - - - - - - - - - - - - - - -
For what? What is/was the problem?

Incorrect PATH environment variable?


--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
D

Dave Patrick

Yes, no problem to delete the duplicates. Possibly a repair installation.

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| The incorrectness is that it's repeated,
| for no reason,
| that's all.
| I'd like to correct that.
|
| PATH=
| C:\WINDOWS\system32;
| C:\WINDOWS;
| C:\WINDOWS\System32\Wbem;
| c:\Python22;
| C:\Program files\PC-Doctor for Windows XP\WINDSAPI;
| C:\WINDOWS\system32;
| C:\WINDOWS;
| C:\WINDOWS\System32\Wbem;
| c:\Python22;
| C:\Program files\PC-Doctor for Windows XP\WINDSAPI;
| C:\utils;C:\batch
|
| Have you seen this before?
| If so, what caused it?
| Thanks again for your help.
 
N

Nobody Special

Hi Dave,
Thanks for the response. I figured there wouldn't be a problem removing the
duplicates. My problem is that I don't know what to delete them from. What
file?
- - -
Yes, no problem to delete the duplicates. Possibly a repair installation.

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| The incorrectness is that it's repeated,
| for no reason,
| that's all.
| I'd like to correct that.
|
| PATH=
| C:\WINDOWS\system32;
| C:\WINDOWS;
| C:\WINDOWS\System32\Wbem;
| c:\Python22;
| C:\Program files\PC-Doctor for Windows XP\WINDSAPI;
| C:\WINDOWS\system32;
| C:\WINDOWS;
| C:\WINDOWS\System32\Wbem;
| c:\Python22;
| C:\Program files\PC-Doctor for Windows XP\WINDSAPI;
| C:\utils;C:\batch
|
| Have you seen this before?
| If so, what caused it?
| Thanks again for your help.
 
D

Dave Patrick

It is stored in the registry. Control Panel|System|Advanced|Environment
Variables|System Variables|Path|Edit

If you want some help with this you can copy the string from "Variable
value:" and paste in a reply.

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| Hi Dave,
| Thanks for the response. I figured there wouldn't be a problem removing
the
| duplicates. My problem is that I don't know what to delete them from. What
| file?
 
N

Nobody Special

Well, that's what's weird. It's shows up there only once rather than two
identical strings concatenated as it shows with the path or set commands. Have
any idea what could be doing that?

It is stored in the registry. Control Panel|System|Advanced|Environment
Variables|System Variables|Path|Edit

If you want some help with this you can copy the string from "Variable
value:" and paste in a reply.

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| Hi Dave,
| Thanks for the response. I figured there wouldn't be a problem removing
the
| duplicates. My problem is that I don't know what to delete them from. What
| file?
 
D

Dave Patrick

Look for a "path" variable in "User variables" Check the contents of
Autoexec.nt found in;
\windows\system32
directory.

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| Well, that's what's weird. It's shows up there only once rather than two
| identical strings concatenated as it shows with the path or set commands.
Have
| any idea what could be doing that?
 
N

Nobody Special

No path variable in "User variables" and nothing out of the ordinary in
Autoexec.nt
Did you notice from my previous response to Wes Vogel showing the contents of
my autoexec.bat?
@echo off
set OLDPATH=%PATH%
set PATH=%OLDPATH%;C:\utils;C:\batch
set OLDPATH=
Would the system assume that the user would _not_ take care of preserving the
initial path?
If the autoexec.bat simply contained only set PATH=C:\utils;C:\batch, would the
system add
that to the existing path, or would it replace the existing path?
- - -
Look for a "path" variable in "User variables" Check the contents of
Autoexec.nt found in;
\windows\system32
directory.

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| Well, that's what's weird. It's shows up there only once rather than two
| identical strings concatenated as it shows with the path or set commands.
Have
| any idea what could be doing that?
 
D

Dave Patrick

No, I missed that. It would append not replace.

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| No path variable in "User variables" and nothing out of the ordinary in
| Autoexec.nt
| Did you notice from my previous response to Wes Vogel showing the contents
of
| my autoexec.bat?
| @echo off
| set OLDPATH=%PATH%
| set PATH=%OLDPATH%;C:\utils;C:\batch
| set OLDPATH=
| Would the system assume that the user would _not_ take care of preserving
the
| initial path?
| If the autoexec.bat simply contained only set PATH=C:\utils;C:\batch,
would the
| system add
| that to the existing path, or would it replace the existing path?
 
N

Nobody Special

That what I thought, but apparently not the case here. After clearing out
autoexec.bat and adding those two directories to the path via the Control
Panel, everything is normal now. No more repeated string in the path variable.
In other batch files where I've wanted to temporarily add a directory to the
path, that method works just fine. I don't get it. Anyway, there's a mystery
for you to ponder in your spare time. Heheh. Thanks again for your help.

No, I missed that. It would append not replace.

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| No path variable in "User variables" and nothing out of the ordinary in
| Autoexec.nt
| Did you notice from my previous response to Wes Vogel showing the contents
of
| my autoexec.bat?
| @echo off
| set OLDPATH=%PATH%
| set PATH=%OLDPATH%;C:\utils;C:\batch
| set OLDPATH=
| Would the system assume that the user would _not_ take care of preserving
the
| initial path?
| If the autoexec.bat simply contained only set PATH=C:\utils;C:\batch,
would the
| system add
| that to the existing path, or would it replace the existing path?
 
N

Nobody Special

PS: I'd sure appreciate it if you would let me know if you ever determine why
the processing of autoexec.bat behaves in that odd manner when launching cmd.
There's got to be something a tad out of the ordinary there. My email address
is rps[at]rpseeley.com

| my autoexec.bat?
| @echo off
| set OLDPATH=%PATH%
| set PATH=%OLDPATH%;C:\utils;C:\batch
| set OLDPATH=
| Would the system assume that the user would _not_ take care of preserving
the
| initial path?
| If the autoexec.bat simply contained only set PATH=C:\utils;C:\batch,
would the
| system add
| that to the existing path, or would it replace the existing path?
 
D

Dave Patrick

Not sure I'm following you. Did you try only;
set PATH=C:\utils;C:\batch
in autoexec.bat?

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| That what I thought, but apparently not the case here. After clearing out
| autoexec.bat and adding those two directories to the path via the Control
| Panel, everything is normal now. No more repeated string in the path
variable.
| In other batch files where I've wanted to temporarily add a directory to
the
| path, that method works just fine. I don't get it. Anyway, there's a
mystery
| for you to ponder in your spare time. Heheh. Thanks again for your help.
 
N

Nobody Special

No. I suppose maybe I should have tried that first just to see what it would
do, but I went ahead and deleted those lines out of autoexec and added the two
directories to my path by way of Control Panel.

Not sure I'm following you. Did you try only;
set PATH=C:\utils;C:\batch
in autoexec.bat?

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| That what I thought, but apparently not the case here. After clearing out
| autoexec.bat and adding those two directories to the path via the Control
| Panel, everything is normal now. No more repeated string in the path
variable.
| In other batch files where I've wanted to temporarily add a directory to
the
| path, that method works just fine. I don't get it. Anyway, there's a
mystery
| for you to ponder in your spare time. Heheh. Thanks again for your help.
 
D

Dave Patrick

Then I don't understand what you meant by "apparently not the case here"

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| No. I suppose maybe I should have tried that first just to see what it
would
| do, but I went ahead and deleted those lines out of autoexec and added the
two
| directories to my path by way of Control Panel.
 
N

Nobody Special

Because having those lines in the autoexec.bat, even though they are designed
to merely append the path variable, what happened was different than what would
normally be expected in that something associated with the execution of
autoexec.bat caused appending the entire path string to itself before appending
the two new directories to the string. That's what I meant by "apparently not
the case here".

Then I don't understand what you meant by "apparently not the case here"

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| No. I suppose maybe I should have tried that first just to see what it
would
| do, but I went ahead and deleted those lines out of autoexec and added the
two
| directories to my path by way of Control Panel.
 
D

Dave Patrick

But you didn't try;
set PATH=C:\utils;C:\batch
in autoexec.bat

These lines are what caused it.
set OLDPATH=%PATH%
set PATH=%OLDPATH%;C:\utils;C:\batch

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| Because having those lines in the autoexec.bat, even though they are
designed
| to merely append the path variable, what happened was different than what
would
| normally be expected in that something associated with the execution of
| autoexec.bat caused appending the entire path string to itself before
appending
| the two new directories to the string. That's what I meant by "apparently
not
| the case here".
 
N

Nobody Special

Ok. Here's what I just did:
I edited autoexec.bat to read

@echo off
set PATH=F:\TEMP3

then rebooted and ran path.
Here's what came up:

PATH=C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;c:\utils;c:\batch;c:\Python22;C:\Program
files\PC-Doctor for Windows XP\WINDSAPI;F:\TEMP3

Do you see it now?
Autoexec.bat didn't REPLACE the path variable,
it appended it.

But you didn't try;
set PATH=C:\utils;C:\batch
in autoexec.bat

These lines are what caused it.
set OLDPATH=%PATH%
set PATH=%OLDPATH%;C:\utils;C:\batch

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| Because having those lines in the autoexec.bat, even though they are
designed
| to merely append the path variable, what happened was different than what
would
| normally be expected in that something associated with the execution of
| autoexec.bat caused appending the entire path string to itself before
appending
| the two new directories to the string. That's what I meant by "apparently
not
| the case here".
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top