persistent disk subst

Hi, Dear Experts!

I need to associate path with drive letter (just the
same as subst command does) , but this drive
letters should be persistent to reboot (this means
no command files or logon scripts or etc.).
Currently I know two ways to implement this:
a) write nt driver which create symbolic links each
time it started :slight_smile:
b) write service which call undocumented
NtCreateSymbolicLinkObject function.
All these methods require to start smth. each time
computer boots up.

Now the question: Is any (legal) way exist to create
persistent symbolic links (i.e. create once not each
boot - like SetVolumeMountPoint does)?

Excuse me for off-topic question.

S.Y.
Igor

On Thu, 29 Jul 2004 13:14:39 +0400, you wrote:

Hi, Dear Experts!

I need to associate path with drive letter (just the
same as subst command does) , but this drive
letters should be persistent to reboot (this means
no command files or logon scripts or etc.).
Currently I know two ways to implement this:
a) write nt driver which create symbolic links each
time it started :slight_smile:
b) write service which call undocumented
NtCreateSymbolicLinkObject function.
All these methods require to start smth. each time
computer boots up.

Now the question: Is any (legal) way exist to create
persistent symbolic links (i.e. create once not each
boot - like SetVolumeMountPoint does)?

Excuse me for off-topic question.

Creating an entry under the SessionManager registry entry would appear
to fit your needs?

James.

> Creating an entry under the SessionManager registry entry would appear

to fit your needs?

More than enough!
Thanks a lot, James;
S.Y.
Igor

That question was very interesting to me but I don’t understand the answer.

I searched my whole registry to find a key with the name SessionManager; I
found only keys related to windows messenger. And the DDK docs do not
contain the string SessionManager.

What’s that key? Sorry to ask…

Mat

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of James
Sent: Thursday, July 29, 2004 5:35 AM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] persistent disk subst

On Thu, 29 Jul 2004 13:14:39 +0400, you wrote:

Hi, Dear Experts!

I need to associate path with drive letter (just the
same as subst command does) , but this drive
letters should be persistent to reboot (this means
no command files or logon scripts or etc.).
Currently I know two ways to implement this:
a) write nt driver which create symbolic links each
time it started :slight_smile:
b) write service which call undocumented
NtCreateSymbolicLinkObject function.
All these methods require to start smth. each time
computer boots up.

Now the question: Is any (legal) way exist to create
persistent symbolic links (i.e. create once not each
boot - like SetVolumeMountPoint does)?

Excuse me for off-topic question.

Creating an entry under the SessionManager registry entry would appear
to fit your needs?

James.


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: xxxxx@encentrus.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

On Thu, 29 Jul 2004 09:47:40 -0400, you wrote:

That question was very interesting to me but I don’t understand the answer.

I searched my whole registry to find a key with the name SessionManager; I
found only keys related to windows messenger. And the DDK docs do not
contain the string SessionManager.

What’s that key? Sorry to ask…

Try searching for “Session Manager” (with the space); you’ll find it
under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session
Manager.

For an example of using it to add a drive mapping, you can look at the
SwapFS driver (written to allow you to mount a Linux swap partition,
so a dual-boot Linux/NT system only needs one, shared, swap location).

http://www.acc.umu.se/~bosse/

(Also some other useful tools: a free ntifs.h, a simple read-only
example filing system and a driver for emulating a disk using a file.)

James.

It contains a space. “Session Manager” under CurrentControlSet/Control

Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com

----- Original Message -----
From: “Mathieu Routhier”
To: “Windows System Software Devs Interest List”
Sent: Thursday, July 29, 2004 5:47 PM
Subject: RE: [ntdev] persistent disk subst

