My /etc/rc.local in Development Server of RHEL

[codesyntax lang=”bash”]

#!/bin/sh
#
# This script will be executed *after* all the other init scripts.
# You can put your own initialization stuff in here if you don't
# want to do the full Sys V style init stuff.

touch /var/lock/subsys/local

#stop iptables
service iptables stop

#start vsftpd
/etc/rc.d/init.d/vsftpd start

#start svn server
/usr/local/svnserver/bin/svnserve -d -r /data/svndata

#start php-fpm
/usr/local/webserver/php/sbin/php-fpm start

#start mysql server
/bin/sh /usr/local/webserver/mysql/bin/mysqld_safe --defaults-file=/data/mysql_data1/my.cnf &
/bin/sh /usr/local/webserver/mysql/bin/mysqld_safe --defaults-file=/data/mysql_data2/my.cnf &
/bin/sh /usr/local/webserver/mysql/bin/mysqld_safe --defaults-file=/data/mysql_data3/my.cnf &

#Start memcached
/usr/local/memcached/bin/memcached -d -m 1024 -u root -l 127.0.0.1 -p 11211 -c 1024 -P /tmp/memcached.pid

#start nginx server
/usr/local/webserver/nginx/sbin/nginx

#mount ftp dir
mount --bind /data/share_data /home/kim/share

[/codesyntax]

Posted in Linux, RHEL | Tagged , | Leave a comment