Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Basic functionality test

Check loaded conditions

dbus-send --system --print-reply --dest=com.citrix.xenclient.xcpmd / com.citrix.xenclient.xcpmd.get_conditions
Running the above command should return a list of 36 conditions (as of this writing).

...

dbus-send --system --print-reply --dest=com.citrix.xenclient.xcpmd / com.citrix.xenclient.xcpmd.remove_var string:'test_var1'
Running 'db-ls /power-management' should show an empty vars node

Load rules from a file (test_rules.rules)

Copy the accompanying rules file to /root/xcpmd.rulesrulesĀ 
dbus-send --system --print-reply --dest=com.citrix.xenclient.xcpmd / com.citrix.xenclient.xcpmd.load_policy_from_file string:'/root/xcpmd.rules'
Running 'db-ls /power-management' should show several rules loaded under the rules node
If this fails due to SELinux, temporarily disable it with 'setenforce 0', rerun the dbus-send command, and reenable with 'setenforce 1'.
The rules in it are used for subsequent tests.

...