Community discussions

MikroTik App
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

ROSInfo - router monitoring

Thu Nov 16, 2006 3:51 pm

Hi!
I have created a simple web application for monitoring routers running Mikrotik RouterOS.

It's been running on our network with eighty routers for about a year and it proved sometimes quite helpful so I decided to share it with you and release it under GPL.

Main functions:
- Signal, CPU load, uptime, latency graphing,
- Traffic monitoring

Screenshots:
Routers list
Image
Signal graphs
Image
Traffic monitoring
Image



Download:
Direct link http://phill.gotdns.org/rosinfo.php
or somewhere on my homepage http://phill.gotdns.org/

Installation:
All information regarding installation is in the file docs/INSTALL.
Part of the README file
Introduction
============
ROSInfo is a simple tool for monitoring signal levels, traffic and network
latency of x86 machines, RouterBoards and other devices running Mikrotik 
RouterOS. It was designed to be used with Mikrotik RouterOS v 2.9 and is being 
developed and tested on a large network with many Mikrotik routers.


Environment
===========

Hardware
--------
Currently supported and tested are all versions of Mikrotik RouterOS 2.9.

Software requirements
---------------------
 - Linux
 - Apache
 - PHP5 with support for snmp
 - RRDTool 1.2
 - php-rrdtool (not mandatory)
 - SNMP utilities
 - Cron or another scheduling daemon
 
 
Instalation
===========
 - Unpack the tarball to a directory accessible by Apache.
 - Make sure, that the ./rrd directory and it's subdirectories are writable by 
Apache. Use chown and chmod to achieve this.
 - Open file ./include/config.inc and change the contents to fit your needs.
 - Setup cron to start the fetchexec.php file every 5 minutes.
 
Cron setup
----------
You can use the following statement placed in /etc/crontab. Make sure you
correct the path to the file fetchexec.php and php binary.

*/5 *  * * *   www-data /usr/bin/php /path/to/rosinfo/fetchexec.php > /dev/null 2>&1


Recomendations
==============
Do not start the fetchexec.php file manualy unless you are logged in as a user 
under which Apache is running. You can use something like su www-data and then
start the fetchexec.php. 

If you want to see some debug information from the fetchexec process, uncomment 
the line $debug=1; in file config.inc. The output will be saved in a few 
logfiles.

Feel free to make any comments or suggestions,

Phill
Last edited by phill on Sat Dec 09, 2006 11:37 am, edited 4 times in total.
 
User avatar
normis
MikroTik Support
MikroTik Support
Posts: 24608
Joined: Fri May 28, 2004 11:04 am
Location: Riga, Latvia

Thu Nov 16, 2006 3:53 pm

wow, definetly a job well done! congratulations!
 
User avatar
balimore
Forum Veteran
Forum Veteran
Posts: 892
Joined: Mon Apr 10, 2006 3:38 am

Thu Nov 16, 2006 4:16 pm

----
again, that's good work ... congratulatioon man....!!!

regards
Hasbullah.com
----
 
User avatar
Campano
Frequent Visitor
Frequent Visitor
Posts: 60
Joined: Mon Apr 17, 2006 2:35 am
Location: Ñuñoa - Chile
Contact:

Mon Nov 20, 2006 1:22 pm

great work!!! and congratulations!!

please put in this page the instructions of the install ( i'm very noob) :D

and programs required for the correct running
 
psm
just joined
Posts: 17
Joined: Thu Apr 06, 2006 3:23 pm
Location: Rzeszow, Poland

Mon Nov 20, 2006 11:50 pm

Good work :)

But ... it isn't working with Nortel 5212 cards :/
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

Tue Nov 21, 2006 12:33 am

Good work :)

But ... it isn't working with Nortel 5212 cards :/
What exactly is not working? Signal graphs are empty? The signal levels are taken via snmp from the registration table, so if you have some entries in your registration table, the data should be read.

Can you please execute
snmpwalk -v1 -c public IP_ADDRESS_OF_THE_ROUTER SNMPv2-SMI::enterprises.14988.1.1.1.2.1.3
to get more information?

Or send me the whole
snmpwalk -v1 -c public IP_ADDRESS_OF_THE_ROUTER
snmp tree via email[phill.at.seznam.cz] or PM.

Thanks
 
psm
just joined
Posts: 17
Joined: Thu Apr 06, 2006 3:23 pm
Location: Rzeszow, Poland

Mon Nov 27, 2006 8:51 pm

Well...

Ok I found problem.
It's not problem with Nortel cards.

Interface names cannot contain - (dash)

Best regards :)
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

Tue Nov 28, 2006 10:34 pm

Well...

Ok I found problem.
It's not problem with Nortel cards.

Interface names cannot contain - (dash)

Best regards :)
Thanks for help, I hope I removed this issue today, but didn't test it. Try the 1.12 version please.

Also, the project has been renamed as requested by Mikrotik.
 
