| General Security Discussions Discuss anything that is security related here. |
|
#1
| ||||
| ||||
| Zabbix
Has anyone used this an tell me what they think? I don't have any test boxes atm to use but there is already plans to write AV monitors. Thanks zabbix.com Update: In the process of setting this up. Will report back what I think as well as my possible soon to be partner in business matters thinks.
__________________ "...a computer is a stupid machine with the ability to do incredibly smart things, while computer programmers are smart people with the ability to do incredibly stupid things. They are, in short, a perfect match". Last edited by Tsukasa; 15th January 2010 at 17:12. |
|
#2
| ||||
| ||||
| Re: Zabbit
Installing zabbix ubuntu 9.10 server Code: sudo apt-get install build-essential gnustep-make sudo apt-get install linux-headers-$(uname -r) sudo apt-get install ntp ntpdate sudo apt-get install mysql-server apache2 php5 php5-gd snmp libsnmp-dev libcurl4 libiksemel3 libiksemel-dev libmysql++-dev fping Code: sudo adduser zabbix Code: sudo mysql -u'user' -p'password' mysql> create database zabbix; mysql> exit Code: su zabbix cd /home/zabbix Code: wget http://downloads.sourceforge.net/project/zabbix/ZABBIX%20Latest%20Stable/1.8/zabbix-1.8.tar.gz?use_mirror=cdnetworks-us-1 tar zxvpf zabbix* cd zabbix* Code: cat create/schema/mysql.sql | mysql -u'user' -p'password' zabbix cat create/data/data.sql | mysql -u'user -p'password' zabbix cat create/data/images_mysql.sql | mysql -u'user' -p'password' zabbix Code: cd ../.. Code: sudo ./configure --enable-server --enable-agent --with-mysql --with-net-snmp --with-jabber=/usr/ --with-libcurl sudo make install Code: sudo nano -w /etc/services *add zabbix_agent 10050/tcp zabbix_trap 10051/tcp *save and exit Code: sudo mkdir /etc/zabbix sudo chown -R zabbix.zabbix /etc/zabbix/ cp misc/conf/zabbix_* /etc/zabbix/ Code: nano /etc/zabbix/zabbix_agentd.conf *find Server=127.0.0.1 and change it to the machines ip *find #ListenIP=127.0.0.1 and uncomment it and change to your machines IP *save and exit Code: nano /etc/zabbix/zabbix_server.conf *find DBPassword=YOUR-DATABASE-PASSWORD *find #ListenIP=127.0.0.1 uncomment and change to your machines IP *save and exit Code: sudo cp misc/init.d/debian/zabbix-server /etc/init.d sudo cp misc/init.d/debian/zabbix-agent /etc/init.d Code: sudo nano /etc/init.d/zabbix-server
*find DAEMON=/home/zabbix/bin/${NAME}
change to DAEMON=/usr/sbin/${NAME}
*save and exit
Code: sudo /etc/init.d/zabbix-agent
*find DAEMON=/home/zabbix/bin/${NAME}
change to DAEMON=/usr/sbin/${NAME}
*save and exit
Code: sudo chmod 755 /etc/init.d/zabbix-server sudo update-rc.d zabbix-server defaults sudo chmod 755 /etc/init.d/zabbix-agent sudo update-rc.d zabbix-agent defaults Code: mkdir /home/zabbix/web cp -R frontends/php/* /home/zabbix/web/ this assumes apache isn't hosting anything else so we are just going to edit 000-default Code: sudo nano /etc/apache2/sites-enabled/000-default
*Make it look kind of like this by changing what needs changing
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerSignature off
DocumentRoot /home/zabbix/web/
ServerName yourservername.com
ErrorLog /var/log/apache2/zabbixweb.log
<Directory />
Order deny,allow
deny from all
Options None
AllowOverride None
</Directory>
<Directory /home/zabbix/web/>
php_Admin_value mbstring.func_overload 2
php_value max_execution_time 300
php_value post_max_size 16M
php_value memory_limit 128M
Options None
AllowOverride None
Order allow,deny
allow from all
</Directory>
Code: cp /home/zabbix/zabbix-1.8/src/zabbix_agent/zabbix_agent /usr/sbin/ cp /home/zabbix/zabbix-1.8/src/zabbix_agent/zabbix_agentd /usr/sbin/ cp /home/zabbix/zabbix-1.8/src/zabbix_get/zabbix_get /usr/sbin/ cp /home/zabbix/zabbix-1.8/src/zabbix_sender/zabbix_sender /usr/sbin/ cp /home/zabbix/zabbix-1.8/src/zabbix_server/zabbix_server /usr/sbin/ Code: /etc/init.d/apache2 restart /etc/init.d/zabbix-server start /etc/init.d/zabbix-agent start Code: ps aux | grec zabbix
__________________ "...a computer is a stupid machine with the ability to do incredibly smart things, while computer programmers are smart people with the ability to do incredibly stupid things. They are, in short, a perfect match". Last edited by Tsukasa; 21st January 2010 at 02:48. |
|
#3
| ||||
| ||||
| Re: Zabbit
Nice one, Zabbix looks pretty cool! +Rep
__________________ ![]() Quote:
|
|
#4
| ||||
| ||||
| Re: Zabbit
Nice tutorial Tsukasa, will be useful when I get around trying zabbix :]
__________________ Quote:
|
|
#5
| ||||
| ||||
| Re: Zabbit
I don't take credit for this script this was written by the name eger. The script works well and uses zabbix_sender Code: serverName = "zabbix.mydoamin.com"
hostName = "web_server.mydomain.com"
zbxSender = "C:\Program Files\Zabbix Agent\zabbix_sender.exe"
updatesHigh = 0
updatesOptional = 0
Set objSearcher = CreateObject("Microsoft.Update.Searcher")
Set objSysInfo = CreateObject("Microsoft.Update.SystemInfo")
Set objResults = objSearcher.Search("IsInstalled=0")
Set colUpdates = objResults.Updates
Set WSHShell = CreateObject("WScript.Shell")
For i = 0 to colUpdates.Count - 1
If (colUpdates.Item(i).IsInstalled = False AND colUpdates.Item(i).AutoSelectOnWebSites = False) Then
updatesOptional = updatesOptional + 1
ElseIf (colUpdates.Item(i).IsInstalled = False AND colUpdates.Item(i).AutoSelectOnWebSites = True) Then
updatesHigh = updatesHigh + 1
End IF
Next
updatesTotal = (updatesHigh + updatesOptional)
WSHShell.Exec zbxSender & " -z " & serverName & " -s " & hostName & " -k win_updates[total] -o " & updatesTotal
WSHShell.Exec zbxSender & " -z " & serverName & " -s " & hostName & " -k win_updates[high] -o " & updatesHigh
WSHShell.Exec zbxSender & " -z " & serverName & " -s " & hostName & " -k win_updates[optional] -o " & updatesOptional
WSHShell.Exec zbxSender & " -z " & serverName & " -s " & hostName & " -k win_updates[reboot] -o " & objSysInfo.RebootRequired
WScript.Quit 0
You will need to add a scheduled task to run this script as often as you want to get Windows Update data.
Then create some new items for your Template or Host to use it. Create an item for each of these 3 keys:
Settings for win_updates[total], win_updates[high], and win_updates[optional]:
Settings for win_updates[reboot]:
Triggers: High priority updates: Code: {Your_Template:win_updates[high].last(0)}>0
Code: ({Your_Template:win_updates[high].last(0)}=0)&({Your_Template:win_updates[reboot].str(True)}=1)
__________________ "...a computer is a stupid machine with the ability to do incredibly smart things, while computer programmers are smart people with the ability to do incredibly stupid things. They are, in short, a perfect match". |
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
| |