In high-density commercial enterprise environments—such as corporate call centers, trading floors, university computer labs, and multi-tenant office complexes—multiple workstations often share identical IP subnets while physically residing in different offices, cubicle clusters, or secure rooms. When an employee dials an emergency number (such as 911 in North America or 112 across Europe) from a Microsoft Teams desk phone or desktop PC, emergency dispatchers must receive pinpoint, room-specific dispatch information rather than a general building address.
Under statutory public safety mandates including the RAY BAUM’S Act, enterprises are legally required to provide dispatchable physical locations for all fixed wired telephony endpoints. Within Microsoft Teams Phone, the highest level of physical location precision is achieved through Network Switch Port mapping in the Location Information Service (LIS). By mapping individual Ethernet switch port IDs directly to granular sub-location IDs using the CsOnlineLisPort cmdlets in PowerShell, telephony administrators guarantee exact room-level dispatch accuracy across enterprise campus networks.
Architecture of Switch Port Dynamic Emergency Calling
When an emergency call is placed from a wired Microsoft Teams client or native Teams IP desk phone, the endpoint queries the local network adapter to capture Link Layer Discovery Protocol (LLDP) or Cisco Discovery Protocol (CDP) advertisements transmitted by the upstream access switch.
From these discovery packets, the Teams client extracts two distinct hardware identifiers:
- Chassis ID: The standardized MAC address representing the physical switch chassis or stack.
- Port ID: The specific physical port identifier advertised by the switch interface (e.g.
GigabitEthernet1/0/14,1/1/24, or interface description string).
The client correlates both the Chassis ID and Port ID against the LIS topology database. Because port mapping resides at the top of the LIS precedence hierarchy, an exact Chassis-and-Port match immediately overrides switch-level, Wi-Fi, and subnet-level emergency address mappings, providing room-level and cubicle-level dispatchable addresses.
Connecting to the Microsoft Teams PowerShell Module
Configuring LIS port associations requires administrative credentials with Teams Administrator or Global Administrator roles and the Microsoft Teams PowerShell module (version 4.0.0 or later).
Launch an elevated PowerShell console and establish a connection:
# Install or update the Microsoft Teams module
Install-Module -Name MicrosoftTeams -Force -AllowClobber
# Authenticate to the Microsoft 365 tenant
Connect-MicrosoftTeams
Identifying Switch Chassis IDs, Port IDs, and Location Identifiers
Before configuring port mappings, collect the network identifiers from your enterprise switch management platform (such as Cisco DNA Center, Aruba Central, or ExtremeCloud IQ):
- Chassis ID: Standard hexadecimal MAC address notation (e.g.
00-1B-D7-89-0A-11). - Port ID: The exact string advertised in the LLDP Port ID TLV. To verify what your switch advertises, check the switch console (e.g.
show lldp interface gigabitEthernet 1/0/14). Common formats include interface names (Gi1/0/14) or port numbers (14).
Next, query the Teams LIS database to retrieve the target LocationId GUID representing the exact office or cubicle:
Get-CsOnlineLisLocation | Format-Table LocationId, Location, CivicAddressId, CompanyName
To isolate the specific room or desk location:
$TargetLoc = Get-CsOnlineLisLocation | Where-Object { $_.Location -like "*Room 304 - Desk 12*" }
$TargetLocationId = $TargetLoc.LocationId
$TargetLocationId
Creating LIS Switch Port Mappings with Set-CsOnlineLisPort
In Microsoft Teams PowerShell, the Set-CsOnlineLisPort cmdlet is used to create new switch port records or update existing associations.
To map an individual Ethernet port on a specific switch chassis to the target location, run:
Set-CsOnlineLisPort `
-ChassisId "00-1B-D7-89-0A-11" `
-PortId "GigabitEthernet1/0/14" `
-LocationId $TargetLocationId `
-Description "IDF-Floor3-Switch1-Port14-Room304"
If the upstream switch advertises raw numeric port identifiers in its LLDP packets instead of full interface names, match the Port ID string exactly as transmitted:
Set-CsOnlineLisPort `
-ChassisId "00-1B-D7-89-0A-11" `
-PortId "14" `
-LocationId $TargetLocationId `
-Description "IDF-Floor3-Switch1-Port14"
Bulk Provisioning Switch Ports from a CSV Template
In enterprise facilities with hundreds or thousands of wired ports, provisioning individual ports manually is impractical. Automate deployment by importing port mapping data from a structured CSV file.
Create a CSV file (e.g. C:\LisData\SwitchPorts.csv) with the following headers:
ChassisId,PortId,LocationId,Description
00-1B-D7-89-0A-11,GigabitEthernet1/0/1,d1e2f3a4-b5c6-7890-abcd-1234567890ab,Bldg 2 - Flr 3 - Office 301
00-1B-D7-89-0A-11,GigabitEthernet1/0/2,d1e2f3a4-b5c6-7890-abcd-1234567890ab,Bldg 2 - Flr 3 - Office 302
00-1B-D7-89-0A-11,GigabitEthernet1/0/3,e2f3a4b5-c6d7-8901-bcde-2345678901bc,Bldg 2 - Flr 3 - Conference A
Execute the bulk import script in PowerShell:
$PortList = Import-Csv -Path "C:\LisData\SwitchPorts.csv"
foreach ($Port in $PortList) {
Write-Host "Provisioning Port: $($Port.PortId) on Switch: $($Port.ChassisId)"
Set-CsOnlineLisPort `
-ChassisId $Port.ChassisId `
-PortId $Port.PortId `
-LocationId $Port.LocationId `
-Description $Port.Description
}
Inspecting and Auditing Active LIS Port Configurations
To view all switch port mappings currently registered in your Microsoft 365 tenant, execute:
Get-CsOnlineLisPort | Format-Table ChassisId, PortId, LocationId, Description
To inspect a single port record in detail:
Get-CsOnlineLisPort -ChassisId "00-1B-D7-89-0A-11" -PortId "GigabitEthernet1/0/14" | Format-List *
To cross-reference configured ports with their human-readable civic address and location descriptions, combine query outputs:
$AllLocations = Get-CsOnlineLisLocation
Get-CsOnlineLisPort | Select-Object ChassisId, PortId, Description, @{
Name = "ResolvedLocation"
Expression = { ($AllLocations | Where-Object { $_.LocationId -eq $_.LocationId }).Location }
} | Format-Table -AutoSize
Modifying and Decommissioning LIS Switch Port Records
When network patching changes or office layouts are reconfigured, keep the LIS database synchronized to prevent emergency responders from being dispatched to the wrong room.
To reassign an existing switch port to a new office location GUID:
Set-CsOnlineLisPort `
-ChassisId "00-1B-D7-89-0A-11" `
-PortId "GigabitEthernet1/0/14" `
-LocationId $NewLocationId `
-Description "Re-patched to Office 308"
To remove a decommissioned or reassigned switch port record permanently:
Remove-CsOnlineLisPort `
-ChassisId "00-1B-D7-89-0A-11" `
-PortId "GigabitEthernet1/0/14" `
-Confirm:$false
Validating Location Resolution on Wired Endpoints
After creating LIS port associations, allow replication to complete across Microsoft 365 services.
To test and verify location resolution on a wired client workstation:
- Connect the workstation via Ethernet to the mapped switch port.
- Ensure LLDP transmit is enabled on the switch interface (e.g.
lldp transmitandlldp receive). - On the client PC, verify that the network adapter is active and receiving LLDP frames.
- Launch or restart the Microsoft Teams desktop client.
- Navigate to the Calls tab. Below the dial pad, the dynamic location display should reflect the exact room, desk, or office mapped to the switch port.
- If an older subnet or building fallback appears, click the location text to trigger an immediate LIS client cache refresh.