FAQ: SC 2012 Configuration Manager Linux Client Command Line Syntax

As I have been working with the Linux client in System Center 2012 Configuration Manager quite a bit of late and thought I would share some command line syntax that will help you navigate working with the ConfigMgr Linux client more easily.

Return the client version

/opt/microsoft/configmgr/bin/ccmexec –v

Force a policy refresh*

/opt/microsoft/configmgr/bin/ccmexec –rs policy

The Linux client has no concept of user policy, so this refresh is machine policy only!

Force hardware inventory to run immediately

/opt/microsoft/configmgr/bin/ccmexec –rs hinv

Force software inventory to run immediately

/opt/microsoft/configmgr/bin/ccmexec –rs sinv

Tail the ConfigMgr Linux Client Log

Tail is a command in Linux that print the last 10 lines of the specified file to standard output, allowing you to easily see the latest additions to the ConfigMgr Linux client log on a managed system.

tail –f /var/opt/microsoft/scxcm.log

Query Inventory (from the command line)

To view inventory data on the client directly, you use nwcli utility to query the OMI equivalent of the WMI database. The following example returns details of the SCXCM_ComputerSystem class.

/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_ComputerSystem

Here are the other classes for good measure:

/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_DiskDrive
/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_DiskPartition
/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_AddRemovePrograms
/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_LogicalDisk
/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_Processor
/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_BIOS
/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_NetworkAdapter
/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_NetworkAdapterConfiguration
/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_OperatingSystem
/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_Process
/opt/microsoft/omi/bin/omicli ei root/cimv2 SCXCM_Service

Uninstall the Client

/opt/microsoft/configmgr/bin/uninstall

Additional Resources

Additional articles related to the SC 2012 Configuration Manager Linux Client.

UPDATE: The correct Collection Query for Linux and UNIX Systems in SC 2012 Configuration Manager

FAQ: Can I Extend the Default Inventory Classes for the System Center 2012 ConfigMgr SP1 Client?

SCCM 2012 Cross-Platform: Access Denied Message When Installing the Cross-Platform Client (even as root)

And Orchestrator-related cross-platform articles…

How to restart a Linux Service (Daemon) with System Center 2012 Orchestrator

3 thoughts on “FAQ: SC 2012 Configuration Manager Linux Client Command Line Syntax

  1. Olly Portingale

    Hi,  I have been trying to deploy a software package with the intention of running some Linux commands but without any success.

    Is this something you have tried? I’m struggling to find decent documentation anywhere on how it should be done.

    The SCCM client is installed ok.  The Linux distro is Centos 6.

    Thanks

    Olly.

  2. Olly Portingale

    Hi,  There are no error messages in the config manager console.  The deployment is listed at 100% compliance however the simple command line has not run on the linux host.

    Microsoft technet article lists the following :-

    “You can install software for Linux and UNIX servers, including the following:

    New software deployment
    Software updates for programs already on the computer
    Operating system patches”

    Unfortunately it neglects to tell describe how to do any of those tasks!

    Thanks

     

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.