On Fri, Jun 10, 2011 at 11:14:47AM +0200, Piotr Kordoń wrote:
>    1)Host don't see alaarms on it.
>    Box host still is green.
>    Thee are some red alerts on events window
Sounds like the consolidator is not running. It is the thing that
changes the events into alarms.

>    2) Reachability don't work 
Now this is strange because that bit of code I've tested a lot and it
works fine. Does your setup page say that the fping executable is OK?
Debian moved the location of fping so depending on which one you have it
might of moved.

>    3) Problems with jffnms.config
>    I can't change it with GUi
Neither can I!  I've looked into it and fixed it in the git repository.
A wrong array/key setup and then I didn't copy the file across.
I've attached a fix for this and an array complaining message.
 - Craig

-- 
Craig Small VK2XLZ    http://www.enc.com.au/       csmall at : enc.com.au
Debian GNU/Linux      http://www.debian.org/       csmall at : debian.org
GPG fingerprint:       1C1B D893 1418 2AF4 45EE  95CB C76C E5AC 12CA DFA5
diff --git a/conf/config.php b/conf/config.php
index 8894e00..139966b 100644
--- a/conf/config.php
+++ b/conf/config.php
@@ -53,8 +53,8 @@ class JffnmsConfig
     fputs($fp, $new_config);
     fclose($fp);
 
-    if ($really == TRUE && file_exists($new_config_name))
-      copy($new_config_name, $file);
+    if (file_exists($new_config_name))
+      copy($new_config_name, $config_file);
   }
 
 
diff --git a/htdocs/admin/setup.php b/htdocs/admin/setup.php
index 0c7d264..b9c0921 100644
--- a/htdocs/admin/setup.php
+++ b/htdocs/admin/setup.php
@@ -233,7 +233,7 @@ function verifyConfig($type, $key, $value)
   {
     $new_config = array();
     
-    foreach (array_keys($Config->default_configs) as 
$config_key=>$default_data)
+    foreach ($Config->default_configs as $config_key=>$default_data)
     {
         $new = $Sanitizer->get_string('new_'.$config_key);
         if (($default_data['type']=='bool') && $new===FALSE)
@@ -250,7 +250,7 @@ function verifyConfig($type, $key, $value)
     unset ($data);
   
     //force configuration re-read
-    include('../../conf/config.php');
+    #include('../../conf/config.php');
   }
   $setup_options = '';
   adm_header('Setup');
diff --git a/lib/api.inc.php b/lib/api.inc.php
index b071171..c01851d 100644
--- a/lib/api.inc.php
+++ b/lib/api.inc.php
@@ -482,7 +482,7 @@ function array_item_blank(&$arr, $key)
 
 function array_fetch(&$arr, $key, $default)
 {
-  if (array_key_exists($key, $arr))
+  if (is_array($arr) and array_key_exists($key, $arr))
     return $arr[$key];
   return $default;
 }
------------------------------------------------------------------------------
EditLive Enterprise is the world's most technically advanced content
authoring tool. Experience the power of Track Changes, Inline Image
Editing and ensure content is compliant with Accessibility Checking.
http://p.sf.net/sfu/ephox-dev2dev
_______________________________________________
jffnms-users mailing list
jffnms-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jffnms-users

Reply via email to