Question

  • Creator
    Topic
  • #2136628

    Not able to delete stale computer

    Locked

    by rgnambiar ·

    Hi,

    I am not able to delete the stale computer from my domain by using the below dsquery command.

    dsquery computer inactive 468 | dsrm noprompt

    Please help me out in deleting the stale computer

All Answers

  • Author
    Replies
    • #2904133

      Clarifications

      by rgnambiar ·

      In reply to Not able to delete stale computer

      Clarifications

    • #2904131

      9 Years?

      by glen.harris ·

      In reply to Not able to delete stale computer

      Hi,
      I’m not currently near a domain to try this but think the command should be:
      dsquery computer -inactive 468 | dsrm -noprompt
      where 468 represents 468 weeks of inactivity.

      • #2904130

        Reponse To Answer

        by rgnambiar ·

        In reply to 9 Years?

        Thanks for the reply. I did try that command, but i am getting an error stating that the dsrm command is not recognised. Yes i am looking out to delete the stale computers for 9 years.

    • #2904126

      You need to download RSAT

      by glen.harris ·

      In reply to Not able to delete stale computer

      (remote server administration tools) Go to microsoft dot com and type 7887 in the search box (Win 7 Version). Alternatively, remote desktop onto one of the domain controllers and run the command from there.

    • #2904064

      From technet

      by glen.harris ·

      In reply to Not able to delete stale computer

      Dsrm is a command-line tool that is built into Windows Server 2008. It is available if you have the Active Directory Domain Services (AD DS) or Active Directory Lightweight Directory Services (AD LDS) server role installed. To use dsrm, you must run the dsrm command from an elevated command prompt. To open an elevated command prompt, click Start, right-click Command Prompt, and then click Run as administrator.

      Not from technet:
      To add the server role go to Server Manager, click roles in the left pane, add roles in the right pane, click next then install.

      I would have thought that you’d already have the AD role installed on the server if it is a DC. AD can be dangerous if you don’t know what you are doing. Unless this is a test domain of some sort that you are experimenting with be very careful.

Viewing 3 reply threads