Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updates for OMV 0.5 and HDDTemp #1

Open
wants to merge 20 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 12 additions & 23 deletions Fanspeed.default
Original file line number Diff line number Diff line change
@@ -1,29 +1,18 @@
/**
* Sensors plugin for system information.
*/
// require("js/omv/NavigationPanel.js")
// require("js/omv/PluginMgr.js")
// require("js/omv/data/DataProxy.js")
// require("js/omv/data/Store.js")
// require("js/omv/grid/TBarGridPanel.js")
// require("js/omv/RrdGraphPanel.js")
// require("js/omv/PluginManager.js")
// require("js/omv/workspace/panel/RrdGraph.js")

Ext.ns("OMV.Module.Diagnostics.SysInfo");
Ext.define("OMV.module.admin.diagnostic.system.plugin.Fanspeed", {
extend: "OMV.workspace.panel.RrdGraph",

/**
* @class OMV.Module.Diagnostics.SysInfo.Temperatures
* @derived Ext.TabPanel
*/

OMV.Module.Diagnostics.SysInfo.Temperature = function(config) {
var initialConfig = {
title: "Fanspeed",
rrdGraphName: "fanspeed"
};
Ext.apply(initialConfig, config);
OMV.Module.Diagnostics.SysInfo.Temperature.superclass.constructor.call(
this, initialConfig);
};
Ext.extend(OMV.Module.Diagnostics.SysInfo.Temperature, OMV.RrdGraphPanel, {
rrdGraphName: "fanspeed"
});
OMV.preg("sysinfo", "system", OMV.Module.Diagnostics.SysInfo.Temperature);

OMV.PluginManager.register({
ptype: "diagnostic",
id: "system",
text: _("Fanspeed"),
className: "OMV.module.admin.diagnostic.system.plugin.Fanspeed"
});
44 changes: 44 additions & 0 deletions HDDTemp.default
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
/**
* This file is part of OpenMediaVault.
*
* @license http://www.gnu.org/licenses/gpl.html GPL Version 3
* @author Volker Theile <[email protected]>
* @copyright Copyright (c) 2009-2013 Volker Theile
*
* Note: File copied from Temperature.js to create a new HDDTemp graph - Andrew Ferguson ([email protected])
* File copied from Cpu.js, to create a new Temperatures graph - Mahmoud <[email protected]>
*
* OpenMediaVault is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* any later version.
*
* OpenMediaVault is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with OpenMediaVault. If not, see <http://www.gnu.org/licenses/>.
*/
// require("js/omv/PluginManager.js")
// require("js/omv/workspace/panel/RrdGraph.js")

/**
* @class OMV.module.admin.diagnostic.system.plugin.HDDTemp
* @derived OMV.workspace.panel.Textarea
* @author Andrew Ferguson <[email protected]>
*/

Ext.define("OMV.module.admin.diagnostic.system.plugin.HDDTemp", {
extend: "OMV.workspace.panel.RrdGraph",

rrdGraphName: "hddtemp"
});

OMV.PluginManager.register({
ptype: "diagnostic",
id: "system",
text: _("HDD Temps"),
className: "OMV.module.admin.diagnostic.system.plugin.HDDTemp"
});
87 changes: 66 additions & 21 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,76 @@
omvsensors
==========

OMV-script for easy setup of sensors (Temperature and Fanspeed)
OMV-script for easy setup of sensors (CPU Temperature, Fanspeed, and HDD Temperature)

Requirements:
installed and configured lm-sensors in OpenMediaVault
http://forums.openmediavault.org/viewtopic.php?f=13&t=79&p=7459#p7459
and

http://forums.openmediavault.org/viewtopic.php?f=13&t=79#p244
(second half of the post)
#Requirements:

Installation:
http://forums.openmediavault.org/viewtopic.php?f=13&t=79&start=60#p7374
Based on Solo0815's instructions:
* http://forums.openmediavault.org/viewtopic.php?f=13&t=79&p=7459#p7459<br/>
* http://forums.openmediavault.org/viewtopic.php?f=13&t=79&start=60#p7374

Edit '/etc/omv-sensor.conf' to fit your needs
and run '/usr/share/openmediavault/scripts/collectd.d/sensors'
to create the rrd-scripts for OMV.
And Jay-Jay instructions:
* http://forums.openmediavault.org/viewtopic.php?f=13&t=79&start=10#p925

After that, please run '/etc/init.d/collectd restart'
to collect the values for your coretemp/fanspeed.
__Note__: Please run your current install-remove script to delete any existing version of omvsensors before using this version, otherwise you risk leaving random files in places that could cause conflict. You may also need to delete Temperature.js, which can be done with:<br/>
`rm /var/www/openmediavault/js/omv/module/admin/diagnostic/system/plugin/Temperature.js`

You can run
'omv-mkgraph' to create the graphs.

Don't forget to run
'/usr/share/openmediavault/scripts/collectd.d/sensors'
and
'omv-mkgraph'
each time after changing the configuration file to make your changes happen in OMV
__Note__: Do the following as root or sudo the commands:

1. Install lm-sensors in OpenMediaVault: `apt-get install lm-sensors`
1. Install hddtemp in OMV: `apt-get install hddtemp`

1. Detect your sensors in lm-sensors:
```
sensors-detect
```
...answer "yes" at the question: if the sensors should be added automatically

1. Check that your CPU temp sensors are working:
```
sensors
```
...you should get something like:
```
~$ sensors
k10temp-pci-00c3
Adapter: PCI adapter
temp1: +58.5°C (high = +70.0°C, crit = +100.0°C)
```
1. Download it: `wget https://github.com/fergbrain/omvsensors/archive/master.zip`
1. Unpack it: `unzip master.zip`
1. Install it:

```
cd omvsensors-master
./install-remove.sh
```

The script will lead you through the installation (and if removal) process.

Edit '/etc/omv-sensor.conf' to fit your needs, then run:
```
/usr/share/openmediavault/scripts/collectd.d/sensors
```
...to create the rrd-scripts for OMV.

After that, please run:
```
/etc/init.d/collectd restart
```
...to collect the values for your coretemp/hddtemp/fanspeed.

You can run:
```
omv-mkgraph
```
...to create the graphs.

Don't forget to run:
```
/usr/share/openmediavault/scripts/collectd.d/sensors
omv-mkgraph
```
...each time after changing the configuration file to make your changes happen in OMV
35 changes: 12 additions & 23 deletions Sensors.default
Original file line number Diff line number Diff line change
@@ -1,29 +1,18 @@
/**
* Sensors plugin for system information.
*/
// require("js/omv/NavigationPanel.js")
// require("js/omv/PluginMgr.js")
// require("js/omv/data/DataProxy.js")
// require("js/omv/data/Store.js")
// require("js/omv/grid/TBarGridPanel.js")
// require("js/omv/RrdGraphPanel.js")
// require("js/omv/PluginManager.js")
// require("js/omv/workspace/panel/RrdGraph.js")

Ext.ns("OMV.Module.Diagnostics.SysInfo");
Ext.define("OMV.module.admin.diagnostic.system.plugin.Temperatures", {
extend: "OMV.workspace.panel.RrdGraph",

/**
* @class OMV.Module.Diagnostics.SysInfo.Temperatures
* @derived Ext.TabPanel
*/

OMV.Module.Diagnostics.SysInfo.Temperature = function(config) {
var initialConfig = {
title: "CPU Temp",
rrdGraphName: "sensors"
};
Ext.apply(initialConfig, config);
OMV.Module.Diagnostics.SysInfo.Temperature.superclass.constructor.call(
this, initialConfig);
};
Ext.extend(OMV.Module.Diagnostics.SysInfo.Temperature, OMV.RrdGraphPanel, {
rrdGraphName: "sensors"
});
OMV.preg("sysinfo", "system", OMV.Module.Diagnostics.SysInfo.Temperature);

OMV.PluginManager.register({
ptype: "diagnostic",
id: "system",
text: _("Temperatures"),
className: "OMV.module.admin.diagnostic.system.plugin.Temperatures"
});
Loading