A resource is a a monitored application within a deployable/assembly
(such as httpd or smartd or mysql, or etc). A resource datablob
contains information about how to monitor the application and what to do
with the application once a failure is detected or escalated.
1. What does the xml blob look like?
------------------------------------
Look at an example of apache web server and smartd:
<ha uuid="UUIDONE">
<resources>
<resource name="apache_webservice" type="apache"
class="ocf"
monitor_interval="60s">
<escalation restarts="5" window="600s"
policy="restart-assembly"/>
</resource>
<resource name="smartd_servicee" type="smartd"
class="ocf"
monitor_interval="60s">
<escalation restarts="3" window="200s"
policy="restart-deployable"/>
</resource>
</resources>
</ha>
2. What does this tell pacemaker cloud to do?
----------------------------------------------
- terminate and restart apache if failure is detected by matahari
- terminate and restart smartd f failure is detected by matahari
- If 5 apache recoveries occur within the trailing 600 seconds
terminate and restart the assembly
- If 3 smartd recoveries occur within the trailing 200 seconds
terminate and restart the deployable
3. What would the conductor deployable.xml data blob look like?
---------------------------------------------------------------
<deployable name="Redmine">
+description>Redmine is a web-based project management
application</description>
<ha uuid="UUIDZERO"/>
<assemblies>
<assembly name="web" hwp="hwp1">
<image id="4fc38a0d-1383-4e1d-bc43-850e42541bc0">
+</image>
+<ha uuid="UUIDONE"/>
/assembly>
<assembly name="database" hwp="hwp1">
<image id="4fc38a0d-1383-4e1d-bc43-850e42541bc0"
build="bb7f6e3e-90cc-4072-afd0-030af99de555">
</image>
+<ha uuid="UUIDTWO"/>
</assembly>
</assemblies>
</deployable>
Point 3 is open for debate but seems to make the most sense to me. This
allows us to create resource templates in a cli/gui and store them via
some (as yet undefined) storage system. pacemaker-cloud would query
this storage system on assembly startup to determine the correct data to
apply to the assembly.
Tips appreciated on where this data should be stored.
Regards
-steve
Show replies by date