1. virtualbox install centos7
download: http://mirrors.163.com/centos/7/isos/x86_64/CentOS-7-x86_64-Minimal-1708.iso
then install with virtualbox;
Note: virtual box use NAT for default network type, change to Bridge mode, otherwise host and virtual cannot ping.
2. config centos7 network
ref: http://blog.csdn.net/crxmai/article/details/49767673
3. install mysql
ref: http://blog.csdn.net/sinat_36384705/article/details/71083032
yum install mysql-community-server mysql-devel
4. install lamp
ref: https://www.cnblogs.com/me80/p/7218883.html
note: default php is 5.4, need to upgrade to 5.6, ref : http://blog.csdn.net/u010738364/article/details/75635334
5. install glpi
ref: http://glpi-project.org/spip.php?article61
ref: http://www.mamicode.com/info-detail-1885758.html
7. install mosquito
ref: http://blog.csdn.net/wangji163163/article/details/50547104
resolve error: https://www.jianshu.com/p/6063e125540b+
log_progress_msg() {
echo $@
}
log_daemon_msg () {
# Dummy function to be replaced by LSB library.
echo $@
}
log_end_msg () {
# Dummy function to be replaced by LSB library.
if test "$1" != "0"; then
echo "Error with $DESCRIPTION: $NAME"
fi
return $1
}
status_of_proc ()
{
local pidfile daemon name status OPTIND;
pidfile=;
OPTIND=1;
while getopts p: opt; do
case "$opt" in
p)
pidfile="$OPTARG"
;;
esac;
done;
shift $(($OPTIND - 1));
if [ -n "$pidfile" ]; then
pidfile="-p $pidfile";
fi;
daemon="$1";
name="$2";
status="0";
pidofproc $pidfile $daemon > /dev/null || status="$?";
if [ "$status" = 0 ]; then
log_success_msg "$name is running";
return 0;
else
if [ "$status" = 4 ]; then
log_failure_msg "could not access PID file for $name";
return $status;
else
log_failure_msg "$name is not running";
return $status;
fi;
fi
}