次の方法で共有


3.3.5.8 Receiving a RequestElection Frame

The RequestElection frame (as specified in section 2.2.3) MUST be sent whenever a browser client or server is unable to retrieve information that is maintained by the local master browser server. It also MUST be issued when a local master browser server receives a frame that indicates that another machine on the machine group also believes it is a local master browser server.

When a browser server receives a RequestElection frame, it MUST calculate its election criteria and update the Uptime value with the time difference, in seconds, between the current time and the BrowserServerUpTime, as specified in section 2.2.3.

The browser server MUST then compare its election criteria value with the election criteria value of the RequestElection frame as an unsigned 32-bit integer. If the browser server's election criteria is greater than the RequestElection frame, the browser server has "won" the election. If the browser server's election criteria is less than the RequestElection frame, the browser server has "lost" the election.

If the browser server's election criteria value is equal to the election criteria of the request frame, then the browser server MUST compare its Uptime field with the Uptime field of the RequestElection frame. If the browser server's Uptime value is greater than the Uptime value of the RequestElection frame, the browser server has "won" the election. If the browser server's Uptime value is less than the Uptime value of the RequestElection frame, the browser server has "lost" the election.

If the browser server's election criteria and Uptime are equal to the election criteria and Uptime of the Election Request, the browser server MUST compare its name with the name in the RequestElection frame. If the browser server's name is alphabetically less than the name in the RequestElection frame, the browser server has "won" the election. If the browser server's name is alphabetically greater than the name in the RequestElection frame, the browser server has "lost" the election.

If the browser server has "won" the election, the browser server MUST set Current Role to local master browser server. The browser server MUST disable advertising of the backup browser service as specified in [MS-SRVS] section 3.1.6.10, passing SV_TYPE_BACKUP_BROWSER as the input parameter, and MUST enable advertising of the master browser service as specified in [MS-SRVS] section 3.1.6.9, passing SV_TYPE_MASTER_BROWSER as the input parameter. The server SHOULD set the LocalMasterAnnouncement Timer Count to 0.<53>

The browser server MUST do the following:

  • Set its Election Transmission Count to 0.

  • Set its DomainAnnouncement Timer Count to 0.

  • Set its MasterAnnouncement Timer Count to 0.

  • Set its Election delay timer as shown in the following table.

     Browser role

     Election delay timer

    Local master browser

    100 ms

    Backup browser

    A pseudo-random number chosen from the range 200 ms to 600 ms

    Potential browser

    A pseudo-random number chosen from the range 800 ms to 3000 ms

In a domain environment, the master browser server SHOULD query the primary domain controller as described in [MS-ADOD] section 2.7.7.3.1. If the primary domain controller is successfully discovered, the master browser server SHOULD issue an I_BrowserrQueryOtherDomains request as specified in [MS-BRWSA] section 3.1.4.1 to the primary domain controller, and append each domain name received in the response to OtherDomains as described in [MS-WKST] section 3.2.6.2 WkstaAddOtherDomains Event. If the number of domain names in the response is greater than 0, the server SHOULD register the NetBIOS name <other domain name>[0x00] for each domain name in the response, and accept requests on that name as described in section 3.3.3. If either the primary domain controller cannot be discovered, or the call to the primary domain controller fails, the server MUST take no action with regards to OtherDomains and the election algorithm continues to execute.

If the master browser server is running on a machine with IsPrimaryDomainController set to TRUE, it MUST act as a domain master browser server for its subnet, as specified in section 3.4.

This election algorithm continues to execute as specified in section 3.3.6.

If the browser server has "lost" the election, the browser MUST stop its election delay timer and set Current Role to potential browser server; if it was previously the local master browser server, it MUST do the following:

  • It MUST disable advertising the service as specified in [MS-SRVS] section 3.1.6.10, passing SV_TYPE_MASTER_BROWSER as the input parameter.

    It MUST unregister the NetBIOS unique name <machine group>[0x1D] so that the winning browser server can successfully register it.

  • If IsDomainController is set to TRUE or AlwaysActAsDomainController is set to TRUE, the browser server MUST take on the backup browser role and MUST set Current Role to backup browser server.

  • If IsDomainController is set to FALSE and AlwaysActAsDomainController is set to FALSE, the browser server MUST take on the potential browser server role, and MUST set Current Role to potential browser server.

  • It MUST empty all elements in the Backup Browser List.