User avatar
111111
Member Candidate
Member Candidate
Posts: 194
Joined: Thu Oct 05, 2006 1:39 am
Location: BG,SOFIA

Wed Nov 29, 2006 8:48 pm

Is there a chanse for version under windows+IIS5+
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

Thu Nov 30, 2006 11:01 am

Is there a chanse for version under windows+IIS5+
I doubt that, unless someone would want to write that :)
 
User avatar
normis
MikroTik Support
MikroTik Support
Posts: 24608
Joined: Fri May 28, 2004 11:04 am
Location: Riga, Latvia

Thu Nov 30, 2006 11:09 am

i doubt that anyone wants to write anything for that :) LAMP is the way to go IMO.
 
Thomas1
just joined
Posts: 3
Joined: Sat Mar 11, 2006 10:11 am
Location: London

Wed Dec 06, 2006 5:35 pm

That worked with PHP4?
Is possibility making any changes or somebody have any adaptation?

Best regards
Thomas
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

Wed Dec 06, 2006 5:48 pm

That worked with PHP4?
Is possibility making any changes or somebody have any adaptation?

Best regards
Thomas
It would require to use a different template engine or not to use one at all. Because I didn't want to use smarty, I used just a simple template engine called PET which unfortunately works only under php5.


Is it a really big deal to get php5 up and running? I think that today php4 is kind of dead.
 
meshnet
Frequent Visitor
Frequent Visitor
Posts: 57
Joined: Tue Jun 01, 2004 6:57 pm

Fri Dec 08, 2006 9:37 pm

phill, a couple of fixes for the next version,

the fetch.php scripts don't use the rrdtool configuration entry, they are hard coded.

also, you might add a config var for the snmp community.

Thanks,
Richard
 
psm
just joined
Posts: 17
Joined: Thu Apr 06, 2006 3:23 pm
Location: Rzeszow, Poland

Sat Dec 09, 2006 10:30 am

Hi,

I think ... snmp community in config will be very useful :)

Best regards
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

Sat Dec 09, 2006 11:11 am

Thanks for the feedback.

fetch.php will be fixed in the next release.

Regarding the snmp community. I was trying to make the project as simple as possible, so there is not involved mysql or any other DB. Problem with snmp community is, that I guess you don't want to configure it globaly, but set it for each router separately.

Another similiar feature in my todolist is setting the http port, because some users may change it for security purposes. Not all people know how to work with arrays in php, so I will try to rewrite the config section into a simple text form.

Regards,
Phill
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

ver 1.20 out

Mon Dec 11, 2006 10:22 pm

I hope that it is fixed now.

What should work now:
- Interface names with any characters
- Easier routers configuration, http port, snmp community
- Few bugs fixed

When upgrading you have to modify the configuration.
 
Thomas1
just joined
Posts: 3
Joined: Sat Mar 11, 2006 10:11 am
Location: London

Wed Dec 13, 2006 3:39 am

Hi all,

I have this error in Apache logs:
[error] PHP Notice: Undefined index: desc in /var/www/htdocs/rosinfo/include/functions.php on line 54
[error] PHP Notice: Undefined variable: old_category in /var/www/htdocs/rosinfo/header.php on line 44

greetings
T.
 
denni
newbie
Posts: 27
Joined: Thu Apr 14, 2005 7:23 am
Location: Jakarta - Indonesia

Wed Dec 13, 2006 4:55 am

hi Phill
can you inform how to install this step by step ?
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

Wed Dec 13, 2006 11:15 am

Hi all,

I have this error in Apache logs:
[error] PHP Notice: Undefined index: desc in /var/www/htdocs/rosinfo/include/functions.php on line 54
[error] PHP Notice: Undefined variable: old_category in /var/www/htdocs/rosinfo/header.php on line 44

greetings
T.
fixed
hi Phill
can you inform how to install this step by step ?
It's written in the README file, I tried to provide more details, hope it's enough.


PS: Want to help me in any way with this app? Just PM me.
 
denni
newbie
Posts: 27
Joined: Thu Apr 14, 2005 7:23 am
Location: Jakarta - Indonesia

Thu Dec 14, 2006 11:40 am

Phil,

Just install and the signal graph not shown..why ? Using rosinfo-1.21 and we have 1 pc install Mikrotik functions as router but got snmp error
any miss coniguration
 
User avatar
stuntshell
Frequent Visitor
Frequent Visitor
Posts: 57
Joined: Sun Feb 27, 2005 5:15 pm

Fri Dec 15, 2006 2:21 am

I have everything working, nice graphs and all, I'm running Centos4 and testing with a RB112 as ap-bridge.
When I try to load the traffic I get:
Unable to fetch data. RouterOS is either not available, or not configured correctly.
:cry:
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

Fri Dec 15, 2006 5:00 pm

Phil,

