Get started with SharePoint Online Management Shell
https://docs.microsoft.com/en-us/powershell/sharepoint/sharepoint-online/connect-sharepoint-online
Get-Module -Name Microsoft.Online.SharePoint.PowerShell -ListAvailable | Select Name,Version
Install-Module -Name Microsoft.Online.SharePoint.PowerShell
Install-Module -Name Microsoft.Online.SharePoint.PowerShell -Scope CurrentUser
Update-Module -Name Microsoft.Online.SharePoint.PowerShell
Connect-SPOService -Url https://sreekanth1-admin.sharepoint.com -Credential admin@contoso.com #For Non-MFA
Connect-SPOService -Url https://sreekanth1-admin.sharepoint.com #For MFA
Start-SPOSiteRename -Identity https://sreekanth1.sharepoint.com/sites/SreekanthOrganization1 -NewSiteUrl https://sreekanth1.sharepoint.com/sites/SreekanthOrganization2 -ValidationOnly
Start-SPOSiteRename -Identity https://sreekanth1.sharepoint.com/sites/SreekanthOrganization1 -NewSiteUrl https://sreekanth1.sharepoint.com/sites/SreekanthOrganization2
Remove-SPOSite -Identity https://sreekanth1.sharepoint.com/sites/SreekanthOrganization1
===
Fix “Connect-SPOService : The term ‘Connect-SPOService’ is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.” Error
1. You can download and install SharePoint Online Management Shell to your client machine:
https://www.microsoft.com/en-us/download/details.aspx?id=35588
follow below steps:
1. Navigate to “C:\Windows\Microsoft.NET\assembly\GAC_MSIL”
2. Select all folders starting with name “Microsoft.SharePoint.Client” and delete them all!
3. Finally, Install the PowerShell Module for SharePoint Online: Install-Module Microsoft.Online.SharePoint.PowerShell -force
for more details:
Get-Module -Name Microsoft.Online.SharePoint.PowerShell -ListAvailable | Select Name,Version
Install-Module Microsoft.Online.SharePoint.PowerShell
Uninstall-Module -Name Microsoft.Online.SharePoint.PowerShell -AllVersions -Force
===