#45021 - 2003-09-10 01:01 PM
Drive mappings disappears
|
Anonymous
Anonymous
Unregistered
|
Hi,
I am working with Active Directory and KiXTart v4.21 which enables all users to logon to the network by the logon script. Strange enough all drive mappings (which has been set up by USE command with KiXTart) disappears after a while. It is also noticed that the drive mappings shows a little red line in the Windows Explorer which I think means that the connection to the drive mapping has been lost anyhow. Is there someone who can help me out? I checked all boards already but I have only found information for Windows95 machines. All my machines are working with Windows 2000 Professional.
Thanks in advance!
|
|
Top
|
|
|
|
#45023 - 2003-09-10 01:18 PM
Re: Drive mappings disappears
|
Anonymous
Anonymous
Unregistered
|
Thanks, do you have any idea where I can set up the IIRC issue?
On the other hand why is it that the connections dispears? Is it a good idea to post my script?
|
|
Top
|
|
|
|
#45025 - 2003-09-10 02:33 PM
Re: Drive mappings disappears
|
Anonymous
Anonymous
Unregistered
|
$pbar.value = 15 $text.value = "Preparing your network mappings:"
$pbar.value = 16 $text.value = "Connecting drive: I" Use i: "\\bellid.com\dfsroot\public"
If @error<>0 AND $debug=1 $text.value = "Connecting drive I to \\bellid.com\dfsroot\public failed" Endif
$pbar.value = 18 $text.value = "Connecting drive: H" Use h: "\\s_rdam_ad_01\$usr$$"
If @error<>0 AND $debug=1 $text.value = "Connecting drive H to \\s_rdam_ad_01\$usr$$ failed" Endif
If ingroup("G_Dep_Services") $pbar.value = 20 If ($debug=0 or $debug=1) $text.value = "Connecting drive: F" Endif
$text.value = "Connecting drive: F" Use f: "\\andis03\apps"
If @error<>0 AND $debug=1 $text.value = "Connecting drive F to \\andis03\apps failed" $text.value = "Errorcode = @error" Endif
$pbar.value = 22 If ($debug=0 or $debug=1) $text.value = "Connecting drive: L" Endif
$text.value = "Connecting drive: L" Use l: "\\bellid.com\dfsroot\services$$"
If @error<>0 AND $debug=1 $text.value = "Connecting drive L to \\andis03\services$$ failed" $text.value = "Errorcode = @error" Endif
; ***************** ;Services people has to work with the same settings Copy "\\ANDIS03\Wincmd\wincmd.ini" "%windir%\Wincmd.ini" Endif
|
|
Top
|
|
|
|
#45027 - 2003-09-10 03:49 PM
Re: Drive mappings disappears
|
Skatterbrainz
Starting to like KiXtart
Registered: 2002-10-17
Posts: 172
Loc: Virginia, USA
|
On a similar issue, I have been trying to develop a function that will only map a drive if it's not already mapped, but will also accept an option "force-map" flag to remap if required. The domain is NT4 and all clients are either W2K or XP. The problem is that if the "force-map" is set and the drive is already mapped. The /DELETE option leaves the drive in a strange state. NET USE at the command windows shows "Unavailable" or "Disconnected" but that prevents the following USE from working.
code:
Function MapDrive($letter, $unc, Optional $force) Dim $fso, $drivemap, $sharename $fso = CreateObject("Scripting.FileSystemObject") If $fso $drivemap = $fso.GetDrive("$letter") If $drivemap $sharename = $drivemap.ShareName ? "...Already mapped: "+$letter+" to "+$sharename If $force = 1 ? "...Forced mapping: "+$letter+" to "+$unc USE "$letter" /DELETE Sleep 1 USE "$letter" "$unc" /PERSISTENT $drivemap = $fso.GetDrive("$letter") If $drivemap $MapDrive = 1 Else $MapDrive = 0 EndIf Else $drivemap = $fso.GetDrive("$letter") ? "...Already mapped: "+$letter+" to "+$drivemap.ShareName $MapDrive = 1 EndIf Else ? "...Mapping drive: "+$letter+" to "+$unc USE "$letter" "$unc" /PERSISTENT Sleep 0.5 $drivemap = $fso.GetDrive("$letter") If $drivemap $MapDrive = 1 Else $MapDrive = 0 EndIf EndIf EndIf $drivemap = 0 $fso = 0 EndFunction
$=MapDrive("U:", "\\vbcsr0001\e$\WebSites", 1) $=MapDrive("V:", "\\vb-svr-04\C$") $=MapDrive("X:", "\\vabsr0004\c$")
Anything in this code (above) that I've hosed up somewhere? If I'm reinventing the wheel, please point me to a better solution if possible? THanks!
_________________________
silence is golden, but duct tape is silver
|
|
Top
|
|
|
|
#45028 - 2003-09-10 04:00 PM
Re: Drive mappings disappears
|
Lonkero
KiX Master Guru
   
Registered: 2001-06-05
Posts: 22346
Loc: OK
|
|
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
1 registered
(Allen)
and 781 anonymous users online.
|
|
|