in reply to Win32::TieRegistry and Connect Method Errors

Sorry that I don't have time right now for a more thorough answer.

Unfortunately, I don't think I ever found a clear-cut explanation for when you might get "Overlapped I/O operation is in progress". But I strongly suspect that the problem is one of authentication.

Before trying to connect to the remote registry, authenticate with the remote server either with something hackish like:

system("net use \\\\$Machine\\\$IPC"); #or, to be more eplicit (and get prompted for your password): system("net use \\\\$Machine\\\$IPC /user:domain\\you *");
or using Win32::NetResource's AddConnection().

There are also cases where SMB authentication will fail when using a computer name. So you might try using an IP address in $Machine instead.

                - tye

Replies are listed 'Best First'.
Re: Re: Win32::TieRegistry and Connect Method Errors (authenticate)
by Anonymous Monk on Nov 12, 2003 at 21:53 UTC

    That's why I posted here, there is no clear cut reason for the error :{ In fact most of the info I found relating to that error related to some bug in IE3 :}

    There is possibly some other processes on the machines that are causing the errors but my indication that it was Win2K specific was based on tests of about a dozen machines here.

    I am not using threading or forking, it's a monolithic program.

    I've seen hints at suggestions of trying to authenticate to the machine before trying the Registry operation and I'll try running the program as the Domain Admin and see if that helps.

    Now that I've been pointed down the authentication track, it makes sense to connect as a power user (domain Admin or such) to the machines.

    With WMI, I can specify the user to connect as (Domain Admin) but with the registry probe, I'm attemtping to connect as an ordinary user.

    Thanks for the suggestions!

    Kakaze

Re: Re: Win32::TieRegistry and Connect Method Errors (authenticate)
by kakaze (Sexton) on Nov 13, 2003 at 09:51 UTC

    I don't know if there is an explicit need to connect to \\Machine\IPC$ since I just connect to the machine (see the post below).

    Perhaps the more enlightened can tell me why it would be advantageous to connect directly to the IPC?

    Also, it's IPC$ and not $IPC :).

      C:\>net use \\fs01 [...] D:\Callwave\Shared\IOCP>net use [...] OK \\fs01\IPC$ [...]

      Yes, newer versions of "net use" fill in the $IPC for you. I doubt anyone is still using "older" versions so there is no advantage.

                      - tye