Attaching to DFS shares from client via login script

G

Guest

I have stumbled across a problem that was hidden for some time because some
fool used the 'On Error Resume Next' VBScript command in our login script.
The problem is as follows (apologies if this isn't the best place to post
this):

The 'MapNetworkDrive' VBScript command is used to map all regular and dfs
network shares. I am receiving an error when try to map a drive to any of our
DFS links saying that the network location cannot be found. The command is as
follows:

WSHNetwork.MapNetworkDrive "x:", "\\<domain_fqdn>\<dfsroot>\<share>"

I know DFS Referals are working because I can enter the
"\\<domain_fqdn>\<dfsroot>\<share>" into the Run command in Windows XP.
However, from the login script I receive an error stating that the path
cannot be found.

Now, on the other hand I CAN use the NetBios domain name to map the through
the login script (also through the Run command):

WSHNetwork.MapNetworkDrive "x:", "\\<domain_netbios_name>\<dfsroot>\<share>"

This is weird. Perhaps the Windows Scripting Host is not clever enough to
work with the FQDN or perhaps there is a problem with the DFS root. I know
our DNS structure is problem free because NSLOOKUPs have returned the correct
information.

I decided to perform a "dfsutil /pktinfo" to query the DFS structure. Here's
the output:

******************* START *******************
--mup.sys--
9 entries...
Entry: \corp.mycompany.com\sysvol
ShortEntry: \corp.mycompany.com\sysvol
Expires in 0 seconds
UseCount: 0 Type:0x81 ( REFERRAL_SVC DFS )
0:[\serverpwh001dcs03.corp.mycompany.com\sysvol] State:0x29 ( )
1:[\serverpwh001dcs05.corp.mycompany.com\sysvol] State:0x39 ( ACTIVE )
2:[\serverPWH001DCS04.corp.mycompany.com\sysvol] State:0x29 ( )
3:[\serverFDC001DCS02.corp.mycompany.com\sysvol] State:0x29 ( )
4:[\serverFDC001DCS03.corp.mycompany.com\sysvol] State:0x29 ( )
5:[\serverrttaffdcs01.corp.mycompany.com\sysvol] State:0x29 ( )

Entry: \mycompany\dfs-shares
ShortEntry: \mycompany\dfs-shares
Expires in 0 seconds
UseCount: 0 Type:0x81 ( REFERRAL_SVC DFS )
0:[\serverPWH001FAP02\DFS-Shares] State:0x09 ( )
1:[\serverPWH001FAP03\DFS-Shares] State:0x19 ( ACTIVE )

Entry: \mycompany\dfs-shares\sophos sweep
ShortEntry: \mycompany\dfs-shares\sophos sweep
Expires in 0 seconds
UseCount: 0 Type:0x1 ( DFS )
0:[\serverPWH001FAP04\SOPHOS SWEEP$] State:0x31 ( ACTIVE )
1:[\serverPWH001FAP05\SOPHOS SWEEP$] State:0x21 ( )
2:[\serverIMP303FAP01\SOPHOS SWEEP$] State:0x21 ( )
3:[\serverNFC981DCS01\SOPHOS SWEEP$] State:0x21 ( )

Entry: \corp.mycompany.com\dfs-shares
ShortEntry: \corp.mycompany.com\dfs-shares
Expires in 0 seconds
UseCount: 0 Type:0x81 ( REFERRAL_SVC DFS )
0:[\serverPWH001FAP02\DFS-Shares] State:0x09 ( )
1:[\serverPWH001FAP03\DFS-Shares] State:0x19 ( ACTIVE )

Entry: \mycompany\dfs-shares\Enterprise Applications
ShortEntry: \mycompany\dfs-shares\Enterprise Applications
Expires in 0 seconds
UseCount: 0 Type:0x1 ( DFS )
0:[\serverPWH001FAP05\ENTERPRISE APPLICATIONS$] State:0x31 ( ACTIVE )
1:[\serverPWH001FAP04\ENTERPRISE APPLICATIONS$] State:0x21 ( )
2:[\serverRDH100FAP01\ENTERPRISE APPLICATIONS$] State:0x21 ( )
3:[\serversfc983dcs01\enterprise applications$] State:0x21 ( )
4:[\serverSLD945DCS01\Enterprise Applications$] State:0x21 ( )


Entry: \mycompany\dfs-shares\Application Installs
ShortEntry: \mycompany\dfs-shares\Application Installs
Expires in 0 seconds
UseCount: 0 Type:0x1 ( DFS )
0:[\serverPWH001NET01\LIVEAPPLICATIONS$] State:0x31 ( ACTIVE )
1:[\serverBAD903DCS01\LIVEAPPLICATIONS$] State:0x21 ( )
2:[\serverSCN711DCS01\LIVEAPPLICATIONS$] State:0x21 ( )
3:[\serverRCS865DCS01\LIVEAPPLICATIONS$] State:0x21 ( )


Entry: \mycompany\dfs-shares\XPImages
ShortEntry: \mycompany\dfs-shares\XPImages
Expires in 0 seconds
UseCount: 0 Type:0x1 ( DFS )
0:[\serverPWH001NET01\images$] State:0x31 ( ACTIVE )

Entry: \corp.mycompany.com\dfs-shares\Enterprise Applications
ShortEntry: \corp.mycompany.com\dfs-shares\Enterprise Applications
Expires in 360 seconds
UseCount: 0 Type:0x1 ( DFS )
0:[\serverPWH001FAP04\ENTERPRISE APPLICATIONS$] State:0x31 ( ACTIVE )
1:[\serverPWH001FAP05\ENTERPRISE APPLICATIONS$] State:0x21 ( )
2:[\serverNFC981DCS01\Enterprise Applications$] State:0x21 ( )
3:[\serverCOT153DCS02\Enterprise Applications$] State:0x21 ( )


Entry: \corp.mycompany.com\DFS-Shares2
ShortEntry: \corp.mycompany.com\DFS-Shares2
Expires in 420 seconds
UseCount: 0 Type:0x81 ( REFERRAL_SVC DFS )
0:[\serverPWH001NET02\DFS-Shares2] State:0x19 ( ACTIVE )

******************* END *******************

I can see that the SYSVOL structure has FQDNs for all Domain Controllers. I
read somewhere that if the DFS links are specified with their NETBIOS names,
rather than FQDNs, then you can only map a drive using the NETBIOS domain
name. Is this true? I makes no sense really because I can enter the path
using the FQDN into the Run command.

Does anyone have any advice to offer? Apologies for the length of this post.

Many thanks in advance.

Mark
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top