Hello,
I got big zabbix database, over 170gb. Over 300nvps. Its working "not bad" but it can work better
I belive the bottleneck of the system is database.
Im looking for some tuning tips.
Of coures I read a lot about howto tuning zabbix, postgres and what hardware should it be.
So my config`s:
Hardware:
2x X5690 @ 3.47
24Gb Ram memory
4x 240gb ssd disk in raid 10
But Raid controler is only 1,5Gbps. <- This is in plans to change.
Software:
Postgres 9.1
Zabbix 2.0.4
Redhat 6.3
Zabbix_server.conf
postgres.conf
1. I`m afraid the autovacuum isnt working at all.
2. I`m making vacuum full on evry sunday. This help for a while. Database is ligther for even 15gb (175gb before and 160gb after vacuum)
3. I want to hold long history. Now Im holding almoust evry item for 90 days. I plan to hold this for 190days. And trends for 365days
4. I know I should make partitionig, so we can jump this tip.
5. 300nvps is big value, but in plan is ~500nvps.
6. When postgres 9.3 will be stable version i wannt to migrate my database.
7. Is there something else then vaccum analyze in postgres, like analyze in oracle?
Please advice me, is this correct path to tuning my zabbix, is there something I can do now?
Regards,
Pietro
I got big zabbix database, over 170gb. Over 300nvps. Its working "not bad" but it can work better

I belive the bottleneck of the system is database.
Im looking for some tuning tips.
Of coures I read a lot about howto tuning zabbix, postgres and what hardware should it be.
So my config`s:
Hardware:
2x X5690 @ 3.47
24Gb Ram memory
4x 240gb ssd disk in raid 10
But Raid controler is only 1,5Gbps. <- This is in plans to change.
Software:
Postgres 9.1
Zabbix 2.0.4
Redhat 6.3
Zabbix_server.conf
NodeID=1
LogFile=/tmp/zabbix_server.log
LogFileSize=1000
DebugLevel=3
DBHost=localhost
DBName=zabbix
DBUser=zabbix
DBPassword=5r4e3w2q
SenderFrequency=5
CacheSize=32M
HistoryCacheSize=256M
TrendCacheSize=16M
HistoryTextCacheSize=64M
Timeout=15
FpingLocation=/usr/local/sbin/fping
LogSlowQueries=10000
StartPollers=30
StartPingers=15
StartPollersUnreachable=30
StartIPMIPollers=10
StartTrappers=15
StartDBSyncers=10
StartHTTPPollers=15
LogFile=/tmp/zabbix_server.log
LogFileSize=1000
DebugLevel=3
DBHost=localhost
DBName=zabbix
DBUser=zabbix
DBPassword=5r4e3w2q
SenderFrequency=5
CacheSize=32M
HistoryCacheSize=256M
TrendCacheSize=16M
HistoryTextCacheSize=64M
Timeout=15
FpingLocation=/usr/local/sbin/fping
LogSlowQueries=10000
StartPollers=30
StartPingers=15
StartPollersUnreachable=30
StartIPMIPollers=10
StartTrappers=15
StartDBSyncers=10
StartHTTPPollers=15
max_connections = 300 # (change requires restart)
shared_buffers = 12288MB # min 128kB
work_mem = 64MB # min 64kB
maintenance_work_mem = 216MB # min 1MB
wal_level = hot_standby # minimal, archive, or hot_standby
wal_buffers = -1 # min 32kB, -1 sets based on shared_buffers
checkpoint_segments = 64 # in logfile segments, min 1, 16MB each
checkpoint_timeout = 30min # range 30s-1h
checkpoint_completion_target = 0.8 # checkpoint target duration, 0.0 - 1.0
max_wal_senders = 5 # max number of walsender processes
cpu_tuple_cost = 0.0030 # same scale as above
cpu_index_tuple_cost = 0.0010 # same scale as above
cpu_operator_cost = 0.0005 # same scale as above
effective_cache_size = 12384MB
log_destination = 'stderr' # Valid values are combinations of
logging_collector = on # Enable capturing of stderr and csvlog
log_directory = 'pg_log' # directory where log files are written,
log_filename = 'postgresql-%a.log' # log file name pattern,
log_truncate_on_rotation = on # If on, an existing log file with the
log_rotation_age = 1d # Automatic rotation of logfiles will
log_rotation_size = 0 # Automatic rotation of logfiles will
log_min_error_statement = warning # values in order of decreasing detail:
log_min_duration_statement = 1000 # -1 is disabled, 0 logs all statements
log_error_verbosity = default # terse, default, or verbose messages
log_line_prefix = '%m %u %e' # special values:
autovacuum = on # Enable autovacuum subprocess? 'on'
autovacuum_max_workers = 5 # max number of autovacuum subprocesses
autovacuum_naptime = 1min # time between autovacuum runs
datestyle = 'iso, mdy'
lc_messages = 'en_US.UTF-8' # locale for system error message
lc_monetary = 'en_US.UTF-8' # locale for monetary formatting
lc_numeric = 'en_US.UTF-8' # locale for number formatting
lc_time = 'en_US.UTF-8' # locale for time formatting
default_text_search_config = 'pg_catalog.english'
shared_buffers = 12288MB # min 128kB
work_mem = 64MB # min 64kB
maintenance_work_mem = 216MB # min 1MB
wal_level = hot_standby # minimal, archive, or hot_standby
wal_buffers = -1 # min 32kB, -1 sets based on shared_buffers
checkpoint_segments = 64 # in logfile segments, min 1, 16MB each
checkpoint_timeout = 30min # range 30s-1h
checkpoint_completion_target = 0.8 # checkpoint target duration, 0.0 - 1.0
max_wal_senders = 5 # max number of walsender processes
cpu_tuple_cost = 0.0030 # same scale as above
cpu_index_tuple_cost = 0.0010 # same scale as above
cpu_operator_cost = 0.0005 # same scale as above
effective_cache_size = 12384MB
log_destination = 'stderr' # Valid values are combinations of
logging_collector = on # Enable capturing of stderr and csvlog
log_directory = 'pg_log' # directory where log files are written,
log_filename = 'postgresql-%a.log' # log file name pattern,
log_truncate_on_rotation = on # If on, an existing log file with the
log_rotation_age = 1d # Automatic rotation of logfiles will
log_rotation_size = 0 # Automatic rotation of logfiles will
log_min_error_statement = warning # values in order of decreasing detail:
log_min_duration_statement = 1000 # -1 is disabled, 0 logs all statements
log_error_verbosity = default # terse, default, or verbose messages
log_line_prefix = '%m %u %e' # special values:
autovacuum = on # Enable autovacuum subprocess? 'on'
autovacuum_max_workers = 5 # max number of autovacuum subprocesses
autovacuum_naptime = 1min # time between autovacuum runs
datestyle = 'iso, mdy'
lc_messages = 'en_US.UTF-8' # locale for system error message
lc_monetary = 'en_US.UTF-8' # locale for monetary formatting
lc_numeric = 'en_US.UTF-8' # locale for number formatting
lc_time = 'en_US.UTF-8' # locale for time formatting
default_text_search_config = 'pg_catalog.english'
1. I`m afraid the autovacuum isnt working at all.
2. I`m making vacuum full on evry sunday. This help for a while. Database is ligther for even 15gb (175gb before and 160gb after vacuum)
3. I want to hold long history. Now Im holding almoust evry item for 90 days. I plan to hold this for 190days. And trends for 365days
4. I know I should make partitionig, so we can jump this tip.
5. 300nvps is big value, but in plan is ~500nvps.
6. When postgres 9.3 will be stable version i wannt to migrate my database.
7. Is there something else then vaccum analyze in postgres, like analyze in oracle?
Please advice me, is this correct path to tuning my zabbix, is there something I can do now?
Regards,
Pietro
Comment