Nagios Exchange - freebsd check memory
Finaly I get it!
--vladget
Labels
freebsd
(12)
AWS
(9)
linux
(8)
mysql
(8)
EC2
(7)
auto-scaling
(7)
php
(7)
unix
(7)
howto
(5)
amazon
(4)
example
(4)
php5.3
(4)
/usr/ports
(3)
backup
(3)
bash
(3)
cloud
(3)
cloudwatch
(3)
ffmpeg
(3)
loadbalancer
(3)
mycld
(3)
patch
(3)
php53
(3)
scaling
(3)
scalr
(3)
security
(3)
spot instances
(3)
sql
(3)
tutorial
(3)
AWSSDKforPHP
(2)
CentOS
(2)
WSDL
(2)
ZEND framework
(2)
alarms
(2)
bug
(2)
cache
(2)
cloudfusion
(2)
console
(2)
exploit
(2)
fileinfo
(2)
fix
(2)
lauchconfig
(2)
mysqldump
(2)
mysqlse
(2)
php-fpm
(2)
policies
(2)
ports
(2)
portupgrade
(2)
redhat
(2)
sed
(2)
shell
(2)
sphinx
(2)
sphinxse
(2)
video
(2)
x264
(2)
/etc/motd
(1)
9.x
(1)
ELB
(1)
MP4Box
(1)
MySQL status codes HY000 sqlstate sql states
(1)
OS
(1)
RFC
(1)
SIP
(1)
URI
(1)
alias
(1)
apache
(1)
banner
(1)
big databases
(1)
blog
(1)
bsd
(1)
bugtraq
(1)
checklist
(1)
chkconfig
(1)
clean
(1)
cleaning
(1)
clear
(1)
code
(1)
conf
(1)
configs
(1)
configuration
(1)
content type
(1)
converting
(1)
core
(1)
cron
(1)
cve
(1)
database
(1)
debian
(1)
deinterlasing
(1)
dependency
(1)
disable
(1)
dump
(1)
editor
(1)
editors
(1)
email
(1)
encoding char utf8 latin1 script linux bash
(1)
error
(1)
escaping
(1)
exim
(1)
expat
(1)
exploits
(1)
extensions
(1)
faac
(1)
fastcgi
(1)
feed
(1)
figlet
(1)
fps
(1)
freebsd-update
(1)
freeswitch
(1)
fresh installation
(1)
gcc
(1)
geo
(1)
gop
(1)
gpac
(1)
grep
(1)
h.264
(1)
h264
(1)
hitrate
(1)
hostname
(1)
incremental
(1)
init
(1)
init.d
(1)
innobackupex
(1)
ivp6
(1)
keyint_min
(1)
libx264
(1)
libxml2
(1)
list
(1)
mail
(1)
make
(1)
map
(1)
maxmind
(1)
mencoder
(1)
mime
(1)
mindmeister
(1)
mindmeister.com
(1)
mp4
(1)
mplayer
(1)
mta queue
(1)
mysql charset
(1)
mysql charset encoding char utf8 latin1 script linux bash
(1)
networking
(1)
nginx
(1)
nmap
(1)
optimization
(1)
paranoia
(1)
paranoiac
(1)
percona
(1)
performance
(1)
portdowngrade
(1)
portsnap
(1)
postgre
(1)
postgres
(1)
postgresql
(1)
presets
(1)
putty
(1)
query cache
(1)
rc
(1)
rc.conf
(1)
rc.d
(1)
remote
(1)
restore
(1)
rhel
(1)
rhel5
(1)
script
(1)
scrubing
(1)
seclist
(1)
seclist.org
(1)
seek
(1)
seeking
(1)
segfault
(1)
slow loris
(1)
slowloris
(1)
smtp
(1)
software
(1)
sphinxsearch
(1)
stty
(1)
terminal
(1)
time
(1)
timezone
(1)
tmp
(1)
transcoding
(1)
tty
(1)
update
(1)
video transcoding
(1)
vulnerabilities
(1)
wal-e
(1)
web
(1)
web servers
(1)
wordpress
(1)
x86_64
(1)
xtrabackup
(1)
yum
(1)
zend
(1)
Saturday, 26 June 2010
Wednesday, 23 June 2010
Correct FreeBSD rc script for php-fpm
# cat /usr/local/etc/rc.d/php-fpm
-- vladget
#!/bin/sh
# PROVIDE: php-fpm
# REQUIRE: NETWORKING SERVERS
# KEYWORD: shutdown
# Add the following lines to /etc/rc.conf to enable php-fpm:
# php_fpm_enable (bool): Set to "NO" by default.
# Set it to "YES" to enable php-fpm
# php_fpm_config (str): Set to "" by default.
# Define your php-fpm configuration file here.
. /etc/rc.subr
name="php_fpm"
rcvar=`set_rcvar`
load_rc_config $name
: ${php_fpm_enable="NO"}
: ${php_fpm_pidfile="/var/run/php-fpm.pid"}
: ${php_fpm_config="/usr/local/etc/php-fpm.conf"}
: ${php_fpm_flags="--fpm"}
command="/usr/local/bin/php-fpm"
pidfile=${php_fpm_pidfile}
reload_precmd="php_fpm_prereload"
quit_cmd="php_fpm_quit"
[ -n "$php_fpm_config" ] && php_fpm_flags="$php_fpm_flags --fpm-config $php_fpm_config"
php_fpm_prereload()
{
sig_reload=USR2
}
php_fpm_quit()
{
sig_stop=QUIT
run_rc_command stop
}
extra_commands="reload quit"
run_rc_command "$1"
-- vladget
Thursday, 17 June 2010
Compiling MySQL 5.0.x with SphinxSE (as Engine) on FreeBSD/Linux - tutorial / copy-paste how to
FreeBSD:
# Install dependencies (bison, patch, automake, libtool), etc:
portsnap fetch update
cd /usr/ports/devel/bison && make install clean distclean
cd /usr/ports/devel/patch && make install clean distclean
cd /usr/ports/devel/automake110 && make install clean distclean
cd /usr/ports/devel/libtool22 && make install clean distclean
cd /usr/ports/ftp/wget && make install clean distclean
# Get sources:
mkdir -p /mysql_new/src && cd /mysql_new/src
wget "http://sphinxsearch.com/downloads/sphinx-0.9.9.tar.gz"
wget "http://downloads.mysql.com/archives/mysql-5.0/mysql-5.0.91.tar.gz"
# Extract sorces:
tar zxpf sphinx-0.9.9.tar.gz
tar zxpf mysql-5.0.91.tar.gz
# Patching MySQL sources:
cd mysql-5.0.91 && patch -p1 < ../sphinx-0.9.9/mysqlse/sphinx.5.0.37.diff
/bin/sh BUILD/autorun.sh
# Copy Sphinx sources to MySQL sources:
mkdir sql/sphinx && cp ../sphinx-0.9.9/mysqlse/* sql/sphinx
# Configure and make MySQL:
# Add this variables to make.conf
# and DONT FORGET REMOVE its from make.conf!
cat /etc/make.conf
CC='cc'
CFLAGS=' -DDBUG_OFF -O2 -pipe -fno-strict-aliasing '
CXX='c++'
CXXFLAGS=' -DDBUG_OFF -O2 -pipe -fno-strict-aliasing -O2 -pipe -fno-strict-aliasing -felide-constructors -fno-rtti -fno-exceptions -fno-implicit-templates -fno-exceptions -fno-rtti -DMYSQLD_NET_RETRY_COUNT=1000000'
LDFLAGS=''
ASFLAGS=''
./configure \
--localstatedir=/var/db/mysql \
--without-debug \
--without-readline \
--without-libedit \
--without-bench \
--without-extra-tools \
--with-libwrap \
--with-low-memory \
--with-sphinx-storage-engine \
--with-comment=FreeBSD && make
# Install MySQL:
make install
# Check it:
mysql> show engines\G
...
*************************** 9. row ***************************
Engine: SPHINX
Support: YES
Comment: Sphinx storage engine 0.9.9
...
# Recommend Readings:
Installing SphinxSE
Linux:
MySQL: How do you enable sphinxse (Sphinx Storage Engine) in your mysql installation?
-- FreeBSDer
# Install dependencies (bison, patch, automake, libtool), etc:
portsnap fetch update
cd /usr/ports/devel/bison && make install clean distclean
cd /usr/ports/devel/patch && make install clean distclean
cd /usr/ports/devel/automake110 && make install clean distclean
cd /usr/ports/devel/libtool22 && make install clean distclean
cd /usr/ports/ftp/wget && make install clean distclean
# Get sources:
mkdir -p /mysql_new/src && cd /mysql_new/src
wget "http://sphinxsearch.com/downloads/sphinx-0.9.9.tar.gz"
wget "http://downloads.mysql.com/archives/mysql-5.0/mysql-5.0.91.tar.gz"
# Extract sorces:
tar zxpf sphinx-0.9.9.tar.gz
tar zxpf mysql-5.0.91.tar.gz
# Patching MySQL sources:
cd mysql-5.0.91 && patch -p1 < ../sphinx-0.9.9/mysqlse/sphinx.5.0.37.diff
/bin/sh BUILD/autorun.sh
# Copy Sphinx sources to MySQL sources:
mkdir sql/sphinx && cp ../sphinx-0.9.9/mysqlse/* sql/sphinx
# Configure and make MySQL:
# Add this variables to make.conf
# and DONT FORGET REMOVE its from make.conf!
cat /etc/make.conf
CC='cc'
CFLAGS=' -DDBUG_OFF -O2 -pipe -fno-strict-aliasing '
CXX='c++'
CXXFLAGS=' -DDBUG_OFF -O2 -pipe -fno-strict-aliasing -O2 -pipe -fno-strict-aliasing -felide-constructors -fno-rtti -fno-exceptions -fno-implicit-templates -fno-exceptions -fno-rtti -DMYSQLD_NET_RETRY_COUNT=1000000'
LDFLAGS=''
ASFLAGS=''
./configure \
--localstatedir=/var/db/mysql \
--without-debug \
--without-readline \
--without-libedit \
--without-bench \
--without-extra-tools \
--with-libwrap \
--with-low-memory \
--with-sphinx-storage-engine \
--with-comment=FreeBSD && make
# Install MySQL:
make install
# Check it:
mysql> show engines\G
...
*************************** 9. row ***************************
Engine: SPHINX
Support: YES
Comment: Sphinx storage engine 0.9.9
...
Installing SphinxSE
Linux:
MySQL: How do you enable sphinxse (Sphinx Storage Engine) in your mysql installation?
-- FreeBSDer
Subscribe to:
Posts (Atom)