Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re^3: Win32API::Net::GetDCName returns error code 87 for remote servers

by BrowserUk (Patriarch)
on Mar 30, 2016 at 11:21 UTC ( [id://1159103]=note: print w/replies, xml ) Need Help??


in reply to Re^2: Win32API::Net::GetDCName returns error code 87 for remote servers
in thread Win32API::Net::GetDCName returns error code 87 for remote servers

According to this netbios names are padded to 15 (or maybe that is 16, somewhat confusing) characters with spaces.

My suggestion is to run the command nbstat command and see what it thinks the names are.


With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority". I knew I was on the right track :)
In the absence of evidence, opinion is indistinguishable from prejudice.
  • Comment on Re^3: Win32API::Net::GetDCName returns error code 87 for remote servers
  • Download Code

Replies are listed 'Best First'.
Re^4: Win32API::Net::GetDCName returns error code 87 for remote servers
by dt667 (Acolyte) on Mar 30, 2016 at 12:59 UTC

    nbtstat output:

    NAME Type Status --------------------------------------------- BW2012R2 <00> UNIQUE Registered TESTLAB <00> GROUP Registered BW2012R2 <20> UNIQUE Registered

    I tried padding the server string out to 15 and 16 characters using space with the same result.

      Take another look at https://technet.microsoft.com/en-us/library/cc738412(v=ws.10).aspx; in particular the bit that says:

      For example, when you attempt to connect to a computer called CORPSERVER, the NetBIOS name corresponding to the File and Printer Sharing for Microsoft Networks service on that computer is:

      CORPSERVER     [20]

      Note the use of spaces to pad the computer name. Before you can establish a file and print sharing connection, a TCP connection must be created. In order for a TCP connection to be established, the NetBIOS name "CORPSERVER     [20]" must be resolved to an IP address.

      Which suggests to me you need to include the numbers in brackets at the end also. Ie. "BW2012R2 <00>".

      The difference/meaning between your output containing <nn> and the example containing [nn] is something you'll have to resolve through trial and error.


      With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
      Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
      "Science is about questioning the status quo. Questioning authority". I knew I was on the right track :)
      In the absence of evidence, opinion is indistinguishable from prejudice.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1159103]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (2)
As of 2024-04-26 00:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found