Menu

#516 use %View inside bb-display.cfg file

open
nobody
None
5
2017-10-16
2017-10-11
No

Hi,
I installed and configured BigSister on Windows Server 2016 (w2k16) operating system using distribution from big-sister-1.12.NTpre.zip file.
Sucessfully installed bbd, bsmon, uxmon, bstrapd and mrtg as windows services.

Configuration of GhostScript and R-project was so painful :(, but now working.

I installed MySQL database and configure BigSister to log all messges to databse.

Also I configure MSSQL as databse to log all massages using dbi:ADO:Provider, but all reports needs to be change to support reading data from MSSQL database using dbi:ADO:Provider. It will be one of mine fetured task. Second task will be to write new plugins for monitoring computer on Windows platfom usnig SNMP, WMI, powershell.

I configured bb-display.cfg to work with different view using %View command.
When started bsmon process, new folder for each %View was created inside C:\bigsis\www folder.

On IIS server I configured two diffrent sites.

The first one, for BigSister server and the second one for data defined by %View command. For example:
%View customer1
will create folder customer1 inside C:\bigsis\www (C:\bigsis\www\customer1), with all files for particular customer1.
To realize this, I must change the way of creating symlink inside Display.pm files, for folders and files.
When I done this, everithing working fine.

Currently, I try to change look of index.html page for customer1 using %skin and %Logskin, but I get stuck with this. I copied folowing skins to new skins:
default -> default_view
frames -> frames_view
structured_bg -> structured_bg_view
techie -> techie_view

Compiled all new skins (also try with deleted cache files fom all skins folder), but there's no way to force index.html page, for customer1 to get new look, defined by new skins. I try so meany different combinations, but no one work as I wish:

%View customer1

version 1:
%skin static_lamps techie_view
$Logskin static_lamps techie_view

version 2:
%skin default_view static_lamps techie_view
%Logskin default_view static_lamps techie_view

version 3:
%skin default_view static_lamps structured_bg_view frames_view
%Logskin default_view static_lamps structured_bg_view frames_view

version 4:
%skin static_lamps structured_bg frames_view
%Logskin static_lamps structured_bg frames_view

version 5:
%skin default_view static_lamps white_bg frames_view
%Logskin default_view static_lamps white_bg frames_view

version 6:
%skin default_view static_lamps structured_bg_view frames_view
%Logskin default_view static_lamps structured_bg_view frames_view

%Page top customer1
...
%Frameset index top Big_Sister_customer1.local

In fact I wish to make index.html page for customer1 without 'Admin' and 'Help' buttons.
Inside new skins I deleted following lines inside FRAME1_MENUS.inc file:
@FRAME1_MENUADMIN.inc@
@FRAME1_MENUHELP.inc@

I look at the code and noticed that skin "default" is always is using when creating index page.

If I created content inside C:\bigsis\www\customer1 folder without index page, everithing is OK.
But I wish to use framed pages to show link with "Problem Hosts" (this is the most useful link inside BigSister server what others monitoring softwares don't have).

Is it possible to force BigSister to use new frames_view skin when creating page insisde %View directory or what I need to change inside BigSister files (Display.pm, DisplayCFG.pm, bbdisp.pm ...) to archive this goal ?
Can someone can point me to right direction?

If anyone need detail user manual how to install and configure BigSister server on w2k16 os and configure ISS to use data generated by BigSister server, please contact me and I will send detail manual with pictures.

Thanks in advance.
Vladan

Discussion

  • Thomas Aeby

    Thomas Aeby - 2017-10-11

    I am afraid that Frameset always makes use of the "global" skin so currently it is impossible to have multiple Framesets each with distinct skin. As a workaround you should be able to remove the two buttons in question globally.

    In order to fix this, one would need to alter DisplayCFG::read_file() ("Frameset" section, store skin like it is done in the "Page" section) and Display::create_frameset().

    Unless I am missing an important point, this should be a rather simple&straight forward modification. I'll give it a try probably this week-end if you do not dive into it.

    At the time that piece of code had been written, nobody thought about having more than one frameset ...

    Kind regards,
    Tom

     
  • Vladan Obradovic

    Tom,
    Thanks a lot for instruction you sent to me. :)
    But I must to tell, that wasn't "simple&straight forward modification" for me. :(
    It take me 2-3 hours to figure out what I need to change to make appropriate modification.

    Followed your instructions I changed files DisplayCFG.pm and Display.pm to get what I wanted.

    I added modified files as attachment, if somone wish to use %View statment inside bb-display.cfg file.
    File SymLink.pm is used on Windows platform to replace function symlink() inside file Display.pm.
    I tested SymLink.pm file on win7 and w2k16 Windows. It's can crate symbolic link for files and folders.

    Now I realized that would be nice that each %View, ONLY show monitoring objects (computers, switches ... etc) from tables defined inside that paricular view.
    I will try to make modification to realize this goal.

    Best regards,
    Vladan

     
  • Thomas Aeby

    Thomas Aeby - 2017-10-12

    Thanks a lot, great job!

    Regarding the objects to be seen within a view: yes, sure, the point of a view is, that only the referenced objects are accessible within the view. Most probably I misunderstood your comment.

    Of course, you have to avoid referencing objects that you do not want to be visible, such as the famous "ALL" group, for instance.

    Best regards,
    Tom

     
  • Thomas Aeby

    Thomas Aeby - 2017-10-12

    Ah, yes, had a look at your bb-display.cfg sample. Something like

    %table ALL

    within a view will display a table with all hosts, thus all hosts make part of this view. It's essential to only use groups containing no more than what you want to display in the respective view.

    Best regards,
    Tom

     
  • Vladan Obradovic

    Tom,
    Thanks for your note

    %table ALL
    This was mistake :).
    When I fixed it, selection for "Problem Hosts" looking fine inside each view.

    I fixed bugs inside previously posted files.

    If anyone wish to use this implementatio with different views, you can find all modified files inside mail atachment. To install files from attachment you need to copy these files over existing files inside BigSister installation folder. For skins you need to copy folders from c:\bigsis\www\skins to new one and rename folder to folder with *_view, then copy files from attachment to new created folder.
    default -> default_view
    frames -> frames_view
    techie -> techie_view
    Inside attachment you can find example of bb-display.cfg with configuration for different views.
    Screenshots of those views you can see also can find inside atachment. :)

    Tom, can you add files from attachment to next release of BigSister?
    If you wish, I can send you all files from my BigSister installation folder (without log files) and you can decide if you wish to include modified files or modification made inside files in next release of BigSister?!
    In the meantime I will make user manual how to install BigSister on windows platform (w1k16) and how configure IIS to display data collected by BigSister. You also can include this user manual to next release of BigSister.

    to do list:
    1.Show data by filter for History,Alarams and Admin links (buttons) for particular view (only show data for objects that bilong to view).
    2.Make new plugin using WMI or powershell, for monitoring MS SQL Standalone / Cluster installation (Microsoft does not support SNMP protocol to monitor MS SQL) and another HW resources inside Windows operating system.
    3.Test users authentication mentioned in the following mail
    https://sourceforge.net/p/bigsister/mailman/message/25739092/
    4.Add support to display history data stored inside MS SQL server (>> button) when using dbi:ADO:Provider to connect db
    5.Add support to create reports from data stored inside MS SQL server (report_consolidate, report_day, report_read, report_sla) when using dbi:ADO:Provider to connect db
    6.Make Visual Studio C# project to generate following configuration files from data entered inside GUI form: bb-display.cfg, uxmon-net, bb_event_generator.cfg, resources, permissions ...

    Tom, can you point me to the right direction or maybe you have some instructions or advice for some numbers inside to do list (1. - 5.) ? :)

    Best regards,
    Vladan

     
  • Vladan Obradovic

    I tested 4. from the upper list.
    It's working by default when using MS SQL db with dbi:ADO:Provider, but with ugly message inside generated html file:
    Win32::OLE(0.1712): GetOleObject() Not a Win32::OLE object at C:/Perl/lib/Win32/OLE/Lite.pm line 154 during global destruction.

    I add new part of code to file bshistgraph.pl
    if( Platforms::iswin32() ) {
    use Win32::OLE();
    }
    END { $perfdb->close(); $perfinfodb->close(); $perfvardb->close(); $hostdb->close(); }
    to suppress this message.

     

    Last edit: Vladan Obradovic 2017-10-16

Log in to post a comment.