Move Mailbox to Office 365 with PowerShell

Refer to the steps below on how to Move Mailbox to Office 365 with PowerShell Prepare a csv file EmailAddress uat5@aventislab.com uat6@aventislab.com The header for this column must be named EmailAddress Assign Office 365 License to all users listed in the CSV file #Assign License $Users = Import-Csv “C:\Temp\MailboxToMigrate.csv” $AccountSKU = Get-MsolAccountSku | ? AccountSkuID …

Read moreMove Mailbox to Office 365 with PowerShell

Assign Office 365 License with PowerShell

Please refer to the steps below on how to assign office 365 license with powershell List all the ServicePlan for E3 #Office 365 License for E3 Get-MsolAccountSku | Where-Object {$_.SkuPartNumber -eq ‘ENTERPRISEPACK’} | ForEach-Object {$_.ServiceStatus} ServicePlan ProvisioningStatus ———– —————— BPOS_S_TODO_2 Success FORMS_PLAN_E3 Success STREAM_O365_E3 Success Deskless Success FLOW_O365_P2 Success POWERAPPS_O365_P2 Success TEAMS1 Success PROJECTWORKMANAGEMENT Success …

Read moreAssign Office 365 License with PowerShell

PowerShell to Provision User Account in AD

Refer to the steps on how to use powershell to provision user account in AD for lab testing purpose #Create a New OU $OU = “UAT” New-ADOrganizationalUnit -Name $OU #Parameter for New Users $Path = Get-ADOrganizationalUnit -Filter {Name -eq $OU} $User = “UAT” $UPN = “aventislab.com” $LastName = “TEST” $Password = “P@ssw0rd!@#$” #To create 10 …

Read morePowerShell to Provision User Account in AD

Provision a Single Exchange 2016 with PowerShell

Steps to provision a Single Exchange 2016 with PowerShell Prepare a Windows 2016 Standard Server with Servicing stack update 2018-11 Cumulative Update-KB4467691 – Download the latest Cumulative from Microsoft Unified Communications Managed API 4.0 Runtime Visual C++ Redistributable Packages x64 Exchange 2016 CU9 Enable PreRequisite #Install PreRequisite Install-WindowsFeature NET-Framework-45-Features, RPC-over-HTTP-proxy, RSAT-Clustering, RSAT-Clustering-CmdInterface, RSAT-Clustering-Mgmt, ` RSAT-Clustering-PowerShell, …

Read moreProvision a Single Exchange 2016 with PowerShell

Generate SSL Certificate with PowerShell

Steps to Generate SSL Certificate with PowerShell Replace the $CommonName & $SANNames with your own FQDN to be included in SSL Certificate #Prepare CSR File with SAN $CommonName = “webmail.aventislab.com” $SANNames = @(“autodiscover.aventislab.com”,”mail.aventislab.com”) $Date = (Get-Date).ToString(‘ddMMyyyy’) $ReqFile = “Cert_Req-$CommonName-” + “$Date” + “.csr” $InfFile = @” [NewRequest] Subject = “CN=$CommonName” KeySpec = 1 KeyLength = …

Read moreGenerate SSL Certificate with PowerShell

Extend Layer2 Network Across Data Center with FortiGate VXLAN

I had prepared a lab to study the concept of how to Extend Layer2 Network Across Data Center with FortiGate VXLAN What is VXLAN Virtual eXtensible LAN (VXLAN – RFC7348) act as Layer 2 virtual networks over Layer 3 physical networks to stretch Layer 2 networks. It uses MAC Address-in-User Datagram Protocol (MAC-in-UDP) encapsulation. The …

Read moreExtend Layer2 Network Across Data Center with FortiGate VXLAN

Install PowerShell Core with PowerCLI on ubuntu 18.04

Steps to install PowerShell Core with PowerCLI on ubuntu 18.04 Switch to root and install PowerShell Core #Switch to root su – # Download the Microsoft repository GPG keys wget -q https://packages.microsoft.com/config/ubuntu/18.04/packages-microsoft-prod.deb # Register the Microsoft repository GPG keys sudo dpkg -i packages-microsoft-prod.deb # Update the list of products sudo apt-get update # Install PowerShell …

Read moreInstall PowerShell Core with PowerCLI on ubuntu 18.04

Sample Preventive Maintenance Reports with PowerCLI

Refer to the list of Sample Preventive Maintenance Reports with PowerCLI Connect to vCenter with PowerCLI #Import VMware Module Import-Module VMware.VimAutomation.Core $vCenter = “10.253.24.16” $User = “administrator@vsphere.local” $Password = “P@ssw0rd” Connect-VIServer -Server $vCenter -User $User -Password $Password -WarningAction SilentlyContinue To get hardware inventory for all VMware ESXi host $VMHosts = Get-VMHost Foreach ($VMHost in $VMHosts) …

Read moreSample Preventive Maintenance Reports with PowerCLI

PowerShell Script to Join AD Domain

PowerShell Script to Join AD Domain Verify DNS Server is configured correctly #Verify DNS Server $DNSServer= “192.168.1.200” if ((Get-DnsClientServerAddress -InterfaceAlias “Ethernet0” -AddressFamily IPv4).ServerAddresses -eq $DNSServer) { Write-Host -ForegroundColor Green “DNS Server is” $DNSServer } else { Set-DnsClientServerAddress -InterfaceAlias “Ethernet0” -ServerAddresses $DNSServer } Prepare an AES Key file to encrypt the Password for Domain Administrator and …

Read morePowerShell Script to Join AD Domain