Home Data Center Finding Service with Account Name Using Microsoft PowerShell V1.0

Finding Service with Account Name Using Microsoft PowerShell V1.0

0
Finding Service with Account Name Using Microsoft PowerShell V1.0
0

A few months back, I worked on a project where the customer needed to find all services on all servers that used a specific Active Directory (AD) account name. The problem was, they had no idea how the account name had been entered, nor did they know which server or what service used the account. I created a hard-coded script to search all computers in Active Directory for a partial account name. I finally made the time to make the script more useful and generic.

By default, the script requires an account name and will search all computers in AD that have “server” in the OperatingSystem property. The parameter, -AccountName, will have “*” added before and after the name. For example, entering “ctx” will cause the script to search all services for “*ctx*”. This will find [email protected], domainsvc_ctxaccount, and domain.tldsvc_ctxaccount.

Using -LiteralAccountName causes the script to use the account name entered exactly as typed. For example, -LiteralAccountName “[email protected]” will look for only that specific account name. The script will not search for domainsvc_ctxaccount or domain.tldsvc_ctxaccount.

Read the entire article here, Finding Service with Account Name Using Microsoft PowerShell V1.0

via Carl Webster

Categories:
Carl Webster Carl Webster is a Sr. Solutions Architect for Choice Solutions, with over 38 years of IT experience, based in the Nashville, TN area. Webster has been working with application and desktop virtualization since 1990 and with Active Directory since 2001. Webster travels the world doing XenApp, XenDesktop, HP Moonshot and Active Directory projects. He holds the prestigious Citrix Technology Professional designation.

Featured Resources:

Related Articles:

| LATEST FEATURED RESOURCES

White Papers

    Application Lifecycle Management with Stratusphere UX – White Paper

    Enterprises today are faced with many challenges, and among those at the top of the list is the struggle surrounding the design, deployment, management and operations that support desktop applications. The demand for applications is increasing at an exponential rate, and organizations are being forced to consider platforms beyond physical, virtual and cloud-based environments. Users […]

    Downloads

      Download Commvault VM Backup and Recovery: end-to-end VM backup, recovery and cloud management

      Commvault’s ability to provide end-to-end VM backup, recovery and cloud management creates a significantly better way to build, protect and optimize VMs throughout their lifecycle. Our best-in-class software for VM backup, recovery and cloud management delivers a number of significant benefits, including: VM recovery with live recovery options; backup to and in the cloud; custom-fit […]

      On-Demand Webinars

        What’s Going on in EUC Printing – A Technical Deep Dive!

        The IGEL Community and ThinPrint invite you to watch the following technical deep dive webinar. The agenda is to technically bring you up to speed on what’s going on in the EUC Printing space today along with a deep dive into new methods, technologies, printing scenarios and a discussion on why printing still matters. You […]

        Latest Videos

          Views All IT News on DABCC.com
          Views All IT Videos on DABCC.com
          Win big $$, visit ITBaller.com for more info!

          Visit Our Sponsors

          Close