Board index » delphi » Net Dir and Pdoxusrs.net

Net Dir and Pdoxusrs.net

Greetings
When I set the net dir parameter to 'c:\' I get two 'Pdoxusrs.net' files-
One of them in the directory chosen for net dir, and the second in the local
directory of the alias I'm using.
Which one of them is used at a given time?
Is there a reason not to set the net dir to the same directory as the
alias I'm working on?
Thank you in advance
 

Re:Net Dir and Pdoxusrs.net


On Mon, 11 Oct 1999 09:53:23 +0200, "Nohalim" <Noha...@Hotmail.com>
wrote:

Quote
>Greetings
>When I set the net dir parameter to 'c:\' I get two 'Pdoxusrs.net' files-
>One of them in the directory chosen for net dir, and the second in the local
>directory of the alias I'm using.
>Which one of them is used at a given time?
>Is there a reason not to set the net dir to the same directory as the
>alias I'm working on?
>Thank you in advance

If you'll access your DB in a network environment (multiuser) you need
to put this file in a common shared directory that all your users can
see (and write).

[]'s
Paulo Garcia
<< I'll learn English >>

Re:Net Dir and Pdoxusrs.net


Quote
>>When I set the net dir parameter to 'c:\' I get two 'Pdoxusrs.net' files-
>If you'll access your DB in a network environment (multiuser) you need
>to put this file in a common shared directory that all your users can see

(and write).

I know the importance of the net dir.
What I'm asking is why another pdxusers.net is created in the alias
directory.

Re:Net Dir and Pdoxusrs.net


There should only be one net file and it should be on
the server and preferably Not in the root directory.  Double check
everyone's bde to make sure
they are all pointing to the same shared path to use for the
net  directory.  Search every machine including the server
for pdoxusr.net files and delete them when no one is using
the application.  The net file should be recreated in the proper
place when the application is restarted, and no other one should be
created.

Quote
Nohalim <Noha...@Hotmail.com> wrote in message

news:7tsqg1$m3v1@forums.borland.com...
Quote
> >>When I set the net dir parameter to 'c:\' I get two 'Pdoxusrs.net'
files-

> >If you'll access your DB in a network environment (multiuser) you need
> >to put this file in a common shared directory that all your users can see
> (and write).

> I know the importance of the net dir.
> What I'm asking is why another pdxusers.net is created in the alias
> directory.

Re:Net Dir and Pdoxusrs.net


It is best to set the NetDir to a subdirectory reserved for that purpose. Do
not use the root directory of a drive.

Bill

--

Bill Todd - TeamB
(TeamB cannot respond to questions received via email)

Re:Net Dir and Pdoxusrs.net


Quote
>When I set the net dir parameter to 'c:\' I get two 'Pdoxusrs.net' files-
>One of them in the directory chosen for net dir, and the second in the local
>directory of the alias I'm using.
>Which one of them is used at a given time?
>Is there a reason not to set the net dir to the same directory as the
>alias I'm working on?

You should not be getting two .net files unless you are creating a session in
your program other than the default Session and setting the NetDir parameter of
that session.

Also it is not a good idea to use a root directory for the network control file.

--
Brian Bushay (TeamB)
Bbus...@NMPLS.com

Re:Net Dir and Pdoxusrs.net


On Tue, 12 Oct 1999 03:04:29 GMT, BBus...@Nmpls.com (Brian Bushay

Quote
TeamB) wrote:
>Also it is not a good idea to use a root directory for the network control file.

Why?

/\/\ichael

--
   * Michael Rittweger,  Nissenstr. 14,  24148 Kiel,  +49-431-7209360 *
         2:240/2120 @ fidonet, +49-431-7209361 (Mailer, FAX, BBS)
               <http://www.users.comcity.de/~zaphod>

Re:Net Dir and Pdoxusrs.net


Quote
mir...@gmx.de (Michael Rittweger) wrote:
>>Also it is not a good idea to use a root directory for the network control file.

The BDE only uses the directory path as the identification of the
network control file location.  (The NCF location is written into the
pdoxusrs.lck file in a database directory.  All BDE sessions accessing
that database directory must be using the same NCF location.) The drive
letter is not considered.  This allows simplified setup systems where
the mapped drives cannot be the same letter.

If you use the root directory of mapped drives as the location, ie. f:\
or g:\, the BDE writes a null string '' (could a '\') into the
pdoxusrs.lck file.  It doesn't take much to see that when using an
incorrect drive for the NCF location, the BDE cannot see any difference.

Use a subdirectory with a name that is self-explanatory and unique in
the network.

--
Regards,
Chris Roberts

Re:Net Dir and Pdoxusrs.net


Michael,

  fwiw - I've worked with alot of different strategies for the PDOSUSER.NET
file.  The best solution I've come up with is to set the Session.NetDir
setting, during program startup,  to the directory where the program is
being run from.  This eliminates making sure that users have access to a
separate directory for the .NET file.   I also set the NetDir using a UNC
filename to eliminate any possible conflict with Drive Mappings. (only works
with 32 bit BDE of course)

This continues to work very well for me.  One caveat though,  this works at
runtime but causes problems when running the program from the IDE during
development.  I include code that checks if Delphi is running ...

Also,  it helps performance to set the PrivateDir to a directory on the
user's local drive and not on the network.

Steve

Quote
Michael Rittweger wrote in message <38041732.13540...@news.btx.dtag.de>...
>On Tue, 12 Oct 1999 03:04:29 GMT, BBus...@Nmpls.com (Brian Bushay
>TeamB) wrote:

>>Also it is not a good idea to use a root directory for the network control
file.

>Why?

>/\/\ichael

>--
>   * Michael Rittweger,  Nissenstr. 14,  24148 Kiel,  +49-431-7209360 *
>         2:240/2120 @ fidonet, +49-431-7209361 (Mailer, FAX, BBS)
>               <http://www.users.comcity.de/~zaphod>

Re:Net Dir and Pdoxusrs.net


Quote
"Steve McWhirter" <smcwh...@pheaa.org> wrote:
>  fwiw - I've worked with alot of different strategies for the PDOSUSER.NET
>file.  The best solution I've come up with is to set the Session.NetDir
>setting, during program startup,  to the directory where the program is
>being run from.  This eliminates making sure that users have access to a
>separate directory for the .NET file.   I also set the NetDir using a UNC
>filename to eliminate any possible conflict with Drive Mappings. (only works
>with 32 bit BDE of course)

Yes.  This works well.

Quote
>This continues to work very well for me.  One caveat though,  this works at
>runtime but causes problems when running the program from the IDE during
>development.  I include code that checks if Delphi is running ...

If you only develope one program at a time ;-) you can temporarily set
the BDE default NET DIR to your program directory.

--
Regards,
Chris Roberts

Other Threads