<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?python
-layout_params['page_title'] = "Monitor Node View"
+layout_params['page_title'] = "MyOps Action List"
from monitor.util import diff_time
from monitor import config
from time import mktime
<table width="100%">
<thead>
<tr>
- <th></th>
- <th><a href="${tg.url('action', filter='active')}">Not Acknowledged(${fc['active']})</a></th>
- <th><a href="${tg.url('action', filter='acknowledged')}">Acknowledged(${fc['acknowledged']})</a></th>
- <th><a href="${tg.url('action', filter='all')}">All(${fc['all']})</a></th>
+ <th><a href="${link('actionlist', action_type='online_notice', since=1)}">Last Day</a></th>
+ <th><a href="${link('actionlist', action_type='online_notice', since=7)}">Last Week</a></th>
+ <th><a href="${link('actionlist', action_type='online_notice', since=30)}">Last Month</a></th>
</tr>
</thead>
<tbody>
<tr>
<td colspan="5">
- <table id="sortable_table" class="datagrid" border="1" width="100%">
+ <h4>Actions Over the Last ${since} Days</h4>
+ <p py:if="actions and len(actions) == 0">
+ There are no recent actions taken for this site.
+ </p>
+ <table py:if="actions and len(actions) > 0" id="sortable_table" class="datagrid" border="1" width="100%">
<thead>
<tr>
<th mochi:format="int"></th>
- <th mochi:format="str">Site</th>
- <th>Hostname</th>
- <th>Issue (severity)</th>
- <th>Last change</th>
- <th>Notes (acknowledged)</th>
- <th></th>
+ <th>Date</th>
+ <th>Action taken on</th>
+ <th>Action Type</th>
+ <th>Message ID</th>
+ <th>Errors</th>
</tr>
</thead>
<tbody>
- <tr py:for="i,node in enumerate(query)">
+ <tr py:for="i,act in enumerate(actions)" class="${i%2 and 'odd' or 'even'}" >
<td></td>
- <td><a href="${link('pcuview', loginbase=node[0])}">${node[0]}</a></td>
- <td nowrap="true" py:content="node[1]"></td>
- <td nowrap='true' id="severity-${node[3]}" py:content="node[2]"></td>
- <td nowrap='true' py:content="diff_time(int(node[4]))"></td>
- <?python
- try:
- int(node[5])
- val = True
- except:
- val = False
- ?>
- <!-- NOTE: only one of the next two columns will be displayed. -->
- <td py:if="val"><a href="${zabbix_event_ack_link(node[5])}">Provide Ack</a></td>
- <td py:if="not val" py:content="node[5]">Message from user</td>
- <td py:if="not val"><a href="${zabbix_event_ack_link(node[6])}">Add</a></td>
+ <td py:content="act.date_created"></td>
+ <td py:if="act.hostname is not None" nowrap="true" >
+ <a class="ext-link" href="${plc_node_uri(act.hostname)}">
+ <span class="icon">${act.hostname}</span></a>
+ </td>
+ <td py:if="act.hostname is None" nowrap="true">
+ <a class="ext-link" href="${plc_site_uri(act.loginbase)}">
+ <span class="icon">${act.loginbase}</span></a>
+ </td>
+ <!--td py : content="diff_time(mktime(node.date_checked.timetuple()))"></td-->
+ <td py:content="act.action_type"></td>
+ <td><a class="ext-link" href="${plc_mail_uri(act.message_id)}">
+ <span py:if="act.message_id != 0" class="icon">${act.message_id}</span></a></td>
+ <td py:if="'bootmanager' in act.action_type or 'unknown' in act.action_type">
+ <a href="/monitorlog/bm.${act.hostname}.log">latest bm log</a>
+ </td>
+ <td py:if="'bootmanager' not in act.action_type">
+ <pre py:content="act.error_string"></pre></td>
</tr>
</tbody>
</table>
+
</td>
</tr>
</tbody>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?python
-layout_params['page_title'] = "Monitor Node View"
+layout_params['page_title'] = "MyOps Action Summary"
from monitor.util import diff_time
from monitor import config
from time import mktime
<table width="100%">
<thead>
<tr>
- <th>Last Day</th>
- <th>Last Week</th>
- <th>Last Month</th>
+ <th><a href="actionsummary?since=1">Last Day</a></th>
+ <th><a href="actionsummary?since=7">Last Week</a></th>
+ <th><a href="actionsummary?since=30">Last Month</a></th>
</tr>
</thead>
<tbody>
<tbody>
<tr py:for="key in results.keys()">
<td></td>
- <td nowrap="true" py:content="key"></td>
+ <td nowrap="true"><a href="actionlist?action_type=${key}" py:content="key"></a></td>
<td nowrap='true' py:content="results[key]"></td>
</tr>
</tbody>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?python
-layout_params['page_title'] = "Monitor Node List"
+layout_params['page_title'] = "MyOps Node History"
from monitor.util import diff_time
from time import mktime
from links import *
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?python
-layout_params['page_title'] = "Monitor Node List"
+layout_params['page_title'] = "MyOps Node List"
from monitor.util import diff_time
from time import mktime
from links import *
+++ /dev/null
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<?python
-layout_params['page_title'] = "Monitor Node View"
-from monitor.util import diff_time
-from time import mktime
-from pcucontrol.reboot import pcu_name, model_to_object
-from links import *
-?>
-<html py:layout="'sitemenu.kid'"
- xmlns:py="http://purl.org/kid/ns#"
- xmlns:mochi="http://www.mochi.org">
-
- <div py:match="item.tag == 'content'">
- <h3>Node Status</h3>
- <table id="sortable_table" class="datagrid" border="1" width="100%">
- <thead>
- <tr>
- <th mochi:format="int"></th>
- <th mochi:format="str">Site</th>
- <th>Hostname</th>
- <th>ping</th>
- <!--th>ssh</th-->
- <th>kernel</th>
- <th>last_change</th>
- <th>last_contact</th>
- </tr>
- </thead>
- <tbody>
- <tr py:for="i,node in enumerate(nodequery)" class="${i%2 and 'odd' or 'even'}" >
- <td></td>
- <td><a class="ext-link" href="${plc_site_uri_id(node.plc_node_stats['site_id'])}">
- <span class="icon">${node.loginbase}</span></a>
- </td>
- <td id="node-${node.observed_status}" nowrap="true" >
- <a class="ext-link" href="${plc_node_uri_id(node.plc_nodeid)}">
- <span class="icon">${node.hostname}</span></a>
- </td>
- <td py:content="node.ping_status"></td>
- <td nowrap="true" py:content="node.kernel"></td>
- <td py:content="diff_time(mktime(node.history.last_changed.timetuple()))"></td>
- <td py:content="diff_time(node.plc_node_stats['last_contact'])"></td>
- </tr>
- </tbody>
- </table>
- <h3 py:if="node.pcu is not None">Controlling PCU</h3>
- <table py:if="node.pcu is not None" id="sortable_table" class="datagrid" border="1" width="100%">
- <thead>
- <tr>
- <th mochi:format="int"></th>
- <th>PCU Name</th>
- <th>Model</th>
- <th width="80%">Test Results</th>
- </tr>
- </thead>
- <tbody>
- <?python pcu = node.pcu ?>
- <tr>
- <td></td>
- <td nowrap="true" >
- <a class="ext-link" href="${plc_pcu_uri_id(pcu.plc_pcu_stats['pcu_id'])}">
- <span class="icon">${pcu_name(pcu.plc_pcu_stats)}</span>
- </a>
- </td>
- <td py:content="pcu.plc_pcu_stats['model']"></td>
- <td width="20%" nowrap='true' align='center' id="status-${node.pcu_short_status}">
- <div id="links">
- <a class="info" py:if="'error' in node.pcu_short_status"
- href="${link('pcuview', pcuid=node.plc_pcuid)}">
- Error<span><pre>${node.pcu.reboot_trial_status}</pre></span></a>
- <a py:if="'error' not in node.pcu_short_status and 'none' not in node.pcu_short_status"
- href="${link('pcuview', pcuid=node.plc_pcuid)}"
- py:content="node.pcu_short_status">Reboot Status</a>
- <span py:if="'none' in node.pcu_short_status"
- py:content="node.pcu_short_status">Reboot Status</span>
- </div>
- </td>
- </tr>
- </tbody>
- </table>
- <h3>Actions Taken</h3>
- </div>
-
-</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?python
-layout_params['page_title'] = "Monitor Node List"
+layout_params['page_title'] = "MyOps PCU History"
from monitor.util import diff_time
from time import mktime
from links import *
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?python
-layout_params['page_title'] = "Monitor PCU List"
+layout_params['page_title'] = "MyOps PCU List"
from pcucontrol.reboot import pcu_name, model_to_object
from monitor import config
from links import *
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?python
-layout_params['page_title'] = "Monitor PCU View"
+layout_params['page_title'] = "MyOps Detail View"
from monitor.util import diff_time
from monitor import config
from time import mktime
<div id="status_block" class="flash"
py:if="value_of('tg_flash', None)" py:content="tg_flash"></div>
- <h4>Actions Over the Last Week</h4>
+ <h4>Actions Over the Last ${since} Days</h4>
<p py:if="actions and len(actions) == 0">
There are no recent actions taken for this site.
</p>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?python
-layout_params['page_title'] = "Monitor Site History List"
+layout_params['page_title'] = "MyOps Site History"
from monitor.util import diff_time
from time import mktime
from links import *
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?python
-layout_params['page_title'] = "Monitor Site List"
+layout_params['page_title'] = "MyOps Site List"
from monitor.util import diff_time
from time import mktime
from links import *
<th><a href="${link('site')}">Sites</a></th>
<th><a href="${link('pcu')}">PCUs</a></th>
<th><a href="${link('node')}">Nodes</a></th>
- <th><a href="">Actions</a></th>
+ <th><a href="${link('actionsummary')}">Actions</a></th>
</tr>
</thead>
<tbody>
+++ /dev/null
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<?python
-layout_params['page_title'] = "Monitor Site View"
-from monitor.util import diff_time
-from time import mktime
-from links import *
-?>
-<html py:layout="'sitemenu.kid'"
- xmlns:py="http://purl.org/kid/ns#"
- xmlns:mochi="http://www.mochi.org">
-
- <div py:match="item.tag == 'content'">
- <h3>Site Status</h3>
- <table id="sub-table" border="1" width="100%">
- <thead>
- <tr>
- <th>Site name</th>
- <th>Enabled</th>
- <th>Penalty</th>
- <th>Slices/Max</th>
- <th>Nodes/Total</th>
- <th>Status</th>
- </tr>
- </thead>
- <tbody>
- <tr py:for="i,site in enumerate(sitequery)">
- <td nowrap="true"><a class="ext-link" href="${plc_site_uri_id(site.plc_siteid)}">
- <span class="icon">${site.loginbase}</span></a>
- </td>
- <td py:content="site.enabled"></td>
- <td>n/a</td>
- <td>${site.slices_used}/${site.slices_total}</td>
- <td>${site.nodes_up} / ${site.nodes_total}</td>
- <td id="site-${site.status}" py:content="diff_time(mktime(site.last_changed.timetuple()))"></td>
- </tr>
- </tbody>
- </table>
- <h3>Node List</h3>
- <p py:if="len(nodequery) == 0">
- There are no registered nodes for this PCU.
- </p>
- <table py:if="len(nodequery) > 0" id="sortable_table" class="datagrid" border="1" width="100%">
- <thead>
- <tr>
- <th mochi:format="int"></th>
- <th>Hostname</th>
- <th>ping</th>
- <!--th>ssh</th-->
- <th>pcu</th>
- <th>kernel</th>
- <th>last_contact</th>
- </tr>
- </thead>
- <tbody>
- <tr py:for="i,node in enumerate(nodequery)">
- <td></td>
- <td id="node-${node.observed_status}" nowrap="true">
- <a href="${link('pcuview', hostname=node.hostname)}" py:content="node.hostname">your.host.org</a></td>
- <td py:content="node.ping_status"></td>
- <td py:if="node.pcu_short_status != 'none'" id="status-${node.pcu_short_status}">
- <a href="${link('pcuview', pcuid=node.plc_node_stats['pcu_ids'])}">${node.pcu_short_status}</a></td>
- <td py:if="node.pcu_short_status == 'none'" id="status-${node.pcu_short_status}">
- ${node.pcu_short_status}</td>
- <td nowrap="true" py:content="node.kernel"></td>
- <td py:content="diff_time(node.plc_node_stats['last_contact'])"></td>
- </tr>
- </tbody>
- </table>
- </div>
-
-</html>
<h2>Learn more</h2>\r
Learn more about MyOps default policies, and take part in its development\r
<ul class="links">\r
- <li><a href="https://svn.planet-lab.org/wiki/MonitorDocs">Documentation</a></li>\r
- <li><a href="https://svn.planet-lab.org/wiki/MonitorPolicyForPlanetLab">Policy</a></li>\r
- <li><a href="https://svn.planet-lab.org/svn/Monitor">Latest Source</a></li>\r
+ <li><a href="https://svn.planet-lab.org/wiki/MyOpsDocs">Documentation</a></li>\r
+ <li><a href="https://svn.planet-lab.org/wiki/MyOpsPolicyForPlanetLab">Policy</a></li>\r
+ <li><a href="https://svn.planet-lab.org/svn/MyOps">Latest Source</a></li>\r
</ul>\r
<span py:replace="now">now</span>\r
</div>\r