NetBackup – не видно баз для восстановления.

Unable to browse successfully backed up SQL Server Availability Group databases

Problem
Unable to browse successfully backed up SQL Server Availability Group (AG) databases. Only system and non-AG databases are listed in the NetBackup MSSQL Client when browsing for restores

Cause
An incorrect Client Name was specified in the “Restore SQL Server objects” dialog.

Solution
SQL Server AlwaysOn Availability Group (AG) databases are automatically backed up using the Windows Server Failover Cluster (WSFC) name. When browsing for AG database backups, change the Client Name from to the correct WSFC name, which is always a fully qualified domain name. The WSFC name can be found in Failover Cluster Manager or in the job details for the backup.

https://www.veritas.com/support/en_US/article.100046841

Найти отключенных в AD пользователей активных в SfB

If you’ve not been disabling users in Lync while disabling them in AD, here’s a one liner to find those users:

Get-CsAdUser -ResultSize Unlimited | Where-Object {$_.UserAccountControl -match “AccountDisabled” -and $_.Enabled -eq $true} | Format-Table Name,Enabled,SipAddress -auto

You can shorten it somewhat by not checking if $_.Enabled is $true, but just that it exists. You can get a count of the users using:

Get-CsAdUser -ResultSize Unlimited | Where-Object {$_.UserAccountControl -match “AccountDisabled” -and $_.Enabled} | Measure-Object

and, if you want, can disable them in one line using

view sourceprint?

Get-CsAdUser -ResultSize Unlimited | Where-Object {$_.UserAccountControl -match “AccountDisabled” -and $_.Enabled} | Disable-CsUser

PowerShell: List All Subnets in Sites & Services

Как получить список всех подсетей в сайте AD.

Скрипт написан Джоном Догерти (John Dougherty)

PowerShell: List All Subnets in Sites & Services

## Get a list of all domain controllers in the forest
$DcList = (Get-ADForest).Domains | ForEach { Get-ADDomainController -Discover -DomainName $_ } | ForEach { Get-ADDomainController -Server $_.Name -filter * } | Select Site, Name, Domain

## Get all replication subnets from Sites & Services
$Subnets = Get-ADReplicationSubnet -filter * -Properties * | Select Name, Site, Location, Description

## Create an empty array to build the subnet list
$ResultsArray = @()

## Loop through all subnets and build the list
ForEach ($Subnet in $Subnets) {

$SiteName = “”
If ($Subnet.Site -ne $null) { $SiteName = $Subnet.Site.Split(‘,’)[0].Trim(‘CN=’) }

$DcInSite = $False
If ($DcList.Site -Contains $SiteName) { $DcInSite = $True }

$RA = New-Object PSObject
$RA | Add-Member -type NoteProperty -name “Subnet” -Value $Subnet.Name
$RA | Add-Member -type NoteProperty -name “SiteName” -Value $SiteName
$RA | Add-Member -type NoteProperty -name “DcInSite” -Value $DcInSite
$RA | Add-Member -type NoteProperty -name “SiteLoc” -Value $Subnet.Location
$RA | Add-Member -type NoteProperty -name “SiteDesc” -Value $Subnet.Description

$ResultsArray += $RA

}

## Export the array as a CSV file
$ResultsArray | Sort Subnet | Export-Csv -Encoding UTF8 .\AD-Subnets.csv -nti

 

Netscaler VPX – лицензионный лимит пропускной способности (проверка)

If you have a Netscaler VPX with let’s say a 1000 Mbps bandwidth limit (due to Netscaler license), then any packets sent to Netscaler will be dropped if the current bandwidth throughput on Netscaler is already at 1000 Mbps. If below command doesn’t show any output then there have been no packet drops due to bandwidth cap recently.

# shell
# nsconmsg -K /var/nslog/newnslog -g nic_err_rl -d current -s disptime=1 | more

Дополнительная информация:
https://support.citrix.com/article/CTX232341

If licenses throughput is 500Mbps, then we can extract the real time throughput over 500 from newnslog. We can see that the real time throughput indeed over 500 sometimes . At the same time ,we can see that the heavy traffic is received from interface 0/2.

# nsconmsg -K newnslog -g mbits -d past -s disptime=1 -s ratecount=500 | more

We also can check whether there are packet dropped due to licensed throughput is reached

# nsconmsg -K newnslog -d current -g nic_err_rl_pkt_drops -s disptime=1

Find all domain controllers in domain

Получить список всех контроллеров домена.

Using powershell one can find all domain controllers in domain using:

1. a LDAP filter:

Get-ADComputer -LDAPFilter “(&(objectCategory=computer)(userAccountControl:1.2.840.113556.1.4.803:=8192))”

2. “Domain controllers” group and retreive his memebers:

Get-ADGroupMember ‘Domain Controllers’

3. Get-ADDomainController cmdlet:

Get-ADDomainController -Filter * | Select-Object name

SfB – ищем кому присвоен номер

SfB вернул “Filter failed to return unique result” при попытке назначить номер

Симптом:
Вы получаете следующее сообщение об ошибке при попытке присвоить номер телефона пользователю с включенным Enterprise Voice PowerShell или Lync Admin Web GUI:

Filter failed to return unique result, «[SipAddress : sip:ivan.ivanov@contoso.com] [LineURI : tel:+2222] [PrivateLine : tel:+2222] «

Решение :
Выполните команды ниже, чтобы найти кому этот номер определён.

Ищем номер телефона +2222
Users:
Get-CsUser | where {$_.LineURI -eq “tel:+2222” -or $_.PrivateLine -eq “tel:+2222”} | Sort-Object LineURI | Select-Object Displayname, LineURI, PrivateLine, Identity

Common Area Phone:

Get-CsCommonAreaPhone | where {$_.LineURI -eq “tel:+2222”} | Sort-Object LineURI | Select-Object Identity, LineURI, DisplayNumber, DisplayName, Description

Workflow:
Get-CsRgsWorkflow | where {$_.LineURI -eq “tel:+2222”} | Sort-Object LineURI | Select-Object Name, Identity, LineURI, DisplayNumber, Description

Exchange UM Contact:
Get-CsExUmContact | where {$_.LineURI -eq “tel:+2222”} | Sort-Object LineURI | Select-Object identity, LineURI

 

get-ummailbox | ForEach { If($_.Extensions -eq 4322){$.DisplayName}}

get-ummailbox | where { $_.Extensions -eq “45873” }

Get-Recipient -ResultSize Unlimited | where{$_.emailaddresses -like “*EUM:*2222*”} | fl displayname,emailaddresses