Blackberry Powershell script to retart services

Wrote me first PowerShell script. It recycles Blackberry Services in the proper order according to Blackberry support docs. Enjoy!



Get-Service Blackberry* | Stop-Service
Start-Service "Blackberry Router"
Start-Service "Blackberry Dispatcher"
Start-Service "Blackberry Controller"
Get-Service Blackberry* -Exclude "Blackberry Database Consistency Service" | Where-Object {$_.Status -eq "Stopped"} | Start-Service
Good luck to all!

Comments

  • astorrsastorrs Member Posts: 3,139 ■■■■■■□□□□
    HeroPsycho wrote:
    Wrote me first PowerShell script. It recycles Blackberry Services in the proper order according to Blackberry support docs. Enjoy!



    Get-Service Blackberry* | Stop-Service
    Start-Service "Blackberry Router"
    Start-Service "Blackberry Dispatcher"
    Start-Service "Blackberry Controller"
    Get-Service Blackberry* -Exclude "Blackberry Database Consistency Service" | Where-Object {$_.Status -eq "Stopped"} | Start-Service
    The simplicity and clarity of PowerShell is gorgeous isn't it... Saved and filed for future use, thanks. icon_cool.gif
  • dynamikdynamik Banned Posts: 12,312 ■■■■■■■■■□
    So you explicitly started those services in the middle because they need to be started in a specific order? Then the last line starts all the others (except from the consistency service) because the order of those doesn't matter? I'm haven't really delved into Powershell, and I'm not familiar with Blackberry services. I'm just trying to figure out what's going on :D
  • HeroPsychoHeroPsycho Inactive Imported Users Posts: 1,940
    dynamik wrote:
    So you explicitly started those services in the middle because they need to be started in a specific order? Then the last line starts all the others (except from the consistency service) because the order of those doesn't matter? I'm haven't really delved into Powershell, and I'm not familiar with Blackberry services. I'm just trying to figure out what's going on :D

    Aye, matey! YAAAAAAAAAAAAAAAAAAAAAAAAR!
    Good luck to all!
Sign In or Register to comment.