Just install and the signal graph not shown..why ? Using rosinfo-1.21 and we have 1 pc install Mikrotik functions as router but got snmp error
any miss coniguration
I am sorry, but this application requires at least a minimal knowledge of linux, apache, etc. and I don't have enough time to give everyone support.
I have everything working, nice graphs and all, I'm running Centos4 and testing with a RB112 as ap-bridge.
When I try to load the traffic I get:
Unable to fetch data. RouterOS is either not available, or not configured correctly.
:cry:
Make sure, that web server is running on your routeros. Check if it runs on port 80, or change the config file.
Try opening http://routeros:80/accounting/ip.cgi in your browser. Try it via lynx, links, or wget from the linux machine. Check that php is allowed to download files from other sites.

Hope this helps you a bit finding the problem.
 
User avatar
stuntshell
Frequent Visitor
Frequent Visitor
Posts: 57
Joined: Sun Feb 27, 2005 5:15 pm

Fri Dec 15, 2006 5:31 pm

Thanks Phill,
Yes everything gets processed as you mentioned.
I believe my problem is in the lock file:
-rwxrwxrwx  1 www www 0 Dec 15 13:07 rosinfo-traffic-172.16.0.226.lock
It tells me 'zero' size.
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

Fri Dec 15, 2006 5:43 pm

Thanks Phill,
Yes everything gets processed as you mentioned.
I believe my problem is in the lock file:
-rwxrwxrwx  1 www www 0 Dec 15 13:07 rosinfo-traffic-172.16.0.226.lock
It tells me 'zero' size.
The lockfiles are checked only by timestamp.

The process is simple:
1. If the lockfile exists and the timestamp is older than now - 4sec, the lock file is recreated and data are fetched from routeros.
If the timestamp is newer than now - 4sec, we wait a few second and try again (another user is reading the data)
2. Read data from routeros
3. wait 4sec
4. read data from routeros
5. remove lockfile
6. calculate the differences and show the results

Your problem is somewhere in point 2.

If the lockfiles are not deleted it's not a bug, it's a feature. If you close your browser somewhere between points 2-4 the php script terminates leaving the lockfile still there.

It's a really simple muttex, allowing you to use nonpatched php.

Try removing the @ in file traffic.php on line 43 to get more information.
$fp = @fopen($page, "r");
==>
$fp = fopen($page, "r");
 
Thomas1
just joined
Posts: 3
Joined: Sat Mar 11, 2006 10:11 am
Location: London

Sat Jan 13, 2007 3:38 am

[...]

Can you please execute
snmpwalk -v1 -c public IP_ADDRESS_OF_THE_ROUTER SNMPv2-SMI::enterprises.14988.1.1.1.2.1.3
to get more information?

Thanks
Hi Phill!
That work great, but can you tell me what command must I use to listed how many clients is connected to the interface?

thx for Your help
Thomas
 
phill
just joined
Topic Author
Posts: 12
Joined: Sun Jun 18, 2006 5:42 pm

Sat Jan 13, 2007 11:36 am

Hi Phill!
That work great, but can you tell me what command must I use to listed how many clients is connected to the interface?

thx for Your help
Thomas
I'm not really sure what do you mean. Via snmp you can list the registration table, counting lines is then quite easy. Or you can use telnet and list whatever you want.
 
marko_bg
Member Candidate
Member Candidate
Posts: 119
Joined: Sat Jun 03, 2006 11:48 am

Tue Feb 06, 2007 11:10 pm

Hi,

do you have problems with this ?!

http://forum.mikrotik.com/posting.php?m ... ly&t=13753
 
ch_m
just joined
Posts: 3
Joined: Fri Jun 30, 2006 8:49 am

Re: ROSInfo - router monitoring

Sun Sep 23, 2007 5:52 pm

Warning: uasort() [function.uasort]: The argument should be an array in /var/www/rosinfo/traffic.php on line 134

Warning: Invalid argument supplied for foreach() in /var/www/rosinfo/traffic.php on line 139

Warning: Invalid argument supplied for foreach() in /var/www/rosinfo/traffic.php on line 184


HELP ! error rosinfo.

ping,snmp error.

router add:

Testing...
Resolving IP... 192.168.x.x
Resolving domain name... x.xx

SNMP test... ok
Traffic accounting Test... ok
Result - Ok
 
Dattero
just joined
Posts: 14
Joined: Thu Feb 14, 2008 4:22 pm
Location: Varazze, SV
Contact:

Re: ROSInfo - router monitoring

Tue Oct 28, 2008 10:32 pm

Hi man! many tks to Phil but, for beginners, this is very hard to set.

Not found all the web a user friendly Guide for this app., sorry.
I just downloaded archive, i believe that it must uploaded to website, i am search all files where i have to insert router address but don't find it... if you have some good guide or would you help me please reply... i use only 1 RB133 and want to look up my first steps in this nice world...by
Mau
 
