Nagios / Opsview setup

nelnel Member Posts: 2,859 ■□□□□□□□□□
Hi guys,

im looking to install one of these in a vm. i have tried several guides i found on google for ubuntu and i constantly seem to run it to issues - one after the other. now i have no linux experiance so go easy with me! i just cant see why they cant do a windows version ;)

I was hoping someone could recommend a guide which THEY have used - not a google one which they havent used.

Even better would be a VM image of a preinstalled environment if possible? ive looked on the vmware VM images but most of the nagios ones have been removed due to faulty links.

Anyone give any help on this as im very keen to set this up at work as we currently have zilch!
Xbox Live: Bring It On

Bsc (hons) Network Computing - 1st Class
WIP: Msc advanced networking

Comments

  • bwcartybwcarty Member Posts: 422 ■■■□□□□□□□
    I've used the quickstart guide for SuSE in the past, and it worked for me, but I'm also pretty familiar with dealing with Linux at the command line.

    Here's the same doc for Ubuntu. http://nagios.sourceforge.net/docs/3_0/quickstart-ubuntu.html

    If you run into issues, post the details here.
    Help eradicate blood cancers with a donation to the Leukemia & Lymphoma Society.
  • nelnel Member Posts: 2,859 ■□□□□□□□□□
    Hi,

    Yes ive seen the link but thanks.

    Anyway. ive installed ubuntu desktop 8.10. Now when using apt-get or apptitude it states:

    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    E: Couldn't find package apache2

    I can access the web and have configured the proxy settings in the software manager. Looking else where via google seems to bring up a few answers. Now i read on one site the source list file should include the following and enable you to access most of the software repositories required:

    Here is my new source list:

    [code# Ubuntu supported packages
    deb http://gb.archive.ubuntu.com/ubuntu dapper main restricted
    deb http://gb.archive.ubuntu.com/ubuntu dapper-updates main restricted
    deb http://security.ubuntu.com/ubuntu dapper-security main restricted

    # Ubuntu community supported packages
    deb http://gb.archive.ubuntu.com/ubuntu dapper universe multiverse
    deb http://gb.archive.ubuntu.com/ubuntu dapper-updates universe multiverse
    deb http://security.ubuntu.com/ubuntu dapper-security universe multiverse

    # Seveas' Ubuntu Packages
    deb http://mirror2.ubuntulinux.nl/ dapper-seveas all

    # Ubuntu backports project
    deb http://gb.archive.ubuntu.com/ubuntu dapper-backports main restricted universe multiverse

    # Upstream Wine
    deb http://wine.budgetdedicated.com/apt dapper main

    # Upstream Opera
    deb http://deb.opera.com/opera etch non-free

    # Medibuntu multimedia packages
    deb http://medibuntu.sos-sts.com/repo/ dapper free non-free

    # Canonical Commercial packages
    deb http://archive.canonical.com dapper-commercial main [/code]

    Do i need to add anything else or am i totally along the wrong lines? also if you use apt-get to install stuff shouldnt it alreadu know where to get all the gear from? or it it basically a case of having to tell it a url to find the packages to install?
    Xbox Live: Bring It On

    Bsc (hons) Network Computing - 1st Class
    WIP: Msc advanced networking
  • dynamikdynamik Banned Posts: 12,312 ■■■■■■■■■□
    Try:
    sudo apt-get apache2
    
  • nelnel Member Posts: 2,859 ■□□□□□□□□□
    hey dynamik,

    ive tried that but get the error : E: Invalid operation apache2
    Xbox Live: Bring It On

    Bsc (hons) Network Computing - 1st Class
    WIP: Msc advanced networking
  • dynamikdynamik Banned Posts: 12,312 ■■■■■■■■■□
    Looks like you're missing some dependencies.

    Try:
    sudo apt-get install apache2
    

    I think that'll get those as well.
  • nelnel Member Posts: 2,859 ■□□□□□□□□□
    Hey,

    Ive tried the sudo apt-get and sudo apptitude commands and neither worked. ive just unticked all of the source repositories, restarted, reticked them and it worked OK through the GUI package manager. However now, when i try to use "sudo apt-get" for the installs on the nagios steps it tries to connect to the ubuntu server and just sits at 0% (this is all through the terminal).

    Any idea's why it would just sit even though i have just completed things using the GUI? just i would rather follow the steps from the nagios docs then variate away from them using the gui.
    Xbox Live: Bring It On

    Bsc (hons) Network Computing - 1st Class
    WIP: Msc advanced networking
  • dynamikdynamik Banned Posts: 12,312 ■■■■■■■■■□
    Not sure. Just curious, did you use the "install" option from my second response? I had the same error as you when I omitted it, but it worked when I used it (I'm using a Linux Mint VM).
  • nelnel Member Posts: 2,859 ■□□□□□□□□□
    yep i tried that as that was the command stated on the nagios docs. it states it cannot find the destiation - even though it works through the gui package manager and i can ping it from the terminal.

    i tried it in a VM originally then i installed it on an old dell at work and still nothing.
    Xbox Live: Bring It On

    Bsc (hons) Network Computing - 1st Class
    WIP: Msc advanced networking
  • remyforbes777remyforbes777 Member Posts: 499
    What happens when you do an sudo aptitude update. Any time you add any repos you should do an update then an install of the package, so

    #aptitude update
    #aptitude install apache2
  • Met44Met44 Member Posts: 194
    OpsView provides an appliance which will run as a VM. It has worked for me with no issues, and should boot right up:

    http://docs.opsview.org/doku.php?id=opsview2.14:vmware_vm

    The manual install on Fedora is hell, but the installation on Debian went very smooth. Haven't tried it with Ubuntu. I would recommend the VM appliance, but here is a link for the Debian installation guide for 2.14 if you would like to look at it:

    http://docs.opsview.org/doku.php?id=opsview2.14:debian-installation
  • AhriakinAhriakin Member Posts: 1,799 ■■■■■■■■□□
    The easiest way to get it all up and running is install Ubuntu server 8.04, you will get an application list during the install listing server components like DNS etc. Choose : LAMP ("Linux Apache MySQL PHP" it's a cool combined pacakage for just about everything you need for a web-based business App. on Linux), OPENSSH Server and Mail Server (For email alerts). It will Ask for a MySQL password which can be anything you choose, this is separate from your operating system credentials but you can have them match, you will only ever need this for any low level MySQL work (which for normal operations means you won't have to touch it). It will also prompt for the mode you want Postfix to run in, presuming you have your own Email server and you want to bounce your email off of it choose "Satellite", choose the mail domain you want to appear as 'from' - like myopsview.net and then the IP address of your own SMTP server. Alternatively you can set Postfix up as a standalone server but that's a lot more complex and Satellite works fine.
    If you want to keep the Ubuntu Server installed you have already rather than reinstall then just run "tasksel" to bring up the same application menu that you would get during the install.

    tasksel.jpg


    Some essential commands you'll need to know:
    The CLI is very similar in function to DOS, obviously a lot more powerful and there are a few syntax differences but not as much as you might think. Also linux uses "/" instead of "\"
    If an editor or an app. like top does not show you a "quit" option usually just pressing "Q" will exit.
    CTRL-C stops a running job, CTZL-Z pauses it and you can run "fg" to bring it back again. Or run "bg" to have it run in the background.

    cd = cd
    Dir = ls
    copy = cp
    delete = rm
    move = mv (you also use this to rename, so mv test.conf test2.conf simply renames the originl file).
    edit = nano (if it's installed, if not try vi but nano is much nice imho)
    Check resource use = top
    To find files first run "updatedb" to scan and index your drive after any big installs, then use "locate xxxxx". You can use the native find command but I prefer this way as it's ultimately faster.
    Most config files are in /etc/xxxxx, most will have the extension .conf .
    Wildcards are just like DOS.


    When everything is installed :

    First up when I know I am going to be doing a lot of root level work I use sudo su (enter your normal user password) to pass into full admin mode on the CLI, otherwise you have to remember to use sudo for anything low level, this way you just do it once.
    Also once you have the system installed, and as long as you did choose OPENSSH SERVER from the install or tasksel you can now connect remotely using SSH. So load up putty and do the rest of the work from there - the main advantage is you will be able to copy/paste commands/paths/urls from the instructions into your command line.

    1. Update the OS - run apt-get update to update your list of available packages, then apt-get dist-upgrade to begin the OS updates. You will likely be prompted for a MySQL password and to choose Okay for the updated OpenSSH keys but that really depends on whether they get updated or not. It's all logical enough and is pretty much Debian's version of Windows Update (though it goes further in updating any non-OS packages that it has updates for aswell).

    2. Follow the instructions here http://docs.opsview.org/doku.php?id=opsview2.14:debian-installation , the main thing is you will edit your sources.list file to include the Opsview download servers so that when you run "apt-get install opsview" it knows where to go (remember to run "apt-get update" after making your changes to sources.list so that it reads the list of files available from the opsview repositories). btw from a windows point of view I think the easiest/best editor to use is "nano" it should already be installed on Ubuntu server but if you ever find it's not just "apt-get install nano", takes a few seconds. So you'd run "nano /etc/apt/sources.list" then simply paste in the lines from the page I linked above, save and exit, then run the update, then install opsview. The opsview install itself is very simple.

    3. The other options listed below for Apache are optional but I advise you to have a go. Just backup any config files you modify (e.g. cp /etc/apache2/apache2.conf /etc/apache2/apache2.conf.old )


    I also recommend you install Webmin as it will let you do most of your operating system maintenance from a nice Web GUI. www.webmin.com, right-click the debian package link on the left and copy the url to the clipboard, open an SSH session to your server and cd /tmp to go into the tmp folder (remember unlike Windows when your server reboots it empties this folder). enter the command wget and leave a space and paste that Webmin/Debian package URL in. So right now for example the command would be wget http://prdownloads.sourceforge.net/webadmin/webmin_1.441_all.deb . When it is downloaded run dpkg -i webmin_1.441_all.deb (or whatever the package name is) . It will give you an error about dependancies, this is fine. Then it is back to the command line run apt-get install -f, this will make APT download and install any outstanding dependancies (which you previously needed for Webmin) and then it will automatically resume the installation of Webmin so you're set. Then just connect to https://xxx.xxx.xxx.xxx:10000 and use your normal Ubuntu credentials to login. It's a pretty cool little app. esp. if you are new to Linux.


    Anyway hope that helps a bit.
    We responded to the Year 2000 issue with "Y2K" solutions...isn't this the kind of thinking that got us into trouble in the first place?
  • nelnel Member Posts: 2,859 ■□□□□□□□□□
    Wow, great post ahriakin.

    At the moment I have ubuntu desktop installed as no one at work knows Linux from the cli and as many people could be using it I thought the GUI would be more appropriate but if you can use websdmin that will be fine. I'll give that a shot in a few hours when I get to work.

    It's been quite frustrating due to my lack - or should I say no Linux experience but I'm desperate for something like this as we have nothing in place at the mo.

    Again thanks for the reaponses and I will no doubt report back! Ha!
    Xbox Live: Bring It On

    Bsc (hons) Network Computing - 1st Class
    WIP: Msc advanced networking
  • nelnel Member Posts: 2,859 ■□□□□□□□□□
    Hi,

    OK, now ive installed ubuntu server with all the options you've mentioned.

    Im at th epoint of installing opsview using aptitude install opsview

    Now when i run it, it goes through the motions but then appears with the error:
    W: GPG error: [url]http://apt.opsview.org[/url] etch Release: The following signatures coul
    dn't be verified because the public key is not available: NO_PUBKEY FB4C675977CB
    2CF6
    W: GPG error: [url]http://ftp.debian.org[/url] etch Release: The following signatures could
    n't be verified because the public key is not available: NO_PUBKEY A70DAF536070D
    3A1 NO_PUBKEY B5D0C804ADB11277
    W: You may want to run apt-get update to correct these problems
    

    Looks like a key is missing. i googled it and found a link saying use this to fix the key issues:
    gpg --keyserver subkeys.pgp.net --recv KEYHERE
    gpg --export --armor KEYHERE | sudo apt-key add -
    

    However, i run this for each key it states is missing and the errors go away and everything seems to update using apt-get update. but when i go to install opsview using "aptitude install opsview" i get the following message:



    aptitude install opsview
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    Reading extended state information
    Initializing package states... Done
    The following packages are BROKEN:
      opsview-base
    The following NEW packages will be installed:
      avahi-daemon{a} defoma{a} fontconfig-config{a} ghostscript{a}
      ghostscript-x{a} gs{a} gsfonts{a} gsfonts-x11{a} java-common{a} ksh{a}
      libart-2.0-2{a} libasound2{a} libavahi-common-data{a} libavahi-common3{a}
      libavahi-core5{a} libcairo2{a} libcupsimage2{a} libdaemon0{a}
      libdigest-hmac-perl{a} libdigest-sha1-perl{a} libfontconfig1{a}
      libfontenc1{a} libfreetype6{a} libgd-tools{a} libgd2-xpm{a} libgs8{a}
      libice6{a} libio-socket-inet6-perl{a} libjpeg62{a} libltdl7{a}
      libmcrypt4{a} libnet-dns-perl{a} libnet-ip-perl{a} libnet-snmp-perl{a}
      libnetpbm10{a} libnss-mdns{a} libpaper-utils{a} libpaper1{a}
      libperl5.10{a} libpixman-1-0{a} librrd2{a} librrds-perl{a} libsensors3{a}
      libsm6{a} libsnmp-base{a} libsnmp-perl{a} libsnmp-session-perl{a}
      libsnmp15{a} libsocket6-perl{a} libsysfs2{a} libtiff4{a}
      libxcb-render-util0{a} libxcb-render0{a} libxfont1{a} libxi6{a}
      libxml-perl{a} libxp6{a} libxpm4{a} libxrender1{a} libxt6{a} libxtst6{a}
      links{a} mrtg{a} netpbm{a} odbcinst1debian1{a} opsview opsview-core{a}
      opsview-perl{a} opsview-reports{a} opsview-web{a} psfontmgr{a} rrdtool{a}
      snmp{a} snmpd{a} sun-java5-bin{a} sun-java5-jre{a} unixodbc{a}
      xfonts-encodings{a} xfonts-utils{a} xutils-dev{a}
    0 packages upgraded, 81 newly installed, 0 to remove and 39 not upgraded.
    Need to get 79.2MB of archives. After unpacking 221MB will be used.
    The following packages have unmet dependencies:
      opsview-base: Depends: libltdl3 which is a virtual package.
    The following actions will resolve these dependencies:
    
    Keep the following packages at their current version:
    opsview [Not Installed]
    opsview-base [Not Installed]
    opsview-core [Not Installed]
    opsview-reports [Not Installed]
    opsview-web [Not Installed]
    
    Score is -9845
    
    Accept this solution? [Y/n/q/?]
    

    Any idea's ??? icon_scratch.gif [/quote]
    Xbox Live: Bring It On

    Bsc (hons) Network Computing - 1st Class
    WIP: Msc advanced networking
  • nelnel Member Posts: 2,859 ■□□□□□□□□□
    sorry forgot to mention that when i press Yes i get:

    No packages will be installed, upgraded, or removed.
    0 packages upgraded, 0 newly installed, 0 to remove and 39 not upgraded.
    Need to get 0B of archives. After unpacking 0B will be used.
    Xbox Live: Bring It On

    Bsc (hons) Network Computing - 1st Class
    WIP: Msc advanced networking
  • nelnel Member Posts: 2,859 ■□□□□□□□□□
    Hi,

    for anyone interested i had continuous problems installing opsview on ubuntu server 8.10. Issue after issue really. As im not a linux user i had difficulties with some of the them. the majority i googled and i was able to get to the next stage but eventually it became a pain. i reverted back to the 8.04 LTS version and got it working OK. I still had lots of issues (even though i was following the documentation!!!) but managed to get it installed.... eventually

    For anyone interested there is a VM image on there website too.

    Now secondly,

    I am trying to install a plugin to capture netflow packets using FLAVIO on the opsview website. However it states just download it etc etc so i used wget but when i try it the console appears with "connection timed out" you can see below:
    http://sourceforge.net/project/downloading.php?group_id=58819
      (try:12) => `downloading.php?group_id=58819'
    Connecting to sourceforge.net|216.34.181.60|:80... failed: Connection timed out.
    Retrying.
    

    You can ping the Server IP ok and you can see it resolves the name. I thought it maybe the url i am using?:

    Even when i try for another URL - for example the webmin advised by ahriakan - it gives the same error.

    Any idea's? Thanks
    Xbox Live: Bring It On

    Bsc (hons) Network Computing - 1st Class
    WIP: Msc advanced networking
  • livenliven Member Posts: 918
    What is the actual file your trying to download?

    If you have a file name, google it and try to download it from an alternate site.

    Then do a manual install. I have had to do this kind of thing when installing linux apps in the past.
    encrypt the encryption, never mind my brain hurts.
  • nelnel Member Posts: 2,859 ■□□□□□□□□□
    liven wrote:
    What is the actual file your trying to download?

    If you have a file name, google it and try to download it from an alternate site.

    Then do a manual install. I have had to do this kind of thing when installing linux apps in the past.

    Its Flavio. a plugin to analyse netflow data. Ive tried using a different URL but not luck. also tried different apps too. Possibly something on the box causing this or something locally perhaps?
    Xbox Live: Bring It On

    Bsc (hons) Network Computing - 1st Class
    WIP: Msc advanced networking
Sign In or Register to comment.