> That question was very interesting to me but I don’t understand the answer.
>
> I searched my whole registry to find a key with the name SessionManager; I
> found only keys related to windows messenger. And the DDK docs do not
> contain the string SessionManager.
>
> What’s that key? Sorry to ask…
>
> Mat
>
> -----Original Message-----
> From: xxxxx@lists.osr.com
> [mailto:xxxxx@lists.osr.com] On Behalf Of James
> Sent: Thursday, July 29, 2004 5:35 AM
> To: Windows System Software Devs Interest List
> Subject: Re: [ntdev] persistent disk subst
>
> On Thu, 29 Jul 2004 13:14:39 +0400, you wrote:
>
> >Hi, Dear Experts!
> >
> >I need to associate path with drive letter (just the
> >same as subst command does) , but this drive
> >letters should be persistent to reboot (this means
> >no command files or logon scripts or etc.).
> >Currently I know two ways to implement this:
> >a) write nt driver which create symbolic links each
> >time it started :slight_smile:
> >b) write service which call undocumented
> >NtCreateSymbolicLinkObject function.
> >All these methods require to start smth. each time
> >computer boots up.
> >
> >Now the question: Is any (legal) way exist to create
> >persistent symbolic links (i.e. create once not each
> >boot - like SetVolumeMountPoint does)?
> >
> >Excuse me for off-topic question.
>
> Creating an entry under the SessionManager registry entry would appear
> to fit your needs?
>
>
> James.
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: xxxxx@encentrus.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
> —
> Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: xxxxx@storagecraft.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com

isnt it something like HKLM\SYSTEM\CurrentControlSet\Control\Session Manager ???

asa

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of Mathieu Routhier
Sent: Thursday, July 29, 2004 8:48 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] persistent disk subst

That question was very interesting to me but I don’t understand the answer.

I searched my whole registry to find a key with the name SessionManager; I
found only keys related to windows messenger. And the DDK docs do not
contain the string SessionManager.

What’s that key? Sorry to ask…

Mat

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of James
Sent: Thursday, July 29, 2004 5:35 AM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] persistent disk subst

On Thu, 29 Jul 2004 13:14:39 +0400, you wrote:

Hi, Dear Experts!

I need to associate path with drive letter (just the
same as subst command does) , but this drive
letters should be persistent to reboot (this means
no command files or logon scripts or etc.).
Currently I know two ways to implement this:
a) write nt driver which create symbolic links each
time it started :slight_smile:
b) write service which call undocumented
NtCreateSymbolicLinkObject function.
All these methods require to start smth. each time
computer boots up.

Now the question: Is any (legal) way exist to create
persistent symbolic links (i.e. create once not each
boot - like SetVolumeMountPoint does)?

Excuse me for off-topic question.

Creating an entry under the SessionManager registry entry would appear
to fit your needs?

James.


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: xxxxx@encentrus.com
To unsubscribe send a blank email to xxxxx@lists.osr.com


Questions? First check the Kernel Driver FAQ at http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: xxxxx@rivin.net
To unsubscribe send a blank email to xxxxx@lists.osr.com

Try “HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session
Manager\DOS Devices”

http://support.microsoft.com/default.aspx?scid=kb;EN-US;102985

It’s not the best way to form a persistant symbolic link, but it should
work for current versions of windows at least. (not to say it won’t be
supported in the future, but who can tell)

-p

This posting is provided “AS IS” with no warranties, and confers no
rights.

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Asa Yeamans
Sent: Thursday, July 29, 2004 11:19 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] persistent disk subst

isnt it something like HKLM\SYSTEM\CurrentControlSet\Control\Session
Manager ???

asa

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of Mathieu Routhier
Sent: Thursday, July 29, 2004 8:48 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] persistent disk subst

That question was very interesting to me but I don’t understand the
answer.

I searched my whole registry to find a key with the name SessionManager;
I found only keys related to windows messenger. And the DDK docs do not
contain the string SessionManager.

What’s that key? Sorry to ask…

Mat

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of James
Sent: Thursday, July 29, 2004 5:35 AM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] persistent disk subst

On Thu, 29 Jul 2004 13:14:39 +0400, you wrote:

Hi, Dear Experts!

I need to associate path with drive letter (just the same as subst
command does) , but this drive letters should be persistent to reboot
(this means no command files or logon scripts or etc.).
Currently I know two ways to implement this:
a) write nt driver which create symbolic links each time it started :slight_smile:
b) write service which call undocumented NtCreateSymbolicLinkObject
function.
All these methods require to start smth. each time computer boots up.

Now the question: Is any (legal) way exist to create persistent
symbolic links (i.e. create once not each boot - like
SetVolumeMountPoint does)?

Excuse me for off-topic question.

Creating an entry under the SessionManager registry entry would appear
to fit your needs?

James.


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: xxxxx@encentrus.com To
unsubscribe send a blank email to xxxxx@lists.osr.com


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: xxxxx@rivin.net To
unsubscribe send a blank email to xxxxx@lists.osr.com


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com