User avatar
normis
MikroTik Support
MikroTik Support
Posts: 24608
Joined: Fri May 28, 2004 11:04 am
Location: Riga, Latvia

Re: ROSInfo - router monitoring

Wed Oct 29, 2008 2:10 pm

Hi man! many tks to Phil but, for beginners, this is very hard to set.
why would a "beginner" be administrating routers and networks? clearly this tool is ok for the intended audience - administrator
No answer to your question? How to write posts
 
ayufan
Member
Member
Posts: 331
Joined: Sun Jun 03, 2007 9:35 pm
Contact:

Re: ROSInfo - router monitoring

Fri Dec 26, 2008 10:33 pm

I've made a few improvements to that script.

Password are now hashed
Fixed many bugs
Added graphing of Simple Queues and Queue Tree
Added availability statistics
Added posibility to disable SNMP or HTTP

If someone is interested PM me, I'll send you a copy.

Image
hAP AC, TP-Link Archer C7 v2, RB951G, RB450G, RPI2, RPI zero
 
dawam
Trainer
Trainer
Posts: 136
Joined: Wed May 31, 2006 1:40 pm
Location: Malaysia

Re: ROSInfo - router monitoring

Tue Jan 06, 2009 8:21 am

ayufan, thanks for the file.

Login ( ok ).

Problem ::Add new router:
I have problem posting new router, when I enter submit , I got blank screen.( the submit form goes blank, no new info displayed, no error).

Router data not posted to database. Offline/All router count still zero value.

Any insight much appreciated.

dawam
----------------------------------------------------------------
Everything looks complicated to begin with, but it's surprisingly simple when you understand it.
 
dawam
Trainer
Trainer
Posts: 136
Joined: Wed May 31, 2006 1:40 pm
Location: Malaysia

Re: ROSInfo - router monitoring

Thu Jan 08, 2009 9:03 pm

I have no problem using rosinfo version 121. So snmp and accounting is working. Must be the new database code!

So. nothing happen after this statement in hosts.php
if (!@snmpget($post_host, $post_snmp, "SNMPv2-MIB::sysName.0"))
Any one else having the same problem on this new version?
 
ayufan
Member
Member
Posts: 331
Joined: Sun Jun 03, 2007 9:35 pm
Contact:

Re: ROSInfo - router monitoring

Fri Jan 09, 2009 1:36 am

In order to make it work create new database. There were significant table changes.
hAP AC, TP-Link Archer C7 v2, RB951G, RB450G, RPI2, RPI zero
 
remuss
newbie
Posts: 43
Joined: Sat May 05, 2007 11:35 am
Location: Romania, Timisoara
Contact:

Re: ROSInfo - router monitoring

Fri Sep 11, 2009 11:06 pm

i can't get it work, wen I add a router and press submit it comes a blank page! what is the problem ? I use 1.30

Thanks Remus
 
User avatar
m4rk0
Member Candidate
Member Candidate
Posts: 195
Joined: Sat Feb 16, 2008 8:30 pm
Location: BA

Re: ROSInfo - router monitoring

Mon Sep 14, 2009 7:02 pm

Awesome job!
Thumbs up!

- Btw: Your web is down...
http://www.mreza-wisp.ba/
Please, give Karma if I fix your problem
Certified MTCNA
 
jparsons
Frequent Visitor
Frequent Visitor
Posts: 83
Joined: Sat Feb 18, 2006 5:41 pm
Location: Maryville, TN
Contact:

Re: ROSInfo - router monitoring

Thu Sep 17, 2009 5:33 pm

I have tried to install version 1.30 from sourceforge.
The templates do not seem to load for me.
I get all of the text from the main page but no graphic, colors, or formatting.

Did I do somethings wrong?

I am running on the following system specs:
mysql-server-5.0.51a
mysql-client-5.0.51a
FreeBSD6.3
apache-2.2.8
php5-5.2.6_2
php5-snmp-5.2.6_2
php5-rrdtool-1.00_1
rrdtool-1.2.28
ucd-snmp-4.2.6_9

I have many other sites using php and mysql on this server fine.

I double checked the config file for inncorect paths and etc. they are all correct.

Forgive me if this is the wrong place to ask for help, but your site seems to be offline.
 
ch_m
just joined
Posts: 3
Joined: Fri Jun 30, 2006 8:49 am

Re: ROSInfo - router monitoring

Thu Sep 17, 2009 7:29 pm

