Rename-Computer error

This topic contains 5 replies, has 3 voices, and was last updated by Profile photo of barinv barinv 3 years, 1 month ago.

  • Author
    Posts
  • #13754
    Profile photo of barinv
    barinv
    Participant

    Trying to rename a remote computer how I get the error
    "Cannot establish the WMI connection to the computer 'computer' with the following error message: Not Found."

    I am specifying domain creds

    I can ping remote computer

    I am able to use Get-WmiObject on the same remote computer without a problem.

  • #13817
    Profile photo of Robert Westerlund
    Robert Westerlund
    Participant

    Is the name of the remote computer actually "computer", have you replaced it before posting or have you provided the wrong computer name to the Cmdlet?

  • #13818
    Profile photo of Richard Siddaway
    Richard Siddaway
    Moderator

    You need admin level access to rename the computer. Do your credentials supply the correct level of access. Can you post the code you are using?

  • #13819
    Profile photo of barinv
    barinv
    Participant

    I'm using the command

    Rename-Computer -ComputerName ret-hurt -NewName retline-3 -DomainCredential domain\admin

    I'm using domain admin credentials

    Thanks for your help!

  • #13833
    Profile photo of Richard Siddaway
    Richard Siddaway
    Moderator

    According to you initial post you can connect to the remote computer using Get-WmiObject – that means you have a DCOM connection

    When you ping the remote machine – is it by IP address or name?

  • #13848
    Profile photo of barinv
    barinv
    Participant

    when I ping it is by name

You must be logged in to reply to this topic.