SQL Server – Connection Port

-- Read the errorlog with a stored procedure

EXEC xp_ReadErrorLog 0, 1, N'Server is listening on', N'any', NULL, NULL, 'DESC'
GO

Or look in the Configuration Manager  

SQL Server Network Configuration/Protocols/IP Addresses/TCP Port

SCOM Notes

scxadmin commands:

Usage: scxadmin
Generic options (for all commands)
  [-quiet]      Set quiet mode (no output)

        General Options
scxadmin -version

        Service Management
scxadmin {-start|-stop|-restart|-status}  [all|cimom|provider]

        Providers Management
scxadmin -config-list {RunAs}
scxadmin -config-set {RunAs} {CWD=|ChRootPath=|AllowRoot={true|false}}
scxadmin -config-reset {RunAs} [CWD|ChRootPath|AllowRoot]

        Log Configuration Management
scxadmin {-log-list|-log-rotate|-log-reset} [all|cimom|provider]
scxadmin -log-set [all|cimom|provider] {verbose|intermediate|errors}
scxadmin -log-set provider {{FILE:|STDOUT}:={SUPPRESS|ERROR|WARNING|INFO|TRACE|HYSTERICAL}}
scxadmin {-log-reset|-log-remove} provider [{FILE:|STDOUT}]

Powershell – Concatenate files

Example: To concatenate all .txt files in directory C:\temp and store result in outfile.txt

$ToNatural = { [regex]::Replace($_, '\d+', { $args[0].Value.PadLeft(20) }) }

if (Test-Path "C:\temp\outfile.txt") {
    Remove-Item "C:\temp\outfile.txt"
}

Get-ChildItem "C:\temp" -Filter *.txt|sort-object $ToNatural | `
Foreach-Object{
  Write-Host $_
  #Get-Content $_ >> C:\temp\outfile.txt
}