[Pacemaker] crm resource restart fails to restart the service

Vadym Chepkov vchepkov at gmail.com
Wed Nov 17 08:30:36 EST 2010


On Wed, Nov 17, 2010 at 8:01 AM, Dejan Muhamedagic <dejanmm at fastmail.fm> wrote:

>> RA doesn't support restart action? Most luckily you get OCF_ERR_UNIMPLEMENTED in the log
>
> It's actually a resource stop followed by start. It says so in
> the help too. Perhaps the start precludes the stop action. The
> logs should give a hint. We need a sleep in between.
>

In this case this command is not working at all, because I tried in
the past for many resources and it never worked, so I just assumed it
has to be implemented by RA.

To test it right now I issued a command
# crm resource restart xen_vbuild

where xen_vbuild is a Xen VM and no results whatsoever.

Here is output of the log

Nov 17 13:04:13 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:05:14 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:06:14 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:07:15 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:07:44 xen-11 cib: [4294]: info: log_data_element: cib:diff:
+       <primitive id="xen_vbuild" >
Nov 17 13:07:44 xen-11 cib: [4294]: info: log_data_element: cib:diff:
+         <meta_attributes id="xen_vbuild-meta_attributes"
__crm_diff_marker__="added:top" >
Nov 17 13:07:44 xen-11 cib: [4294]: info: log_data_element: cib:diff:
+           <nvpair id="xen_vbuild-meta_attributes-target-role"
name="target-role" value="Stopped" />
Nov 17 13:07:44 xen-11 cib: [4294]: info: log_data_element: cib:diff:
-       <primitive id="xen_vbuild" >
Nov 17 13:07:44 xen-11 cib: [4294]: info: log_data_element: cib:diff:
-         <meta_attributes id="xen_vbuild-meta_attributes" >
Nov 17 13:07:44 xen-11 cib: [4294]: info: log_data_element: cib:diff:
-           <nvpair value="Stopped"
id="xen_vbuild-meta_attributes-target-role" />
Nov 17 13:07:44 xen-11 pengine: [22958]: debug: unpack_lrm_rsc_state:
xen_vbuild: Overwriting calculated next role Unknown with requested
next role Stopped
Nov 17 13:07:44 xen-11 cib: [4294]: info: log_data_element: cib:diff:
+       <primitive id="xen_vbuild" >
Nov 17 13:07:44 xen-11 cib: [4294]: info: log_data_element: cib:diff:
+         <meta_attributes id="xen_vbuild-meta_attributes" >
Nov 17 13:07:44 xen-11 cib: [4294]: info: log_data_element: cib:diff:
+           <nvpair value="Started"
id="xen_vbuild-meta_attributes-target-role" />
Nov 17 13:07:45 xen-11 pengine: [22958]: debug: unpack_lrm_rsc_state:
xen_vbuild: Overwriting calculated next role Unknown with requested
next role Stopped
Nov 17 13:07:45 xen-11 pengine: [22958]: notice: native_print:
xen_vbuild	(ocf::heartbeat:Xen):	Started xen-11
Nov 17 13:07:45 xen-11 pengine: [22958]: debug: native_assign_node:
All nodes for resource xen_vbuild are unavailable, unclean or shutting
down (xen-11: 1, -1000000)
Nov 17 13:07:45 xen-11 pengine: [22958]: debug: native_assign_node:
Could not allocate a node for xen_vbuild
Nov 17 13:07:45 xen-11 pengine: [22958]: info: native_color: Resource
xen_vbuild cannot run anywhere
Nov 17 13:07:45 xen-11 pengine: [22958]: notice: LogActions: Stop
resource xen_vbuild	(xen-11)
Nov 17 13:07:46 xen-11 pengine: [22958]: notice: native_print:
xen_vbuild	(ocf::heartbeat:Xen):	Started xen-11
Nov 17 13:07:46 xen-11 pengine: [22958]: debug: native_assign_node:
Assigning xen-11 to xen_vbuild
Nov 17 13:07:46 xen-11 pengine: [22958]: notice: LogActions: Leave
resource xen_vbuild	(Started xen-11)
Nov 17 13:08:15 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:09:15 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:10:16 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:11:16 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:12:17 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:13:17 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:14:17 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:15:18 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:16:18 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:17:19 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:17:47 xen-11 pengine: [22958]: notice: native_print:
xen_vbuild	(ocf::heartbeat:Xen):	Started xen-11
Nov 17 13:17:47 xen-11 pengine: [22958]: debug: native_assign_node:
Assigning xen-11 to xen_vbuild
Nov 17 13:17:47 xen-11 pengine: [22958]: notice: LogActions: Leave
resource xen_vbuild	(Started xen-11)
Nov 17 13:18:19 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:19:19 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor
Nov 17 13:20:20 xen-11 lrmd: [4295]: debug: rsc:xen_vbuild:101: monitor

but VM never stopped:


[root at xen-11 ~]# xm list|grep vbuild
vbuild                                     3      511     2 -b----    352.4


still ID 3 as it was before

Vadym




More information about the Pacemaker mailing list