Troubleshoot computer problems with Service Manager tasks
If you want to view the logs on a remote computer that is exhibiting problems, you must first create a task that opens Event Viewer. Event Viewer reads logs from remote computers.
In Service Manager, administrators can create and use tasks to automate and simplify lengthy, complex, or repetitive processes. Operators typically use tasks to help troubleshoot user incidents. After creating a task, operators can run the task directly from the Service Manager console.
Important
To create a task, the logged-on user must have administrative credentials.
The Event Viewer task that you create will display logs from the computer that is identified as a configuration item in the incident. The help desk analyst can then select an incident in the Service Manager console and run this task for the computers that are related to the incident.
Create a task
Use the following procedures in Service Manager to create a task—for example, a task that you can use to open Event Viewer and view logs on a computer—and then validate the new task. Event Viewer displays the logs from the remote computer that is listed as a Configuration Item in the incident.
To create a task, follow these steps:
In the Service Manager console, select Library.
On the Library pane, expand Library, and select Tasks.
On the Tasks pane, select Create Task.
On the Before You Begin page, select Next.
On the General page, do the following:
In the Task name box, enter a name for the task. For example, enter Event Viewer.
Note
In this release, if you edit and change any of the properties of a task, you've to close and reopen the console before you can view the task.
Next to the Target class area, select the ellipsis button (...).
In the Choose Class dialog, in the Class list, select Incident, and select OK.
In the Management pack list, ensure that Service Manager Incident Management Configuration Library is selected, and select Next.
Note
In this release, if you select the option to create a new management pack, you've to close and reopen the console before you can view this task.
On the Display Task by Category page, select the category where the task will be displayed. For example, select Incident Management Folder Tasks, and select Next.
On the Command Line page, do the following:
In the Full path to command box, enter the full path of the command you want to run with this task. For example, enter %windir%\system32\eventvwr.exe.
In the Parameters area, select Insert Property.
In the Select Property dialog, in the Related classes list, expand Incident, and select Is Related to Configuration Item.
In the Available Properties box, enter Computer Name.
Under Windows Computer, select NetBIOS Computer Name, and select Add.
Optionally, select Log in action log when this task is run to add information to the incident action log when the task runs, and select Next.
On the Summary page, select Create.
On the Completion page, observe that The new task was created successfully appears, and select Close.
Validate a new task
In the Service Manager console, select Work Items.
In the Work Items pane, expand Work Items, expand Incident Management, and select All Incidents.
In the All Incidents pane, select an incident for which a computer name has been entered as a configuration item.
In the Tasks pane, under the name of the incident you selected in the previous step, select Event Viewer.
Notice that Event Viewer starts, and the events from the computer that are associated with the incident are displayed.
You can use the Get-SCSMTask Windows PowerShell command to view Service Manager tasks.
Run a task from an incident view
Use the following procedure to run a task, such as the Ping task, from an Incident view in Service Manager.
To run a task from an Incident view, follow these steps:
In the Service Manager console, select Work Items, and then select any Incident Management view. Select an incident in the view, and notice that in the Tasks pane, under Incident Name, the Ping Related Computer task appears.
In the Tasks pane, select the task to run it. For example, Ping Related Computer. If a computer isn't associated with the incident, you must specify the name of the computer to run the task on. If more than one computer is associated with an incident, choose one computer to run the task on.
If the task logs actions into the action log, you can open the incident and view the action log to see the output that the task generated.
If the Console Task Output - Task Name box appears, verify the output generated by the task, and select Close.