Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Powershell services detail listing

Posted on 2014-01-13
2
Medium Priority
?
297 Views
Last Modified: 2014-01-13
Hello Experts,

I am looking for a PS script allowing me to list services running on a server farm. Ideally the output CSV should say Service Name, Status, Startup Type, Log on As.

Many thanks for your help.
0
Comment
Question by:08519826
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 40

Accepted Solution

by:
Subsun earned 2000 total points
ID: 39776293
User the following code.. you can input the server names in C:\server.txt file..
Get-Content C:\server.txt | %{
	Get-WmiObject Win32_Service -ComputerName $_ | 
	Select __SERVER,Name,StartMode,State,StartName} | 
Export-Csv C:\report.csv -nti

Open in new window

0
 

Author Comment

by:08519826
ID: 39776311
It works perfectly. Thank you very much
0

Featured Post

Looking for the Wi-Fi vendor that's right for you?

We know how difficult it can be to evaluate Wi-Fi vendors, so we created this helpful Wi-Fi Buyer's Guide to help you find the Wi-Fi vendor that's right for your business! Download the guide and get started on our checklist today!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This script can help you clean up your user profile database by comparing profiles to Active Directory users in a particular OU, and removing the profiles that don't match.
In previous parts of this Nano Server deployment series, we learned how to create, deploy and configure Nano Server as a Hyper-V host. In this part, we will look for a clustering option. We will create a Hyper-V cluster of 3 Nano Server host nodes w…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question