#163655 - 2006-06-26 01:57 PM
Drive mapping / server down / script hang - shouldn't something timeout?
|
myxiplx
Lurker
Registered: 2006-06-26
Posts: 2
|
This weekend our archive server died. Now that shouldn't have caused any problems but for some reason the network logon scripts mapping a drive to that server hung as staff logged on, and we found AutoCAD hung on file/open.
Ordinarily I'd expect something like the USE command to timeout after a short while if a share isn't available, but it appeared to hang the logon script completely this weekend. I didn't really pay a lot of attention, just rebooted things to clear the errors, but the script had certainly hung for long enough for the server to reboot, and I had to reboot the clients to clear the problem.
2 questions I'm struggling to answer right now:
- How does the USE command handle errors. Does it have a default timeout? - Are there any changes I can make to the scripts so they don't hang like this?
thanks,
Ross
|
|
Top
|
|
|
|
#163658 - 2006-06-26 10:01 PM
Re: Drive mapping / server down / script hang - shouldn't something timeout?
|
NTDOC
Administrator
   
Registered: 2000-07-28
Posts: 11634
Loc: Space
|
Well I think we need to see your code as I don't have that result.
Code:
Break On Dim $Start, $Stop, $Timeout 'KiXtart version is: ' + @KiX ? $Start = @TICKS 'Start time was: ' + $Start ? 'Will now try to map a bogus share that does not exist...' ? USE X: '\\BOGUS\NOTHERE' 'Error mapping drive was: ' + @ERROR + ' - ' +@SERROR ? $Stop = @TICKS $Timeout = ($Stop-$Start) 'Time out took ' + $Timeout ?
Produced this result for me.
Code:
KiXtart version is: 4.52 Release Candidate 2 Start time was: 506277843 Will now try to map a bogus share that does not exist... Error mapping drive was: 1203 - No network provider accepted the given network path. Time out took 2282 As you can see the timeout for me was under 3 seconds. Maybe some other issues going on there.
But this was NOT done within a LOGON script, it was done from a system that was already logged on.
|
|
Top
|
|
|
|
#163660 - 2006-06-26 10:12 PM
Re: Drive mapping / server down / script hang - shouldn't something timeout?
|
NTDOC
Administrator
   
Registered: 2000-07-28
Posts: 11634
Loc: Space
|
Quote:
LaBrea Tarpit
ROFLMAO - hehe... hmmm like a SAMBA connection trying to locate the proper Windows resources?
|
|
Top
|
|
|
|
#163664 - 2006-06-27 10:15 AM
Re: Drive mapping / server down / script hang - shouldn't something timeout?
|
Richard H.
Administrator
   
Registered: 2000-01-24
Posts: 4946
Loc: Leatherhead, Surrey, UK
|
Quote:
Well... trying to map to a non-existent name that it cannot resolve is not the same as trying to map to one it can resolve but behaves like a Tarpit.
True. If the server is not actually down then you may get this sort of problem, and there is not really a good solution.
The problem is that the server may be sufficiently active to accept any part of the drive mapping process and *then* block - something like a hung process which has set a kernel latch to protect an atomic operation.
As far as the client is concerned it has a valid and active connection, so it will not time out. If the client is in a system call it may not be possible to timeout even if you wanted to.
I think it's fair to say that this was an unusual situation so any sort of aberrant behaviour is possible.
|
|
Top
|
|
|
|
#163666 - 2006-06-27 11:10 AM
Re: Drive mapping / server down / script hang - shouldn't something timeout?
|
myxiplx
Lurker
Registered: 2006-06-26
Posts: 2
|
Yeah, server was still powered on and visible on the network, but explorer hung on my machine when I tried to connect to it... didn't get the 'share unavailable' message until after I rebooted it.
If exist() sounds like it's worth implementing anyway, but I'm gonna put this one down to a problem caused by the server crash rather than the logon script.
Thanks for all the feedback guys.
|
|
Top
|
|
|
|
Moderator: Arend_, Allen, Jochen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Mart
|
0 registered
and 2220 anonymous users online.
|
|
|