Collaborate without boundaries

Office 365 Password Expiry

Office 365 Password Expiry

  • 4 Followers
  • 4 Replies |
  • This post has 1 verified answer |
Answered (Verified) This question is answered

Hi

 

I received a prompt today regarding the expiry of my password. I don't want to change the password and as there is only the two of us I don't feel the risks warrant the changes.

 

I found a post in one of the Lync forums that gave instructions as to how to change the settings using Powershell. I've followed the instructions, entering the administrative username and password when prompted and the commands have seemed to have been accepted (no error messages) but there wasn't any confirmation message either.

 

This is the commands from Powershell. Is there anyway for me to tell whether the change I have made to my settings have been succesfull or not?

 

PS C:\Windows\system32> $LiveCred = Get-Credential

cmdlet Get-Credential at command pipeline position 1
Supply values for the following parameters:
Credential
PS C:\Windows\system32> connect-MSOLService -Credential $cred
PS C:\Windows\system32> Get-MSOLUser | Set-MSOLUser -PasswordNeverExpires $true
PS C:\Windows\system32>

 

Thanks

 

Tom

 

 

  

    1 out of 1 people found this post helpful.

Verified Answer
  • Hi Tomg35,

    If you want to verify that the settings, you can run the following command from Poweshell.

    After you have connected to MSol as in your example above type the following to verify the setting are set to $true

    Get-Msoluser -UserPrincipalName <You Login ID> | fl

    Dan Rose

    Cogmotive Reports | Office 365 Reporting and Analytics

    • Not Ranked
All Replies
  • Brilliant - Thanks you

    • Top 500 Contributor
  • Hi

    When I use..

    connect-MSOLService -Credential $cred

    I get

    PS C:\Users\admin> connect-MSOLService -Credential $cred

    The term 'connect-MSOLService' is not recognized as the name of a cmdlet, function, script file, or operable program. C

    heck the spelling of the name, or if a path was included, verify that the path is correct and try again.

    At line:1 char:20

    + connect-MSOLService <<<<  -Credential $cred

       + CategoryInfo          : ObjectNotFound: (connect-MSOLService:String) [], CommandNotFoundException

       + FullyQualifiedErrorId : CommandNotFoundException

    • Not Ranked
  • Hi Rob,

    This issue can be caused if you are running Windows PowerShell for Exchange Online instead of Microsoft Online Services Module for Windows PowerShell. Given this situation, please download and install Microsoft Online Services Module for Windows PowerShell from http://onlinehelp.microsoft.com/en-US/office365-enterprises/hh124998.aspx. After that, try to run the cmdlet again.

    If the issue persists, I suggest you create a new thread for this issue, so that we can dig deeper on this issue.

    Thanks,
    Mindy Pan

     

    • Top 10 Contributor
Page 1 of 1 (5 items)