Hello everyone!
Is out of order for me, the routert does not admit it into the database.
Accross i checked but I receive any kind of feedback that the mikrotiket records it.
I tried to ask help many times but nothing. :(
 
ch_m
just joined
Posts: 3
Joined: Fri Jun 30, 2006 8:49 am

Re: ROSInfo - router monitoring

Thu Sep 17, 2009 7:31 pm

ayufan, thanks for the file.

Login ( ok ).

Problem ::Add new router:
I have problem posting new router, when I enter submit , I got blank screen.( the submit form goes blank, no new info displayed, no error).

Router data not posted to database. Offline/All router count still zero value.

Any insight much appreciated.

dawam
This is my problem though.
 
dawam
Trainer
Trainer
Posts: 136
Joined: Wed May 31, 2006 1:40 pm
Location: Malaysia

Re: ROSInfo - router monitoring

Tue Sep 29, 2009 7:38 pm


Login ( ok ).

Problem ::Add new router:
I have problem posting new router, when I enter submit , I got blank screen.( the submit form goes blank, no new info displayed, no error).

Router data not posted to database. Offline/All router count still zero value.

Any insight much appreciated.

dawam
I solved this :
make sure you install

- PHP5 command-line interpreter (php5-cli)
check php binary is available in /usr/bin/php. An apt-get install php5-cli solved this for my debian server


dawam
----------------------------------------------------------------
Everything looks complicated to begin with, but it's surprisingly simple when you understand it.
 
MethOd63
just joined
Posts: 10
Joined: Tue Sep 30, 2008 11:57 pm

Re: ROSInfo - router monitoring

Sun Oct 04, 2009 10:21 pm

Is there possibility to change kbytes to kbits ???

Thanks for answer

BTW great job, i like rosinfo.
 
tomtom
just joined
Posts: 5
Joined: Sat Jan 09, 2010 11:56 pm

Re: ROSInfo - router monitoring

Sat Jan 16, 2010 9:33 pm

Where can the script been downloaded?
The above URL is not working currently. :(

Thanks for your work!

tomtom
 
dssmiktik
Forum Veteran
Forum Veteran
Posts: 732
Joined: Fri Aug 17, 2007 8:42 am

Re: ROSInfo - router monitoring

Sun Jan 17, 2010 6:43 am

It seems the project is posted (and appears updated) on SourceForge here:
[url]http://sourceforge.net/projects/rosinfo/[/url]

phill,
Could you update your original first post with this new link?
BTW, really great job on the project.
 
pikpik
Frequent Visitor
Frequent Visitor
Posts: 73
Joined: Wed Jan 20, 2010 11:25 am

Re: ROSInfo - router monitoring

Wed Jan 20, 2010 2:22 pm

can anybody upload it on another mirror ?
 
User avatar
normis
MikroTik Support
MikroTik Support
Posts: 24608
Joined: Fri May 28, 2004 11:04 am
Location: Riga, Latvia

Re: ROSInfo - router monitoring

Thu Jan 21, 2010 9:24 am

can anybody upload it on another mirror ?
this link works: http://sourceforge.net/projects/rosinfo/
No answer to your question? How to write posts
 
rzirzi
Member
Member
Posts: 387
Joined: Mon Oct 09, 2006 2:33 pm

Re: ROSInfo - router monitoring

Sun Aug 22, 2010 1:12 pm

Warning: uasort() [function.uasort]: The argument should be an array in /var/www/rosinfo/traffic.php on line 134

Warning: Invalid argument supplied for foreach() in /var/www/rosinfo/traffic.php on line 139

Warning: Invalid argument supplied for foreach() in /var/www/rosinfo/traffic.php on line 184
I have the same problem. How to resolve it?
How to ser ROSInfo to show in kilobytes NOT in kBytes??
 
User avatar
czolo
Member
Member
Posts: 418
Joined: Fri Mar 04, 2005 9:49 am
Location: Poland (Warsaw)
Contact:

Re: ROSInfo - router monitoring

Tue Oct 05, 2010 8:41 pm

I have the same problem. How to resolve it?
How to set ROSInfo to show in kilobytes NOT in kBytes??[/quote]

Look in file rrdgraph.php - there are some lines:
//orginal "CDEF:AVG_traffic_in_kB=AVG_traffic_in,1024,/",
//orginal "CDEF:AVG_traffic_out_kB=AVG_traffic_out,1024,/",
//orginal "CDEF:AVG_traffic_total_kB=AVG_traffic_total,1024,/",...........

Chenge it to this:
"CDEF:AVG_traffic_in_kB=AVG_traffic_in,0.008,*",
"CDEF:AVG_traffic_out_kB=AVG_traffic_out,0.008,*",
"CDEF:AVG_traffic_total_kB=AVG_traffic_total,0.008,*",...........

Than change lower lines to something like that (My comments are in polish, but U can set anything U want):
"AREA:MAX_traffic_total_kB#ffaaaa::",
"AREA:MAX_traffic_out_kB#aaaacc::",
"AREA:MAX_traffic_in_kB#aaccaa::",

"AREA:AVG_traffic_total_kB#ff1111:".$quote."Srednio razem \: ".$quote.":", // Srednio razem - polish comments
"GPRINT:AVG_traffic_total_kB:AVERAGE:".$quote."%5.0lf kb/sec".''.$quote,
"GPRINT:MAX_traffic_total_kB:MAX:".$quote." Max\:%5.0lf kb/sec".'\n'.$quote,
......
"AREA:AVG_traffic_out_kB#1111cc:".$quote."Srednio wychodzacy \: ".$quote.":",
"GPRINT:AVG_traffic_out_kB:AVERAGE:".$quote."%5.0lf kb/sec".''.$quote,
"GPRINT:MAX_traffic_out_kB:MAX:".$quote." Max\:%5.0lf kb/sec".'\n'.$quote,
......
"AREA:AVG_traffic_in_kB#11cc11:".$quote."Srednio przychodzacy\:".$quote.":",
"GPRINT:AVG_traffic_in_kB:AVERAGE:".$quote."%5.0lf kb/sec".''.$quote,
"GPRINT:MAX_traffic_in_kB:MAX:".$quote." Max\:%5.0lf kb/sec".'\n'.$quote,
"LINE2:AVG_traffic_out_kB#1111cc::"...........

Remember to change graph opts array, parameter "-v kbps"
| --= Czo|_o =--
| http://wifi4eu.pl
| Innovation in WiFi
 
malpi
just joined
Posts: 2
Joined: Mon Mar 28, 2005 12:53 am

Re: ROSInfo - router monitoring

Fri Oct 29, 2010 4:14 pm

Remember to change graph opts array, parameter "-v kbps"
Where Can I do that (which file)?
 
method
just joined
Posts: 13
Joined: Fri Mar 25, 2005 3:29 pm

Re: ROSInfo - router monitoring

Tue Dec 14, 2010 12:48 pm

Is there chance to make rosinfo to work at PHP 5.3.3 ??

I have this error: Deprecated: Function split() is deprecated in /var/www/rosinfo/include/functions.php on line 58

Graph show's only latency.
snmpwalk -v1 -c public IP_ADDRESS
Result:
iso.3.6.1.2.1.31.1.1.1.15.1 = Gauge32: 0
iso.3.6.1.2.1.31.1.1.1.15.2 = Gauge32: 0
iso.3.6.1.2.1.31.1.1.1.15.3 = Gauge32: 0
iso.3.6.1.2.1.31.1.1.1.15.4 = Gauge32: 0
iso.3.6.1.2.1.31.1.1.1.15.5 = Gauge32: 0
iso.3.6.1.2.1.31.1.1.1.15.6 = Gauge32: 0
iso.3.6.1.2.1.31.1.1.1.15.7 = Gauge32: 0
iso.3.6.1.2.1.31.1.1.1.15.9 = Gauge32: 0
iso.3.6.1.2.1.9999.1.1.1.1.0 = STRING: "MikroTik DHCP server"
iso.3.6.1.2.1.9999.1.1.1.2.0 = OID: iso.3.6.1.4.1.14988.1
There are much more lines, bo graph dosn't show anything.
Where is the problem ???
 
sw0rdf1sh
Frequent Visitor
Frequent Visitor
Posts: 50
Joined: Sun Nov 28, 2010 6:16 pm

Re: ROSInfo - router monitoring

Sun Feb 06, 2011 3:35 am

Does this work under xampp or wampp?Anyone tested that?
 
rado3105
Member
Member
Posts: 493
Joined: Sat Jan 12, 2008 11:45 pm

Re: ROSInfo - router monitoring

Fri Apr 08, 2011 5:45 pm

Instalation
===========
- Unpack the tarball to a directory accessible by Apache.
- Make sure, that the ./rrd directory and it's subdirectories are writable by
Apache. Use chown and chmod to achieve this.
- Open file ./include/config.inc and change the contents to fit your needs.
- Setup cron to start the fetchexec.php file every 5 minutes.


I dont understand the step 2. How to make subdirectories writable by apache. I just unpacked it to /var/www. And dont know what to do next. Can anybody be more specific.
 
User avatar
janisk
MikroTik Support
MikroTik Support
Posts: 6283
Joined: Tue Feb 14, 2006 9:46 am
Location: Riga, Latvia

Re: ROSInfo - router monitoring

Tue Apr 12, 2011 1:42 pm

at least on debian/ubuntu apache is part of www-data group/user

so,
chown -R www-data:www-data /var/www/*
will change ownership of all the files and directories to www-data user and group
 
galaxsat
just joined
Posts: 1
Joined: Mon Jun 13, 2005 3:28 pm
Location: SW Florida

Re: ROSInfo - router monitoring

Sat Apr 23, 2011 8:10 pm

I spent a little time sprucing up the traffic graphing this morning. The following section of rrdgraph.php will produce auto-scaled (bps,kbps,Mbps) traffic graphs. Be sure to backup your working file first, then replace the whole section. I have the total traffic lines commented out, but simply remove the comments to enable them if you like to see aggregate throughput.
function graph_traffic()
{
    global $phprrd, $rrd_directory;
    $id = $_GET["id"];
    $description = $_GET["description"];
    $interface = $_GET["interface"];
    $interface_printable = convert_alphabet_rev($interface);
    $interface_printable = strtr($interface_printable, array ("'" => "", "\"" => ""));

    $timestamp = isset($_GET["timestamp"]) ? $_GET["timestamp"] : "now-1d";

    $fname = $rrd_directory."rosinfo-traffic-$id-$interface.rrd";
    $quote = "";
    if (!$phprrd)
        $quote = "\"";

    $opts = array(
      "--imgformat=PNG",
      "-e now",
      "-s $timestamp",
      "-t ".$quote."Traffic - $description - $interface_printable".$quote,
      "-r",
      "-b 1000",
      "-h 110",
      "-w 430",
      //"-u -40",
      //"-l -100",
      "-v 'bits per second'",
      "-A",
      "--slope-mode",
      "-cBACK#ffffff",
      "-cSHADEA#DCDCDC",
      "-cSHADEB#DCDCDC",

      "DEF:MAX_traffic_in=".$quote."$fname".$quote.":traffic_in:MAX",
      "DEF:MAX_traffic_out=".$quote."$fname".$quote.":traffic_out:MAX",
      "CDEF:MAX_traffic_total=MAX_traffic_out,MAX_traffic_in,+",
      "CDEF:MAX_traffic_total_bits=MAX_traffic_total,8,*",
      "CDEF:MAX_traffic_in_bits=MAX_traffic_in,8,*",
      "CDEF:MAX_traffic_out_bits=MAX_traffic_out,8,*",

      "DEF:AVG_traffic_in=".$quote."$fname".$quote.":traffic_in:AVERAGE",
      "DEF:AVG_traffic_out=".$quote."$fname".$quote.":traffic_out:AVERAGE",
      "CDEF:AVG_traffic_total=AVG_traffic_out,AVG_traffic_in,+",
      "CDEF:AVG_traffic_total_bits=AVG_traffic_total,8,*",
      "CDEF:AVG_traffic_in_bits=AVG_traffic_in,8,*",
      "CDEF:AVG_traffic_out_bits=AVG_traffic_out,8,*",

//      "AREA:MAX_traffic_total_bits#ffaaaa::",
      "AREA:MAX_traffic_out_bits#aaaacc::",
      "AREA:MAX_traffic_in_bits#aaccaa::",

//      "AREA:AVG_traffic_total_bits#ff1111:".$quote."Average total\:    ".$quote.":",
//      "GPRINT:AVG_traffic_total_bits:AVERAGE:".$quote."%8.2lf%s".''.$quote,
//      "GPRINT:MAX_traffic_total_bits:MAX:".$quote."    Maximum\:%8.2lf%s".'\n'.$quote,

      "AREA:AVG_traffic_out_bits#1111cc:".$quote."Average outgoing\: ".$quote.":",
      "GPRINT:AVG_traffic_out_bits:AVERAGE:".$quote."%8.2lf%s".''.$quote,
      "GPRINT:MAX_traffic_out_bits:MAX:".$quote."    Maximum\:%8.2lf%s".'\n'.$quote,

      "AREA:AVG_traffic_in_bits#11cc11:".$quote."Average incoming\:".$quote.":",
      "GPRINT:AVG_traffic_in_bits:AVERAGE:".$quote."%8.2lf%s".''.$quote,
      "GPRINT:MAX_traffic_in_bits:MAX:".$quote."    Maximum\:%8.2lf%s".'\n'.$quote,
      "LINE1:AVG_traffic_out_bits#1111cc::"
    );
    return $opts;
}
 
parshivets
just joined
Posts: 1
Joined: Wed May 04, 2011 12:12 pm

Re: ROSInfo - router monitoring

Wed May 04, 2011 1:13 pm

Hello.
Installed, login. Add router.
Testing...Resolving IP...	10.13.16.197
Resolving domain name...	10.13.16.197
 	
SNMP test...	ok
Traffic accounting Test...	error

Result - Ok
But when open
All routers (1)
- I dont see IP for router.And have errors at all fields.
Appache error.log give
[Wed May 04 13:09:04 2011] [error] [client 127.0.0.1] PHP Notice:  Undefined variable: filter in /srv/www/htdocs/show.php on line 20, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=submit_edit
[Wed May 04 13:09:04 2011] [error] [client 127.0.0.1] PHP Notice:  Undefined index: snmp_system_description in /srv/www/htdocs/show.php on line 78, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=submit_edit
[Wed May 04 13:09:04 2011] [error] [client 127.0.0.1] PHP Notice:  Undefined variable: filter in /srv/www/htdocs/show.php on line 34, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=submit_edit
[Wed May 04 13:09:04 2011] [error] [client 127.0.0.1] PHP Warning:  date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Helsinki' for 'EEST/3.0/DST' instead in /srv/www/htdocs/footer.php on line 4, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=submit_edit
[Wed May 04 13:09:04 2011] [error] [client 127.0.0.1] PHP Warning:  strftime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Helsinki' for 'EEST/3.0/DST' instead in /srv/www/htdocs/footer.php on line 5, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=submit_edit
[Wed May 04 13:09:04 2011] [error] [client 127.0.0.1] File does not exist: /srv/www/htdocs/favicon.ico, referer: http://artemchuk.nk.pbank.com.ua/show.php
[Wed May 04 13:09:05 2011] [error] [client 127.0.0.1] PHP Notice:  Undefined variable: filter in /srv/www/htdocs/show.php on line 20, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=submit_edit
[Wed May 04 13:09:05 2011] [error] [client 127.0.0.1] PHP Notice:  Undefined index: snmp_system_description in /srv/www/htdocs/show.php on line 78, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=submit_edit
[Wed May 04 13:09:05 2011] [error] [client 127.0.0.1] PHP Notice:  Undefined variable: filter in /srv/www/htdocs/show.php on line 34, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=submit_edit
[Wed May 04 13:09:05 2011] [error] [client 127.0.0.1] PHP Warning:  date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Helsinki' for 'EEST/3.0/DST' instead in /srv/www/htdocs/footer.php on line 4, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=submit_edit
[Wed May 04 13:09:05 2011] [error] [client 127.0.0.1] PHP Warning:  strftime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Helsinki' for 'EEST/3.0/DST' instead in /srv/www/htdocs/footer.php on line 5, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=submit_edit
[Wed May 04 13:09:06 2011] [error] [client 127.0.0.1] File does not exist: /srv/www/htdocs/favicon.ico, referer: http://artemchuk.nk.pbank.com.ua/show.php
[Wed May 04 13:10:38 2011] [error] [client 127.0.0.1] PHP Warning:  date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Helsinki' for 'EEST/3.0/DST' instead in /srv/www/htdocs/footer.php on line 4, referer: http://artemchuk.nk.pbank.com.ua/show.php
[Wed May 04 13:10:38 2011] [error] [client 127.0.0.1] PHP Warning:  strftime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Helsinki' for 'EEST/3.0/DST' instead in /srv/www/htdocs/footer.php on line 5, referer: http://artemchuk.nk.pbank.com.ua/show.php
[Wed May 04 13:10:39 2011] [error] [client 127.0.0.1] PHP Warning:  date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Helsinki' for 'EEST/3.0/DST' instead in /srv/www/htdocs/footer.php on line 4, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=edit&id=3
[Wed May 04 13:10:39 2011] [error] [client 127.0.0.1] PHP Warning:  strftime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Helsinki' for 'EEST/3.0/DST' instead in /srv/www/htdocs/footer.php on line 5, referer: http://artemchuk.nk.pbank.com.ua/hosts.php?action=edit&id=3
What I have to do?
Ps. At SQL database I see IP address for host - find - when add router - ip add to host field at SQL base
 
rado3105
Member
Member
Posts: 493
Joined: Sat Jan 12, 2008 11:45 pm

Re: ROSInfo - router monitoring

Wed Jun 08, 2011 6:41 pm

it shows me snmp error. Snmp is set in mikrotik routers, also in linux(where is rosinfo installed).
I also tryed to change:
$snmp = snmpget($router["host"], $router["snmp"], "DISMAN-EVENT-MIB::sysUpTimeInstance", 1000000, 2);

for:

$snmp = snmpget($router["host"], $router["snmp"], ".1.3.6.1.2.1.1.3.0", 1000000, 2);

didnt helped. Ping is working, also ip accounting.
 
User avatar
czolo
Member
Member
Posts: 418
Joined: Fri Mar 04, 2005 9:49 am
Location: Poland (Warsaw)
Contact:

Re: ROSInfo - router monitoring

Fri Sep 16, 2011 12:04 am

it shows me snmp error. Snmp is set in mikrotik routers, also in linux(where is rosinfo installed).
I also tryed to change:
$snmp = snmpget($router["host"], $router["snmp"], "DISMAN-EVENT-MIB::sysUpTimeInstance", 1000000, 2);

for:

$snmp = snmpget($router["host"], $router["snmp"], ".1.3.6.1.2.1.1.3.0", 1000000, 2);

didnt helped. Ping is working, also ip accounting.
Maybe U should install php-snmp package? I think it's a part of pear or pecl (I dont't remember now whichone)
| --= Czo|_o =--
| http://wifi4eu.pl
| Innovation in WiFi
 
phantomfx
just joined
Posts: 3
Joined: Sat Jun 24, 2006 3:36 pm

Re: ROSInfo - router monitoring

Fri Mar 23, 2012 1:34 pm

Anybody tried rosinfo with more than 3k routers? :)

Who is online

Users browsing this forum: saltynomad and 12 guests