Powershell Computer Rename (Prompt)
Log In or Register to download the BES file, and more.

0 Votes


<enter a description of the task here>

Property Details

StatusBeta - Preliminary testing ready for more
TitlePowershell Computer Rename (Prompt)
SourceBrad Sexton
Source Release Date12/4/2018 12:00:00 AM
Keywordsrename computer, powershell, windows
Is TaskTrue
Added by on 2/12/2019 9:51:50 AM
Last Modified by on 2/12/2019 9:51:50 AM
Counters 355 Views / 5 Downloads
User Rating 1 star 2 star 3 star 4 star 5 star * Average over 0 ratings. ** Log In or Register to add your rating.


Used in 361 fixlets   * Results in a true/false
Show indented relevance
(if( name of operating system starts with "Win" ) then platform id of operating system != 3 else false) AND (if exists property "in proxy agent context" then ( not in proxy agent context ) else true )


Action 1 (default)

Action Link Click here to deploy this action.
Script Type BigFix Action Script
// Disable wow64 redirection on x64 OSes
action parameter query "PC-Name" with description "Please enter the new PC name"

action uses wow64 redirection {not x64 of operating system}

delete __createfile

createfile until END_OF_FILE

$computerName = Get-WmiObject Win32_ComputerSystem
$computername.Rename("{parameter "PC-Name" of action}")

get-help | Out-File "{(pathname of folder "__BESData\__Global\Logs" of parent folder of client)}\config_powershell.log"


delete powershell.ps1
move __createfile powershell.ps1

waithidden { pathname of file ((it as string) of value "Path" of key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell" of native registry) } -ExecutionPolicy unrestricted -File powershell.ps1
Success Criteria

This action will be considered successful when the applicability relevance evaluates to false.


Social Media:
Share this page on Yammer


Log In or Register to leave comments!