Browse Source

Rename _version to _ver

lj2007331@gmail.com 7 years ago
parent
commit
4644eebaf5
86 changed files with 1155 additions and 1156 deletions
  1. 36 36
      addons.sh
  2. 2 2
      backup.sh
  3. 28 28
      backup_setup.sh
  4. 4 4
      include/GraphicsMagick.sh
  5. 7 7
      include/ImageMagick.sh
  6. 1 1
      include/ZendGuardLoader.sh
  7. 5 5
      include/alisql-5.6.sh
  8. 7 7
      include/apache-2.2.sh
  9. 17 17
      include/apache-2.4.sh
  10. 6 6
      include/apcu.sh
  11. 1 1
      include/boost.sh
  12. 1 1
      include/check_dir.sh
  13. 184 184
      include/check_download.sh
  14. 2 2
      include/check_os.sh
  15. 12 12
      include/check_sw.sh
  16. 1 1
      include/color.sh
  17. 2 2
      include/demo.sh
  18. 1 1
      include/download.sh
  19. 5 5
      include/eaccelerator.sh
  20. 1 1
      include/get_char.sh
  21. 1 1
      include/hhvm_CentOS.sh
  22. 3 3
      include/init_CentOS.sh
  23. 3 3
      include/init_Debian.sh
  24. 3 3
      include/init_Ubuntu.sh
  25. 1 1
      include/ioncube.sh
  26. 3 3
      include/jdk-1.6.sh
  27. 3 3
      include/jdk-1.7.sh
  28. 3 3
      include/jdk-1.8.sh
  29. 4 4
      include/jemalloc.sh
  30. 12 12
      include/mariadb-10.0.sh
  31. 12 12
      include/mariadb-10.1.sh
  32. 12 12
      include/mariadb-10.2.sh
  33. 13 13
      include/mariadb-5.5.sh
  34. 16 16
      include/memcached.sh
  35. 1 1
      include/memory.sh
  36. 5 5
      include/mongodb.sh
  37. 13 13
      include/mysql-5.5.sh
  38. 12 12
      include/mysql-5.6.sh
  39. 12 12
      include/mysql-5.7.sh
  40. 10 10
      include/nginx.sh
  41. 12 12
      include/openresty.sh
  42. 4 4
      include/openssl.sh
  43. 7 7
      include/pecl_mongodb.sh
  44. 1 1
      include/pecl_pgsql.sh
  45. 11 11
      include/percona-5.5.sh
  46. 10 10
      include/percona-5.6.sh
  47. 13 13
      include/percona-5.7.sh
  48. 25 25
      include/php-5.3.sh
  49. 25 25
      include/php-5.4.sh
  50. 29 29
      include/php-5.5.sh
  51. 28 28
      include/php-5.6.sh
  52. 28 28
      include/php-7.0.sh
  53. 28 28
      include/php-7.1.sh
  54. 22 22
      include/php-7.2.sh
  55. 3 3
      include/phpmyadmin.sh
  56. 5 5
      include/postgresql.sh
  57. 4 4
      include/pureftpd.sh
  58. 13 13
      include/python.sh
  59. 7 7
      include/redis.sh
  60. 10 10
      include/tengine.sh
  61. 7 7
      include/tomcat-6.sh
  62. 7 7
      include/tomcat-7.sh
  63. 7 7
      include/tomcat-8.sh
  64. 24 24
      include/upgrade_db.sh
  65. 1 1
      include/upgrade_memcached.sh
  66. 1 1
      include/upgrade_oneinstack.sh
  67. 19 19
      include/upgrade_php.sh
  68. 16 16
      include/upgrade_phpmyadmin.sh
  69. 1 1
      include/upgrade_redis.sh
  70. 56 56
      include/upgrade_web.sh
  71. 4 4
      include/xcache.sh
  72. 4 4
      include/zendopcache.sh
  73. 1 1
      init.d/SS-python-init
  74. 163 164
      install.sh
  75. 1 1
      pureftpd_vhost.sh
  76. 1 1
      reset_db_root_password.sh
  77. 2 2
      ss.sh
  78. 1 1
      tools/ckssh.py
  79. 3 3
      tools/db_bk.sh
  80. 1 1
      tools/mabs.sh
  81. 1 1
      tools/thread.sh
  82. 4 4
      tools/website_bk.sh
  83. 2 2
      uninstall.sh
  84. 1 1
      upgrade.sh
  85. 76 76
      versions.txt
  86. 1 1
      vhost.sh

+ 36 - 36
addons.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #
@@ -62,19 +62,19 @@ if [ -e "${php_install_dir}/bin/phpize" ]; then
 
   case "${PHP_main_version}" in
     "5.3")
-      PHP_version=1
+      php_ver=1
       ;;
     "5.4")
-      PHP_version=2
+      php_ver=2
       ;;
     "5.5")
-      PHP_version=3
+      php_ver=3
       ;;
     "5.6")
-      PHP_version=4
+      php_ver=4
       ;;
     "7.0" | "7.1" | "7.2" )
-      PHP_version=5
+      php_ver=5
       ;;
     *)
       echo "${CFAILURE}Your PHP version ${PHP_main_version} is not supported! ${CEND}"
@@ -125,9 +125,9 @@ Uninstall_letsencrypt() {
 Install_fail2ban() {
   [ ! -e "${python_install_dir}/bin/python" ] && Install_Python
   pushd ${oneinstack_dir}/src
-  src_url=http://mirrors.linuxeye.com/oneinstack/src/fail2ban-${fail2ban_version}.tar.gz && Download_src
-  tar xzf fail2ban-${fail2ban_version}.tar.gz
-  pushd fail2ban-${fail2ban_version}
+  src_url=http://mirrors.linuxeye.com/oneinstack/src/fail2ban-${fail2ban_ver}.tar.gz && Download_src
+  tar xzf fail2ban-${fail2ban_ver}.tar.gz
+  pushd fail2ban-${fail2ban_ver}
   ${python_install_dir}/bin/python setup.py install
   if [ "${OS}" == "CentOS" ]; then
     LOGPATH=/var/log/secure
@@ -146,7 +146,7 @@ Install_fail2ban() {
     chmod +x /etc/init.d/fail2ban
     update-rc.d fail2ban defaults
   fi
-  [ -z "`grep ^Port /etc/ssh/sshd_config`" ] && ssh_port=22 || ssh_port=`grep ^Port /etc/ssh/sshd_config | awk '{print $2}'`
+  [ -z "`grep ^Port /etc/ssh/sshd_config`" ] && now_ssh_port=22 || now_ssh_port=`grep ^Port /etc/ssh/sshd_config | awk '{print $2}'`
   cat > /etc/fail2ban/jail.local << EOF
 [DEFAULT]
 ignoreip = 127.0.0.1/8
@@ -156,7 +156,7 @@ maxretry = 5
 [ssh-iptables]
 enabled = true
 filter  = sshd
-action  = iptables[name=SSH, port=$ssh_port, protocol=tcp]
+action  = iptables[name=SSH, port=$now_ssh_port, protocol=tcp]
 logpath = $LOGPATH 
 EOF
   cat > /etc/logrotate.d/fail2ban << EOF 
@@ -232,12 +232,12 @@ What Are You Doing?
           echo -e "\t${CMSG}2${CEND}. XCache"
           echo -e "\t${CMSG}3${CEND}. APCU"
           echo -e "\t${CMSG}4${CEND}. eAccelerator"
-          read -p "Please input a number:(Default 1 press Enter) " PHP_cache
-          [ -z "${PHP_cache}" ] && PHP_cache=1
-          if [[ ! "${PHP_cache}" =~ ^[1-4]$ ]]; then
+          read -p "Please input a number:(Default 1 press Enter) " php_cache
+          [ -z "${php_cache}" ] && php_cache=1
+          if [[ ! "${php_cache}" =~ ^[1-4]$ ]]; then
             echo "${CWARNING}input error! Please only input number 1~4${CEND}"
           else
-            case "${PHP_cache}" in
+            case "${php_cache}" in
               1)
                 PHP_extension=opcache
                 ;;
@@ -259,11 +259,11 @@ What Are You Doing?
           if [ -e ${php_install_dir}/etc/php.d/ext-ZendGuardLoader.ini ]; then
             echo; echo "${CWARNING}You have to install ZendGuardLoader, You need to uninstall it before install ${PHP_extension}! ${CEND}"; echo; exit 1
           else
-            case "${PHP_cache}" in
+            case "${php_cache}" in
               1)
                 pushd ${oneinstack_dir}/src
                 if [[ "${PHP_main_version}" =~ ^5.[3-4]$ ]]; then
-                  src_url=https://pecl.php.net/get/zendopcache-${zendopcache_version}.tgz && Download_src
+                  src_url=https://pecl.php.net/get/zendopcache-${zendopcache_ver}.tgz && Download_src
                   Install_ZendOPcache
                 else
                   src_url=http://www.php.net/distributions/php-${PHP_detail_version}.tar.gz && Download_src
@@ -328,11 +328,11 @@ What Are You Doing?
         if [ "${ACTION}" = '1' ]; then
           Check_PHP_Extension
           if [ "${Loader}" = '1' ]; then
-            if [[ "${PHP_main_version}" =~ ^5.[3-6]$ ]] || [ "${armPlatform}" != 'y' ]; then
+            if [[ "${PHP_main_version}" =~ ^5.[3-6]$ ]] || [ "${armplatform}" != 'y' ]; then
               if [ -e ${php_install_dir}/etc/php.d/ext-opcache.ini ]; then
                 echo; echo "${CWARNING}You have to install OpCache, You need to uninstall it before install ZendGuardLoader! ${CEND}"; echo; exit 1
               else
-                ZendGuardLoader_yn='y' && checkDownload
+                zendguardloader_yn='y' && checkDownload
                 Install_ZendGuardLoader
                 Check_succ
               fi
@@ -341,7 +341,7 @@ What Are You Doing?
             fi
           elif [ "${Loader}" = '2' ]; then
             if [[ "${PHP_main_version}" =~ ^5.[3-6]$|^7.[0-2]$ ]] || [ "${TARGET_ARCH}" != "arm64" ]; then
-              ionCube_yn='y' && checkDownload
+              ioncube_yn='y' && checkDownload
               Install_ionCube
               Restart_PHP; echo "${CSUCCESS}PHP ioncube module installed successfully! ${CEND}";
             else
@@ -358,24 +358,24 @@ What Are You Doing?
           echo "Please select ImageMagick/GraphicsMagick:"
           echo -e "\t${CMSG}1${CEND}. ImageMagick"
           echo -e "\t${CMSG}2${CEND}. GraphicsMagick"
-          read -p "Please input a number:(Default 1 press Enter) " Magick
-          [ -z "${Magick}" ] && Magick=1
-          if [[ ! "${Magick}" =~ ^[1,2]$ ]]; then
+          read -p "Please input a number:(Default 1 press Enter) " magick
+          [ -z "${magick}" ] && magick=1
+          if [[ ! "${magick}" =~ ^[1,2]$ ]]; then
             echo "${CWARNING}input error! Please only input number 1~2${CEND}"
           else
-            [ "${Magick}" = '1' ] && PHP_extension=imagick
-            [ "${Magick}" = '2' ] && PHP_extension=gmagick
+            [ "${magick}" = '1' ] && PHP_extension=imagick
+            [ "${magick}" = '2' ] && PHP_extension=gmagick
             break
           fi
         done
         if [ "${ACTION}" = '1' ]; then
           Check_PHP_Extension
-          Magick_yn=y && checkDownload
-          if [ "${Magick}" = '1' ]; then
+          magick_yn=y && checkDownload
+          if [ "${magick}" = '1' ]; then
             [ ! -d "/usr/local/imagemagick" ] && Install_ImageMagick
             Install_php-imagick
             Check_succ
-          elif [ "${Magick}" = '2' ]; then
+          elif [ "${magick}" = '2' ]; then
             [ ! -d "/usr/local/graphicsmagick" ] && Install_GraphicsMagick
             Install_php-gmagick
             Check_succ
@@ -481,9 +481,9 @@ What Are You Doing?
           Check_PHP_Extension
           pushd ${oneinstack_dir}/src
           if [[ "${PHP_main_version}" =~ ^7\.[0-1]$ ]]; then
-            src_url=https://pecl.php.net/get/swoole-${swoole_version}.tgz && Download_src
-            tar xzf swoole-${swoole_version}.tgz
-            pushd swoole-${swoole_version}
+            src_url=https://pecl.php.net/get/swoole-${swoole_ver}.tgz && Download_src
+            tar xzf swoole-${swoole_ver}.tgz
+            pushd swoole-${swoole_ver}
           else
             src_url=https://pecl.php.net/get/swoole-1.10.1.tgz && Download_src
             tar xzf swoole-1.10.1.tgz
@@ -493,7 +493,7 @@ What Are You Doing?
           ./configure --with-php-config=${php_install_dir}/bin/php-config
           make -j ${THREAD} && make install
           popd
-          rm -rf swoole-${swoole_version} 
+          rm -rf swoole-${swoole_ver} 
           popd
           echo 'extension=swoole.so' > ${php_install_dir}/etc/php.d/ext-swoole.ini
           Check_succ
@@ -508,17 +508,17 @@ What Are You Doing?
         if [ "${ACTION}" = '1' ]; then
           Check_PHP_Extension
           pushd ${oneinstack_dir}/src
-          src_url=https://pecl.php.net/get/xdebug-${xdebug_version}.tgz && Download_src
+          src_url=https://pecl.php.net/get/xdebug-${xdebug_ver}.tgz && Download_src
           src_url=http://mirrors.linuxeye.com/oneinstack/src/webgrind-master.zip && Download_src
-          tar xzf xdebug-${xdebug_version}.tgz
+          tar xzf xdebug-${xdebug_ver}.tgz
           unzip -q webgrind-master.zip 
           /bin/mv webgrind-master ${wwwroot_dir}/default/webgrind 
-          pushd xdebug-${xdebug_version}
+          pushd xdebug-${xdebug_ver}
           ${php_install_dir}/bin/phpize
           ./configure --with-php-config=${php_install_dir}/bin/php-config
           make -j ${THREAD} && make install
           popd
-          rm -rf xdebug-${xdebug_version} 
+          rm -rf xdebug-${xdebug_ver} 
           popd
           [ ! -e /tmp/xdebug ] && { mkdir /tmp/xdebug; chown ${run_user}.${run_user} /tmp/xdebug; }
           [ ! -e /tmp/webgrind ] && { mkdir /tmp/webgrind; chown ${run_user}.${run_user} /tmp/webgrind; }

+ 2 - 2
backup.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #
@@ -64,7 +64,7 @@ WEB_Local_BK() {
 WEB_Remote_BK() {
   for W in `echo $website_name | tr ',' ' '`
   do
-    if [ `du -sm "$wwwroot_dir/$WebSite" | awk '{print $1}'` -lt 1024 ];then
+    if [ `du -sm "$wwwroot_dir/$WebSite" | awk '{print $1}'` -lt 1024 ]; then
       ./website_bk.sh $W
       Web_GREP="Web_${W}_`date +%Y`"
       Web_FILE=`ls -lrt $backup_dir | grep ${Web_GREP} | tail -1 | awk '{print $NF}'`

+ 28 - 28
backup_setup.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #
@@ -37,10 +37,10 @@ while :; do echo
   echo -e "\t${CMSG}2${CEND}. Remote host"
   echo -e "\t${CMSG}3${CEND}. Qcloud COS"
   echo -e "\t${CMSG}4${CEND}. UPYUN(又拍云)" 
-  read -p "Please input a number:(Default 1 press Enter) " DESC_BK
-  [ -z "$DESC_BK" ] && DESC_BK=1
+  read -p "Please input a number:(Default 1 press Enter) " desc_bk
+  [ -z "$desc_bk" ] && desc_bk=1
   ary=(1 2 3 4 12 13 14 23 24 34 123 124 234 1234)
-  if [[ "${ary[@]}" =~ "$DESC_BK" ]]; then
+  if [[ "${ary[@]}" =~ "$desc_bk" ]]; then
     break
   else
     echo "${CWARNING}input error! Please only input number 1,2,12,23,234 and so on${CEND}"
@@ -48,10 +48,10 @@ while :; do echo
 done
 
 sed -i 's@^backup_destination=.*@backup_destination=@' ./options.conf
-[ `echo $DESC_BK | grep -e 1` ] && sed -i 's@^backup_destination=.*@backup_destination=local@' ./options.conf
-[ `echo $DESC_BK | grep -e 2` ] && sed -i 's@^backup_destination=.*@&,remote@' ./options.conf
-[ `echo $DESC_BK | grep -e 3` ] && sed -i 's@^backup_destination=.*@&,cos@' ./options.conf
-[ `echo $DESC_BK | grep -e 4` ] && sed -i 's@^backup_destination=.*@&,upyun@' ./options.conf
+[ `echo $desc_bk | grep -e 1` ] && sed -i 's@^backup_destination=.*@backup_destination=local@' ./options.conf
+[ `echo $desc_bk | grep -e 2` ] && sed -i 's@^backup_destination=.*@&,remote@' ./options.conf
+[ `echo $desc_bk | grep -e 3` ] && sed -i 's@^backup_destination=.*@&,cos@' ./options.conf
+[ `echo $desc_bk | grep -e 4` ] && sed -i 's@^backup_destination=.*@&,upyun@' ./options.conf
 sed -i 's@^backup_destination=,@backup_destination=@' ./options.conf
 
 while :; do echo
@@ -59,31 +59,31 @@ while :; do echo
   echo -e "\t${CMSG}1${CEND}. Only Database"
   echo -e "\t${CMSG}2${CEND}. Only Website"
   echo -e "\t${CMSG}3${CEND}. Database and Website"
-  read -p "Please input a number:(Default 1 press Enter) " CONTENT_BK
-  [ -z "$CONTENT_BK" ] && CONTENT_BK=1
-  if [[ ! $CONTENT_BK =~ ^[1-3]$ ]]; then
+  read -p "Please input a number:(Default 1 press Enter) " content_bk
+  [ -z "$content_bk" ] && content_bk=1
+  if [[ ! $content_bk =~ ^[1-3]$ ]]; then
     echo "${CWARNING}input error! Please only input number 1~3${CEND}"
   else
     break
   fi
 done
 
-[ "$CONTENT_BK" == '1' ] && sed -i 's@^backup_content=.*@backup_content=db@' ./options.conf
-[ "$CONTENT_BK" == '2' ] && sed -i 's@^backup_content=.*@backup_content=web@' ./options.conf
-[ "$CONTENT_BK" == '3' ] && sed -i 's@^backup_content=.*@backup_content=db,web@' ./options.conf
+[ "$content_bk" == '1' ] && sed -i 's@^backup_content=.*@backup_content=db@' ./options.conf
+[ "$content_bk" == '2' ] && sed -i 's@^backup_content=.*@backup_content=web@' ./options.conf
+[ "$content_bk" == '3' ] && sed -i 's@^backup_content=.*@backup_content=db,web@' ./options.conf
 
-if [[ $DESC_BK =~ ^[1,2]$ ]]; then
+if [[ $desc_bk =~ ^[1,2]$ ]]; then
   while :; do echo
     echo "Please enter the directory for save the backup file: "
-    read -p "(Default directory: $backup_dir): " NEW_backup_dir
-    [ -z "$NEW_backup_dir" ] && NEW_backup_dir="$backup_dir"
-    if [ -z "`echo $NEW_backup_dir| grep '^/'`" ]; then
+    read -p "(Default directory: $backup_dir): " new_backup_dir
+    [ -z "$new_backup_dir" ] && new_backup_dir="$backup_dir"
+    if [ -z "`echo $new_backup_dir| grep '^/'`" ]; then
       echo "${CWARNING}input error! ${CEND}"
     else
       break
     fi
   done
-  sed -i "s@^backup_dir=.*@backup_dir=$NEW_backup_dir@" ./options.conf
+  sed -i "s@^backup_dir=.*@backup_dir=$new_backup_dir@" ./options.conf
 fi
 
 while :; do echo
@@ -94,7 +94,7 @@ while :; do echo
 done
 sed -i "s@^expired_days=.*@expired_days=$expired_days@" ./options.conf
 
-if [ "$CONTENT_BK" != '2' ]; then
+if [ "$content_bk" != '2' ]; then
   databases=`$db_install_dir/bin/mysql -uroot -p$dbrootpwd -e "show databases\G" | grep Database | awk '{print $2}' | grep -Evw "(performance_schema|information_schema|mysql|sys)"`
   while :; do echo
     echo "Please enter one or more name for database, separate multiple database names with commas: "
@@ -111,7 +111,7 @@ if [ "$CONTENT_BK" != '2' ]; then
   sed -i "s@^db_name=.*@db_name=$db_name@" ./options.conf
 fi
 
-if [ "$CONTENT_BK" != '1' ]; then
+if [ "$content_bk" != '1' ]; then
   websites=`ls $wwwroot_dir | grep -vw default`
   while :; do echo
     echo "Please enter one or more name for website, separate multiple website names with commas: "
@@ -130,10 +130,10 @@ fi
 
 echo
 echo "You have to backup the content:"
-[ "$CONTENT_BK" != '2' ] && echo "Database: ${CMSG}$db_name${CEND}"
-[ "$CONTENT_BK" != '1' ] && echo "Website: ${CMSG}$website_name${CEND}"
+[ "$content_bk" != '2' ] && echo "Database: ${CMSG}$db_name${CEND}"
+[ "$content_bk" != '1' ] && echo "Website: ${CMSG}$website_name${CEND}"
 
-if [ `echo $DESC_BK | grep -e 2` ]; then
+if [ `echo $desc_bk | grep -e 2` ]; then
   > tools/iplist.txt
   while :; do echo
     read -p "Please enter the remote host ip: " remote_ip
@@ -166,7 +166,7 @@ if [ `echo $DESC_BK | grep -e 2` ]; then
   done
 fi
 
-if [ `echo $DESC_BK | grep -e 3` ]; then
+if [ `echo $desc_bk | grep -e 3` ]; then
   [ ! -e "${python_install_dir}/bin/python" ] && Install_Python
   [ ! -e "${python_install_dir}/lib/coscmd" ] && ${python_install_dir}/bin/pip install coscmd >/dev/null 2>&1 
   while :; do echo
@@ -208,7 +208,7 @@ if [ `echo $DESC_BK | grep -e 3` ]; then
     echo
     $python_install_dir/bin/coscmd config -u $appid -a $SecretId -s $SecretKey -r $region -b $bucket >/dev/null 2>&1
     $python_install_dir/bin/coscmd list >/dev/null 2>&1
-    if [ $? = 0 ];then
+    if [ $? = 0 ]; then
       echo "${CMSG}appid/SecretId/SecretKey/region/bucket OK${CEND}"
       echo
       break
@@ -218,7 +218,7 @@ if [ `echo $DESC_BK | grep -e 3` ]; then
   done
 fi
 
-if [ `echo $DESC_BK | grep -e 4` ]; then
+if [ `echo $desc_bk | grep -e 4` ]; then
   if [ ! -e "/usr/local/bin/upx" ] ;then
     if [ "$OS_BIT" == '64' ]; then
       wget -qc http://collection.b0.upaiyun.com/softwares/upx/upx-linux-amd64-v0.2.3 -O /usr/local/bin/upx
@@ -239,7 +239,7 @@ if [ `echo $DESC_BK | grep -e 4` ]; then
     echo
     /usr/local/bin/upx login $ServiceName $Operator $Password >/dev/null 2>&1
     /usr/local/bin/upx ls >/dev/null 2>&1
-    if [ $? = 0 ];then
+    if [ $? = 0 ]; then
       echo "${CMSG}ServiceName/Operator/Password OK${CEND}"
       echo
       break

+ 4 - 4
include/GraphicsMagick.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -10,12 +10,12 @@
 
 Install_GraphicsMagick() {
   pushd ${oneinstack_dir}/src
-  tar xzf GraphicsMagick-${GraphicsMagick_version}.tar.gz
-  pushd GraphicsMagick-${GraphicsMagick_version}
+  tar xzf GraphicsMagick-${graphicsmagick_ver}.tar.gz
+  pushd GraphicsMagick-${graphicsmagick_ver}
   ./configure --prefix=/usr/local/graphicsmagick --enable-shared --enable-static
   make -j ${THREAD} && make install
   popd
-  rm -rf GraphicsMagick-${GraphicsMagick_version}
+  rm -rf GraphicsMagick-${graphicsmagick_ver}
   popd
 }
 

+ 7 - 7
include/ImageMagick.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -10,12 +10,12 @@
 
 Install_ImageMagick() {
   pushd ${oneinstack_dir}/src
-  tar xzf ImageMagick-${ImageMagick_version}.tar.gz
-  pushd ImageMagick-${ImageMagick_version}
+  tar xzf ImageMagick-${imagemagick_ver}.tar.gz
+  pushd ImageMagick-${imagemagick_ver}
   ./configure --prefix=/usr/local/imagemagick --enable-shared --enable-static
   make -j ${THREAD} && make install
   popd
-  rm -rf ImageMagick-${ImageMagick_version}
+  rm -rf ImageMagick-${imagemagick_ver}
   popd
 }
 
@@ -23,8 +23,8 @@ Install_php-imagick() {
   pushd ${oneinstack_dir}/src
   if [ -e "${php_install_dir}/bin/phpize" ]; then
     phpExtensionDir=`${php_install_dir}/bin/php-config --extension-dir`
-    tar xzf imagick-${imagick_version}.tgz
-    pushd imagick-${imagick_version}
+    tar xzf imagick-${imagick_ver}.tgz
+    pushd imagick-${imagick_ver}
     export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
     ${php_install_dir}/bin/phpize
     ./configure --with-php-config=${php_install_dir}/bin/php-config --with-imagick=/usr/local/imagemagick
@@ -33,7 +33,7 @@ Install_php-imagick() {
     if [ -f "${phpExtensionDir}/imagick.so" ]; then
       echo 'extension=imagick.so' > ${php_install_dir}/etc/php.d/ext-imagick.ini
       echo "${CSUCCESS}PHP imagick module installed successfully! ${CEND}"
-      rm -rf imagick-${imagick_version}
+      rm -rf imagick-${imagick_ver}
     else
       echo "${CFAILURE}PHP imagick module install failed, Please contact the author! ${CEND}"
     fi

+ 1 - 1
include/ZendGuardLoader.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 5 - 5
include/alisql-5.6.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,8 +17,8 @@ Install_AliSQL56() {
   [ ! -d "${alisql_install_dir}" ] && mkdir -p ${alisql_install_dir}
   mkdir -p ${alisql_data_dir};chown mysql.mysql -R ${alisql_data_dir}
 
-  tar xvf alisql-${alisql56_version}.tar.gz
-  pushd alisql-${alisql56_version}
+  tar xvf alisql-${alisql_ver}.tar.gz
+  pushd alisql-${alisql_ver}
   cmake . -DCMAKE_INSTALL_PREFIX=${alisql_install_dir} \
   -DCMAKE_BUILD_TYPE="Release" \
   -DWITH_EMBEDDED_SERVER=0 \
@@ -39,10 +39,10 @@ Install_AliSQL56() {
   if [ -d "${alisql_install_dir}/support-files" ]; then
     echo never > /sys/kernel/mm/transparent_hugepage/enabled
     echo "${CSUCCESS}AliSQL installed successfully! ${CEND}"
-    rm -rf alisql-${alisql56_version}
+    rm -rf alisql-${alisql_ver}
   else
     rm -rf ${alisql_install_dir}
-    rm -rf alisql-${alisql56_version}
+    rm -rf alisql-${alisql_ver}
     echo "${CFAILURE}AliSQL install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 7 - 7
include/apache-2.2.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -12,8 +12,8 @@ Install_Apache22() {
   pushd ${oneinstack_dir}/src
   id -u ${run_user} >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin ${run_user}
-  tar xzf httpd-${apache22_version}.tar.gz
-  pushd httpd-${apache22_version}
+  tar xzf httpd-${apache22_ver}.tar.gz
+  pushd httpd-${apache22_ver}
   [ ! -d "${apache_install_dir}" ] && mkdir -p ${apache_install_dir}
   [ "${Ubuntu_version}" == "12" ] && sed -i '@SSL_PROTOCOL_SSLV2@d' modules/ssl/ssl_engine_io.c
   LDFLAGS=-ldl ./configure --prefix=${apache_install_dir} --with-mpm=prefork --with-included-apr --enable-headers --enable-deflate --enable-so --enable-rewrite --enable-ssl--with-ssl=${openssl_install_dir} --enable-expires --enable-static-support --enable-suexec --enable-modules=all --enable-mods-shared=all
@@ -22,7 +22,7 @@ Install_Apache22() {
   if [ -e "${apache_install_dir}/conf/httpd.conf" ]; then
     echo "${CSUCCESS}Apache installed successfully! ${CEND}"
     popd
-    rm -rf httpd-${apache22_version}
+    rm -rf httpd-${apache22_ver}
   else
     rm -rf ${apache_install_dir}
     echo "${CFAILURE}Apache install failed, Please contact the author! ${CEND}"
@@ -42,10 +42,10 @@ Install_Apache22() {
   
   sed -i "s@^User daemon@User ${run_user}@" ${apache_install_dir}/conf/httpd.conf
   sed -i "s@^Group daemon@Group ${run_user}@" ${apache_install_dir}/conf/httpd.conf
-  if [ "${Nginx_version}" == '4' -a ! -e "${web_install_dir}/sbin/nginx" ]; then
+  if [ "${nginx_ver}" == '4' -a ! -e "${web_install_dir}/sbin/nginx" ]; then
     sed -i 's/^#ServerName www.example.com:80/ServerName 0.0.0.0:80/' ${apache_install_dir}/conf/httpd.conf
     TMP_PORT=80
-  elif [[ ${Nginx_version} =~ ^[1-3]$ ]] || [ -e "${web_install_dir}/sbin/nginx" ]; then
+  elif [[ ${nginx_ver} =~ ^[1-3]$ ]] || [ -e "${web_install_dir}/sbin/nginx" ]; then
     sed -i 's/^#ServerName www.example.com:80/ServerName 127.0.0.1:88/' ${apache_install_dir}/conf/httpd.conf
     sed -i 's@^Listen.*@Listen 127.0.0.1:88@' ${apache_install_dir}/conf/httpd.conf
     TMP_PORT=88
@@ -116,7 +116,7 @@ ServerSignature Off
 Include conf/vhost/*.conf
 EOF
 
-  if [ "${Nginx_version}" != '4' -o -e "${web_install_dir}/sbin/nginx" ]; then
+  if [ "${nginx_ver}" != '4' -o -e "${web_install_dir}/sbin/nginx" ]; then
     ${apache_install_dir}/bin/apxs -i -c -n mod_remoteip.so mod_remoteip.c
     cat > ${apache_install_dir}/conf/extra/httpd-remoteip.conf << EOF
 LoadModule remoteip_module modules/mod_remoteip.so

+ 17 - 17
include/apache-2.4.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -10,39 +10,39 @@
 
 Install_Apache24() {
   pushd ${oneinstack_dir}/src
-  tar xzf pcre-${pcre_version}.tar.gz
-  pushd pcre-${pcre_version}
+  tar xzf pcre-${pcre_ver}.tar.gz
+  pushd pcre-${pcre_ver}
   ./configure
   make -j ${THREAD} && make install
   popd
   id -u ${run_user} >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
-  tar xzf httpd-${apache24_version}.tar.gz
-  tar xzf nghttp2-${nghttp2_version}.tar.gz
-  tar xzf apr-${apr_version}.tar.gz
-  tar xzf apr-util-${apr_util_version}.tar.gz
+  tar xzf httpd-${apache24_ver}.tar.gz
+  tar xzf nghttp2-${nghttp2_ver}.tar.gz
+  tar xzf apr-${apr_ver}.tar.gz
+  tar xzf apr-util-${apr_util_ver}.tar.gz
 
   # install nghttp2
   if [ ! -e "/usr/local/lib/libnghttp2.so" ]; then
-    pushd nghttp2-${nghttp2_version}
+    pushd nghttp2-${nghttp2_ver}
     ./configure
     make -j ${THREAD} && make install
     popd
     echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf; ldconfig
-    rm -rf nghttp2-${nghttp2_version}
+    rm -rf nghttp2-${nghttp2_ver}
   fi
 
-  pushd httpd-${apache24_version}
+  pushd httpd-${apache24_ver}
   [ ! -d "${apache_install_dir}" ] && mkdir -p ${apache_install_dir}
-  /bin/cp -R ../apr-${apr_version} ./srclib/apr
-  /bin/cp -R ../apr-util-${apr_util_version} ./srclib/apr-util
+  /bin/cp -R ../apr-${apr_ver} ./srclib/apr
+  /bin/cp -R ../apr-util-${apr_util_ver} ./srclib/apr-util
   LDFLAGS=-ldl LD_LIBRARY_PATH=${openssl_install_dir}/lib ./configure --prefix=${apache_install_dir} --enable-mpms-shared=all --with-included-apr --enable-headers --enable-deflate --enable-so --enable-dav --enable-rewrite --enable-ssl --with-ssl=${openssl_install_dir} --enable-http2 --with-nghttp2=/usr/local --enable-expires --enable-static-support --enable-suexec --enable-modules=all --enable-mods-shared=all
   make -j ${THREAD} && make install
   unset LDFLAGS
   if [ -e "${apache_install_dir}/conf/httpd.conf" ]; then
     echo "${CSUCCESS}Apache installed successfully! ${CEND}"
     popd 
-    rm -rf httpd-${apache24_version}
+    rm -rf httpd-${apache24_ver}
   else
     rm -rf ${apache_install_dir}
     echo "${CFAILURE}Apache install failed, Please contact the author! ${CEND}"
@@ -63,10 +63,10 @@ Install_Apache24() {
   
   sed -i "s@^User daemon@User $run_user@" ${apache_install_dir}/conf/httpd.conf
   sed -i "s@^Group daemon@Group $run_user@" ${apache_install_dir}/conf/httpd.conf
-  if [ "${Nginx_version}" == '4' -a ! -e "${web_install_dir}/sbin/nginx" ]; then
+  if [ "${nginx_ver}" == '4' -a ! -e "${web_install_dir}/sbin/nginx" ]; then
     sed -i 's/^#ServerName www.example.com:80/ServerName 0.0.0.0:80/' ${apache_install_dir}/conf/httpd.conf
     TMP_PORT=80
-  elif [[ ${Nginx_version} =~ ^[1-3]$ ]] || [ -e "${web_install_dir}/sbin/nginx" ]; then
+  elif [[ ${nginx_ver} =~ ^[1-3]$ ]] || [ -e "${web_install_dir}/sbin/nginx" ]; then
     sed -i 's/^#ServerName www.example.com:80/ServerName 127.0.0.1:88/' ${apache_install_dir}/conf/httpd.conf
     sed -i 's@^Listen.*@Listen 127.0.0.1:88@' ${apache_install_dir}/conf/httpd.conf
     TMP_PORT=88
@@ -144,8 +144,8 @@ ServerTokens ProductOnly
 ServerSignature Off
 Include conf/vhost/*.conf
 EOF
-  [ "${Nginx_version}" == '4' -a ! -e "${web_install_dir}/sbin/nginx" ] && echo 'Protocols h2 http/1.1' >> ${apache_install_dir}/conf/httpd.conf
-  if [ "${Nginx_version}" != '4' -o -e "${web_install_dir}/sbin/nginx" ]; then
+  [ "${nginx_ver}" == '4' -a ! -e "${web_install_dir}/sbin/nginx" ] && echo 'Protocols h2 http/1.1' >> ${apache_install_dir}/conf/httpd.conf
+  if [ "${nginx_ver}" != '4' -o -e "${web_install_dir}/sbin/nginx" ]; then
     cat > ${apache_install_dir}/conf/extra/httpd-remoteip.conf << EOF
 LoadModule remoteip_module modules/mod_remoteip.so
 RemoteIPHeader X-Forwarded-For

+ 6 - 6
include/apcu.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -12,11 +12,11 @@ Install_APCU() {
   pushd ${oneinstack_dir}/src
   phpExtensionDir=`${php_install_dir}/bin/php-config --extension-dir`
   if [ "`${php_install_dir}/bin/php -r 'echo PHP_VERSION;' | awk -F. '{print $1}'`" == '7' ]; then
-    tar xzf apcu-${apcu_for_php7_version}.tgz
-    pushd apcu-${apcu_for_php7_version}
+    tar xzf apcu-${apcu_for_php7_ver}.tgz
+    pushd apcu-${apcu_for_php7_ver}
   else
-    tar xzf apcu-${apcu_version}.tgz
-    pushd apcu-${apcu_version}
+    tar xzf apcu-${apcu_ver}.tgz
+    pushd apcu-${apcu_ver}
   fi
 
   ${php_install_dir}/bin/phpize
@@ -34,7 +34,7 @@ EOF
     /bin/cp apc.php ${wwwroot_dir}/default
     echo "${CSUCCESS}APCU module installed successfully! ${CEND}"
     popd
-    rm -rf apcu-${apcu_for_php7_version} apcu-${apcu_version} package.xml
+    rm -rf apcu-${apcu_for_php7_ver} apcu-${apcu_ver} package.xml
   else
     echo "${CFAILURE}APCU module install failed, Please contact the author! ${CEND}"
   fi

+ 1 - 1
include/boost.sh

@@ -10,7 +10,7 @@
 installBoost() {
   pushd ${oneinstack_dir}/src
   if [ ! -e "/usr/local/lib/libboost_system.so" ]; then
-    boostVersion2=$(echo ${boost_version} | awk -F. '{print $1}')_$(echo ${boost_version} | awk -F. '{print $2}')_$(echo ${boost_version} | awk -F. '{print $3}')
+    boostVersion2=$(echo ${boost_ver} | awk -F. '{print $1}')_$(echo ${boost_ver} | awk -F. '{print $2}')_$(echo ${boost_ver} | awk -F. '{print $3}')
     tar xvf boost_${boostVersion2}.tar.gz
     pushd boost_${boostVersion2}
     ./bootstrap.sh

+ 1 - 1
include/check_dir.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 184 - 184
include/check_download.sh

@@ -13,97 +13,97 @@ checkDownload() {
 
   # General system utils
   echo "Download openSSL..."
-  src_url=https://www.openssl.org/source/openssl-${openssl_version}.tar.gz && Download_src
+  src_url=https://www.openssl.org/source/openssl-${openssl_ver}.tar.gz && Download_src
   src_url=http://curl.haxx.se/ca/cacert.pem && Download_src
 
   # Web
-  if [ "${Web_yn}" == 'y' ]; then
-    case "${Nginx_version}" in
+  if [ "${web_yn}" == 'y' ]; then
+    case "${nginx_ver}" in
       1)
         echo "Download nginx..."
-        src_url=http://nginx.org/download/nginx-${nginx_version}.tar.gz && Download_src
+        src_url=http://nginx.org/download/nginx-${nginx_ver}.tar.gz && Download_src
         ;;
       2)
         echo "Download tengine..."
-        src_url=http://tengine.taobao.org/download/tengine-${tengine_version}.tar.gz && Download_src
+        src_url=http://tengine.taobao.org/download/tengine-${tengine_ver}.tar.gz && Download_src
         ;;
       3)
         echo "Download openresty..."
-        src_url=https://openresty.org/download/openresty-${openresty_version}.tar.gz && Download_src
+        src_url=https://openresty.org/download/openresty-${openresty_ver}.tar.gz && Download_src
         ;;
     esac
 
-    if [[ "${Nginx_version}" =~ ^[1-3]$ || ${Apache_version} == '1' ]]; then
+    if [[ "${nginx_ver}" =~ ^[1-3]$ || ${apache_ver} == '1' ]]; then
       echo "Download pcre..."
-      src_url=${mirrorLink}/pcre-${pcre_version}.tar.gz && Download_src
+      src_url=${mirrorLink}/pcre-${pcre_ver}.tar.gz && Download_src
     fi
 
     # apache
-    if [ "${Apache_version}" == '1' ]; then
+    if [ "${apache_ver}" == '1' ]; then
       echo "Download apache 2.4..."
-      src_url=http://archive.apache.org/dist/apr/apr-${apr_version}.tar.gz && Download_src
-      src_url=http://archive.apache.org/dist/apr/apr-util-${apr_util_version}.tar.gz && Download_src
-      src_url=http://mirrors.linuxeye.com/apache/httpd/nghttp2-${nghttp2_version}.tar.gz && Download_src
-      src_url=http://mirrors.linuxeye.com/apache/httpd/httpd-${apache24_version}.tar.gz && Download_src
+      src_url=http://archive.apache.org/dist/apr/apr-${apr_ver}.tar.gz && Download_src
+      src_url=http://archive.apache.org/dist/apr/apr-util-${apr_util_ver}.tar.gz && Download_src
+      src_url=http://mirrors.linuxeye.com/apache/httpd/nghttp2-${nghttp2_ver}.tar.gz && Download_src
+      src_url=http://mirrors.linuxeye.com/apache/httpd/httpd-${apache24_ver}.tar.gz && Download_src
     fi
-    if [ "${Apache_version}" == '2' ]; then
+    if [ "${apache_ver}" == '2' ]; then
       echo "Download apache 2.2..."
-      src_url=http://mirrors.linuxeye.com/apache/httpd/httpd-${apache22_version}.tar.gz && Download_src
+      src_url=http://mirrors.linuxeye.com/apache/httpd/httpd-${apache22_ver}.tar.gz && Download_src
 
       echo "Download mod_remoteip.c for apache 2.2..."
       src_url=${mirrorLink}/mod_remoteip.c && Download_src
     fi
 
     # tomcat
-    case "${Tomcat_version}" in
+    case "${tomcat_ver}" in
       1)
         echo "Download tomcat 8..."
-        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat8_version}/apache-tomcat-${tomcat8_version}.tar.gz && Download_src
-        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat8_version}/catalina-jmx-remote.jar && Download_src
+        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat8_ver}/apache-tomcat-${tomcat8_ver}.tar.gz && Download_src
+        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat8_ver}/catalina-jmx-remote.jar && Download_src
         ;;
       2)
         echo "Download tomcat 7..."
-        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat7_version}/apache-tomcat-${tomcat7_version}.tar.gz && Download_src
-        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat7_version}/catalina-jmx-remote.jar && Download_src
+        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat7_ver}/apache-tomcat-${tomcat7_ver}.tar.gz && Download_src
+        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat7_ver}/catalina-jmx-remote.jar && Download_src
         ;;
       3)
         echo "Download tomcat 6..."
-        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat6_version}/apache-tomcat-${tomcat6_version}.tar.gz && Download_src
-        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat6_version}/catalina-jmx-remote.jar && Download_src
+        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat6_ver}/apache-tomcat-${tomcat6_ver}.tar.gz && Download_src
+        src_url=http://mirrors.linuxeye.com/apache/tomcat/v${tomcat6_ver}/catalina-jmx-remote.jar && Download_src
         ;;
     esac
 
-    if [[ "${JDK_version}"  =~ ^[1-3]$ ]]; then
-      case "${JDK_version}" in
+    if [[ "${jdk_version}"  =~ ^[1-3]$ ]]; then
+      case "${jdk_version}" in
         1)
           echo "Download JDK 1.8..."
-          JDK_FILE="jdk-$(echo ${jdk18_version} | awk -F. '{print $2}')u$(echo ${jdk18_version} | awk -F_ '{print $NF}')-linux-${SYS_BIG_FLAG}.tar.gz"
+          JDK_FILE="jdk-$(echo ${jdk18_ver} | awk -F. '{print $2}')u$(echo ${jdk18_ver} | awk -F_ '{print $NF}')-linux-${SYS_BIG_FLAG}.tar.gz"
           ;;
         2)
           echo "Download JDK 1.7..."
-          JDK_FILE="jdk-$(echo ${jdk17_version} | awk -F. '{print $2}')u$(echo ${jdk17_version} | awk -F_ '{print $NF}')-linux-${SYS_BIG_FLAG}.tar.gz"
+          JDK_FILE="jdk-$(echo ${jdk17_ver} | awk -F. '{print $2}')u$(echo ${jdk17_ver} | awk -F_ '{print $NF}')-linux-${SYS_BIG_FLAG}.tar.gz"
           ;;
         3)
           echo "Download JDK 1.6..."
-          JDK_FILE="jdk-$(echo ${jdk16_version} | awk -F. '{print $2}')u$(echo ${jdk16_version} | awk -F_ '{print $NF}')-linux-${SYS_BIG_FLAG}.bin"
+          JDK_FILE="jdk-$(echo ${jdk16_ver} | awk -F. '{print $2}')u$(echo ${jdk16_ver} | awk -F_ '{print $NF}')-linux-${SYS_BIG_FLAG}.bin"
           ;;
       esac
       echo "Download apr..."
-      src_url=http://archive.apache.org/dist/apr/apr-${apr_version}.tar.gz && Download_src
+      src_url=http://archive.apache.org/dist/apr/apr-${apr_ver}.tar.gz && Download_src
       # start download...
       src_url=http://mirrors.linuxeye.com/jdk/${JDK_FILE} && Download_src
     fi
   fi
 
-  if [ "${DB_yn}" == 'y' ]; then
-    if [[ "${DB_version}" =~ ^[1,4,8]$ ]] && [ "${dbInstallMethods}" == "2" ]; then
+  if [ "${db_yn}" == 'y' ]; then
+    if [[ "${db_ver}" =~ ^[1,4,8]$ ]] && [ "${dbinstallmethod}" == "2" ]; then
       echo "Download boost..."
-      [ "${IPADDR_COUNTRY}"x == "CN"x ] && DOWN_ADDR_BOOST=${mirrorLink} || DOWN_ADDR_BOOST=http://downloads.sourceforge.net/project/boost/boost/${boost_version}
-      boostVersion2=$(echo ${boost_version} | awk -F. '{print $1}')_$(echo ${boost_version} | awk -F. '{print $2}')_$(echo ${boost_version} | awk -F. '{print $3}')
+      [ "${IPADDR_COUNTRY}"x == "CN"x ] && DOWN_ADDR_BOOST=${mirrorLink} || DOWN_ADDR_BOOST=http://downloads.sourceforge.net/project/boost/boost/${boost_ver}
+      boostVersion2=$(echo ${boost_ver} | awk -F. '{print $1}')_$(echo ${boost_ver} | awk -F. '{print $2}')_$(echo ${boost_ver} | awk -F. '{print $3}')
       src_url=${DOWN_ADDR_BOOST}/boost_${boostVersion2}.tar.gz && Download_src
     fi
 
-    case "${DB_version}" in
+    case "${db_ver}" in
       1)
         # MySQL 5.7
         if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
@@ -124,15 +124,15 @@ checkDownload() {
           fi
         fi
 
-        if [ "${dbInstallMethods}" == '1' ]; then
+        if [ "${dbinstallmethod}" == '1' ]; then
           echo "Download MySQL 5.7 binary package..."
-          FILE_NAME=mysql-${mysql57_version}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
-        elif [ "${dbInstallMethods}" == '2' ]; then
+          FILE_NAME=mysql-${mysql57_ver}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
+        elif [ "${dbinstallmethod}" == '2' ]; then
           echo "Download MySQL 5.7 source package..."
-          FILE_NAME=mysql-${mysql57_version}.tar.gz
+          FILE_NAME=mysql-${mysql57_ver}.tar.gz
         fi
         # start download
-        wget --tries=6 -c --no-check-certificate ${DOWN_ADDR_MYSQL}/${FILE_NAME}
+        wget -4 --tries=6 -c --no-check-certificate ${DOWN_ADDR_MYSQL}/${FILE_NAME}
         # verifying download
         MYSQL_TAR_MD5=$(curl -s ${DOWN_ADDR_MYSQL}/${FILE_NAME}.md5 | grep ${FILE_NAME} | awk '{print $1}')
         [ -z "${MYSQL_TAR_MD5}" ] && MYSQL_TAR_MD5=$(curl -s ${DOWN_ADDR_MYSQL_BK}/${FILE_NAME}.md5 | grep ${FILE_NAME} | awk '{print $1}') 
@@ -170,14 +170,14 @@ checkDownload() {
           fi
         fi
 
-        if [ "${dbInstallMethods}" == '1' ]; then
+        if [ "${dbinstallmethod}" == '1' ]; then
           echo "Download MySQL 5.6 binary package..."
-          FILE_NAME=mysql-${mysql56_version}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
-        elif [ "${dbInstallMethods}" == '2' ]; then
+          FILE_NAME=mysql-${mysql56_ver}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
+        elif [ "${dbinstallmethod}" == '2' ]; then
           echo "Download MySQL 5.6 source package..."
-          FILE_NAME=mysql-${mysql56_version}.tar.gz
+          FILE_NAME=mysql-${mysql56_ver}.tar.gz
         fi
-        wget --tries=6 -c --no-check-certificate ${DOWN_ADDR_MYSQL}/${FILE_NAME}
+        wget -4 --tries=6 -c --no-check-certificate ${DOWN_ADDR_MYSQL}/${FILE_NAME}
         # verifying download
         MYSQL_TAR_MD5=$(curl -s ${DOWN_ADDR_MYSQL}/${FILE_NAME}.md5 | grep ${FILE_NAME} | awk '{print $1}')
         [ -z "${MYSQL_TAR_MD5}" ] && MYSQL_TAR_MD5=$(curl -s ${DOWN_ADDR_MYSQL_BK}/${FILE_NAME}.md5 | grep ${FILE_NAME} | awk '{print $1}') 
@@ -215,15 +215,15 @@ checkDownload() {
           fi
         fi
 
-        if [ "${dbInstallMethods}" == '1' ]; then
+        if [ "${dbinstallmethod}" == '1' ]; then
           echo "Download MySQL 5.5 binary package..."
-          FILE_NAME=mysql-${mysql55_version}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
-        elif [ "${dbInstallMethods}" == '2' ]; then
+          FILE_NAME=mysql-${mysql55_ver}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
+        elif [ "${dbinstallmethod}" == '2' ]; then
           echo "Download MySQL 5.5 source package..."
-          FILE_NAME=mysql-${mysql55_version}.tar.gz
+          FILE_NAME=mysql-${mysql55_ver}.tar.gz
           src_url=${mirrorLink}/mysql-5.5-fix-arm-client_plugin.patch && Download_src
         fi
-        wget --tries=6 -c --no-check-certificate ${DOWN_ADDR_MYSQL}/${FILE_NAME}
+        wget -4 --tries=6 -c --no-check-certificate ${DOWN_ADDR_MYSQL}/${FILE_NAME}
         # verifying download
         MYSQL_TAR_MD5=$(curl -s ${DOWN_ADDR_MYSQL}/${FILE_NAME}.md5 | grep ${FILE_NAME} | awk '{print $1}')
         [ -z "${MYSQL_TAR_MD5}" ] && MYSQL_TAR_MD5=$(curl -s ${DOWN_ADDR_MYSQL_BK}/${FILE_NAME}.md5 | grep ${FILE_NAME} | awk '{print $1}') 
@@ -243,27 +243,27 @@ checkDownload() {
 
       4)
         # MariaDB 10.2
-        if [ "${dbInstallMethods}" == '1' ]; then
+        if [ "${dbinstallmethod}" == '1' ]; then
           echo "Download MariaDB 10.2 binary package..."
-          FILE_NAME=mariadb-${mariadb102_version}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
+          FILE_NAME=mariadb-${mariadb102_ver}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
-            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb102_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
+            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb102_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
             MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}')
-            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb102_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
+            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb102_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb102_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
-            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb102_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
+            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb102_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
+            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb102_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
           fi
-        elif [ "${dbInstallMethods}" == '2' ]; then
+        elif [ "${dbinstallmethod}" == '2' ]; then
           echo "Download MariaDB 10.2 source package..."
-          FILE_NAME=mariadb-${mariadb102_version}.tar.gz
+          FILE_NAME=mariadb-${mariadb102_ver}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
-            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb102_version}/source
+            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb102_ver}/source
             MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}')
-            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb102_version}/source; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
+            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb102_ver}/source; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb102_version}/source
-            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb102_version}/source/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
+            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb102_ver}/source
+            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb102_ver}/source/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
           fi
         fi
         tryDlCount=0
@@ -282,27 +282,27 @@ checkDownload() {
 
       5)
         # MariaDB 10.1
-        if [ "${dbInstallMethods}" == '1' ]; then
+        if [ "${dbinstallmethod}" == '1' ]; then
           echo "Download MariaDB 10.1 binary package..."
-          FILE_NAME=mariadb-${mariadb101_version}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
+          FILE_NAME=mariadb-${mariadb101_ver}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
-            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb101_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
+            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb101_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
             MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}')
-            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb101_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
+            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb101_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb101_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
-            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb101_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
+            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb101_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
+            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb101_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
           fi
-        elif [ "${dbInstallMethods}" == '2' ]; then
+        elif [ "${dbinstallmethod}" == '2' ]; then
           echo "Download MariaDB 10.1 source package..."
-          FILE_NAME=mariadb-${mariadb101_version}.tar.gz
+          FILE_NAME=mariadb-${mariadb101_ver}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
-            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb101_version}/source
+            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb101_ver}/source
             MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}')
-            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb101_version}/source; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
+            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb101_ver}/source; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb101_version}/source
-            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb101_version}/source/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
+            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb101_ver}/source
+            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb101_ver}/source/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
           fi
         fi
         tryDlCount=0
@@ -321,27 +321,27 @@ checkDownload() {
 
       6)
         # MariaDB 10.0
-        if [ "${dbInstallMethods}" == '1' ]; then
+        if [ "${dbinstallmethod}" == '1' ]; then
           echo "Download MariaDB 10.0 binary package..."
-          FILE_NAME=mariadb-${mariadb100_version}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
+          FILE_NAME=mariadb-${mariadb100_ver}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
-            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb100_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
+            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb100_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
             MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}')
-            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb100_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
+            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb100_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb100_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
-            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb100_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
+            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb100_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
+            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb100_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
           fi
-        elif [ "${dbInstallMethods}" == '2' ]; then
+        elif [ "${dbinstallmethod}" == '2' ]; then
           echo "Download MariaDB 10.0 source package..."
-          FILE_NAME=mariadb-${mariadb100_version}.tar.gz
+          FILE_NAME=mariadb-${mariadb100_ver}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
-            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb100_version}/source
+            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb100_ver}/source
             MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}')
-            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb100_version}/source; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
+            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb100_ver}/source; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb100_version}/source
-            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb100_version}/source/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
+            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb100_ver}/source
+            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb100_ver}/source/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
           fi
         fi
         tryDlCount=0
@@ -360,27 +360,27 @@ checkDownload() {
 
       7)
         # MariaDB 5.5
-        if [ "${dbInstallMethods}" == '1' ]; then
+        if [ "${dbinstallmethod}" == '1' ]; then
           echo "Download MariaDB 5.5 binary package..."
-          FILE_NAME=mariadb-${mariadb55_version}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
+          FILE_NAME=mariadb-${mariadb55_ver}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
-            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb55_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
+            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb55_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
             MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}')
-            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb55_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
+            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb55_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb55_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
-            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb55_version}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
+            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb55_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}
+            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb55_ver}/bintar-${GLIBC_FLAG}-${SYS_BIT_a}/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
           fi
-        elif [ "${dbInstallMethods}" == '2' ]; then
+        elif [ "${dbinstallmethod}" == '2' ]; then
           echo "Download MariaDB 5.5 source package..."
-          FILE_NAME=mariadb-${mariadb55_version}.tar.gz
+          FILE_NAME=mariadb-${mariadb55_ver}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
-            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb55_version}/source
+            DOWN_ADDR_MARIADB=https://mirrors.tuna.tsinghua.edu.cn/mariadb/mariadb-${mariadb55_ver}/source
             MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}')
-            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb55_version}/source; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
+            [ -z "${MARAIDB_TAR_MD5}" ] && { DOWN_ADDR_MARIADB=https://mirrors.ustc.edu.cn/mariadb/mariadb-${mariadb55_ver}/source; MARAIDB_TAR_MD5=$(curl -s ${DOWN_ADDR_MARIADB}/md5sums.txt | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb55_version}/source
-            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb55_version}/source/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
+            DOWN_ADDR_MARIADB=https://downloads.mariadb.org/interstitial/mariadb-${mariadb55_ver}/source
+            MARAIDB_TAR_MD5=$(curl -s http://archive.mariadb.org/mariadb-${mariadb55_ver}/source/md5sums.txt |  grep ${FILE_NAME} | awk '{print $1}')
           fi
         fi
         tryDlCount=0
@@ -399,21 +399,21 @@ checkDownload() {
 
       8)
         # Precona 5.7
-        if [ "${dbInstallMethods}" == '1' ]; then
+        if [ "${dbinstallmethod}" == '1' ]; then
           echo "Download Percona 5.7 binary package..."
-          FILE_NAME=Percona-Server-${percona57_version}-Linux.${SYS_BIT_b}.${sslLibVer}.tar.gz
-          DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.7/Percona-Server-${percona57_version}/binary/tarball
-          PERCONA_TAR_MD5=$(curl -s https://www.percona.com/downloads/Percona-Server-5.7/Percona-Server-${percona57_version}/binary/tarball/${FILE_NAME}.md5sum |  grep ${FILE_NAME} | awk '{print $1}')
-        elif [ "${dbInstallMethods}" == '2' ]; then
+          FILE_NAME=Percona-Server-${percona57_ver}-Linux.${SYS_BIT_b}.${sslLibVer}.tar.gz
+          DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.7/Percona-Server-${percona57_ver}/binary/tarball
+          PERCONA_TAR_MD5=$(curl -s https://www.percona.com/downloads/Percona-Server-5.7/Percona-Server-${percona57_ver}/binary/tarball/${FILE_NAME}.md5sum |  grep ${FILE_NAME} | awk '{print $1}')
+        elif [ "${dbinstallmethod}" == '2' ]; then
           echo "Download Percona 5.7 source package..."
-          FILE_NAME=percona-server-${percona57_version}.tar.gz
+          FILE_NAME=percona-server-${percona57_ver}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
             DOWN_ADDR_PERCONA=${mirrorLink}
-            DOWN_ADDR_PERCONA_BK=https://www.percona.com/downloads/Percona-Server-5.7/Percona-Server-${percona57_version}/source/tarball
+            DOWN_ADDR_PERCONA_BK=https://www.percona.com/downloads/Percona-Server-5.7/Percona-Server-${percona57_ver}/source/tarball
             PERCONA_TAR_MD5=$(curl -s ${DOWN_ADDR_PERCONA}/${FILE_NAME}.md5sum | grep ${FILE_NAME} | awk '{print $1}')
             [ -z "${PERCONA_TAR_MD5}" ] && { DOWN_ADDR_PERCONA=${DOWN_ADDR_PERCONA_BK}; PERCONA_TAR_MD5=$(curl -s ${DOWN_ADDR_PERCONA_BK}/${FILE_NAME}.md5sum | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.7/Percona-Server-${percona57_version}/source/tarball
+            DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.7/Percona-Server-${percona57_ver}/source/tarball
             PERCONA_TAR_MD5=$(curl -s ${DOWN_ADDR_PERCONA}/${FILE_NAME}.md5sum |  grep ${FILE_NAME} | awk '{print $1}')
           fi
         fi
@@ -433,22 +433,22 @@ checkDownload() {
 
       9)
         # Precona 5.6
-        if [ "${dbInstallMethods}" == '1' ]; then
+        if [ "${dbinstallmethod}" == '1' ]; then
           echo "Download Percona 5.6 binary package..."
-          perconaVerStr1=$(echo ${percona56_version} | sed "s@-@-rel@")
+          perconaVerStr1=$(echo ${percona56_ver} | sed "s@-@-rel@")
           FILE_NAME=Percona-Server-${perconaVerStr1}-Linux.${SYS_BIT_b}.${sslLibVer}.tar.gz
-          DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.6/Percona-Server-${percona56_version}/binary/tarball
-          PERCONA_TAR_MD5=$(curl -s https://www.percona.com/downloads/Percona-Server-5.6/Percona-Server-${percona56_version}/binary/tarball/${FILE_NAME}.md5sum |  grep ${FILE_NAME} | awk '{print $1}')
-        elif [ "${dbInstallMethods}" == '2' ]; then
+          DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.6/Percona-Server-${percona56_ver}/binary/tarball
+          PERCONA_TAR_MD5=$(curl -s https://www.percona.com/downloads/Percona-Server-5.6/Percona-Server-${percona56_ver}/binary/tarball/${FILE_NAME}.md5sum |  grep ${FILE_NAME} | awk '{print $1}')
+        elif [ "${dbinstallmethod}" == '2' ]; then
           echo "Download Percona 5.6 source package..."
-          FILE_NAME=percona-server-${percona56_version}.tar.gz
+          FILE_NAME=percona-server-${percona56_ver}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
             DOWN_ADDR_PERCONA=${mirrorLink}
-            DOWN_ADDR_PERCONA_BK=https://www.percona.com/downloads/Percona-Server-5.6/Percona-Server-${percona56_version}/source/tarball
+            DOWN_ADDR_PERCONA_BK=https://www.percona.com/downloads/Percona-Server-5.6/Percona-Server-${percona56_ver}/source/tarball
             PERCONA_TAR_MD5=$(curl -s ${DOWN_ADDR_PERCONA}/${FILE_NAME}.md5sum | grep ${FILE_NAME} | awk '{print $1}')
             [ -z "${PERCONA_TAR_MD5}" ] && { DOWN_ADDR_PERCONA=${DOWN_ADDR_PERCONA_BK}; PERCONA_TAR_MD5=$(curl -s ${DOWN_ADDR_PERCONA_BK}/${FILE_NAME}.md5sum | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.6/Percona-Server-${percona56_version}/source/tarball
+            DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.6/Percona-Server-${percona56_ver}/source/tarball
             PERCONA_TAR_MD5=$(curl -s ${DOWN_ADDR_PERCONA}/${FILE_NAME}.md5sum |  grep ${FILE_NAME} | awk '{print $1}')
           fi
         fi
@@ -468,22 +468,22 @@ checkDownload() {
 
       10)
         # Percona 5.5
-        if [ "${dbInstallMethods}" == '1' ]; then
+        if [ "${dbinstallmethod}" == '1' ]; then
           echo "Download Percona 5.5 binary package..."
-          perconaVerStr1=$(echo ${percona55_version} | sed "s@-@-rel@")
+          perconaVerStr1=$(echo ${percona55_ver} | sed "s@-@-rel@")
           FILE_NAME=Percona-Server-${perconaVerStr1}-Linux.${SYS_BIT_b}.${sslLibVer}.tar.gz
-          DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.5/Percona-Server-${percona55_version}/binary/tarball
-          PERCONA_TAR_MD5=$(curl -s https://www.percona.com/downloads/Percona-Server-5.5/Percona-Server-${percona55_version}/binary/tarball/${FILE_NAME}.md5sum |  grep ${FILE_NAME} | awk '{print $1}')
-        elif [ "${dbInstallMethods}" == '2' ]; then
+          DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.5/Percona-Server-${percona55_ver}/binary/tarball
+          PERCONA_TAR_MD5=$(curl -s https://www.percona.com/downloads/Percona-Server-5.5/Percona-Server-${percona55_ver}/binary/tarball/${FILE_NAME}.md5sum |  grep ${FILE_NAME} | awk '{print $1}')
+        elif [ "${dbinstallmethod}" == '2' ]; then
           echo "Download Percona 5.5 source package..."
-          FILE_NAME=percona-server-${percona55_version}.tar.gz
+          FILE_NAME=percona-server-${percona55_ver}.tar.gz
           if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
             DOWN_ADDR_PERCONA=${mirrorLink}
-            DOWN_ADDR_PERCONA_BK=https://www.percona.com/downloads/Percona-Server-5.5/Percona-Server-${percona55_version}/source/tarball
+            DOWN_ADDR_PERCONA_BK=https://www.percona.com/downloads/Percona-Server-5.5/Percona-Server-${percona55_ver}/source/tarball
             PERCONA_TAR_MD5=$(curl -s ${DOWN_ADDR_PERCONA}/${FILE_NAME}.md5sum | grep ${FILE_NAME} | awk '{print $1}')
             [ -z "${PERCONA_TAR_MD5}" ] && { DOWN_ADDR_PERCONA=${DOWN_ADDR_PERCONA_BK}; PERCONA_TAR_MD5=$(curl -s ${DOWN_ADDR_PERCONA_BK}/${FILE_NAME}.md5sum | grep ${FILE_NAME} | awk '{print $1}'); }
           else
-            DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.5/Percona-Server-${percona55_version}/source/tarball
+            DOWN_ADDR_PERCONA=https://www.percona.com/downloads/Percona-Server-5.5/Percona-Server-${percona55_ver}/source/tarball
             PERCONA_TAR_MD5=$(curl -s ${DOWN_ADDR_PERCONA}/${FILE_NAME}.md5sum | grep ${FILE_NAME} | awk '{print $1}')
           fi
         fi
@@ -505,9 +505,9 @@ checkDownload() {
         # AliSQL 5.6
         DOWN_ADDR_ALISQL=$mirrorLink
         echo "Download AliSQL 5.6 source package..."
-        FILE_NAME=alisql-${alisql56_version}.tar.gz
-        wget --tries=6 -c --no-check-certificate ${DOWN_ADDR_ALISQL}/${FILE_NAME}
-        wget --tries=6 -c --no-check-certificate ${DOWN_ADDR_ALISQL}/${FILE_NAME}.md5
+        FILE_NAME=alisql-${alisql_ver}.tar.gz
+        wget -4 --tries=6 -c --no-check-certificate ${DOWN_ADDR_ALISQL}/${FILE_NAME}
+        wget -4 --tries=6 -c --no-check-certificate ${DOWN_ADDR_ALISQL}/${FILE_NAME}.md5
         ALISQL_TAR_MD5=$(awk '{print $1}' ${FILE_NAME}.md5)
         while [ "$(md5sum ${FILE_NAME} | awk '{print $1}')" != "${ALISQL_TAR_MD5}" ];do
           wget -4c --no-check-certificate ${DOWN_ADDR_ALISQL}/${FILE_NAME};sleep 1
@@ -518,13 +518,13 @@ checkDownload() {
       12) 
         # PostgreSQL 
         echo "Download PostgreSQL source package..."
-        FILE_NAME=postgresql-${pgsql_version}.tar.gz
+        FILE_NAME=postgresql-${pgsql_ver}.tar.gz
         if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
-          DOWN_ADDR_PGSQL=https://mirrors.tuna.tsinghua.edu.cn/postgresql/source/v${pgsql_version}
+          DOWN_ADDR_PGSQL=https://mirrors.tuna.tsinghua.edu.cn/postgresql/source/v${pgsql_ver}
           PGSQL_TAR_MD5=$(curl -s ${DOWN_ADDR_PGSQL}/${FILE_NAME}.md5 | grep ${FILE_NAME} | awk '{print $1}')
-          [ -z "${PGSQL_TAR_MD5}" ] && { DOWN_ADDR_PGSQL=https://mirrors.ustc.edu.cn/postgresql/source/v${pgsql_version}; PGSQL_TAR_MD5=$(curl -s ${DOWN_ADDR_PGSQL}/${FILE_NAME}.md5 | grep ${FILE_NAME} | awk '{print $1}'); }
+          [ -z "${PGSQL_TAR_MD5}" ] && { DOWN_ADDR_PGSQL=https://mirrors.ustc.edu.cn/postgresql/source/v${pgsql_ver}; PGSQL_TAR_MD5=$(curl -s ${DOWN_ADDR_PGSQL}/${FILE_NAME}.md5 | grep ${FILE_NAME} | awk '{print $1}'); }
         else
-          DOWN_ADDR_PGSQL=https://ftp.postgresql.org/pub/source/v${pgsql_version}
+          DOWN_ADDR_PGSQL=https://ftp.postgresql.org/pub/source/v${pgsql_ver}
           PGSQL_TAR_MD5=$(curl -s ${DOWN_ADDR_PGSQL}/${FILE_NAME}.md5 | grep ${FILE_NAME} | awk '{print $1}')
         fi
 
@@ -544,7 +544,7 @@ checkDownload() {
       13) 
         # MongoDB
         echo "Download MongoDB binary package..."
-        FILE_NAME=mongodb-linux-${SYS_BIT_b}-${mongodb_version}.tgz
+        FILE_NAME=mongodb-linux-${SYS_BIT_b}-${mongodb_ver}.tgz
         if [ "${IPADDR_COUNTRY}"x == "CN"x ]; then
           DOWN_ADDR_MongoDB=${mirrorLink}
         else
@@ -568,78 +568,78 @@ checkDownload() {
     esac
   fi
   # PHP
-  if [ "${PHP_yn}" == 'y' ]; then
+  if [ "${php_yn}" == 'y' ]; then
     # php 5.3 5.4 5.5 5.6 5.7
     echo "PHP common..."
-    src_url=http://ftp.gnu.org/pub/gnu/libiconv/libiconv-${libiconv_version}.tar.gz && Download_src
-    src_url=https://curl.haxx.se/download/curl-${curl_version}.tar.gz && Download_src
-    src_url=http://downloads.sourceforge.net/project/mcrypt/Libmcrypt/${libmcrypt_version}/libmcrypt-${libmcrypt_version}.tar.gz && Download_src
-    src_url=http://downloads.sourceforge.net/project/mhash/mhash/${mhash_version}/mhash-${mhash_version}.tar.gz && Download_src
-    src_url=http://downloads.sourceforge.net/project/mcrypt/MCrypt/${mcrypt_version}/mcrypt-${mcrypt_version}.tar.gz && Download_src
+    src_url=http://ftp.gnu.org/pub/gnu/libiconv/libiconv-${libiconv_ver}.tar.gz && Download_src
+    src_url=https://curl.haxx.se/download/curl-${curl_ver}.tar.gz && Download_src
+    src_url=http://downloads.sourceforge.net/project/mcrypt/Libmcrypt/${libmcrypt_ver}/libmcrypt-${libmcrypt_ver}.tar.gz && Download_src
+    src_url=http://downloads.sourceforge.net/project/mhash/mhash/${mhash_ver}/mhash-${mhash_ver}.tar.gz && Download_src
+    src_url=http://downloads.sourceforge.net/project/mcrypt/MCrypt/${mcrypt_ver}/mcrypt-${mcrypt_ver}.tar.gz && Download_src
     src_url=${mirrorLink}/libiconv-glibc-2.16.patch && Download_src
 
-    case "${PHP_version}" in
+    case "${php_ver}" in
       1)
         # php 5.3
         src_url=${mirrorLink}/debian_patches_disable_SSLv2_for_openssl_1_0_0.patch && Download_src
         src_url=${mirrorLink}/php5.3patch && Download_src
-        src_url=http://www.php.net/distributions/php-${php53_version}.tar.gz && Download_src
+        src_url=http://www.php.net/distributions/php-${php53_ver}.tar.gz && Download_src
         src_url=${mirrorLink}/fpm-race-condition.patch && Download_src
         ;;
       2)
-        src_url=http://www.php.net/distributions/php-${php54_version}.tar.gz && Download_src
+        src_url=http://www.php.net/distributions/php-${php54_ver}.tar.gz && Download_src
         src_url=${mirrorLink}/fpm-race-condition.patch && Download_src
         ;;
       3)
-        src_url=http://www.php.net/distributions/php-${php55_version}.tar.gz && Download_src
+        src_url=http://www.php.net/distributions/php-${php55_ver}.tar.gz && Download_src
         src_url=${mirrorLink}/fpm-race-condition.patch && Download_src
         ;;
       4)
-        src_url=http://www.php.net/distributions/php-${php56_version}.tar.gz && Download_src
+        src_url=http://www.php.net/distributions/php-${php56_ver}.tar.gz && Download_src
         ;;
       5)
-        src_url=http://www.php.net/distributions/php-${php70_version}.tar.gz && Download_src
+        src_url=http://www.php.net/distributions/php-${php70_ver}.tar.gz && Download_src
         ;;
       6)
-        src_url=http://www.php.net/distributions/php-${php71_version}.tar.gz && Download_src
+        src_url=http://www.php.net/distributions/php-${php71_ver}.tar.gz && Download_src
         ;;
       7)
-        src_url=http://www.php.net/distributions/php-${php72_version}.tar.gz && Download_src
+        src_url=http://www.php.net/distributions/php-${php72_ver}.tar.gz && Download_src
         ;;
     esac
   fi
 
   # PHP OPCache
-  case "${PHP_cache}" in
+  case "${php_cache}" in
     1)
-      if [[ "$PHP_version" =~ ^[1-2]$ ]]; then
+      if [[ "$php_ver" =~ ^[1-2]$ ]]; then
         # php 5.3 5.4
         echo "Download Zend OPCache..."
-        src_url=https://pecl.php.net/get/zendopcache-${zendopcache_version}.tgz && Download_src
+        src_url=https://pecl.php.net/get/zendopcache-${zendopcache_ver}.tgz && Download_src
       fi
       ;;
     2)
-      if [[ "$PHP_version" =~ ^[1-4]$ ]]; then
+      if [[ "$php_ver" =~ ^[1-4]$ ]]; then
         # php 5.3 5.4 5.5 5.6
         echo "Download xcache..."
-        src_url=http://xcache.lighttpd.net/pub/Releases/${xcache_version}/xcache-${xcache_version}.tar.gz && Download_src
+        src_url=http://xcache.lighttpd.net/pub/Releases/${xcache_ver}/xcache-${xcache_ver}.tar.gz && Download_src
       fi
       ;;
     3)
       # php 5.3 5.4 5.5 5.6 7.0 7.1 7.2
       echo "Download apcu..."
-      if [[ "$PHP_version" =~ ^[1-4]$ ]]; then
-        src_url=https://pecl.php.net/get/apcu-${apcu_version}.tgz && Download_src
+      if [[ "$php_ver" =~ ^[1-4]$ ]]; then
+        src_url=https://pecl.php.net/get/apcu-${apcu_ver}.tgz && Download_src
       else
-        src_url=https://pecl.php.net/get/apcu-${apcu_for_php7_version}.tgz && Download_src
+        src_url=https://pecl.php.net/get/apcu-${apcu_for_php7_ver}.tgz && Download_src
       fi
       ;;
     4)
       # php 5.3 5.4
-      if [ "${PHP_version}" == '1' ]; then
+      if [ "${php_ver}" == '1' ]; then
         echo "Download eaccelerator 0.9..."
-        src_url=https://github.com/downloads/eaccelerator/eaccelerator/eaccelerator-${eaccelerator_version}.tar.bz2 && Download_src
-      elif [ "${PHP_version}" == '2' ]; then
+        src_url=https://github.com/downloads/eaccelerator/eaccelerator/eaccelerator-${eaccelerator_ver}.tar.bz2 && Download_src
+      elif [ "${php_ver}" == '2' ]; then
         echo "Download eaccelerator 1.0 dev..."
         src_url=https://github.com/eaccelerator/eaccelerator/tarball/master && Download_src
       fi
@@ -647,8 +647,8 @@ checkDownload() {
   esac
 
   # Zend Guard Loader
-  if [ "${ZendGuardLoader_yn}" == 'y' -a "${armPlatform}" != 'y' ]; then
-    case "${PHP_version}" in
+  if [ "${zendguardloader_yn}" == 'y' -a "${armplatform}" != 'y' ]; then
+    case "${php_ver}" in
       4)
         if [ "${OS_BIT}" == "64" ]; then
           # 64 bit
@@ -696,17 +696,17 @@ checkDownload() {
     esac
   fi
 
-  if [ "${DB_version}" == '13' ]; then
-    if [[ "$PHP_version" =~ ^[1-2]$ ]]; then
+  if [ "${db_ver}" == '13' ]; then
+    if [[ "$php_ver" =~ ^[1-2]$ ]]; then
       echo "Download pecl mongo for php..."
-      src_url=https://pecl.php.net/get/mongo-${mongo_pecl_version}.tgz && Download_src
+      src_url=https://pecl.php.net/get/mongo-${mongo_pecl_ver}.tgz && Download_src
     else
       echo "Download pecl mongodb for php..."
-      src_url=https://pecl.php.net/get/mongodb-${mongodb_pecl_version}.tgz && Download_src
+      src_url=https://pecl.php.net/get/mongodb-${mongodb_pecl_ver}.tgz && Download_src
     fi
   fi
 
-  if [ "${ionCube_yn}" == 'y' ]; then
+  if [ "${ioncube_yn}" == 'y' ]; then
     echo "Download ioncube..."
     if [ "${OS_BIT}" == '64' ]; then
         src_url=http://downloads3.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz && Download_src
@@ -719,16 +719,16 @@ checkDownload() {
     fi
   fi
 
-  if [ "${Magick_yn}" == 'y' ]; then
-    if [ "${Magick}" == '1' ]; then
+  if [ "${magick_yn}" == 'y' ]; then
+    if [ "${magick}" == '1' ]; then
       echo "Download ImageMagick..."
-      src_url=${mirrorLink}/ImageMagick-${ImageMagick_version}.tar.gz && Download_src
+      src_url=${mirrorLink}/ImageMagick-${imagemagick_ver}.tar.gz && Download_src
       echo "Download imagick..."
-      src_url=https://pecl.php.net/get/imagick-${imagick_version}.tgz && Download_src
+      src_url=https://pecl.php.net/get/imagick-${imagick_ver}.tgz && Download_src
     else
       echo "Download graphicsmagick..."
-      src_url=http://downloads.sourceforge.net/project/graphicsmagick/graphicsmagick/${GraphicsMagick_version}/GraphicsMagick-${GraphicsMagick_version}.tar.gz && Download_src
-      if [[ "$PHP_version" =~ ^[5-7]$ ]]; then
+      src_url=http://downloads.sourceforge.net/project/graphicsmagick/graphicsmagick/${graphicsmagick_ver}/GraphicsMagick-${graphicsmagick_ver}.tar.gz && Download_src
+      if [[ "$php_ver" =~ ^[5-7]$ ]]; then
         echo "Download gmagick for php 7.x..."
         src_url=https://pecl.php.net/get/gmagick-${gmagick_for_php7_version}.tgz && Download_src
       else
@@ -738,21 +738,21 @@ checkDownload() {
     fi
   fi
 
-  if [ "${FTP_yn}" == 'y' ]; then
+  if [ "${ftp_yn}" == 'y' ]; then
     echo "Download pureftpd..."
-    src_url=https://download.pureftpd.org/pub/pure-ftpd/releases/pure-ftpd-${pureftpd_version}.tar.gz && Download_src
+    src_url=https://download.pureftpd.org/pub/pure-ftpd/releases/pure-ftpd-${pureftpd_ver}.tar.gz && Download_src
   fi
 
-  if [ "${phpMyAdmin_yn}" == 'y' ]; then
+  if [ "${phpmyadmin_yn}" == 'y' ]; then
     echo "Download phpMyAdmin..."
-    src_url=https://files.phpmyadmin.net/phpMyAdmin/${phpMyAdmin_version}/phpMyAdmin-${phpMyAdmin_version}-all-languages.tar.gz && Download_src
+    src_url=https://files.phpmyadmin.net/phpMyAdmin/${phpmyadmin_ver}/phpMyAdmin-${phpmyadmin_ver}-all-languages.tar.gz && Download_src
   fi
 
   if [ "${redis_yn}" == 'y' ]; then
     echo "Download redis..."
-    src_url=http://download.redis.io/releases/redis-${redis_version}.tar.gz && Download_src
+    src_url=http://download.redis.io/releases/redis-${redis_ver}.tar.gz && Download_src
     echo "Download redis pecl..."
-    src_url=https://pecl.php.net/get/redis-${redis_pecl_version}.tgz && Download_src
+    src_url=https://pecl.php.net/get/redis-${redis_pecl_ver}.tgz && Download_src
     if [ "${OS}" == "CentOS" ]; then
       echo "Download start-stop-daemon.c for CentOS..."
       src_url=${mirrorLink}/start-stop-daemon.c && Download_src
@@ -761,43 +761,43 @@ checkDownload() {
 
   if [ "${memcached_yn}" == 'y' ]; then
     echo "Download memcached..."
-    src_url=http://www.memcached.org/files/memcached-${memcached_version}.tar.gz && Download_src
-    if [[ "$PHP_version" =~ ^[5-7]$ ]]; then
+    src_url=http://www.memcached.org/files/memcached-${memcached_ver}.tar.gz && Download_src
+    if [[ "$php_ver" =~ ^[5-7]$ ]]; then
       echo "Download pecl memcache for php 7.x..."
       # src_url=https://codeload.github.com/websupport-sk/pecl-memcache/zip/php7 && Download_src
       src_url=${mirrorLink}/pecl-memcache-php7.tgz && Download_src
       echo "Download pecl memcached for php 7.x..."
-      src_url=https://pecl.php.net/get/memcached-${memcached_pecl_php7_version}.tgz && Download_src
+      src_url=https://pecl.php.net/get/memcached-${memcached_pecl_php7_ver}.tgz && Download_src
     else
       echo "Download pecl memcache for php..."
-      src_url=https://pecl.php.net/get/memcache-${memcache_pecl_version}.tgz && Download_src
+      src_url=https://pecl.php.net/get/memcache-${memcache_pecl_ver}.tgz && Download_src
       echo "Download pecl memcached for php..."
-      src_url=https://pecl.php.net/get/memcached-${memcached_pecl_version}.tgz && Download_src
+      src_url=https://pecl.php.net/get/memcached-${memcached_pecl_ver}.tgz && Download_src
     fi
 
     echo "Download libmemcached..."
-    src_url=https://launchpad.net/libmemcached/1.0/${libmemcached_version}/+download/libmemcached-${libmemcached_version}.tar.gz && Download_src
+    src_url=https://launchpad.net/libmemcached/1.0/${libmemcached_ver}/+download/libmemcached-${libmemcached_ver}.tar.gz && Download_src
   fi
 
-  if [[ $Nginx_version =~ ^[1-3]$ ]] || [ "$DB_yn" == 'y' -a "$DB_version" != '10' ]; then
+  if [[ $nginx_ver =~ ^[1-3]$ ]] || [ "$db_yn" == 'y' -a "$db_ver" != '10' ]; then
     echo "Download jemalloc..."
-    src_url=${mirrorLink}/jemalloc-${jemalloc_version}.tar.bz2 && Download_src
+    src_url=${mirrorLink}/jemalloc-${jemalloc_ver}.tar.bz2 && Download_src
   fi
 
   # others
   if [ "${downloadDepsSrc}" == '1' ]; then
     if [ "${OS}" == "CentOS" ]; then
       echo "Download tmux for CentOS..."
-      src_url=${mirrorLink}/libevent-${libevent_version}.tar.gz && Download_src
-      src_url=https://github.com/tmux/tmux/releases/download/${tmux_version}/tmux-${tmux_version}.tar.gz && Download_src
+      src_url=${mirrorLink}/libevent-${libevent_ver}.tar.gz && Download_src
+      src_url=https://github.com/tmux/tmux/releases/download/${tmux_ver}/tmux-${tmux_ver}.tar.gz && Download_src
 
       echo "Download htop for CentOS..."
-      src_url=http://hisham.hm/htop/releases/${htop_version}/htop-${htop_version}.tar.gz && Download_src
+      src_url=http://hisham.hm/htop/releases/${htop_ver}/htop-${htop_ver}.tar.gz && Download_src
     fi
 
     if [[ "${Ubuntu_version}" =~ ^14$|^15$ ]]; then
       echo "Download bison for Ubuntu..."
-      src_url=http://ftp.gnu.org/gnu/bison/bison-${bison_version}.tar.gz && Download_src
+      src_url=http://ftp.gnu.org/gnu/bison/bison-${bison_ver}.tar.gz && Download_src
     fi
   fi
 

+ 2 - 2
include/check_os.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -66,7 +66,7 @@ LIBC_YN=$(awk -v A=$(getconf -a | grep GNU_LIBC_VERSION | awk '{print $NF}') -v
 [ $LIBC_YN == '0' ] && GLIBC_FLAG=linux-glibc_214 || GLIBC_FLAG=linux
 
 if uname -m | grep -Eqi "arm"; then
-  armPlatform="y"
+  armplatform="y"
   if uname -m | grep -Eqi "armv7"; then
     TARGET_ARCH="armv7"
   elif uname -m | grep -Eqi "armv8"; then

+ 12 - 12
include/check_sw.sh

@@ -124,31 +124,31 @@ installDepsBySrc() {
   if [ "${OS}" == "Ubuntu" ]; then
     if [[ "${Ubuntu_version}" =~ ^14$|^15$ ]]; then
       # Install bison on ubt 14.x 15.x
-      tar xzf bison-${bison_version}.tar.gz
-      pushd bison-${bison_version}
+      tar xzf bison-${bison_ver}.tar.gz
+      pushd bison-${bison_ver}
       ./configure
       make -j ${THREAD} && make install
       popd
-      rm -rf bison-${bison_version}
+      rm -rf bison-${bison_ver}
     fi
   elif [ "${OS}" == "CentOS" ]; then
     # Install tmux
     if [ ! -e "$(which tmux)" ]; then
       # Install libevent first
-      tar xzf libevent-${libevent_version}.tar.gz
-      pushd libevent-${libevent_version}
+      tar xzf libevent-${libevent_ver}.tar.gz
+      pushd libevent-${libevent_ver}
       ./configure
       make -j ${THREAD} && make install
       popd
-      rm -rf libevent-${libevent_version}
+      rm -rf libevent-${libevent_ver}
 
-      tar xzf tmux-${tmux_version}.tar.gz
-      pushd tmux-${tmux_version}
+      tar xzf tmux-${tmux_ver}.tar.gz
+      pushd tmux-${tmux_ver}
       CFLAGS="-I/usr/local/include" LDFLAGS="-L/usr/local/lib" ./configure
       make -j ${THREAD} && make install
       unset LDFLAGS
       popd
-      rm -rf tmux-${tmux_version}
+      rm -rf tmux-${tmux_ver}
 
       if [ "${OS_BIT}" == "64" ]; then
         ln -s /usr/local/lib/libevent-2.0.so.5 /usr/lib64/libevent-2.0.so.5
@@ -159,12 +159,12 @@ installDepsBySrc() {
 
     # install htop
     if [ ! -e "$(which htop)" ]; then
-      tar xzf htop-${htop_version}.tar.gz
-      pushd htop-${htop_version}
+      tar xzf htop-${htop_ver}.tar.gz
+      pushd htop-${htop_ver}
       ./configure
       make -j ${THREAD} && make install
       popd
-      rm -rf htop-${htop_version}
+      rm -rf htop-${htop_ver}
     fi
   else
     echo "No need to install software from source packages."

+ 1 - 1
include/color.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 2 - 2
include/demo.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -23,7 +23,7 @@ DEMO() {
     fi
 
     echo "<?php phpinfo() ?>" > ${wwwroot_dir}/default/phpinfo.php
-    case "${PHP_cache}" in
+    case "${php_cache}" in
       1)
         src_url=http://mirrors.linuxeye.com/oneinstack/src/ocp.php && Download_src
         /bin/cp ocp.php ${wwwroot_dir}/default

+ 1 - 1
include/download.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 5 - 5
include/eaccelerator.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,10 +11,10 @@
 Install_eAccelerator() {
   pushd ${oneinstack_dir}/src
   phpExtensionDir=$(${php_install_dir}/bin/php-config --extension-dir)
-  case "${PHP_version}" in
+  case "${php_ver}" in
     1)
-      tar jxf eaccelerator-${eaccelerator_version}.tar.bz2
-      pushd eaccelerator-${eaccelerator_version}
+      tar jxf eaccelerator-${eaccelerator_ver}.tar.bz2
+      pushd eaccelerator-${eaccelerator_ver}
       ;;
     2)
       /bin/mv master eaccelerator-eaccelerator-42067ac.tar.gz
@@ -54,7 +54,7 @@ EOF
     echo "${CSUCCESS}Accelerator module installed successfully! ${CEND}"
     [ -z "$(grep 'kernel.shmmax = 67108864' /etc/sysctl.conf)" ] && echo "kernel.shmmax = 67108864" >> /etc/sysctl.conf
     sysctl -p
-    rm -rf eaccelerator-${eaccelerator_version} eaccelerator-eaccelerator-42067ac
+    rm -rf eaccelerator-${eaccelerator_ver} eaccelerator-eaccelerator-42067ac
   else
     echo "${CFAILURE}Accelerator module install failed, Please contact the author! ${CEND}"
   fi

+ 1 - 1
include/get_char.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 1 - 1
include/hhvm_CentOS.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 3 - 3
include/init_CentOS.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -152,8 +152,8 @@ COMMIT
 EOF
   fi
 
-  FW_PORT_FLAG=$(grep -ow "dport ${SSH_PORT}" /etc/sysconfig/iptables)
-  [ -z "${FW_PORT_FLAG}" -a "${SSH_PORT}" != "22" ] && sed -i "s@dport 22 -j ACCEPT@&\n-A INPUT -p tcp -m state --state NEW -m tcp --dport ${SSH_PORT} -j ACCEPT@" /etc/sysconfig/iptables
+  FW_PORT_FLAG=$(grep -ow "dport ${ssh_port}" /etc/sysconfig/iptables)
+  [ -z "${FW_PORT_FLAG}" -a "${ssh_port}" != "22" ] && sed -i "s@dport 22 -j ACCEPT@&\n-A INPUT -p tcp -m state --state NEW -m tcp --dport ${ssh_port} -j ACCEPT@" /etc/sysconfig/iptables
   chkconfig --level 3 iptables on
   service iptables restart
 fi

+ 3 - 3
include/init_Debian.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -121,8 +121,8 @@ COMMIT
 EOF
   fi
 
-  FW_PORT_FLAG=$(grep -ow "dport ${SSH_PORT}" /etc/iptables.up.rules)
-  [ -z "${FW_PORT_FLAG}" -a "${SSH_PORT}" != "22" ] && sed -i "s@dport 22 -j ACCEPT@&\n-A INPUT -p tcp -m state --state NEW -m tcp --dport ${SSH_PORT} -j ACCEPT@" /etc/iptables.up.rules
+  FW_PORT_FLAG=$(grep -ow "dport ${ssh_port}" /etc/iptables.up.rules)
+  [ -z "${FW_PORT_FLAG}" -a "${ssh_port}" != "22" ] && sed -i "s@dport 22 -j ACCEPT@&\n-A INPUT -p tcp -m state --state NEW -m tcp --dport ${ssh_port} -j ACCEPT@" /etc/iptables.up.rules
   iptables-restore < /etc/iptables.up.rules
   cat > /etc/network/if-pre-up.d/iptables << EOF
 #!/bin/bash

+ 3 - 3
include/init_Ubuntu.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -129,8 +129,8 @@ COMMIT
 EOF
   fi
 
-  FW_PORT_FLAG=$(grep -ow "dport ${SSH_PORT}" /etc/iptables.up.rules)
-  [ -z "${FW_PORT_FLAG}" -a "${SSH_PORT}" != "22" ] && sed -i "s@dport 22 -j ACCEPT@&\n-A INPUT -p tcp -m state --state NEW -m tcp --dport ${SSH_PORT} -j ACCEPT@" /etc/iptables.up.rules
+  FW_PORT_FLAG=$(grep -ow "dport ${ssh_port}" /etc/iptables.up.rules)
+  [ -z "${FW_PORT_FLAG}" -a "${ssh_port}" != "22" ] && sed -i "s@dport 22 -j ACCEPT@&\n-A INPUT -p tcp -m state --state NEW -m tcp --dport ${ssh_port} -j ACCEPT@" /etc/iptables.up.rules
   iptables-restore < /etc/iptables.up.rules
   cat > /etc/network/if-pre-up.d/iptables << EOF
 #!/bin/bash

+ 1 - 1
include/ioncube.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 3 - 3
include/jdk-1.6.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,9 +11,9 @@
 Install-JDK16() {
   pushd ${oneinstack_dir}/src
   
-  JDK_FILE="jdk-`echo $jdk16_version | awk -F. '{print $2}'`u`echo $jdk16_version | awk -F_ '{print $NF}'`-linux-$SYS_BIG_FLAG.bin"
+  JDK_FILE="jdk-`echo $jdk16_ver | awk -F. '{print $2}'`u`echo $jdk16_ver | awk -F_ '{print $NF}'`-linux-$SYS_BIG_FLAG.bin"
   JAVA_dir=/usr/java
-  JDK_NAME="jdk$jdk16_version"
+  JDK_NAME="jdk$jdk16_ver"
   JDK_PATH=$JAVA_dir/$JDK_NAME
   
   [ "$OS" == 'CentOS' ] && [ -n "`rpm -qa | grep jdk`" ] && rpm -e `rpm -qa | grep jdk`

+ 3 - 3
include/jdk-1.7.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,9 +11,9 @@
 Install-JDK17() {
   pushd ${oneinstack_dir}/src
 
-  JDK_FILE="jdk-`echo $jdk17_version | awk -F. '{print $2}'`u`echo $jdk17_version | awk -F_ '{print $NF}'`-linux-$SYS_BIG_FLAG.tar.gz"
+  JDK_FILE="jdk-`echo $jdk17_ver | awk -F. '{print $2}'`u`echo $jdk17_ver | awk -F_ '{print $NF}'`-linux-$SYS_BIG_FLAG.tar.gz"
   JAVA_dir=/usr/java
-  JDK_NAME="jdk$jdk17_version"
+  JDK_NAME="jdk$jdk17_ver"
   JDK_PATH=$JAVA_dir/$JDK_NAME
   
   [ "$OS" == 'CentOS' ] && [ -n "`rpm -qa | grep jdk`" ] && rpm -e `rpm -qa | grep jdk`

+ 3 - 3
include/jdk-1.8.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,9 +11,9 @@
 Install-JDK18() {
   pushd ${oneinstack_dir}/src
   
-  JDK_FILE="jdk-`echo $jdk18_version | awk -F. '{print $2}'`u`echo $jdk18_version | awk -F_ '{print $NF}'`-linux-$SYS_BIG_FLAG.tar.gz"
+  JDK_FILE="jdk-`echo $jdk18_ver | awk -F. '{print $2}'`u`echo $jdk18_ver | awk -F_ '{print $NF}'`-linux-$SYS_BIG_FLAG.tar.gz"
   JAVA_dir=/usr/java
-  JDK_NAME="jdk$jdk18_version"
+  JDK_NAME="jdk$jdk18_ver"
   JDK_PATH=$JAVA_dir/$JDK_NAME
   
   [ "$OS" == 'CentOS' ] && [ -n "`rpm -qa | grep jdk`" ] && rpm -e `rpm -qa | grep jdk`

+ 4 - 4
include/jemalloc.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,8 +11,8 @@
 Install_Jemalloc() {
   if [ ! -e "/usr/local/lib/libjemalloc.so" ]; then
     pushd ${oneinstack_dir}/src
-    tar xjf jemalloc-$jemalloc_version.tar.bz2
-    pushd jemalloc-$jemalloc_version
+    tar xjf jemalloc-$jemalloc_ver.tar.bz2
+    pushd jemalloc-$jemalloc_ver
     LDFLAGS="${LDFLAGS} -lrt" ./configure
     make -j ${THREAD} && make install
     unset LDFLAGS
@@ -26,7 +26,7 @@ Install_Jemalloc() {
       echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf
       ldconfig
       echo "${CSUCCESS}jemalloc module installed successfully! ${CEND}"
-      rm -rf jemalloc-${jemalloc_version}
+      rm -rf jemalloc-${jemalloc_ver}
     else
       echo "${CFAILURE}jemalloc install failed, Please contact the author! ${CEND}"
       kill -9 $$

+ 12 - 12
include/mariadb-10.0.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,14 +17,14 @@ Install_MariaDB100() {
   [ ! -d "${mariadb_install_dir}" ] && mkdir -p ${mariadb_install_dir}
   mkdir -p ${mariadb_data_dir};chown mysql.mysql -R ${mariadb_data_dir}
 
-  if [ "${dbInstallMethods}" == "1" ]; then
-    tar zxf mariadb-${mariadb100_version}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
-    mv mariadb-${mariadb100_version}-*-${SYS_BIT_b}/* ${mariadb_install_dir}
+  if [ "${dbinstallmethod}" == "1" ]; then
+    tar zxf mariadb-${mariadb100_ver}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
+    mv mariadb-${mariadb100_ver}-*-${SYS_BIT_b}/* ${mariadb_install_dir}
     sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' ${mariadb_install_dir}/bin/mysqld_safe
     sed -i "s@/usr/local/mysql@${mariadb_install_dir}@g" ${mariadb_install_dir}/bin/mysqld_safe
-  elif [ "${dbInstallMethods}" == "2" ]; then
-    tar xvf mariadb-${mariadb100_version}.tar.gz
-    pushd mariadb-${mariadb100_version}
+  elif [ "${dbinstallmethod}" == "2" ]; then
+    tar xvf mariadb-${mariadb100_ver}.tar.gz
+    pushd mariadb-${mariadb100_ver}
     cmake . -DCMAKE_INSTALL_PREFIX=${mariadb_install_dir} \
     -DMYSQL_DATADIR=${mariadb_data_dir} \
     -DSYSCONFDIR=/etc \
@@ -47,14 +47,14 @@ Install_MariaDB100() {
 
   if [ -d "${mariadb_install_dir}/support-files" ]; then
     echo "${CSUCCESS}MariaDB installed successfully! ${CEND}"
-    if [ "${dbInstallMethods}" == "1" ]; then
-      rm -rf mariadb-${mariadb100_version}-*-${SYS_BIT_b}
-    elif [ "${dbInstallMethods}" == "2" ]; then
-      rm -rf mariadb-${mariadb100_version}
+    if [ "${dbinstallmethod}" == "1" ]; then
+      rm -rf mariadb-${mariadb100_ver}-*-${SYS_BIT_b}
+    elif [ "${dbinstallmethod}" == "2" ]; then
+      rm -rf mariadb-${mariadb100_ver}
     fi
   else
     rm -rf ${mariadb_install_dir}
-    rm -rf mariadb-${mariadb100_version}
+    rm -rf mariadb-${mariadb100_ver}
     echo "${CFAILURE}MariaDB install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 12 - 12
include/mariadb-10.1.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,14 +17,14 @@ Install_MariaDB101() {
   [ ! -d "${mariadb_install_dir}" ] && mkdir -p ${mariadb_install_dir}
   mkdir -p ${mariadb_data_dir};chown mysql.mysql -R ${mariadb_data_dir}
 
-  if [ "${dbInstallMethods}" == "1" ]; then
-    tar zxf mariadb-${mariadb101_version}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
-    mv mariadb-${mariadb101_version}-*-${SYS_BIT_b}/* ${mariadb_install_dir}
+  if [ "${dbinstallmethod}" == "1" ]; then
+    tar zxf mariadb-${mariadb101_ver}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
+    mv mariadb-${mariadb101_ver}-*-${SYS_BIT_b}/* ${mariadb_install_dir}
     sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' ${mariadb_install_dir}/bin/mysqld_safe
     sed -i "s@/usr/local/mysql@${mariadb_install_dir}@g" ${mariadb_install_dir}/bin/mysqld_safe
-  elif [ "${dbInstallMethods}" == "2" ]; then
-    tar xvf mariadb-${mariadb101_version}.tar.gz
-    pushd mariadb-${mariadb101_version}
+  elif [ "${dbinstallmethod}" == "2" ]; then
+    tar xvf mariadb-${mariadb101_ver}.tar.gz
+    pushd mariadb-${mariadb101_ver}
     cmake . -DCMAKE_INSTALL_PREFIX=${mariadb_install_dir} \
     -DMYSQL_DATADIR=${mariadb_data_dir} \
     -DSYSCONFDIR=/etc \
@@ -47,14 +47,14 @@ Install_MariaDB101() {
 
   if [ -d "${mariadb_install_dir}/support-files" ]; then
     echo "${CSUCCESS}MariaDB installed successfully! ${CEND}"
-    if [ "${dbInstallMethods}" == "1" ]; then
-      rm -rf mariadb-${mariadb101_version}-*-${SYS_BIT_b}
-    elif [ "${dbInstallMethods}" == "2" ]; then
-      rm -rf mariadb-${mariadb101_version}
+    if [ "${dbinstallmethod}" == "1" ]; then
+      rm -rf mariadb-${mariadb101_ver}-*-${SYS_BIT_b}
+    elif [ "${dbinstallmethod}" == "2" ]; then
+      rm -rf mariadb-${mariadb101_ver}
     fi
   else
     rm -rf ${mariadb_install_dir}
-    rm -rf mariadb-${mariadb101_version}
+    rm -rf mariadb-${mariadb101_ver}
     echo "${CFAILURE}MariaDB install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 12 - 12
include/mariadb-10.2.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,14 +17,14 @@ Install_MariaDB102() {
   [ ! -d "${mariadb_install_dir}" ] && mkdir -p ${mariadb_install_dir}
   mkdir -p ${mariadb_data_dir};chown mysql.mysql -R ${mariadb_data_dir}
 
-  if [ "${dbInstallMethods}" == "1" ]; then
-    tar zxf mariadb-${mariadb102_version}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
-    mv mariadb-${mariadb102_version}-*-${SYS_BIT_b}/* ${mariadb_install_dir}
+  if [ "${dbinstallmethod}" == "1" ]; then
+    tar zxf mariadb-${mariadb102_ver}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
+    mv mariadb-${mariadb102_ver}-*-${SYS_BIT_b}/* ${mariadb_install_dir}
     sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' ${mariadb_install_dir}/bin/mysqld_safe
     sed -i "s@/usr/local/mysql@${mariadb_install_dir}@g" ${mariadb_install_dir}/bin/mysqld_safe
-  elif [ "${dbInstallMethods}" == "2" ]; then
-    tar xvf mariadb-${mariadb102_version}.tar.gz
-    pushd mariadb-${mariadb102_version}
+  elif [ "${dbinstallmethod}" == "2" ]; then
+    tar xvf mariadb-${mariadb102_ver}.tar.gz
+    pushd mariadb-${mariadb102_ver}
     cmake . -DCMAKE_INSTALL_PREFIX=${mariadb_install_dir} \
     -DMYSQL_DATADIR=${mariadb_data_dir} \
     -DSYSCONFDIR=/etc \
@@ -47,14 +47,14 @@ Install_MariaDB102() {
 
   if [ -d "${mariadb_install_dir}/support-files" ]; then
     echo "${CSUCCESS}MariaDB installed successfully! ${CEND}"
-    if [ "${dbInstallMethods}" == "1" ]; then
-      rm -rf mariadb-${mariadb102_version}-*-${SYS_BIT_b}
-    elif [ "${dbInstallMethods}" == "2" ]; then
-      rm -rf mariadb-${mariadb102_version}
+    if [ "${dbinstallmethod}" == "1" ]; then
+      rm -rf mariadb-${mariadb102_ver}-*-${SYS_BIT_b}
+    elif [ "${dbinstallmethod}" == "2" ]; then
+      rm -rf mariadb-${mariadb102_ver}
     fi
   else
     rm -rf ${mariadb_install_dir}
-    rm -rf mariadb-${mariadb102_version}
+    rm -rf mariadb-${mariadb102_ver}
     echo "${CFAILURE}MariaDB install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 13 - 13
include/mariadb-5.5.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,15 +17,15 @@ Install_MariaDB55() {
   [ ! -d "${mariadb_install_dir}" ] && mkdir -p ${mariadb_install_dir}
   mkdir -p ${mariadb_data_dir};chown mysql.mysql -R ${mariadb_data_dir}
 
-  if [ "${dbInstallMethods}" == "1" ]; then
-    tar zxf mariadb-${mariadb55_version}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
-    mv mariadb-${mariadb55_version}-*-${SYS_BIT_b}/* ${mariadb_install_dir}
+  if [ "${dbinstallmethod}" == "1" ]; then
+    tar zxf mariadb-${mariadb55_ver}-${GLIBC_FLAG}-${SYS_BIT_b}.tar.gz
+    mv mariadb-${mariadb55_ver}-*-${SYS_BIT_b}/* ${mariadb_install_dir}
     sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' ${mariadb_install_dir}/bin/mysqld_safe
     sed -i "s@/usr/local/mysql@${mariadb_install_dir}@g" ${mariadb_install_dir}/bin/mysqld_safe
-  elif [ "${dbInstallMethods}" == "2" ]; then
-    tar xvf mariadb-${mariadb55_version}.tar.gz
-    pushd mariadb-${mariadb55_version}
-    [ "${armPlatform}" == "y" ] && patch -p1 < ../mysql-5.5-fix-arm-client_plugin.patch
+  elif [ "${dbinstallmethod}" == "2" ]; then
+    tar xvf mariadb-${mariadb55_ver}.tar.gz
+    pushd mariadb-${mariadb55_ver}
+    [ "${armplatform}" == "y" ] && patch -p1 < ../mysql-5.5-fix-arm-client_plugin.patch
     cmake . -DCMAKE_INSTALL_PREFIX=${mariadb_install_dir} \
     -DMYSQL_DATADIR=${mariadb_data_dir} \
     -DSYSCONFDIR=/etc \
@@ -49,14 +49,14 @@ Install_MariaDB55() {
 
   if [ -d "${mariadb_install_dir}/support-files" ]; then
     echo "${CSUCCESS}MariaDB installed successfully! ${CEND}"
-    if [ "${dbInstallMethods}" == "1" ]; then
-      rm -rf mariadb-${mariadb55_version}-*-${SYS_BIT_b}
-    elif [ "${dbInstallMethods}" == "2" ]; then
-      rm -rf mariadb-${mariadb55_version}
+    if [ "${dbinstallmethod}" == "1" ]; then
+      rm -rf mariadb-${mariadb55_ver}-*-${SYS_BIT_b}
+    elif [ "${dbinstallmethod}" == "2" ]; then
+      rm -rf mariadb-${mariadb55_ver}
     fi
   else
     rm -rf ${mariadb_install_dir}
-    rm -rf mariadb-${mariadb55_version}
+    rm -rf mariadb-${mariadb55_ver}
     echo "${CFAILURE}MariaDB install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 16 - 16
include/memcached.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -15,15 +15,15 @@ Install_memcached() {
   id -u memcached >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin memcached
 
-  tar xzf memcached-${memcached_version}.tar.gz
-  pushd memcached-${memcached_version}
+  tar xzf memcached-${memcached_ver}.tar.gz
+  pushd memcached-${memcached_ver}
   [ ! -d "${memcached_install_dir}" ] && mkdir -p ${memcached_install_dir}
   ./configure --prefix=${memcached_install_dir}
   make -j ${THREAD} && make install
   popd
   if [ -d "${memcached_install_dir}/include/memcached" ]; then
     echo "${CSUCCESS}memcached installed successfully! ${CEND}"
-    rm -rf memcached-${memcached_version}
+    rm -rf memcached-${memcached_ver}
     ln -s ${memcached_install_dir}/bin/memcached /usr/bin/memcached
     [ "${OS}" == "CentOS" ] && { /bin/cp ../init.d/Memcached-init-CentOS /etc/init.d/memcached; chkconfig --add memcached; chkconfig memcached on; }
     [[ "${OS}" =~ ^Ubuntu$|^Debian$ ]] && { /bin/cp ../init.d/Memcached-init-Ubuntu /etc/init.d/memcached; update-rc.d memcached defaults; }
@@ -32,7 +32,7 @@ Install_memcached() {
     [ -n "$(grep 'CACHESIZE=' /etc/init.d/memcached)" ] && sed -i "s@^CACHESIZE=.*@CACHESIZE=${memcachedCache}@" /etc/init.d/memcached
     [ -n "$(grep 'start_instance default 256;' /etc/init.d/memcached)" ] && sed -i "s@start_instance default 256;@start_instance default ${memcachedCache};@" /etc/init.d/memcached
     service memcached start
-    rm -rf memcached-${memcached_version}
+    rm -rf memcached-${memcached_ver}
   else
     rm -rf ${memcached_install_dir}
     echo "${CFAILURE}memcached install failed, Please contact the author! ${CEND}"
@@ -52,8 +52,8 @@ Install_php-memcache() {
       tar xzf pecl-memcache-php7.tgz
       pushd pecl-memcache-php7
     else
-      tar xzf memcache-${memcache_pecl_version}.tgz
-      pushd memcache-${memcache_pecl_version}
+      tar xzf memcache-${memcache_pecl_ver}.tgz
+      pushd memcache-${memcache_pecl_ver}
     fi
     ${php_install_dir}/bin/phpize
     ./configure --with-php-config=${php_install_dir}/bin/php-config
@@ -62,7 +62,7 @@ Install_php-memcache() {
     if [ -f "${phpExtensionDir}/memcache.so" ]; then
       echo "extension=memcache.so" > ${php_install_dir}/etc/php.d/ext-memcache.ini
       echo "${CSUCCESS}PHP memcache module installed successfully! ${CEND}"
-      rm -rf pecl-memcache-php7 memcache-${memcache_pecl_version}
+      rm -rf pecl-memcache-php7 memcache-${memcache_pecl_ver}
     else
       echo "${CFAILURE}PHP memcache module install failed, Please contact the author! ${CEND}"
     fi
@@ -75,21 +75,21 @@ Install_php-memcached() {
   if [ -e "${php_install_dir}/bin/phpize" ]; then
     phpExtensionDir=$(${php_install_dir}/bin/php-config --extension-dir)
     # php memcached extension
-    tar xzf libmemcached-${libmemcached_version}.tar.gz
-    pushd libmemcached-${libmemcached_version}
+    tar xzf libmemcached-${libmemcached_ver}.tar.gz
+    pushd libmemcached-${libmemcached_ver}
     [ "${OS}" == "CentOS" ] && yum -y install cyrus-sasl-devel
     [[ "${OS}" =~ ^Ubuntu$|^Debian$ ]] && sed -i "s@lthread -pthread -pthreads@lthread -lpthread -pthreads@" ./configure
     ./configure --with-memcached=${memcached_install_dir}
     make -j ${THREAD} && make install
     popd
-    rm -rf libmemcached-${libmemcached_version}
+    rm -rf libmemcached-${libmemcached_ver}
 
     if [ "$(${php_install_dir}/bin/php -r 'echo PHP_VERSION;' | awk -F. '{print $1}')" == '7' ]; then
-      tar xzf memcached-${memcached_pecl_php7_version}.tgz 
-      pushd memcached-${memcached_pecl_php7_version} 
+      tar xzf memcached-${memcached_pecl_php7_ver}.tgz 
+      pushd memcached-${memcached_pecl_php7_ver} 
     else
-      tar xzf memcached-${memcached_pecl_version}.tgz
-      pushd memcached-${memcached_pecl_version}
+      tar xzf memcached-${memcached_pecl_ver}.tgz
+      pushd memcached-${memcached_pecl_ver}
     fi
     ${php_install_dir}/bin/phpize
     ./configure --with-php-config=${php_install_dir}/bin/php-config
@@ -101,7 +101,7 @@ extension=memcached.so
 memcached.use_sasl=1
 EOF
       echo "${CSUCCESS}PHP memcached module installed successfully! ${CEND}"
-      rm -rf memcached-${memcached_pecl_version} memcached-${memcached_pecl_php7_version}
+      rm -rf memcached-${memcached_pecl_ver} memcached-${memcached_pecl_php7_ver}
     else
       echo "${CFAILURE}PHP memcached module install failed, Please contact the author! ${CEND}"
     fi

+ 1 - 1
include/memory.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 5 - 5
include/mongodb.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -13,8 +13,8 @@ Install_MongoDB() {
   id -u mongod >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -s /sbin/nologin mongod
   mkdir -p ${mongo_data_dir};chown mongod.mongod -R ${mongo_data_dir}
-  tar xzf mongodb-linux-${SYS_BIT_b}-${mongodb_version}.tgz
-  /bin/mv mongodb-linux-${SYS_BIT_b}-${mongodb_version} ${mongo_install_dir}
+  tar xzf mongodb-linux-${SYS_BIT_b}-${mongodb_ver}.tgz
+  /bin/mv mongodb-linux-${SYS_BIT_b}-${mongodb_ver} ${mongo_install_dir}
   [ "${OS}" == "CentOS" ] && { /bin/cp ../init.d/MongoDB-init-CentOS /etc/init.d/mongod; sed -i "s@/usr/local/mongodb@${mongo_install_dir}@g" /etc/init.d/mongod; chkconfig --add mongod; chkconfig mongod on; }
   [[ "${OS}" =~ ^Ubuntu$|^Debian$ ]] && { /bin/cp ../init.d/MongoDB-init-Ubuntu /etc/init.d/mongod; sed -i "s@/usr/local/mongodb@${mongo_install_dir}@g" /etc/init.d/mongod; update-rc.d mongod defaults; }
   cat > /etc/mongod.conf << EOF
@@ -63,9 +63,9 @@ EOF
   sed -i 's@^#  authorization:@  authorization:@' /etc/mongod.conf 
   if [ -e "${mongo_install_dir}/bin/mongo" ]; then
     echo "${CSUCCESS}MongoDB installed successfully! ${CEND}"
-    rm -rf mongodb-linux-${SYS_BIT_b}-${mongodb_version} 
+    rm -rf mongodb-linux-${SYS_BIT_b}-${mongodb_ver} 
   else
-    rm -rf ${mongo_install_dir} ${mongo_data_dir} mongodb-linux-${SYS_BIT_b}-${mongodb_version} 
+    rm -rf ${mongo_install_dir} ${mongo_data_dir} mongodb-linux-${SYS_BIT_b}-${mongodb_ver} 
     echo "${CFAILURE}MongoDB install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 13 - 13
include/mysql-5.5.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,15 +17,15 @@ Install_MySQL55() {
   [ ! -d "${mysql_install_dir}" ] && mkdir -p ${mysql_install_dir}
   mkdir -p ${mysql_data_dir};chown mysql.mysql -R ${mysql_data_dir}
 
-  if [ "${dbInstallMethods}" == "1" ]; then
-    tar xvf mysql-${mysql55_version}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
-    mv mysql-${mysql55_version}-linux-glibc2.12-${SYS_BIT_b}/* ${mysql_install_dir}
+  if [ "${dbinstallmethod}" == "1" ]; then
+    tar xvf mysql-${mysql55_ver}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
+    mv mysql-${mysql55_ver}-linux-glibc2.12-${SYS_BIT_b}/* ${mysql_install_dir}
     sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' ${mysql_install_dir}/bin/mysqld_safe
     sed -i "s@/usr/local/mysql@${mysql_install_dir}@g" ${mysql_install_dir}/bin/mysqld_safe
-  elif [ "${dbInstallMethods}" == "2" ]; then
-    tar xvf mysql-${mysql55_version}.tar.gz
-    pushd mysql-${mysql55_version}
-    [ "${armPlatform}" == "y" ] && patch -p1 < ../mysql-5.5-fix-arm-client_plugin.patch
+  elif [ "${dbinstallmethod}" == "2" ]; then
+    tar xvf mysql-${mysql55_ver}.tar.gz
+    pushd mysql-${mysql55_ver}
+    [ "${armplatform}" == "y" ] && patch -p1 < ../mysql-5.5-fix-arm-client_plugin.patch
     cmake . -DCMAKE_INSTALL_PREFIX=${mysql_install_dir} \
     -DMYSQL_DATADIR=${mysql_data_dir} \
     -DSYSCONFDIR=/etc \
@@ -49,14 +49,14 @@ Install_MySQL55() {
 
   if [ -d "${mysql_install_dir}/support-files" ]; then
     echo "${CSUCCESS}MySQL installed successfully! ${CEND}"
-    if [ "${dbInstallMethods}" == "1" ]; then
-      rm -rf mysql-${mysql55_version}-*-${SYS_BIT_b}
-    elif [ "${dbInstallMethods}" == "2" ]; then
-      rm -rf mysql-${mysql55_version}
+    if [ "${dbinstallmethod}" == "1" ]; then
+      rm -rf mysql-${mysql55_ver}-*-${SYS_BIT_b}
+    elif [ "${dbinstallmethod}" == "2" ]; then
+      rm -rf mysql-${mysql55_ver}
     fi
   else
     rm -rf ${mysql_install_dir}
-    rm -rf mysql-${mysql55_version}
+    rm -rf mysql-${mysql55_ver}
     echo "${CFAILURE}MySQL install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 12 - 12
include/mysql-5.6.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,14 +17,14 @@ Install_MySQL56() {
   [ ! -d "${mysql_install_dir}" ] && mkdir -p ${mysql_install_dir}
   mkdir -p ${mysql_data_dir};chown mysql.mysql -R ${mysql_data_dir}
 
-  if [ "${dbInstallMethods}" == "1" ]; then
-    tar xvf mysql-${mysql56_version}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
-    mv mysql-${mysql56_version}-linux-glibc2.12-${SYS_BIT_b}/* ${mysql_install_dir}
+  if [ "${dbinstallmethod}" == "1" ]; then
+    tar xvf mysql-${mysql56_ver}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
+    mv mysql-${mysql56_ver}-linux-glibc2.12-${SYS_BIT_b}/* ${mysql_install_dir}
     sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' ${mysql_install_dir}/bin/mysqld_safe
     sed -i "s@/usr/local/mysql@${mysql_install_dir}@g" ${mysql_install_dir}/bin/mysqld_safe
-  elif [ "${dbInstallMethods}" == "2" ]; then
-    tar xvf mysql-${mysql56_version}.tar.gz
-    pushd mysql-${mysql56_version}
+  elif [ "${dbinstallmethod}" == "2" ]; then
+    tar xvf mysql-${mysql56_ver}.tar.gz
+    pushd mysql-${mysql56_ver}
     cmake . -DCMAKE_INSTALL_PREFIX=${mysql_install_dir} \
     -DMYSQL_DATADIR=${mysql_data_dir} \
     -DSYSCONFDIR=/etc \
@@ -47,14 +47,14 @@ Install_MySQL56() {
 
   if [ -d "${mysql_install_dir}/support-files" ]; then
     echo "${CSUCCESS}MySQL installed successfully! ${CEND}"
-    if [ "${dbInstallMethods}" == "1" ]; then
-      rm -rf mysql-${mysql56_version}-*-${SYS_BIT_b}
-    elif [ "${dbInstallMethods}" == "2" ]; then
-      rm -rf mysql-${mysql56_version}
+    if [ "${dbinstallmethod}" == "1" ]; then
+      rm -rf mysql-${mysql56_ver}-*-${SYS_BIT_b}
+    elif [ "${dbinstallmethod}" == "2" ]; then
+      rm -rf mysql-${mysql56_ver}
     fi
   else
     rm -rf ${mysql_install_dir}
-    rm -rf mysql-${mysql56_version}
+    rm -rf mysql-${mysql56_ver}
     echo "${CFAILURE}MySQL install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 12 - 12
include/mysql-5.7.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,14 +17,14 @@ Install_MySQL57() {
   [ ! -d "${mysql_install_dir}" ] && mkdir -p ${mysql_install_dir}
   mkdir -p ${mysql_data_dir};chown mysql.mysql -R ${mysql_data_dir}
 
-  if [ "${dbInstallMethods}" == "1" ]; then
-    tar xvf mysql-${mysql57_version}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
-    mv mysql-${mysql57_version}-linux-glibc2.12-${SYS_BIT_b}/* ${mysql_install_dir}
+  if [ "${dbinstallmethod}" == "1" ]; then
+    tar xvf mysql-${mysql57_ver}-linux-glibc2.12-${SYS_BIT_b}.tar.gz
+    mv mysql-${mysql57_ver}-linux-glibc2.12-${SYS_BIT_b}/* ${mysql_install_dir}
     sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' ${mysql_install_dir}/bin/mysqld_safe
     sed -i "s@/usr/local/mysql@${mysql_install_dir}@g" ${mysql_install_dir}/bin/mysqld_safe
-  elif [ "${dbInstallMethods}" == "2" ]; then
-    tar xvf mysql-${mysql57_version}.tar.gz
-    pushd mysql-${mysql57_version}
+  elif [ "${dbinstallmethod}" == "2" ]; then
+    tar xvf mysql-${mysql57_ver}.tar.gz
+    pushd mysql-${mysql57_ver}
     cmake . -DCMAKE_INSTALL_PREFIX=${mysql_install_dir} \
     -DMYSQL_DATADIR=${mysql_data_dir} \
     -DSYSCONFDIR=/etc \
@@ -47,14 +47,14 @@ Install_MySQL57() {
 
   if [ -d "${mysql_install_dir}/support-files" ]; then
     echo "${CSUCCESS}MySQL installed successfully! ${CEND}"
-    if [ "${dbInstallMethods}" == "1" ]; then
-      rm -rf mysql-${mysql57_version}-*-${SYS_BIT_b}
-    elif [ "${dbInstallMethods}" == "2" ]; then
-      rm -rf mysql-${mysql57_version}
+    if [ "${dbinstallmethod}" == "1" ]; then
+      rm -rf mysql-${mysql57_ver}-*-${SYS_BIT_b}
+    elif [ "${dbinstallmethod}" == "2" ]; then
+      rm -rf mysql-${mysql57_ver}
     fi
   else
     rm -rf ${mysql_install_dir}
-    rm -rf mysql-${mysql57_version}
+    rm -rf mysql-${mysql57_ver}
     echo "${CFAILURE}MySQL install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 10 - 10
include/nginx.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -14,10 +14,10 @@ Install_Nginx() {
   id -u $run_user >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
   
-  tar xzf pcre-$pcre_version.tar.gz
-  tar xzf nginx-$nginx_version.tar.gz
-  tar xzf openssl-$openssl_version.tar.gz
-  pushd nginx-$nginx_version
+  tar xzf pcre-$pcre_ver.tar.gz
+  tar xzf nginx-$nginx_ver.tar.gz
+  tar xzf openssl-$openssl_ver.tar.gz
+  pushd nginx-$nginx_ver
   # Modify Nginx version
   #sed -i 's@#define NGINX_VERSION.*$@#define NGINX_VERSION      "1.2"@' src/core/nginx.h
   #sed -i 's@#define NGINX_VER.*NGINX_VERSION$@#define NGINX_VER          "Linuxeye/" NGINX_VERSION@' src/core/nginx.h
@@ -27,11 +27,11 @@ Install_Nginx() {
   sed -i 's@CFLAGS="$CFLAGS -g"@#CFLAGS="$CFLAGS -g"@' auto/cc/gcc
   
   [ ! -d "$nginx_install_dir" ] && mkdir -p $nginx_install_dir
-  ./configure --prefix=$nginx_install_dir --user=$run_user --group=$run_user --with-http_stub_status_module --with-http_v2_module --with-http_ssl_module --with-http_gzip_static_module --with-http_realip_module --with-http_flv_module --with-http_mp4_module --with-openssl=../openssl-$openssl_version --with-pcre=../pcre-$pcre_version --with-pcre-jit --with-ld-opt='-ljemalloc' $nginx_modules_options 
+  ./configure --prefix=$nginx_install_dir --user=$run_user --group=$run_user --with-http_stub_status_module --with-http_v2_module --with-http_ssl_module --with-http_gzip_static_module --with-http_realip_module --with-http_flv_module --with-http_mp4_module --with-openssl=../openssl-$openssl_ver --with-pcre=../pcre-$pcre_ver --with-pcre-jit --with-ld-opt='-ljemalloc' $nginx_modules_options 
   make -j ${THREAD} && make install
   if [ -e "$nginx_install_dir/conf/nginx.conf" ]; then
     popd 
-    rm -rf nginx-$nginx_version
+    rm -rf nginx-$nginx_ver
     echo "${CSUCCESS}Nginx installed successfully! ${CEND}"
   else
     rm -rf $nginx_install_dir
@@ -49,13 +49,13 @@ Install_Nginx() {
   sed -i "s@/usr/local/nginx@$nginx_install_dir@g" /etc/init.d/nginx
   
   mv $nginx_install_dir/conf/nginx.conf{,_bk}
-  if [[ $Apache_version =~ ^[1-2]$ ]]; then
+  if [[ $apache_ver =~ ^[1-2]$ ]]; then
     /bin/cp ../config/nginx_apache.conf $nginx_install_dir/conf/nginx.conf
-  elif [[ $Tomcat_version =~ ^[1-2]$ ]] && [ ! -e "$php_install_dir/bin/php" ]; then
+  elif [[ $tomcat_ver =~ ^[1-2]$ ]] && [ ! -e "$php_install_dir/bin/php" ]; then
     /bin/cp ../config/nginx_tomcat.conf $nginx_install_dir/conf/nginx.conf
   else
     /bin/cp ../config/nginx.conf $nginx_install_dir/conf/nginx.conf
-    [ "$PHP_yn" == 'y' ] && [ -z "`grep '/php-fpm_status' $nginx_install_dir/conf/nginx.conf`" ] &&  sed -i "s@index index.html index.php;@index index.html index.php;\n    location ~ /php-fpm_status {\n        #fastcgi_pass remote_php_ip:9000;\n        fastcgi_pass unix:/dev/shm/php-cgi.sock;\n        fastcgi_index index.php;\n        include fastcgi.conf;\n        allow 127.0.0.1;\n        deny all;\n        }@" $nginx_install_dir/conf/nginx.conf
+    [ "$php_yn" == 'y' ] && [ -z "`grep '/php-fpm_status' $nginx_install_dir/conf/nginx.conf`" ] &&  sed -i "s@index index.html index.php;@index index.html index.php;\n    location ~ /php-fpm_status {\n        #fastcgi_pass remote_php_ip:9000;\n        fastcgi_pass unix:/dev/shm/php-cgi.sock;\n        fastcgi_index index.php;\n        include fastcgi.conf;\n        allow 127.0.0.1;\n        deny all;\n        }@" $nginx_install_dir/conf/nginx.conf
   fi
   cat > $nginx_install_dir/conf/proxy.conf << EOF
 proxy_connect_timeout 300s;

+ 12 - 12
include/openresty.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -14,21 +14,21 @@ Install_OpenResty() {
   id -u $run_user >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
   
-  tar xzf pcre-$pcre_version.tar.gz
-  tar xzf openresty-$openresty_version.tar.gz
-  tar xzf openssl-$openssl_version.tar.gz
-  pushd openresty-$openresty_version
+  tar xzf pcre-$pcre_ver.tar.gz
+  tar xzf openresty-$openresty_ver.tar.gz
+  tar xzf openssl-$openssl_ver.tar.gz
+  pushd openresty-$openresty_ver
   
   # close debug
-  openresty_version_tmp=${openresty_version%.*}
-  sed -i 's@CFLAGS="$CFLAGS -g"@#CFLAGS="$CFLAGS -g"@' bundle/nginx-$openresty_version_tmp/auto/cc/gcc # close debug
+  openresty_ver_tmp=${openresty_ver%.*}
+  sed -i 's@CFLAGS="$CFLAGS -g"@#CFLAGS="$CFLAGS -g"@' bundle/nginx-$openresty_ver_tmp/auto/cc/gcc # close debug
   
   [ ! -d "$openresty_install_dir" ] && mkdir -p $openresty_install_dir
-  ./configure --prefix=$openresty_install_dir --user=$run_user --group=$run_user --with-http_stub_status_module --with-http_v2_module --with-http_ssl_module --with-http_gzip_static_module --with-http_realip_module --with-http_flv_module --with-http_mp4_module --with-openssl=../openssl-$openssl_version --with-pcre=../pcre-$pcre_version --with-pcre-jit --with-ld-opt='-ljemalloc' $nginx_modules_options 
+  ./configure --prefix=$openresty_install_dir --user=$run_user --group=$run_user --with-http_stub_status_module --with-http_v2_module --with-http_ssl_module --with-http_gzip_static_module --with-http_realip_module --with-http_flv_module --with-http_mp4_module --with-openssl=../openssl-$openssl_ver --with-pcre=../pcre-$pcre_ver --with-pcre-jit --with-ld-opt='-ljemalloc' $nginx_modules_options 
   make -j ${THREAD} && make install
   if [ -e "$openresty_install_dir/nginx/conf/nginx.conf" ]; then
     popd
-    rm -rf openresty-$openresty_version
+    rm -rf openresty-$openresty_ver
     echo "${CSUCCESS}OpenResty installed successfully! ${CEND}"
   else
     rm -rf $openresty_install_dir
@@ -46,13 +46,13 @@ Install_OpenResty() {
   sed -i "s@/usr/local/nginx@$openresty_install_dir/nginx@g" /etc/init.d/nginx
   
   mv $openresty_install_dir/nginx/conf/nginx.conf{,_bk}
-  if [[ $Apache_version =~ ^[1-2]$ ]]; then
+  if [[ $apache_ver =~ ^[1-2]$ ]]; then
     /bin/cp ../config/nginx_apache.conf $openresty_install_dir/nginx/conf/nginx.conf
-  elif [[ $Tomcat_version =~ ^[1-2]$ ]] && [ ! -e "$php_install_dir/bin/php" ]; then
+  elif [[ $tomcat_ver =~ ^[1-2]$ ]] && [ ! -e "$php_install_dir/bin/php" ]; then
     /bin/cp ../config/nginx_tomcat.conf $openresty_install_dir/nginx/conf/nginx.conf
   else
     /bin/cp ../config/nginx.conf $openresty_install_dir/nginx/conf/nginx.conf
-    [ "$PHP_yn" == 'y' ] && [ -z "`grep '/php-fpm_status' $openresty_install_dir/nginx/conf/nginx.conf`" ] &&  sed -i "s@index index.html index.php;@index index.html index.php;\n    location ~ /php-fpm_status {\n        #fastcgi_pass remote_php_ip:9000;\n        fastcgi_pass unix:/dev/shm/php-cgi.sock;\n        fastcgi_index index.php;\n        include fastcgi.conf;\n        allow 127.0.0.1;\n        deny all;\n        }@" $openresty_install_dir/nginx/conf/nginx.conf
+    [ "$php_yn" == 'y' ] && [ -z "`grep '/php-fpm_status' $openresty_install_dir/nginx/conf/nginx.conf`" ] &&  sed -i "s@index index.html index.php;@index index.html index.php;\n    location ~ /php-fpm_status {\n        #fastcgi_pass remote_php_ip:9000;\n        fastcgi_pass unix:/dev/shm/php-cgi.sock;\n        fastcgi_index index.php;\n        include fastcgi.conf;\n        allow 127.0.0.1;\n        deny all;\n        }@" $openresty_install_dir/nginx/conf/nginx.conf
   fi
   cat > $openresty_install_dir/nginx/conf/proxy.conf << EOF
 proxy_connect_timeout 300s;

+ 4 - 4
include/openssl.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -12,8 +12,8 @@ Install_openSSL102() {
   if [ ! -e "${openssl_install_dir}/lib/libcrypto.a" ]; then
     # install openssl-1.0.2
     pushd ${oneinstack_dir}/src
-    tar xzf openssl-${openssl_version}.tar.gz
-    pushd openssl-${openssl_version}
+    tar xzf openssl-${openssl_ver}.tar.gz
+    pushd openssl-${openssl_ver}
     make clean
     ./config --prefix=${openssl_install_dir} -fPIC shared zlib-dynamic
     make -j ${THREAD} && make install
@@ -26,7 +26,7 @@ Install_openSSL102() {
       /bin/cp cacert.pem ${openssl_install_dir}/ssl/cert.pem
       echo "${openssl_install_dir}/lib" > /etc/ld.so.conf.d/openssl.conf
       ldconfig
-      rm -rf openssl-${openssl_version}
+      rm -rf openssl-${openssl_ver}
     else
       echo "${CFAILURE}openssl-1.0.2 install failed, Please contact the author! ${CEND}"
       kill -9 $$

+ 7 - 7
include/pecl_mongodb.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -13,29 +13,29 @@ Install_pecl-mongodb() {
   if [ -e "${php_install_dir}/bin/phpize" ]; then
     phpExtensionDir=$(${php_install_dir}/bin/php-config --extension-dir)
     if [[ "$(${php_install_dir}/bin/php -r 'echo PHP_VERSION;' | awk -F. '{print $1$2}')" =~ ^5[3-4]$ ]]; then
-      tar xzf mongo-${mongo_pecl_version}.tgz 
-      pushd mongo-${mongo_pecl_version} 
+      tar xzf mongo-${mongo_pecl_ver}.tgz 
+      pushd mongo-${mongo_pecl_ver} 
       ${php_install_dir}/bin/phpize
       ./configure --with-php-config=${php_install_dir}/bin/php-config
       make -j ${THREAD} && make install
       popd
       if [ -f "${phpExtensionDir}/mongo.so" ]; then
         echo 'extension=mongo.so' > ${php_install_dir}/etc/php.d/ext-mongo.ini
-        rm -rf mongo-${mongo_pecl_version}
+        rm -rf mongo-${mongo_pecl_ver}
         echo "${CSUCCESS}PHP mongo module installed successfully! ${CEND}"
       else
         echo "${CFAILURE}PHP mongo module install failed, Please contact the author! ${CEND}"
       fi
     else
-      tar xzf mongodb-${mongodb_pecl_version}.tgz 
-      pushd mongodb-${mongodb_pecl_version} 
+      tar xzf mongodb-${mongodb_pecl_ver}.tgz 
+      pushd mongodb-${mongodb_pecl_ver} 
       ${php_install_dir}/bin/phpize
       ./configure --with-php-config=${php_install_dir}/bin/php-config
       make -j ${THREAD} && make install
       popd
       if [ -f "${phpExtensionDir}/mongodb.so" ]; then
         echo 'extension=mongodb.so' > ${php_install_dir}/etc/php.d/ext-mongodb.ini
-        rm -rf mongodb-${mongodb_pecl_version}
+        rm -rf mongodb-${mongodb_pecl_ver}
         echo "${CSUCCESS}PHP mongodb module installed successfully! ${CEND}"
       else
         echo "${CFAILURE}PHP mongodb module install failed, Please contact the author! ${CEND}"

+ 1 - 1
include/pecl_pgsql.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 11 - 11
include/percona-5.5.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,16 +17,16 @@ Install_Percona55() {
   [ ! -d "${percona_install_dir}" ] && mkdir -p ${percona_install_dir}
   mkdir -p ${percona_data_dir};chown mysql.mysql -R ${percona_data_dir}
 
-  if [ "${dbInstallMethods}" == "1" ]; then
-    perconaVerStr1=$(echo ${percona55_version} | sed "s@-@-rel@")
+  if [ "${dbinstallmethod}" == "1" ]; then
+    perconaVerStr1=$(echo ${percona55_ver} | sed "s@-@-rel@")
     tar xvf Percona-Server-${perconaVerStr1}-Linux.${SYS_BIT_b}.${sslLibVer}.tar.gz
     mv Percona-Server-${perconaVerStr1}-Linux.${SYS_BIT_b}.${sslLibVer}/* ${percona_install_dir}
     sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' ${percona_install_dir}/bin/mysqld_safe
     sed -i "s@/usr/local/Percona-Server-${perconaVerStr1}-Linux.${SYS_BIT_b}.${sslLibVer}@${percona_install_dir}@g" ${percona_install_dir}/bin/mysqld_safe 
-  elif [ "${dbInstallMethods}" == "2" ]; then
-    tar xvf percona-server-${percona55_version}.tar.gz
-    pushd percona-server-${percona55_version}
-    [ "${armPlatform}" == "y" ] && patch -p1 < ../mysql-5.5-fix-arm-client_plugin.patch
+  elif [ "${dbinstallmethod}" == "2" ]; then
+    tar xvf percona-server-${percona55_ver}.tar.gz
+    pushd percona-server-${percona55_ver}
+    [ "${armplatform}" == "y" ] && patch -p1 < ../mysql-5.5-fix-arm-client_plugin.patch
     cmake . -DCMAKE_INSTALL_PREFIX=${percona_install_dir} \
     -DMYSQL_DATADIR=${percona_data_dir} \
     -DSYSCONFDIR=/etc \
@@ -50,14 +50,14 @@ Install_Percona55() {
 
   if [ -d "${percona_install_dir}/support-files" ]; then
     echo "${CSUCCESS}Percona installed successfully! ${CEND}"
-    if [ "${dbInstallMethods}" == "1" ]; then
+    if [ "${dbinstallmethod}" == "1" ]; then
       rm -rf Percona-Server-${perconaVerStr1}-Linux.${SYS_BIT_b}.${sslLibVer}
-    elif [ "${dbInstallMethods}" == "2" ]; then
-    rm -rf percona-server-${percona55_version}
+    elif [ "${dbinstallmethod}" == "2" ]; then
+    rm -rf percona-server-${percona55_ver}
     fi
   else
     rm -rf ${percona_install_dir}
-    rm -rf percona-server-${percona55_version}
+    rm -rf percona-server-${percona55_ver}
     echo "${CFAILURE}Percona install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 10 - 10
include/percona-5.6.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,15 +17,15 @@ Install_Percona56() {
   [ ! -d "${percona_install_dir}" ] && mkdir -p ${percona_install_dir}
   mkdir -p ${percona_data_dir};chown mysql.mysql -R ${percona_data_dir}
 
-  if [ "${dbInstallMethods}" == "1" ]; then
-    perconaVerStr1=$(echo ${percona56_version} | sed "s@-@-rel@")
+  if [ "${dbinstallmethod}" == "1" ]; then
+    perconaVerStr1=$(echo ${percona56_ver} | sed "s@-@-rel@")
     tar xvf Percona-Server-${perconaVerStr1}-Linux.${SYS_BIT_b}.${sslLibVer}.tar.gz
     mv Percona-Server-${perconaVerStr1}-Linux.${SYS_BIT_b}.${sslLibVer}/* ${percona_install_dir}
     sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' ${percona_install_dir}/bin/mysqld_safe
     sed -i "s@/usr/local/Percona-Server-${perconaVerStr1}-Linux.${SYS_BIT_b}.${sslLibVer}@${percona_install_dir}@g" ${percona_install_dir}/bin/mysqld_safe 
-  elif [ "${dbInstallMethods}" == "2" ]; then
-    tar xvf percona-server-${percona56_version}.tar.gz
-    pushd percona-server-${percona56_version}
+  elif [ "${dbinstallmethod}" == "2" ]; then
+    tar xvf percona-server-${percona56_ver}.tar.gz
+    pushd percona-server-${percona56_ver}
     cmake . -DCMAKE_INSTALL_PREFIX=${percona_install_dir} \
     -DMYSQL_DATADIR=${percona_data_dir} \
     -DSYSCONFDIR=/etc \
@@ -49,14 +49,14 @@ Install_Percona56() {
 
   if [ -d "${percona_install_dir}/support-files" ]; then
     echo "${CSUCCESS}Percona installed successfully! ${CEND}"
-    if [ "${dbInstallMethods}" == "1" ]; then
+    if [ "${dbinstallmethod}" == "1" ]; then
       rm -rf Percona-Server-${perconaVerStr1}-Linux.${SYS_BIT_b}.${sslLibVer}
-    elif [ "${dbInstallMethods}" == "2" ]; then
-      rm -rf percona-server-${percona56_version}
+    elif [ "${dbinstallmethod}" == "2" ]; then
+      rm -rf percona-server-${percona56_ver}
     fi
   else
     rm -rf ${percona_install_dir}
-    rm -rf percona-server-${percona56_version}
+    rm -rf percona-server-${percona56_ver}
     echo "${CFAILURE}Percona install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 13 - 13
include/percona-5.7.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,14 +17,14 @@ Install_Percona57() {
   [ ! -d "${percona_install_dir}" ] && mkdir -p ${percona_install_dir}
   mkdir -p ${percona_data_dir};chown mysql.mysql -R ${percona_data_dir}
 
-  if [ "${dbInstallMethods}" == "1" ]; then
-    tar xvf Percona-Server-${percona57_version}-Linux.${SYS_BIT_b}.${sslLibVer}.tar.gz
-    mv Percona-Server-${percona57_version}-Linux.${SYS_BIT_b}.${sslLibVer}/* ${percona_install_dir}
+  if [ "${dbinstallmethod}" == "1" ]; then
+    tar xvf Percona-Server-${percona57_ver}-Linux.${SYS_BIT_b}.${sslLibVer}.tar.gz
+    mv Percona-Server-${percona57_ver}-Linux.${SYS_BIT_b}.${sslLibVer}/* ${percona_install_dir}
     sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' ${percona_install_dir}/bin/mysqld_safe
-    sed -i "s@/usr/local/Percona-Server-${percona57_version}-Linux.${SYS_BIT_b}.${sslLibVer}@${percona_install_dir}@g" ${percona_install_dir}/bin/mysqld_safe 
-  elif [ "${dbInstallMethods}" == "2" ]; then
-    tar xvf percona-server-${percona57_version}.tar.gz
-    pushd percona-server-${percona57_version}
+    sed -i "s@/usr/local/Percona-Server-${percona57_ver}-Linux.${SYS_BIT_b}.${sslLibVer}@${percona_install_dir}@g" ${percona_install_dir}/bin/mysqld_safe 
+  elif [ "${dbinstallmethod}" == "2" ]; then
+    tar xvf percona-server-${percona57_ver}.tar.gz
+    pushd percona-server-${percona57_ver}
     cmake . -DCMAKE_INSTALL_PREFIX=${percona_install_dir} \
     -DMYSQL_DATADIR=${percona_data_dir} \
     -DSYSCONFDIR=/etc \
@@ -49,14 +49,14 @@ Install_Percona57() {
 
   if [ -d "${percona_install_dir}/support-files" ]; then
     echo "${CSUCCESS}Percona installed successfully! ${CEND}"
-    if [ "${dbInstallMethods}" == "1" ]; then
-      rm -rf Percona-Server-${percona57_version}-Linux.${SYS_BIT_b}.${sslLibVer}
-    elif [ "${dbInstallMethods}" == "2" ]; then
-      rm -rf percona-server-${percona57_version}
+    if [ "${dbinstallmethod}" == "1" ]; then
+      rm -rf Percona-Server-${percona57_ver}-Linux.${SYS_BIT_b}.${sslLibVer}
+    elif [ "${dbinstallmethod}" == "2" ]; then
+      rm -rf percona-server-${percona57_ver}
     fi
   else
     rm -rf ${percona_install_dir}
-    rm -rf percona-server-${percona57_version}
+    rm -rf percona-server-${percona57_ver}
     echo "${CFAILURE}Percona install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 25 - 25
include/php-5.3.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,23 +11,23 @@
 Install_PHP53() {
   pushd ${oneinstack_dir}/src
   
-  tar xzf libiconv-$libiconv_version.tar.gz
-  patch -d libiconv-$libiconv_version -p0 < libiconv-glibc-2.16.patch
-  pushd libiconv-$libiconv_version
+  tar xzf libiconv-$libiconv_ver.tar.gz
+  patch -d libiconv-$libiconv_ver -p0 < libiconv-glibc-2.16.patch
+  pushd libiconv-$libiconv_ver
   ./configure --prefix=/usr/local
   make -j ${THREAD} && make install
   popd
-  rm -rf libiconv-$libiconv_version
+  rm -rf libiconv-$libiconv_ver
   
-  tar xzf curl-$curl_version.tar.gz
-  pushd curl-$curl_version
+  tar xzf curl-$curl_ver.tar.gz
+  pushd curl-$curl_ver
   ./configure --prefix=/usr/local --with-ssl=${openssl_install_dir}
   make -j ${THREAD} && make install
   popd
-  rm -rf curl-$curl_version
+  rm -rf curl-$curl_ver
 
-  tar xzf libmcrypt-$libmcrypt_version.tar.gz
-  pushd libmcrypt-$libmcrypt_version
+  tar xzf libmcrypt-$libmcrypt_ver.tar.gz
+  pushd libmcrypt-$libmcrypt_ver
   ./configure
   make -j ${THREAD} && make install
   ldconfig
@@ -35,14 +35,14 @@ Install_PHP53() {
   ./configure --enable-ltdl-install
   make -j ${THREAD} && make install
   popd;popd 
-  rm -rf libmcrypt-$libmcrypt_version
+  rm -rf libmcrypt-$libmcrypt_ver
   
-  tar xzf mhash-$mhash_version.tar.gz
-  pushd mhash-$mhash_version
+  tar xzf mhash-$mhash_ver.tar.gz
+  pushd mhash-$mhash_ver
   ./configure
   make -j ${THREAD} && make install
   popd 
-  rm -rf mhash-$mhash_version
+  rm -rf mhash-$mhash_ver
   
   echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf
   ldconfig
@@ -50,25 +50,25 @@ Install_PHP53() {
   
   [ ! -e '/usr/include/freetype2/freetype' ] &&  ln -s /usr/include/freetype2 /usr/include/freetype2/freetype
   
-  tar xzf mcrypt-$mcrypt_version.tar.gz
-  pushd mcrypt-$mcrypt_version
+  tar xzf mcrypt-$mcrypt_ver.tar.gz
+  pushd mcrypt-$mcrypt_ver
   ldconfig
   ./configure
   make -j ${THREAD} && make install
   popd 
-  rm -rf mcrypt-$mcrypt_version
+  rm -rf mcrypt-$mcrypt_ver
   
   id -u $run_user >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
   
-  tar xzf php-$php53_version.tar.gz
-  patch -d php-$php53_version -p0 < fpm-race-condition.patch
-  pushd php-$php53_version
+  tar xzf php-$php53_ver.tar.gz
+  patch -d php-$php53_ver -p0 < fpm-race-condition.patch
+  pushd php-$php53_ver
   patch -p1 < ../php5.3patch
   patch -p1 < ../debian_patches_disable_SSLv2_for_openssl_1_0_0.patch
   make clean
   [ ! -d "$php_install_dir" ] && mkdir -p $php_install_dir
-  if [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  if [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
     --with-apxs2=$apache_install_dir/bin/apxs --disable-fileinfo \
@@ -126,7 +126,7 @@ Install_PHP53() {
   sed -i 's@^disable_functions.*@disable_functions = passthru,exec,system,chroot,chgrp,chown,shell_exec,proc_open,proc_get_status,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,stream_socket_server,fsocket,popen@' $php_install_dir/etc/php.ini
   [ -e /usr/sbin/sendmail ] && sed -i 's@^;sendmail_path.*@sendmail_path = /usr/sbin/sendmail -t -i@' $php_install_dir/etc/php.ini
   
-  if [[ ! $Apache_version =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
+  if [[ ! $apache_ver =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
     # php-fpm Init Script
     /bin/cp sapi/fpm/init.d.php-fpm /etc/init.d/php-fpm
     chmod +x /etc/init.d/php-fpm
@@ -218,13 +218,13 @@ EOF
       sed -i "s@^pm.max_spare_servers.*@pm.max_spare_servers = 80@" $php_install_dir/etc/php-fpm.conf
     fi
 
-    #[ "$Web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
+    #[ "$web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
     service php-fpm start
 
-  elif [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  elif [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     service httpd restart
   fi
   popd
-  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php53_version
+  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php53_ver
   popd
 }

+ 25 - 25
include/php-5.4.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,23 +11,23 @@
 Install_PHP54() {
   pushd ${oneinstack_dir}/src
   
-  tar xzf libiconv-$libiconv_version.tar.gz
-  patch -d libiconv-$libiconv_version -p0 < libiconv-glibc-2.16.patch
-  pushd libiconv-$libiconv_version
+  tar xzf libiconv-$libiconv_ver.tar.gz
+  patch -d libiconv-$libiconv_ver -p0 < libiconv-glibc-2.16.patch
+  pushd libiconv-$libiconv_ver
   ./configure --prefix=/usr/local
   make -j ${THREAD} && make install
   popd
-  rm -rf libiconv-$libiconv_version
+  rm -rf libiconv-$libiconv_ver
   
-  tar xzf curl-$curl_version.tar.gz
-  pushd curl-$curl_version
+  tar xzf curl-$curl_ver.tar.gz
+  pushd curl-$curl_ver
   ./configure --prefix=/usr/local --with-ssl=${openssl_install_dir}
   make -j ${THREAD} && make install
   popd
-  rm -rf curl-$curl_version
+  rm -rf curl-$curl_ver
   
-  tar xzf libmcrypt-$libmcrypt_version.tar.gz
-  pushd libmcrypt-$libmcrypt_version
+  tar xzf libmcrypt-$libmcrypt_ver.tar.gz
+  pushd libmcrypt-$libmcrypt_ver
   ./configure
   make -j ${THREAD} && make install
   ldconfig
@@ -35,36 +35,36 @@ Install_PHP54() {
   ./configure --enable-ltdl-install
   make -j ${THREAD} && make install
   popd;popd
-  rm -rf libmcrypt-$libmcrypt_version
+  rm -rf libmcrypt-$libmcrypt_ver
   
-  tar xzf mhash-$mhash_version.tar.gz
-  pushd mhash-$mhash_version
+  tar xzf mhash-$mhash_ver.tar.gz
+  pushd mhash-$mhash_ver
   ./configure
   make -j ${THREAD} && make install
   popd 
-  rm -rf mhash-$mhash_version
+  rm -rf mhash-$mhash_ver
   
   echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf
   ldconfig
   [ "$OS" == 'CentOS' ] && { ln -s /usr/local/bin/libmcrypt-config /usr/bin/libmcrypt-config; [ "$OS_BIT" == '64' ] && ln -s /lib64/libpcre.so.0.0.1 /lib64/libpcre.so.1 || ln -s /lib/libpcre.so.0.0.1 /lib/libpcre.so.1; }
   
-  tar xzf mcrypt-$mcrypt_version.tar.gz
-  pushd mcrypt-$mcrypt_version
+  tar xzf mcrypt-$mcrypt_ver.tar.gz
+  pushd mcrypt-$mcrypt_ver
   ldconfig
   ./configure
   make -j ${THREAD} && make install
   popd
-  rm -rf mcrypt-$mcrypt_version
+  rm -rf mcrypt-$mcrypt_ver
   
   id -u $run_user >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
   
-  tar xzf php-$php54_version.tar.gz
-  patch -d php-$php54_version -p0 < fpm-race-condition.patch
-  pushd php-$php54_version
+  tar xzf php-$php54_ver.tar.gz
+  patch -d php-$php54_ver -p0 < fpm-race-condition.patch
+  pushd php-$php54_ver
   make clean
   [ ! -d "$php_install_dir" ] && mkdir -p $php_install_dir
-  if [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  if [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
     --with-apxs2=$apache_install_dir/bin/apxs --disable-fileinfo \
@@ -121,7 +121,7 @@ Install_PHP54() {
   sed -i 's@^disable_functions.*@disable_functions = passthru,exec,system,chroot,chgrp,chown,shell_exec,proc_open,proc_get_status,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,stream_socket_server,fsocket,popen@' $php_install_dir/etc/php.ini
   [ -e /usr/sbin/sendmail ] && sed -i 's@^;sendmail_path.*@sendmail_path = /usr/sbin/sendmail -t -i@' $php_install_dir/etc/php.ini
   
-  if [[ ! $Apache_version =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
+  if [[ ! $apache_ver =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
     # php-fpm Init Script
     /bin/cp sapi/fpm/init.d.php-fpm /etc/init.d/php-fpm
     chmod +x /etc/init.d/php-fpm
@@ -213,13 +213,13 @@ EOF
       sed -i "s@^pm.max_spare_servers.*@pm.max_spare_servers = 80@" $php_install_dir/etc/php-fpm.conf
     fi
 
-    #[ "$Web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
+    #[ "$web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
     service php-fpm start
 
-  elif [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  elif [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     service httpd restart
   fi
   popd
-  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php54_version
+  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php54_ver
   popd
 }

+ 29 - 29
include/php-5.5.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,23 +11,23 @@
 Install_PHP55() {
   pushd ${oneinstack_dir}/src
   
-  tar xzf libiconv-$libiconv_version.tar.gz
-  patch -d libiconv-$libiconv_version -p0 < libiconv-glibc-2.16.patch
-  pushd libiconv-$libiconv_version
+  tar xzf libiconv-$libiconv_ver.tar.gz
+  patch -d libiconv-$libiconv_ver -p0 < libiconv-glibc-2.16.patch
+  pushd libiconv-$libiconv_ver
   ./configure --prefix=/usr/local
   make -j ${THREAD} && make install
   popd
-  rm -rf libiconv-$libiconv_version
+  rm -rf libiconv-$libiconv_ver
   
-  tar xzf curl-$curl_version.tar.gz
-  pushd curl-$curl_version
+  tar xzf curl-$curl_ver.tar.gz
+  pushd curl-$curl_ver
   ./configure --prefix=/usr/local --with-ssl=${openssl_install_dir}
   make -j ${THREAD} && make install
   popd
-  rm -rf curl-$curl_version
+  rm -rf curl-$curl_ver
   
-  tar xzf libmcrypt-$libmcrypt_version.tar.gz
-  pushd libmcrypt-$libmcrypt_version
+  tar xzf libmcrypt-$libmcrypt_ver.tar.gz
+  pushd libmcrypt-$libmcrypt_ver
   ./configure
   make -j ${THREAD} && make install
   ldconfig
@@ -35,38 +35,38 @@ Install_PHP55() {
   ./configure --enable-ltdl-install
   make -j ${THREAD} && make install
   popd;popd
-  rm -rf libmcrypt-$libmcrypt_version
+  rm -rf libmcrypt-$libmcrypt_ver
   
-  tar xzf mhash-$mhash_version.tar.gz
-  pushd mhash-$mhash_version
+  tar xzf mhash-$mhash_ver.tar.gz
+  pushd mhash-$mhash_ver
   ./configure
   make -j ${THREAD} && make install
   popd
-  rm -rf mhash-$mhash_version
+  rm -rf mhash-$mhash_ver
   
   echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf
   ldconfig
   [ "$OS" == 'CentOS' ] && { ln -s /usr/local/bin/libmcrypt-config /usr/bin/libmcrypt-config; [ "$OS_BIT" == '64' ] && ln -s /lib64/libpcre.so.0.0.1 /lib64/libpcre.so.1 || ln -s /lib/libpcre.so.0.0.1 /lib/libpcre.so.1; }
   
-  tar xzf mcrypt-$mcrypt_version.tar.gz
-  pushd mcrypt-$mcrypt_version
+  tar xzf mcrypt-$mcrypt_ver.tar.gz
+  pushd mcrypt-$mcrypt_ver
   ldconfig
   ./configure
   make -j ${THREAD} && make install
   popd
-  rm -rf mcrypt-$mcrypt_version
+  rm -rf mcrypt-$mcrypt_ver
   
   id -u $run_user >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
-  tar xzf php-$php55_version.tar.gz
-  patch -d php-$php55_version -p0 < fpm-race-condition.patch
-  pushd php-$php55_version
+  tar xzf php-$php55_ver.tar.gz
+  patch -d php-$php55_ver -p0 < fpm-race-condition.patch
+  pushd php-$php55_ver
   [ ! -d "$php_install_dir" ] && mkdir -p $php_install_dir
-  [ "$PHP_cache" == '1' ] && PHP_cache_tmp='--enable-opcache' || PHP_cache_tmp='--disable-opcache'
-  if [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  [ "$php_cache" == '1' ] && php_cache_tmp='--enable-opcache' || php_cache_tmp='--disable-opcache'
+  if [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
-    --with-apxs2=$apache_install_dir/bin/apxs $PHP_cache_tmp --disable-fileinfo \
+    --with-apxs2=$apache_install_dir/bin/apxs $php_cache_tmp --disable-fileinfo \
     --with-mysql=mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd \
     --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib \
     --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-exif \
@@ -77,7 +77,7 @@ Install_PHP55() {
   else
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
-    --with-fpm-user=$run_user --with-fpm-group=$run_user --enable-fpm $PHP_cache_tmp --disable-fileinfo \
+    --with-fpm-user=$run_user --with-fpm-group=$run_user --enable-fpm $php_cache_tmp --disable-fileinfo \
     --with-mysql=mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd \
     --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib \
     --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-exif \
@@ -120,7 +120,7 @@ Install_PHP55() {
   sed -i 's@^disable_functions.*@disable_functions = passthru,exec,system,chroot,chgrp,chown,shell_exec,proc_open,proc_get_status,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,stream_socket_server,fsocket,popen@' $php_install_dir/etc/php.ini
   [ -e /usr/sbin/sendmail ] && sed -i 's@^;sendmail_path.*@sendmail_path = /usr/sbin/sendmail -t -i@' $php_install_dir/etc/php.ini
   
-  [ "$PHP_cache" == '1' ] && cat > $php_install_dir/etc/php.d/ext-opcache.ini << EOF
+  [ "$php_cache" == '1' ] && cat > $php_install_dir/etc/php.d/ext-opcache.ini << EOF
 [opcache]
 zend_extension=opcache.so
 opcache.enable=1
@@ -134,7 +134,7 @@ opcache.enable_cli=1
 ;opcache.optimization_level=0
 EOF
 
-  if [[ ! $Apache_version =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
+  if [[ ! $apache_ver =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
     # php-fpm Init Script
     /bin/cp sapi/fpm/init.d.php-fpm /etc/init.d/php-fpm
     chmod +x /etc/init.d/php-fpm
@@ -226,13 +226,13 @@ EOF
       sed -i "s@^pm.max_spare_servers.*@pm.max_spare_servers = 80@" $php_install_dir/etc/php-fpm.conf
     fi
 
-    #[ "$Web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
+    #[ "$web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
     service php-fpm start
 
-  elif [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  elif [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     service httpd restart
   fi
   popd
-  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php55_version
+  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php55_ver
   popd
 }

+ 28 - 28
include/php-5.6.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,23 +11,23 @@
 Install_PHP56() {
   pushd ${oneinstack_dir}/src
   
-  tar xzf libiconv-$libiconv_version.tar.gz
-  patch -d libiconv-$libiconv_version -p0 < libiconv-glibc-2.16.patch
-  pushd libiconv-$libiconv_version
+  tar xzf libiconv-$libiconv_ver.tar.gz
+  patch -d libiconv-$libiconv_ver -p0 < libiconv-glibc-2.16.patch
+  pushd libiconv-$libiconv_ver
   ./configure --prefix=/usr/local
   make -j ${THREAD} && make install
   popd
-  rm -rf libiconv-$libiconv_version
+  rm -rf libiconv-$libiconv_ver
   
-  tar xzf curl-$curl_version.tar.gz
-  pushd curl-$curl_version
+  tar xzf curl-$curl_ver.tar.gz
+  pushd curl-$curl_ver
   ./configure --prefix=/usr/local --with-ssl=${openssl_install_dir}
   make -j ${THREAD} && make install
   popd
-  rm -rf curl-$curl_version
+  rm -rf curl-$curl_ver
   
-  tar xzf libmcrypt-$libmcrypt_version.tar.gz
-  pushd libmcrypt-$libmcrypt_version
+  tar xzf libmcrypt-$libmcrypt_ver.tar.gz
+  pushd libmcrypt-$libmcrypt_ver
   ./configure
   make -j ${THREAD} && make install
   ldconfig
@@ -35,39 +35,39 @@ Install_PHP56() {
   ./configure --enable-ltdl-install
   make -j ${THREAD} && make install
   popd;popd
-  rm -rf libmcrypt-$libmcrypt_version
+  rm -rf libmcrypt-$libmcrypt_ver
   
-  tar xzf mhash-$mhash_version.tar.gz
-  pushd mhash-$mhash_version
+  tar xzf mhash-$mhash_ver.tar.gz
+  pushd mhash-$mhash_ver
   ./configure
   make -j ${THREAD} && make install
   popd
-  rm -rf mhash-$mhash_version
+  rm -rf mhash-$mhash_ver
   
   echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf
   ldconfig
   [ "$OS" == 'CentOS' ] && { ln -s /usr/local/bin/libmcrypt-config /usr/bin/libmcrypt-config; [ "$OS_BIT" == '64' ] && ln -s /lib64/libpcre.so.0.0.1 /lib64/libpcre.so.1 || ln -s /lib/libpcre.so.0.0.1 /lib/libpcre.so.1; }
   
-  tar xzf mcrypt-$mcrypt_version.tar.gz
-  pushd mcrypt-$mcrypt_version
+  tar xzf mcrypt-$mcrypt_ver.tar.gz
+  pushd mcrypt-$mcrypt_ver
   ldconfig
   ./configure
   make -j ${THREAD} && make install
   popd
-  rm -rf mcrypt-$mcrypt_version
+  rm -rf mcrypt-$mcrypt_ver
   
   id -u $run_user >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
   
-  tar xzf php-$php56_version.tar.gz
-  pushd php-$php56_version
+  tar xzf php-$php56_ver.tar.gz
+  pushd php-$php56_ver
   make clean
   [ ! -d "$php_install_dir" ] && mkdir -p $php_install_dir
-  [ "$PHP_cache" == '1' ] && PHP_cache_tmp='--enable-opcache' || PHP_cache_tmp='--disable-opcache'
-  if [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  [ "$php_cache" == '1' ] && php_cache_tmp='--enable-opcache' || php_cache_tmp='--disable-opcache'
+  if [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
-    --with-apxs2=$apache_install_dir/bin/apxs $PHP_cache_tmp --disable-fileinfo \
+    --with-apxs2=$apache_install_dir/bin/apxs $php_cache_tmp --disable-fileinfo \
     --with-mysql=mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd \
     --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib \
     --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-exif \
@@ -78,7 +78,7 @@ Install_PHP56() {
   else
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
-    --with-fpm-user=$run_user --with-fpm-group=$run_user --enable-fpm $PHP_cache_tmp --disable-fileinfo \
+    --with-fpm-user=$run_user --with-fpm-group=$run_user --enable-fpm $php_cache_tmp --disable-fileinfo \
     --with-mysql=mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd \
     --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib \
     --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-exif \
@@ -121,7 +121,7 @@ Install_PHP56() {
   sed -i 's@^disable_functions.*@disable_functions = passthru,exec,system,chroot,chgrp,chown,shell_exec,proc_open,proc_get_status,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,stream_socket_server,fsocket,popen@' $php_install_dir/etc/php.ini
   [ -e /usr/sbin/sendmail ] && sed -i 's@^;sendmail_path.*@sendmail_path = /usr/sbin/sendmail -t -i@' $php_install_dir/etc/php.ini
   
-  [ "$PHP_cache" == '1' ] && cat > $php_install_dir/etc/php.d/ext-opcache.ini << EOF
+  [ "$php_cache" == '1' ] && cat > $php_install_dir/etc/php.d/ext-opcache.ini << EOF
 [opcache]
 zend_extension=opcache.so
 opcache.enable=1
@@ -135,7 +135,7 @@ opcache.enable_cli=1
 ;opcache.optimization_level=0
 EOF
 
-  if [[ ! $Apache_version =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
+  if [[ ! $apache_ver =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
     # php-fpm Init Script
     /bin/cp sapi/fpm/init.d.php-fpm /etc/init.d/php-fpm
     chmod +x /etc/init.d/php-fpm
@@ -227,13 +227,13 @@ EOF
       sed -i "s@^pm.max_spare_servers.*@pm.max_spare_servers = 80@" $php_install_dir/etc/php-fpm.conf
     fi
 
-    #[ "$Web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
+    #[ "$web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
     service php-fpm start
 
-  elif [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  elif [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     service httpd restart
   fi
   popd
-  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php56_version
+  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php56_ver
   popd
 }

+ 28 - 28
include/php-7.0.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,23 +11,23 @@
 Install_PHP70() {
   pushd ${oneinstack_dir}/src
   
-  tar xzf libiconv-$libiconv_version.tar.gz
-  patch -d libiconv-$libiconv_version -p0 < libiconv-glibc-2.16.patch
-  pushd libiconv-$libiconv_version
+  tar xzf libiconv-$libiconv_ver.tar.gz
+  patch -d libiconv-$libiconv_ver -p0 < libiconv-glibc-2.16.patch
+  pushd libiconv-$libiconv_ver
   ./configure --prefix=/usr/local
   make -j ${THREAD} && make install
   popd
-  rm -rf libiconv-$libiconv_version
+  rm -rf libiconv-$libiconv_ver
   
-  tar xzf curl-$curl_version.tar.gz
-  pushd curl-$curl_version
+  tar xzf curl-$curl_ver.tar.gz
+  pushd curl-$curl_ver
   ./configure --prefix=/usr/local --with-ssl=${openssl_install_dir}
   make -j ${THREAD} && make install
   popd
-  rm -rf curl-$curl_version
+  rm -rf curl-$curl_ver
   
-  tar xzf libmcrypt-$libmcrypt_version.tar.gz
-  pushd libmcrypt-$libmcrypt_version
+  tar xzf libmcrypt-$libmcrypt_ver.tar.gz
+  pushd libmcrypt-$libmcrypt_ver
   ./configure
   make -j ${THREAD} && make install
   ldconfig
@@ -35,40 +35,40 @@ Install_PHP70() {
   ./configure --enable-ltdl-install
   make -j ${THREAD} && make install
   popd;popd
-  rm -rf libmcrypt-$libmcrypt_version
+  rm -rf libmcrypt-$libmcrypt_ver
   
-  tar xzf mhash-$mhash_version.tar.gz
-  pushd mhash-$mhash_version
+  tar xzf mhash-$mhash_ver.tar.gz
+  pushd mhash-$mhash_ver
   ./configure
   make -j ${THREAD} && make install
   popd
-  rm -rf mhash-$mhash_version
+  rm -rf mhash-$mhash_ver
   
   echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf
   ldconfig
   [ "$OS" == 'CentOS' ] && { ln -s /usr/local/bin/libmcrypt-config /usr/bin/libmcrypt-config; [ "$OS_BIT" == '64' ] && ln -s /lib64/libpcre.so.0.0.1 /lib64/libpcre.so.1 || ln -s /lib/libpcre.so.0.0.1 /lib/libpcre.so.1; }
   
-  tar xzf mcrypt-$mcrypt_version.tar.gz
-  pushd mcrypt-$mcrypt_version
+  tar xzf mcrypt-$mcrypt_ver.tar.gz
+  pushd mcrypt-$mcrypt_ver
   ldconfig
   ./configure
   make -j ${THREAD} && make install
   popd
-  rm -rf mcrypt-$mcrypt_version
+  rm -rf mcrypt-$mcrypt_ver
   
   id -u $run_user >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
   
-  tar xzf php-$php70_version.tar.gz
-  pushd php-$php70_version
+  tar xzf php-$php70_ver.tar.gz
+  pushd php-$php70_ver
   make clean
   ./buildconf
   [ ! -d "$php_install_dir" ] && mkdir -p $php_install_dir
-  [ "$PHP_cache" == '1' ] && PHP_cache_tmp='--enable-opcache' || PHP_cache_tmp='--disable-opcache'
-  if [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  [ "$php_cache" == '1' ] && php_cache_tmp='--enable-opcache' || php_cache_tmp='--disable-opcache'
+  if [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
-    --with-apxs2=$apache_install_dir/bin/apxs $PHP_cache_tmp --disable-fileinfo \
+    --with-apxs2=$apache_install_dir/bin/apxs $php_cache_tmp --disable-fileinfo \
     --enable-mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd \
     --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib \
     --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-exif \
@@ -79,7 +79,7 @@ Install_PHP70() {
   else
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
-    --with-fpm-user=$run_user --with-fpm-group=$run_user --enable-fpm $PHP_cache_tmp --disable-fileinfo \
+    --with-fpm-user=$run_user --with-fpm-group=$run_user --enable-fpm $php_cache_tmp --disable-fileinfo \
     --enable-mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd \
     --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib \
     --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-exif \
@@ -123,7 +123,7 @@ Install_PHP70() {
   sed -i 's@^disable_functions.*@disable_functions = passthru,exec,system,chroot,chgrp,chown,shell_exec,proc_open,proc_get_status,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,stream_socket_server,fsocket,popen@' $php_install_dir/etc/php.ini
   [ -e /usr/sbin/sendmail ] && sed -i 's@^;sendmail_path.*@sendmail_path = /usr/sbin/sendmail -t -i@' $php_install_dir/etc/php.ini
   
-  [ "$PHP_cache" == '1' ] && cat > $php_install_dir/etc/php.d/ext-opcache.ini << EOF
+  [ "$php_cache" == '1' ] && cat > $php_install_dir/etc/php.d/ext-opcache.ini << EOF
 [opcache]
 zend_extension=opcache.so
 opcache.enable=1
@@ -141,7 +141,7 @@ opcache.consistency_checks=0
 ;opcache.optimization_level=0
 EOF
 
-  if [[ ! $Apache_version =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
+  if [[ ! $apache_ver =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
     # php-fpm Init Script
     /bin/cp sapi/fpm/init.d.php-fpm /etc/init.d/php-fpm
     chmod +x /etc/init.d/php-fpm
@@ -233,13 +233,13 @@ EOF
       sed -i "s@^pm.max_spare_servers.*@pm.max_spare_servers = 80@" $php_install_dir/etc/php-fpm.conf
     fi
 
-    #[ "$Web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
+    #[ "$web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
     service php-fpm start
 
-  elif [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  elif [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     service httpd restart
   fi
   popd
-  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php70_version
+  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php70_ver
   popd
 }

+ 28 - 28
include/php-7.1.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,23 +11,23 @@
 Install_PHP71() {
   pushd ${oneinstack_dir}/src
   
-  tar xzf libiconv-$libiconv_version.tar.gz
-  patch -d libiconv-$libiconv_version -p0 < libiconv-glibc-2.16.patch
-  pushd libiconv-$libiconv_version
+  tar xzf libiconv-$libiconv_ver.tar.gz
+  patch -d libiconv-$libiconv_ver -p0 < libiconv-glibc-2.16.patch
+  pushd libiconv-$libiconv_ver
   ./configure --prefix=/usr/local
   make -j ${THREAD} && make install
   popd
-  rm -rf libiconv-$libiconv_version
+  rm -rf libiconv-$libiconv_ver
   
-  tar xzf curl-$curl_version.tar.gz
-  pushd curl-$curl_version
+  tar xzf curl-$curl_ver.tar.gz
+  pushd curl-$curl_ver
   ./configure --prefix=/usr/local --with-ssl=${openssl_install_dir}
   make -j ${THREAD} && make install
   popd
-  rm -rf curl-$curl_version
+  rm -rf curl-$curl_ver
   
-  tar xzf libmcrypt-$libmcrypt_version.tar.gz
-  pushd libmcrypt-$libmcrypt_version
+  tar xzf libmcrypt-$libmcrypt_ver.tar.gz
+  pushd libmcrypt-$libmcrypt_ver
   ./configure
   make -j ${THREAD} && make install
   ldconfig
@@ -35,40 +35,40 @@ Install_PHP71() {
   ./configure --enable-ltdl-install
   make -j ${THREAD} && make install
   popd;popd
-  rm -rf libmcrypt-$libmcrypt_version
+  rm -rf libmcrypt-$libmcrypt_ver
   
-  tar xzf mhash-$mhash_version.tar.gz
-  pushd mhash-$mhash_version
+  tar xzf mhash-$mhash_ver.tar.gz
+  pushd mhash-$mhash_ver
   ./configure
   make -j ${THREAD} && make install
   popd
-  rm -rf mhash-$mhash_version
+  rm -rf mhash-$mhash_ver
   
   echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf
   ldconfig
   [ "$OS" == 'CentOS' ] && { ln -s /usr/local/bin/libmcrypt-config /usr/bin/libmcrypt-config; [ "$OS_BIT" == '64' ] && ln -s /lib64/libpcre.so.0.0.1 /lib64/libpcre.so.1 || ln -s /lib/libpcre.so.0.0.1 /lib/libpcre.so.1; }
   
-  tar xzf mcrypt-$mcrypt_version.tar.gz
-  pushd mcrypt-$mcrypt_version
+  tar xzf mcrypt-$mcrypt_ver.tar.gz
+  pushd mcrypt-$mcrypt_ver
   ldconfig
   ./configure
   make -j ${THREAD} && make install
   popd
-  rm -rf mcrypt-$mcrypt_version
+  rm -rf mcrypt-$mcrypt_ver
   
   id -u $run_user >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
   
-  tar xzf php-$php71_version.tar.gz
-  pushd php-$php71_version
+  tar xzf php-$php71_ver.tar.gz
+  pushd php-$php71_ver
   make clean
   ./buildconf
   [ ! -d "$php_install_dir" ] && mkdir -p $php_install_dir
-  [ "$PHP_cache" == '1' ] && PHP_cache_tmp='--enable-opcache' || PHP_cache_tmp='--disable-opcache'
-  if [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  [ "$php_cache" == '1' ] && php_cache_tmp='--enable-opcache' || php_cache_tmp='--disable-opcache'
+  if [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
-    --with-apxs2=$apache_install_dir/bin/apxs $PHP_cache_tmp --disable-fileinfo \
+    --with-apxs2=$apache_install_dir/bin/apxs $php_cache_tmp --disable-fileinfo \
     --enable-mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd \
     --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib \
     --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-exif \
@@ -79,7 +79,7 @@ Install_PHP71() {
   else
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
-    --with-fpm-user=$run_user --with-fpm-group=$run_user --enable-fpm $PHP_cache_tmp --disable-fileinfo \
+    --with-fpm-user=$run_user --with-fpm-group=$run_user --enable-fpm $php_cache_tmp --disable-fileinfo \
     --enable-mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd \
     --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib \
     --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-exif \
@@ -123,7 +123,7 @@ Install_PHP71() {
   sed -i 's@^disable_functions.*@disable_functions = passthru,exec,system,chroot,chgrp,chown,shell_exec,proc_open,proc_get_status,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,stream_socket_server,fsocket,popen@' $php_install_dir/etc/php.ini
   [ -e /usr/sbin/sendmail ] && sed -i 's@^;sendmail_path.*@sendmail_path = /usr/sbin/sendmail -t -i@' $php_install_dir/etc/php.ini
   
-  [ "$PHP_cache" == '1' ] && cat > $php_install_dir/etc/php.d/ext-opcache.ini << EOF
+  [ "$php_cache" == '1' ] && cat > $php_install_dir/etc/php.d/ext-opcache.ini << EOF
 [opcache]
 zend_extension=opcache.so
 opcache.enable=1
@@ -141,7 +141,7 @@ opcache.consistency_checks=0
 ;opcache.optimization_level=0
 EOF
 
-  if [[ ! $Apache_version =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
+  if [[ ! $apache_ver =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
     # php-fpm Init Script
     /bin/cp sapi/fpm/init.d.php-fpm /etc/init.d/php-fpm
     chmod +x /etc/init.d/php-fpm
@@ -233,13 +233,13 @@ EOF
       sed -i "s@^pm.max_spare_servers.*@pm.max_spare_servers = 80@" $php_install_dir/etc/php-fpm.conf
     fi
 
-    #[ "$Web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
+    #[ "$web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
     service php-fpm start
 
-  elif [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  elif [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     service httpd restart
   fi
   popd
-  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php71_version
+  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php71_ver
   popd
 }

+ 22 - 22
include/php-7.2.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,27 +11,27 @@
 Install_PHP72() {
   pushd ${oneinstack_dir}/src
   
-  tar xzf libiconv-$libiconv_version.tar.gz
-  patch -d libiconv-$libiconv_version -p0 < libiconv-glibc-2.16.patch
-  pushd libiconv-$libiconv_version
+  tar xzf libiconv-$libiconv_ver.tar.gz
+  patch -d libiconv-$libiconv_ver -p0 < libiconv-glibc-2.16.patch
+  pushd libiconv-$libiconv_ver
   ./configure --prefix=/usr/local
   make -j ${THREAD} && make install
   popd
-  rm -rf libiconv-$libiconv_version
+  rm -rf libiconv-$libiconv_ver
   
-  tar xzf curl-$curl_version.tar.gz
-  pushd curl-$curl_version
+  tar xzf curl-$curl_ver.tar.gz
+  pushd curl-$curl_ver
   ./configure --prefix=/usr/local --with-ssl=${openssl_install_dir}
   make -j ${THREAD} && make install
   popd
-  rm -rf curl-$curl_version
+  rm -rf curl-$curl_ver
   
-  tar xzf mhash-$mhash_version.tar.gz
-  pushd mhash-$mhash_version
+  tar xzf mhash-$mhash_ver.tar.gz
+  pushd mhash-$mhash_ver
   ./configure
   make -j ${THREAD} && make install
   popd
-  rm -rf mhash-$mhash_version
+  rm -rf mhash-$mhash_ver
   
   echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf
   ldconfig
@@ -40,16 +40,16 @@ Install_PHP72() {
   id -u $run_user >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
   
-  tar xzf php-$php72_version.tar.gz
-  pushd php-$php72_version
+  tar xzf php-$php72_ver.tar.gz
+  pushd php-$php72_ver
   make clean
   ./buildconf
   [ ! -d "$php_install_dir" ] && mkdir -p $php_install_dir
-  [ "$PHP_cache" == '1' ] && PHP_cache_tmp='--enable-opcache' || PHP_cache_tmp='--disable-opcache'
-  if [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  [ "$php_cache" == '1' ] && php_cache_tmp='--enable-opcache' || php_cache_tmp='--disable-opcache'
+  if [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
-    --with-apxs2=$apache_install_dir/bin/apxs $PHP_cache_tmp --disable-fileinfo \
+    --with-apxs2=$apache_install_dir/bin/apxs $php_cache_tmp --disable-fileinfo \
     --enable-mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd \
     --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib \
     --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-exif \
@@ -60,7 +60,7 @@ Install_PHP72() {
   else
     ./configure --prefix=$php_install_dir --with-config-file-path=$php_install_dir/etc \
     --with-config-file-scan-dir=$php_install_dir/etc/php.d \
-    --with-fpm-user=$run_user --with-fpm-group=$run_user --enable-fpm $PHP_cache_tmp --disable-fileinfo \
+    --with-fpm-user=$run_user --with-fpm-group=$run_user --enable-fpm $php_cache_tmp --disable-fileinfo \
     --enable-mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd \
     --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib \
     --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-exif \
@@ -104,7 +104,7 @@ Install_PHP72() {
   sed -i 's@^disable_functions.*@disable_functions = passthru,exec,system,chroot,chgrp,chown,shell_exec,proc_open,proc_get_status,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,stream_socket_server,fsocket,popen@' $php_install_dir/etc/php.ini
   [ -e /usr/sbin/sendmail ] && sed -i 's@^;sendmail_path.*@sendmail_path = /usr/sbin/sendmail -t -i@' $php_install_dir/etc/php.ini
   
-  [ "$PHP_cache" == '1' ] && cat > $php_install_dir/etc/php.d/ext-opcache.ini << EOF
+  [ "$php_cache" == '1' ] && cat > $php_install_dir/etc/php.d/ext-opcache.ini << EOF
 [opcache]
 zend_extension=opcache.so
 opcache.enable=1
@@ -122,7 +122,7 @@ opcache.consistency_checks=0
 ;opcache.optimization_level=0
 EOF
 
-  if [[ ! $Apache_version =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
+  if [[ ! $apache_ver =~ ^[1-2]$ ]] && [ ! -e "$apache_install_dir/bin/apxs" ]; then
     # php-fpm Init Script
     /bin/cp sapi/fpm/init.d.php-fpm /etc/init.d/php-fpm
     chmod +x /etc/init.d/php-fpm
@@ -214,13 +214,13 @@ EOF
       sed -i "s@^pm.max_spare_servers.*@pm.max_spare_servers = 80@" $php_install_dir/etc/php-fpm.conf
     fi
 
-    #[ "$Web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
+    #[ "$web_yn" == 'n' ] && sed -i "s@^listen =.*@listen = $IPADDR:9000@" $php_install_dir/etc/php-fpm.conf
     service php-fpm start
 
-  elif [[ $Apache_version =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
+  elif [[ $apache_ver =~ ^[1-2]$ ]] || [ -e "$apache_install_dir/bin/apxs" ]; then
     service httpd restart
   fi
   popd
-  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php72_version
+  [ -e "$php_install_dir/bin/phpize" ] && rm -rf php-$php72_ver
   popd
 }

+ 3 - 3
include/phpmyadmin.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -10,8 +10,8 @@
 
 Install_phpMyAdmin() {
   pushd ${oneinstack_dir}/src
-  tar xzf phpMyAdmin-${phpMyAdmin_version}-all-languages.tar.gz
-  /bin/mv phpMyAdmin-${phpMyAdmin_version}-all-languages ${wwwroot_dir}/default/phpMyAdmin
+  tar xzf phpMyAdmin-${phpmyadmin_ver}-all-languages.tar.gz
+  /bin/mv phpMyAdmin-${phpmyadmin_ver}-all-languages ${wwwroot_dir}/default/phpMyAdmin
   /bin/cp ${wwwroot_dir}/default/phpMyAdmin/{config.sample.inc.php,config.inc.php}
   mkdir ${wwwroot_dir}/default/phpMyAdmin/{upload,save}
   sed -i "s@UploadDir.*@UploadDir'\] = 'upload';@" ${wwwroot_dir}/default/phpMyAdmin/config.inc.php

+ 5 - 5
include/postgresql.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -13,8 +13,8 @@ Install_PostgreSQL() {
   id -u postgres >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -d ${pgsql_install_dir} -s /bin/bash postgres 
   mkdir -p ${pgsql_data_dir};chown postgres.postgres -R ${pgsql_data_dir}
-  tar xzf postgresql-${pgsql_version}.tar.gz
-  pushd postgresql-${pgsql_version}
+  tar xzf postgresql-${pgsql_ver}.tar.gz
+  pushd postgresql-${pgsql_ver}
   ./configure --prefix=$pgsql_install_dir
   make -j ${THREAD}
   make install
@@ -39,9 +39,9 @@ Install_PostgreSQL() {
 
   if [ -e "${pgsql_install_dir}/bin/psql" ]; then
     echo "${CSUCCESS}PostgreSQL installed successfully! ${CEND}"
-    rm -rf postgresql-${pgsql_version}
+    rm -rf postgresql-${pgsql_ver}
   else
-    rm -rf ${pgsql_install_dir} ${pgsql_data_dir} postgresql-${pgsql_version}
+    rm -rf ${pgsql_install_dir} ${pgsql_data_dir} postgresql-${pgsql_ver}
     echo "${CFAILURE}PostgreSQL install failed, Please contact the author! ${CEND}"
     kill -9 $$
   fi

+ 4 - 4
include/pureftpd.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -14,8 +14,8 @@ Install_PureFTPd() {
   id -u ${run_user} >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin ${run_user}
 
-  tar xzf pure-ftpd-${pureftpd_version}.tar.gz
-  pushd pure-ftpd-${pureftpd_version}
+  tar xzf pure-ftpd-${pureftpd_ver}.tar.gz
+  pushd pure-ftpd-${pureftpd_ver}
   [ ! -d "${pureftpd_install_dir}" ] && mkdir -p ${pureftpd_install_dir}
   ./configure --prefix=${pureftpd_install_dir} CFLAGS=-O2 --with-puredb --with-quotas --with-cookie --with-virtualhosts --with-virtualchroot --with-diraliases --with-sysquotas --with-ratios --with-altlog --with-paranoidmsg --with-shadow --with-welcomemsg  --with-throttling --with-uploadscript --with-language=english --with-rfc2640
   make -j ${THREAD} && make install
@@ -53,7 +53,7 @@ Install_PureFTPd() {
     fi
 
     echo "${CSUCCESS}Pure-Ftp installed successfully! ${CEND}"
-    rm -rf pure-ftpd-${pureftpd_version}
+    rm -rf pure-ftpd-${pureftpd_ver}
   else
     rm -rf ${pureftpd_install_dir}
     echo "${CFAILURE}Pure-Ftpd install failed, Please contact the author! ${CEND}"

+ 13 - 13
include/python.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -46,32 +46,32 @@ EOF
 
   # Install Python
   if [ ! -e "${python_install_dir}/bin/python" -a ! -e "${python_install_dir}/bin/python3" ] ;then
-    src_url=http://mirrors.linuxeye.com/oneinstack/src/Python-${python_version}.tgz && Download_src
-    tar xzf Python-${python_version}.tgz
-    pushd Python-${python_version}
+    src_url=http://mirrors.linuxeye.com/oneinstack/src/Python-${python_ver}.tgz && Download_src
+    tar xzf Python-${python_ver}.tgz
+    pushd Python-${python_ver}
     ./configure --prefix=${python_install_dir}
     make && make install
     [ ! -e "${python_install_dir}/bin/python" -a -e "${python_install_dir}/bin/python3" ] && ln -s ${python_install_dir}/bin/python{3,}
     popd
-    rm -rf Python-${python_version}
+    rm -rf Python-${python_ver}
   fi
 
   if [ ! -e "${python_install_dir}/bin/easy_install" ] ;then
-    src_url=http://mirrors.linuxeye.com/oneinstack/src/setuptools-${setuptools_version}.zip && Download_src
-    unzip -q setuptools-${setuptools_version}.zip
-    pushd setuptools-${setuptools_version}
+    src_url=http://mirrors.linuxeye.com/oneinstack/src/setuptools-${setuptools_ver}.zip && Download_src
+    unzip -q setuptools-${setuptools_ver}.zip
+    pushd setuptools-${setuptools_ver}
     ${python_install_dir}/bin/python setup.py install
     popd
-    rm -rf setuptools-${setuptools_version}
+    rm -rf setuptools-${setuptools_ver}
   fi
 
   if [ ! -e "${python_install_dir}/bin/pip" ] ;then
-    src_url=http://mirrors.linuxeye.com/oneinstack/src/pip-${pip_version}.tar.gz && Download_src
-    tar xzf pip-${pip_version}.tar.gz
-    pushd pip-${pip_version}
+    src_url=http://mirrors.linuxeye.com/oneinstack/src/pip-${pip_ver}.tar.gz && Download_src
+    tar xzf pip-${pip_ver}.tar.gz
+    pushd pip-${pip_ver}
     ${python_install_dir}/bin/python setup.py install
     popd
-    rm -rf pip-${pip_version}
+    rm -rf pip-${pip_ver}
   fi
 
   if [ ! -e "/root/.pip/pip.conf" ] ;then

+ 7 - 7
include/redis.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -10,8 +10,8 @@
 
 Install_redis-server() {
   pushd ${oneinstack_dir}/src
-  tar xzf redis-${redis_version}.tar.gz
-  pushd redis-${redis_version}
+  tar xzf redis-${redis_ver}.tar.gz
+  pushd redis-${redis_ver}
   if [ "$OS_BIT" == '32' ]; then
     sed -i '1i\CFLAGS= -march=i686' src/Makefile
     sed -i 's@^OPT=.*@OPT=-O2 -march=i686@' src/.make-settings
@@ -31,7 +31,7 @@ Install_redis-server() {
     [ -z "`grep ^maxmemory ${redis_install_dir}/etc/redis.conf`" ] && sed -i "s@maxmemory <bytes>@maxmemory <bytes>\nmaxmemory `expr $Mem / 8`000000@" ${redis_install_dir}/etc/redis.conf
     echo "${CSUCCESS}Redis-server installed successfully! ${CEND}"
     popd
-    rm -rf redis-${redis_version}
+    rm -rf redis-${redis_ver}
     id -u redis >/dev/null 2>&1
     [ $? -ne 0 ] && useradd -M -s /sbin/nologin redis
     chown -R redis:redis ${redis_install_dir}/{var,etc}
@@ -59,8 +59,8 @@ Install_php-redis() {
   pushd ${oneinstack_dir}/src
   if [ -e "${php_install_dir}/bin/phpize" ]; then
     phpExtensionDir=`${php_install_dir}/bin/php-config --extension-dir`
-    tar xzf redis-$redis_pecl_version.tgz
-    pushd redis-$redis_pecl_version
+    tar xzf redis-$redis_pecl_ver.tgz
+    pushd redis-$redis_pecl_ver
     ${php_install_dir}/bin/phpize
     ./configure --with-php-config=${php_install_dir}/bin/php-config
     make -j ${THREAD} && make install
@@ -68,7 +68,7 @@ Install_php-redis() {
       echo 'extension=redis.so' > ${php_install_dir}/etc/php.d/ext-redis.ini
       echo "${CSUCCESS}PHP Redis module installed successfully! ${CEND}"
       popd
-      rm -rf redis-$redis_pecl_version
+      rm -rf redis-$redis_pecl_ver
     else
       echo "${CFAILURE}PHP Redis module install failed, Please contact the author! ${CEND}"
     fi

+ 10 - 10
include/tengine.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -14,10 +14,10 @@ Install_Tengine() {
   id -u $run_user >/dev/null 2>&1
   [ $? -ne 0 ] && useradd -M -s /sbin/nologin $run_user
   
-  tar xzf pcre-$pcre_version.tar.gz
-  tar xzf tengine-$tengine_version.tar.gz
-  tar xzf openssl-$openssl_version.tar.gz
-  pushd tengine-$tengine_version
+  tar xzf pcre-$pcre_ver.tar.gz
+  tar xzf tengine-$tengine_ver.tar.gz
+  tar xzf openssl-$openssl_ver.tar.gz
+  pushd tengine-$tengine_ver
   # Modify Tengine version
   #sed -i 's@TENGINE "/" TENGINE_VERSION@"Tengine/unknown"@' src/core/nginx.h
   
@@ -25,11 +25,11 @@ Install_Tengine() {
   sed -i 's@CFLAGS="$CFLAGS -g"@#CFLAGS="$CFLAGS -g"@' auto/cc/gcc
   
   [ ! -d "$tengine_install_dir" ] && mkdir -p $tengine_install_dir
-  ./configure --prefix=$tengine_install_dir --user=$run_user --group=$run_user --with-http_v2_module --with-http_ssl_module --with-http_gzip_static_module --with-http_realip_module --with-http_flv_module --with-http_mp4_module --with-http_concat_module=shared --with-http_sysguard_module=shared --with-openssl=../openssl-$openssl_version --with-pcre=../pcre-$pcre_version --with-pcre-jit --with-jemalloc $nginx_modules_options
+  ./configure --prefix=$tengine_install_dir --user=$run_user --group=$run_user --with-http_v2_module --with-http_ssl_module --with-http_gzip_static_module --with-http_realip_module --with-http_flv_module --with-http_mp4_module --with-http_concat_module=shared --with-http_sysguard_module=shared --with-openssl=../openssl-$openssl_ver --with-pcre=../pcre-$pcre_ver --with-pcre-jit --with-jemalloc $nginx_modules_options
   make -j ${THREAD} && make install
   if [ -e "$tengine_install_dir/conf/nginx.conf" ]; then
     popd
-    rm -rf tengine-$tengine_version
+    rm -rf tengine-$tengine_ver
     echo "${CSUCCESS}Tengine installed successfully! ${CEND}"
   else
     rm -rf $tengine_install_dir
@@ -47,13 +47,13 @@ Install_Tengine() {
   sed -i "s@/usr/local/nginx@$tengine_install_dir@g" /etc/init.d/nginx
   
   mv $tengine_install_dir/conf/nginx.conf{,_bk}
-  if [[ $Apache_version =~ ^[1-2]$ ]]; then
+  if [[ $apache_ver =~ ^[1-2]$ ]]; then
     /bin/cp ../config/nginx_apache.conf $tengine_install_dir/conf/nginx.conf
-  elif [[ $Tomcat_version =~ ^[1-2]$ ]] && [ ! -e "$php_install_dir/bin/php" ]; then
+  elif [[ $tomcat_ver =~ ^[1-2]$ ]] && [ ! -e "$php_install_dir/bin/php" ]; then
     /bin/cp ../config/nginx_tomcat.conf $tengine_install_dir/conf/nginx.conf
   else
     /bin/cp ../config/nginx.conf $tengine_install_dir/conf/nginx.conf
-    [ "$PHP_yn" == 'y' ] && [ -z "`grep '/php-fpm_status' $tengine_install_dir/conf/nginx.conf`" ] &&  sed -i "s@index index.html index.php;@index index.html index.php;\n    location ~ /php-fpm_status {\n        #fastcgi_pass remote_php_ip:9000;\n        fastcgi_pass unix:/dev/shm/php-cgi.sock;\n        fastcgi_index index.php;\n        include fastcgi.conf;\n        allow 127.0.0.1;\n        deny all;\n        }@" $tengine_install_dir/conf/nginx.conf
+    [ "$php_yn" == 'y' ] && [ -z "`grep '/php-fpm_status' $tengine_install_dir/conf/nginx.conf`" ] &&  sed -i "s@index index.html index.php;@index index.html index.php;\n    location ~ /php-fpm_status {\n        #fastcgi_pass remote_php_ip:9000;\n        fastcgi_pass unix:/dev/shm/php-cgi.sock;\n        fastcgi_index index.php;\n        include fastcgi.conf;\n        allow 127.0.0.1;\n        deny all;\n        }@" $tengine_install_dir/conf/nginx.conf
   fi
   cat > $tengine_install_dir/conf/proxy.conf << EOF
 proxy_connect_timeout 300s;

+ 7 - 7
include/tomcat-6.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,17 +17,17 @@ Install_Tomcat6() {
 
   # install apr
   if [ ! -e "/usr/local/apr/bin/apr-1-config" ]; then
-    tar xzf apr-${apr_version}.tar.gz
-    pushd apr-${apr_version}
+    tar xzf apr-${apr_ver}.tar.gz
+    pushd apr-${apr_ver}
     ./configure
     make -j ${THREAD} && make install
     popd
-    rm -rf apr-${apr_version} 
+    rm -rf apr-${apr_ver} 
   fi
 
-  tar xzf apache-tomcat-${tomcat6_version}.tar.gz
+  tar xzf apache-tomcat-${tomcat6_ver}.tar.gz
   [ ! -d "${tomcat_install_dir}" ] && mkdir -p ${tomcat_install_dir}
-  /bin/cp -R apache-tomcat-${tomcat6_version}/* ${tomcat_install_dir}
+  /bin/cp -R apache-tomcat-${tomcat6_ver}/* ${tomcat_install_dir}
   rm -rf ${tomcat_install_dir}/webapps/{docs,examples,host-manager,manager,ROOT/*}
 
   if [ ! -e "${tomcat_install_dir}/conf/server.xml" ]; then
@@ -129,7 +129,7 @@ EOF
     [ "${OS}" == "CentOS" ] && { chkconfig --add tomcat; chkconfig tomcat on; }
     [[ "${OS}" =~ ^Ubuntu$|^Debian$ ]] && update-rc.d tomcat defaults
     echo "${CSUCCESS}Tomcat installed successfully! ${CEND}"
-    rm -rf apache-tomcat-${tomcat6_version}
+    rm -rf apache-tomcat-${tomcat6_ver}
   else
     popd
     echo "${CFAILURE}Tomcat install failed, Please contact the author! ${CEND}"

+ 7 - 7
include/tomcat-7.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,17 +17,17 @@ Install_Tomcat7() {
 
   # install apr
   if [ ! -e "/usr/local/apr/bin/apr-1-config" ]; then
-    tar xzf apr-${apr_version}.tar.gz
-    pushd apr-${apr_version}
+    tar xzf apr-${apr_ver}.tar.gz
+    pushd apr-${apr_ver}
     ./configure
     make -j ${THREAD} && make install
     popd
-    rm -rf apr-${apr_version} 
+    rm -rf apr-${apr_ver} 
   fi
 
-  tar xzf apache-tomcat-${tomcat7_version}.tar.gz
+  tar xzf apache-tomcat-${tomcat7_ver}.tar.gz
   [ ! -d "${tomcat_install_dir}" ] && mkdir -p ${tomcat_install_dir}
-  /bin/cp -R apache-tomcat-${tomcat7_version}/* ${tomcat_install_dir}
+  /bin/cp -R apache-tomcat-${tomcat7_ver}/* ${tomcat_install_dir}
   rm -rf ${tomcat_install_dir}/webapps/{docs,examples,host-manager,manager,ROOT/*}
 
   if [ ! -e "${tomcat_install_dir}/conf/server.xml" ]; then
@@ -129,7 +129,7 @@ EOF
     [ "${OS}" == "CentOS" ] && { chkconfig --add tomcat; chkconfig tomcat on; }
     [[ "${OS}" =~ ^Ubuntu$|^Debian$ ]] && update-rc.d tomcat defaults
     echo "${CSUCCESS}Tomcat installed successfully! ${CEND}"
-    rm -rf apache-tomcat-${tomcat7_version}
+    rm -rf apache-tomcat-${tomcat7_ver}
   else
     popd
     echo "${CFAILURE}Tomcat install failed, Please contact the author! ${CEND}"

+ 7 - 7
include/tomcat-8.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -17,17 +17,17 @@ Install_Tomcat8() {
 
   # install apr
   if [ ! -e "/usr/local/apr/bin/apr-1-config" ]; then
-    tar xzf apr-${apr_version}.tar.gz
-    pushd apr-${apr_version}
+    tar xzf apr-${apr_ver}.tar.gz
+    pushd apr-${apr_ver}
     ./configure
     make -j ${THREAD} && make install
     popd
-    rm -rf apr-${apr_version} 
+    rm -rf apr-${apr_ver} 
   fi
 
-  tar xzf apache-tomcat-${tomcat8_version}.tar.gz
+  tar xzf apache-tomcat-${tomcat8_ver}.tar.gz
   [ ! -d "${tomcat_install_dir}" ] && mkdir -p ${tomcat_install_dir}
-  /bin/cp -R apache-tomcat-${tomcat8_version}/* ${tomcat_install_dir}
+  /bin/cp -R apache-tomcat-${tomcat8_ver}/* ${tomcat_install_dir}
   rm -rf ${tomcat_install_dir}/webapps/{docs,examples,host-manager,manager,ROOT/*}
 
   if [ ! -e "${tomcat_install_dir}/conf/server.xml" ]; then
@@ -129,7 +129,7 @@ EOF
     [ "${OS}" == "CentOS" ] && { chkconfig --add tomcat; chkconfig tomcat on; }
     [[ "${OS}" =~ ^Ubuntu$|^Debian$ ]] && update-rc.d tomcat defaults
     echo "${CSUCCESS}Tomcat installed successfully! ${CEND}"
-    rm -rf apache-tomcat-${tomcat8_version}
+    rm -rf apache-tomcat-${tomcat8_ver}
   else
     popd
     echo "${CFAILURE}Tomcat install failed, Please contact the author! ${CEND}"

+ 24 - 24
include/upgrade_db.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,19 +11,19 @@
 Upgrade_DB() {
   pushd ${oneinstack_dir}/src > /dev/null
   [ ! -e "$db_install_dir/bin/mysql" ] && echo "${CWARNING}MySQL/MariaDB/Percona is not installed on your system! ${CEND}" && exit 1
-  OLD_DB_version_tmp=`$db_install_dir/bin/mysql -V | awk '{print $5}' | awk -F, '{print $1}'`
-  DB_tmp=`echo $OLD_DB_version_tmp | awk -F'-' '{print $2}'`
+  OLD_db_ver_tmp=`$db_install_dir/bin/mysql -V | awk '{print $5}' | awk -F, '{print $1}'`
+  DB_tmp=`echo $OLD_db_ver_tmp | awk -F'-' '{print $2}'`
   if [ "$DB_tmp" == 'MariaDB' ]; then
     [ "$IPADDR_COUNTRY"x == "CN"x ] && DOWN_ADDR=https://mirrors.tuna.tsinghua.edu.cn/mariadb || DOWN_ADDR=https://downloads.mariadb.org/f
     DB=MariaDB
-    OLD_DB_version=`echo $OLD_DB_version_tmp | awk -F'-' '{print $1}'`
+    OLD_db_ver=`echo $OLD_db_ver_tmp | awk -F'-' '{print $1}'`
   elif [ -n "$DB_tmp" -a "$DB_tmp" != 'MariaDB' ]; then
     DB=Percona
-    OLD_DB_version=$OLD_DB_version_tmp
+    OLD_db_ver=$OLD_db_ver_tmp
   else
     [ "$IPADDR_COUNTRY"x == "CN"x ] && DOWN_ADDR=http://mirrors.ustc.edu.cn/mysql-ftp/Downloads || DOWN_ADDR=http://cdn.mysql.com/Downloads
     DB=MySQL
-    OLD_DB_version=$OLD_DB_version_tmp
+    OLD_db_ver=$OLD_db_ver_tmp
   fi
 
   #backup
@@ -52,19 +52,19 @@ Upgrade_DB() {
   
   #upgrade
   echo
-  echo "Current $DB Version: ${CMSG}$OLD_DB_version${CEND}"
+  echo "Current $DB Version: ${CMSG}$OLD_db_ver${CEND}"
   while :; do echo
-    read -p "Please input upgrade $DB Version(example: $OLD_DB_version): " NEW_DB_version
-    if [ `echo $NEW_DB_version | awk -F. '{print $1"."$2}'` == `echo $OLD_DB_version | awk -F. '{print $1"."$2}'` ]; then
+    read -p "Please input upgrade $DB Version(example: $OLD_db_ver): " NEW_db_ver
+    if [ `echo $NEW_db_ver | awk -F. '{print $1"."$2}'` == `echo $OLD_db_ver | awk -F. '{print $1"."$2}'` ]; then
       if [ "$DB" == 'MariaDB' ]; then
-        DB_name=mariadb-${NEW_DB_version}-${GLIBC_FLAG}-${SYS_BIT_b}
-        DB_URL=$DOWN_ADDR/mariadb-${NEW_DB_version}/bintar-${GLIBC_FLAG}-$SYS_BIT_a/$DB_name.tar.gz
+        DB_name=mariadb-${NEW_db_ver}-${GLIBC_FLAG}-${SYS_BIT_b}
+        DB_URL=$DOWN_ADDR/mariadb-${NEW_db_ver}/bintar-${GLIBC_FLAG}-$SYS_BIT_a/$DB_name.tar.gz
       elif [ "$DB" == 'Percona' ]; then
-        DB_name=percona-server-$NEW_DB_version
-        DB_URL=http://www.percona.com/redir/downloads/Percona-Server-`echo $NEW_DB_version | awk -F. '{print $1"."$2}'`/LATEST/source/tarball/$DB_name.tar.gz
+        DB_name=percona-server-$NEW_db_ver
+        DB_URL=http://www.percona.com/redir/downloads/Percona-Server-`echo $NEW_db_ver | awk -F. '{print $1"."$2}'`/LATEST/source/tarball/$DB_name.tar.gz
       elif [ "$DB" == 'MySQL' ]; then
-        DB_name=mysql-${NEW_DB_version}-linux-glibc2.12-${SYS_BIT_b}
-        DB_URL=$DOWN_ADDR/MySQL-`echo $NEW_DB_version | awk -F. '{print $1"."$2}'`/$DB_name.tar.gz
+        DB_name=mysql-${NEW_db_ver}-linux-glibc2.12-${SYS_BIT_b}
+        DB_URL=$DOWN_ADDR/MySQL-`echo $NEW_db_ver | awk -F. '{print $1"."$2}'`/$DB_name.tar.gz
       fi
         [ ! -e "$DB_name.tar.gz" ] && wget --no-check-certificate -c $DB_URL > /dev/null 2>&1
         if [ -e "$DB_name.tar.gz" ]; then
@@ -74,7 +74,7 @@ Upgrade_DB() {
         fi
         break
     else
-      echo "${CWARNING}input error! ${CEND}Please only input '${CMSG}${OLD_DB_version%.*}.xx${CEND}'"
+      echo "${CWARNING}input error! ${CEND}Please only input '${CMSG}${OLD_db_ver%.*}.xx${CEND}'"
     fi
   done
 
@@ -89,7 +89,7 @@ Upgrade_DB() {
       mkdir -p $mariadb_data_dir;chown mysql.mysql -R $mariadb_data_dir
       tar xzf $DB_name.tar.gz
       [ ! -d "$mariadb_install_dir" ] && mkdir -p $mariadb_install_dir
-      mv mariadb-${NEW_DB_version}-*-${SYS_BIT_b}/* $mariadb_install_dir
+      mv mariadb-${NEW_db_ver}-*-${SYS_BIT_b}/* $mariadb_install_dir
       sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' $mariadb_install_dir/bin/mysqld_safe
       $mariadb_install_dir/scripts/mysql_install_db --user=mysql --basedir=$mariadb_install_dir --datadir=$mariadb_data_dir
       chown mysql.mysql -R $mariadb_data_dir
@@ -98,12 +98,12 @@ Upgrade_DB() {
       service mysqld restart
       $mariadb_install_dir/bin/mysql -uroot -p${dbrootpwd} -e "drop database test;" >/dev/null 2>&1
       $mariadb_install_dir/bin/mysql -uroot -p${dbrootpwd} -e "reset master;" >/dev/null 2>&1
-      [ $? -eq 0 ] &&  echo "You have ${CMSG}successfully${CEND} upgrade from ${CMSG}$OLD_DB_version${CEND} to ${CMSG}$NEW_DB_version${CEND}"
+      [ $? -eq 0 ] &&  echo "You have ${CMSG}successfully${CEND} upgrade from ${CMSG}$OLD_db_ver${CEND} to ${CMSG}$NEW_db_ver${CEND}"
     elif [ "$DB" == 'Percona' ]; then
       tar xzf $DB_name.tar.gz
       pushd $DB_name
       make clean
-      if [ "`echo $NEW_DB_version | awk -F. '{print $1"."$2}'`" == '5.5' ]; then
+      if [ "`echo $NEW_db_ver | awk -F. '{print $1"."$2}'`" == '5.5' ]; then
         cmake . -DCMAKE_INSTALL_PREFIX=$percona_install_dir \
         -DMYSQL_DATADIR=$percona_data_dir \
         -DSYSCONFDIR=/etc \
@@ -143,7 +143,7 @@ Upgrade_DB() {
       mkdir -p $percona_data_dir;chown mysql.mysql -R $percona_data_dir
       make install
       popd 
-      if [ "`echo $NEW_DB_version | awk -F. '{print $1"."$2}'`" == '5.7' ]; then
+      if [ "`echo $NEW_db_ver | awk -F. '{print $1"."$2}'`" == '5.7' ]; then
         $percona_install_dir/bin/mysqld --initialize-insecure --user=mysql --basedir=$percona_install_dir --datadir=$percona_data_dir
       else
         $percona_install_dir/scripts/mysql_install_db --user=mysql --basedir=$percona_install_dir --datadir=$percona_data_dir
@@ -154,7 +154,7 @@ Upgrade_DB() {
       service mysqld restart
       $percona_install_dir/bin/mysql -uroot -p${dbrootpwd} -e "drop database test;" >/dev/null 2>&1
       $percona_install_dir/bin/mysql -uroot -p${dbrootpwd} -e "reset master;" >/dev/null 2>&1
-      [ $? -eq 0 ] &&  echo "You have ${CMSG}successfully${CEND} upgrade from ${CMSG}$OLD_DB_version${CEND} to ${CMSG}$NEW_DB_version${CEND}"
+      [ $? -eq 0 ] &&  echo "You have ${CMSG}successfully${CEND} upgrade from ${CMSG}$OLD_db_ver${CEND} to ${CMSG}$NEW_db_ver${CEND}"
     elif [ "$DB" == 'MySQL' ]; then
       tar xzf $DB_name.tar.gz
       service mysqld stop
@@ -165,8 +165,8 @@ Upgrade_DB() {
       mv $DB_name/* $mysql_install_dir/
       sed -i 's@executing mysqld_safe@executing mysqld_safe\nexport LD_PRELOAD=/usr/local/lib/libjemalloc.so@' $mysql_install_dir/bin/mysqld_safe
       sed -i "s@/usr/local/mysql@${mysql_install_dir}@g" ${mysql_install_dir}/bin/mysqld_safe
-      [ "`echo $NEW_DB_version | awk -F. '{print $1"."$2}'`" != '5.7' ] && $mysql_install_dir/scripts/mysql_install_db --user=mysql --basedir=$mysql_install_dir --datadir=$mysql_data_dir
-      [ "`echo $NEW_DB_version | awk -F. '{print $1"."$2}'`" == '5.7' ] && $mysql_install_dir/bin/mysqld --initialize-insecure --user=mysql --basedir=$mysql_install_dir --datadir=$mysql_data_dir
+      [ "`echo $NEW_db_ver | awk -F. '{print $1"."$2}'`" != '5.7' ] && $mysql_install_dir/scripts/mysql_install_db --user=mysql --basedir=$mysql_install_dir --datadir=$mysql_data_dir
+      [ "`echo $NEW_db_ver | awk -F. '{print $1"."$2}'`" == '5.7' ] && $mysql_install_dir/bin/mysqld --initialize-insecure --user=mysql --basedir=$mysql_install_dir --datadir=$mysql_data_dir
 
       chown mysql.mysql -R $mysql_data_dir
       [ -e "$mysql_install_dir/my.cnf" ] && rm -rf $mysql_install_dir/my.cnf
@@ -175,7 +175,7 @@ Upgrade_DB() {
       service mysqld restart
       $mysql_install_dir/bin/mysql -uroot -p${dbrootpwd} -e "drop database test;" >/dev/null 2>&1
       $mysql_install_dir/bin/mysql -uroot -p${dbrootpwd} -e "reset master;" >/dev/null 2>&1
-      [ $? -eq 0 ] &&  echo "You have ${CMSG}successfully${CEND} upgrade from ${CMSG}$OLD_DB_version${CEND} to ${CMSG}$NEW_DB_version${CEND}"
+      [ $? -eq 0 ] &&  echo "You have ${CMSG}successfully${CEND} upgrade from ${CMSG}$OLD_db_ver${CEND} to ${CMSG}$NEW_db_ver${CEND}"
     fi
   fi
 }

+ 1 - 1
include/upgrade_memcached.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 1 - 1
include/upgrade_oneinstack.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 19 - 19
include/upgrade_php.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,35 +11,35 @@
 Upgrade_PHP() {
   pushd ${oneinstack_dir}/src > /dev/null
   [ ! -e "${php_install_dir}" ] && echo "${CWARNING}PHP is not installed on your system! ${CEND}" && exit 1
-  OLD_PHP_version=`${php_install_dir}/bin/php -r 'echo PHP_VERSION;'`
-  Latest_PHP_version=`curl -s http://php.net/downloads.php | awk '/Changelog/{print $2}' | grep "${OLD_PHP_version%.*}"`
-  [ -z "$Latest_PHP_version" ] && Latest_PHP_version=5.5.38
+  OLD_php_ver=`${php_install_dir}/bin/php -r 'echo PHP_VERSION;'`
+  Latest_php_ver=`curl -s http://php.net/downloads.php | awk '/Changelog/{print $2}' | grep "${OLD_php_ver%.*}"`
+  [ -z "$Latest_php_ver" ] && Latest_php_ver=5.5.38
   echo
-  echo "Current PHP Version: ${CMSG}$OLD_PHP_version${CEND}"
+  echo "Current PHP Version: ${CMSG}$OLD_php_ver${CEND}"
   while :; do echo
-    read -p "Please input upgrade PHP Version(Default: $Latest_PHP_version): " NEW_PHP_version
-    [ -z "$NEW_PHP_version" ] && NEW_PHP_version=$Latest_PHP_version
-    if [ "${NEW_PHP_version%.*}" == "${OLD_PHP_version%.*}" ]; then
-      [ ! -e "php-${NEW_PHP_version}.tar.gz" ] && wget --no-check-certificate -c http://www.php.net/distributions/php-${NEW_PHP_version}.tar.gz > /dev/null 2>&1
-      if [ -e "php-${NEW_PHP_version}.tar.gz" ]; then
-        echo "Download [${CMSG}php-${NEW_PHP_version}.tar.gz${CEND}] successfully! "
+    read -p "Please input upgrade PHP Version(Default: $Latest_php_ver): " NEW_php_ver
+    [ -z "$NEW_php_ver" ] && NEW_php_ver=$Latest_php_ver
+    if [ "${NEW_php_ver%.*}" == "${OLD_php_ver%.*}" ]; then
+      [ ! -e "php-${NEW_php_ver}.tar.gz" ] && wget --no-check-certificate -c http://www.php.net/distributions/php-${NEW_php_ver}.tar.gz > /dev/null 2>&1
+      if [ -e "php-${NEW_php_ver}.tar.gz" ]; then
+        echo "Download [${CMSG}php-${NEW_php_ver}.tar.gz${CEND}] successfully! "
       else
         echo "${CWARNING}PHP version does not exist! ${CEND}"
       fi
       break
     else
-      echo "${CWARNING}input error! ${CEND}Please only input '${CMSG}${OLD_PHP_version%.*}.xx${CEND}'"
+      echo "${CWARNING}input error! ${CEND}Please only input '${CMSG}${OLD_php_ver%.*}.xx${CEND}'"
     fi
   done
 
-  if [ -e "php-${NEW_PHP_version}.tar.gz" ]; then
-    echo "[${CMSG}php-${NEW_PHP_version}.tar.gz${CEND}] found"
+  if [ -e "php-${NEW_php_ver}.tar.gz" ]; then
+    echo "[${CMSG}php-${NEW_php_ver}.tar.gz${CEND}] found"
     echo "Press Ctrl+c to cancel or Press any key to continue..."
     char=`get_char`
-    tar xzf php-${NEW_PHP_version}.tar.gz
+    tar xzf php-${NEW_php_ver}.tar.gz
     src_url=http://mirrors.linuxeye.com/oneinstack/src/fpm-race-condition.patch && Download_src
-    patch -d php-${NEW_PHP_version} -p0 < fpm-race-condition.patch
-    pushd php-${NEW_PHP_version}
+    patch -d php-${NEW_php_ver} -p0 < fpm-race-condition.patch
+    pushd php-${NEW_php_ver}
     make clean
     ${php_install_dir}/bin/php -i |grep 'Configure Command' | awk -F'=>' '{print $2}' | bash
     make ZEND_EXTRA_LIBS='-liconv'
@@ -57,8 +57,8 @@ Upgrade_PHP() {
       service php-fpm start
     fi
     popd > /dev/null
-    echo "You have ${CMSG}successfully${CEND} upgrade from ${CWARNING}$OLD_PHP_version${CEND} to ${CWARNING}${NEW_PHP_version}${CEND}"
-    rm -rf php-${NEW_PHP_version}
+    echo "You have ${CMSG}successfully${CEND} upgrade from ${CWARNING}$OLD_php_ver${CEND} to ${CWARNING}${NEW_php_ver}${CEND}"
+    rm -rf php-${NEW_php_ver}
   fi
   popd > /dev/null
 }

+ 16 - 16
include/upgrade_phpmyadmin.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,17 +11,17 @@
 Upgrade_phpMyAdmin() {
   pushd ${oneinstack_dir}/src > /dev/null
   [ ! -e "${wwwroot_dir}/default/phpMyAdmin" ] && echo "${CWARNING}phpMyAdmin is not installed on your system! ${CEND}" && exit 1
-  OLD_phpMyAdmin_version=`grep Version ${wwwroot_dir}/default/phpMyAdmin/README | awk '{print $2}'`
-  Latest_phpMyAdmin_version=`curl -s https://www.phpmyadmin.net/files/ | awk -F'>|<' '/\/files\/[0-9]/{print $5}' | head -1`
-  [ -z "$Latest_phpMyAdmin_version" ] && Latest_phpMyAdmin_version=4.8.6
-  echo "Current phpMyAdmin Version: ${CMSG}${OLD_phpMyAdmin_version}${CEND}"
+  OLD_phpmyadmin_ver=`grep Version ${wwwroot_dir}/default/phpMyAdmin/README | awk '{print $2}'`
+  Latest_phpmyadmin_ver=`curl -s https://www.phpmyadmin.net/files/ | awk -F'>|<' '/\/files\/[0-9]/{print $5}' | head -1`
+  [ -z "$Latest_phpmyadmin_ver" ] && Latest_phpmyadmin_ver=4.8.6
+  echo "Current phpMyAdmin Version: ${CMSG}${OLD_phpmyadmin_ver}${CEND}"
   while :; do echo
-    read -p "Please input upgrade phpMyAdmin Version(default: $Latest_phpMyAdmin_version): " NEW_phpMyAdmin_version
-    [ -z "$NEW_phpMyAdmin_version" ] && NEW_phpMyAdmin_version=$Latest_phpMyAdmin_version
-    if [ "${NEW_phpMyAdmin_version}" != "${OLD_phpMyAdmin_version}" ]; then
-      [ ! -e "phpMyAdmin-${NEW_phpMyAdmin_version}-all-languages.tar.gz" ] && wget --no-check-certificate -c https://files.phpmyadmin.net/phpMyAdmin/${NEW_phpMyAdmin_version}/phpMyAdmin-${NEW_phpMyAdmin_version}-all-languages.tar.gz > /dev/null 2>&1
-      if [ -e "phpMyAdmin-${NEW_phpMyAdmin_version}-all-languages.tar.gz" ]; then
-        echo "Download [${CMSG}phpMyAdmin-${NEW_phpMyAdmin_version}-all-languages.tar.gz${CEND}] successfully! "
+    read -p "Please input upgrade phpMyAdmin Version(default: $Latest_phpmyadmin_ver): " NEW_phpmyadmin_ver
+    [ -z "$NEW_phpmyadmin_ver" ] && NEW_phpmyadmin_ver=$Latest_phpmyadmin_ver
+    if [ "${NEW_phpmyadmin_ver}" != "${OLD_phpmyadmin_ver}" ]; then
+      [ ! -e "phpMyAdmin-${NEW_phpmyadmin_ver}-all-languages.tar.gz" ] && wget --no-check-certificate -c https://files.phpmyadmin.net/phpMyAdmin/${NEW_phpmyadmin_ver}/phpMyAdmin-${NEW_phpmyadmin_ver}-all-languages.tar.gz > /dev/null 2>&1
+      if [ -e "phpMyAdmin-${NEW_phpmyadmin_ver}-all-languages.tar.gz" ]; then
+        echo "Download [${CMSG}phpMyAdmin-${NEW_phpmyadmin_ver}-all-languages.tar.gz${CEND}] successfully! "
         break
       else
         echo "${CWARNING}phpMyAdmin version does not exist! ${CEND}"
@@ -31,20 +31,20 @@ Upgrade_phpMyAdmin() {
     fi
   done
 
-  if [ -e "phpMyAdmin-${NEW_phpMyAdmin_version}-all-languages.tar.gz" ]; then
-    echo "[${CMSG}phpMyAdmin-${NEW_phpMyAdmin_version}-all-languages.tar.gz${CEND}] found"
+  if [ -e "phpMyAdmin-${NEW_phpmyadmin_ver}-all-languages.tar.gz" ]; then
+    echo "[${CMSG}phpMyAdmin-${NEW_phpmyadmin_ver}-all-languages.tar.gz${CEND}] found"
     echo "Press Ctrl+c to cancel or Press any key to continue..."
     char=`get_char`
-    tar xzf phpMyAdmin-${NEW_phpMyAdmin_version}-all-languages.tar.gz
+    tar xzf phpMyAdmin-${NEW_phpmyadmin_ver}-all-languages.tar.gz
     rm -rf ${wwwroot_dir}/default/phpMyAdmin
-    /bin/mv phpMyAdmin-${NEW_phpMyAdmin_version}-all-languages ${wwwroot_dir}/default/phpMyAdmin
+    /bin/mv phpMyAdmin-${NEW_phpmyadmin_ver}-all-languages ${wwwroot_dir}/default/phpMyAdmin
     /bin/cp ${wwwroot_dir}/default/phpMyAdmin/{config.sample.inc.php,config.inc.php}
     mkdir ${wwwroot_dir}/default/phpMyAdmin/{upload,save}
     sed -i "s@UploadDir.*@UploadDir'\] = 'upload';@" ${wwwroot_dir}/default/phpMyAdmin/config.inc.php
     sed -i "s@SaveDir.*@SaveDir'\] = 'save';@" ${wwwroot_dir}/default/phpMyAdmin/config.inc.php
     sed -i "s@blowfish_secret.*;@blowfish_secret\'\] = \'$(cat /dev/urandom | head -1 | base64 | head -c 45)\';@" ${wwwroot_dir}/default/phpMyAdmin/config.inc.php
     chown -R ${run_user}.$run_user ${wwwroot_dir}/default/phpMyAdmin
-    echo "You have ${CMSG}successfully${CEND} upgrade from ${CWARNING}$OLD_phpMyAdmin_version${CEND} to ${CWARNING}$NEW_phpMyAdmin_version${CEND}"
+    echo "You have ${CMSG}successfully${CEND} upgrade from ${CWARNING}$OLD_phpmyadmin_ver${CEND} to ${CWARNING}$NEW_phpmyadmin_ver${CEND}"
   fi
   popd > /dev/null
 }

+ 1 - 1
include/upgrade_redis.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #

+ 56 - 56
include/upgrade_web.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,23 +11,23 @@
 Upgrade_Nginx() {
   pushd ${oneinstack_dir}/src > /dev/null
   [ ! -e "$nginx_install_dir/sbin/nginx" ] && echo "${CWARNING}Nginx is not installed on your system! ${CEND}" && exit 1
-  OLD_Nginx_version_tmp=`$nginx_install_dir/sbin/nginx -v 2>&1`
-  OLD_Nginx_version=${OLD_Nginx_version_tmp##*/}
-  Latest_Nginx_version=`curl -s http://nginx.org/en/CHANGES-1.12 | awk '/Changes with nginx/{print$0}' | awk '{print $4}' | head -1`
-  [ -z "$Latest_Nginx_version" ] && Latest_Nginx_version=`curl -s http://nginx.org/en/CHANGES | awk '/Changes with nginx/{print$0}' | awk '{print $4}' | head -1`
+  OLD_nginx_ver_tmp=`$nginx_install_dir/sbin/nginx -v 2>&1`
+  OLD_nginx_ver=${OLD_nginx_ver_tmp##*/}
+  Latest_nginx_ver=`curl -s http://nginx.org/en/CHANGES-1.12 | awk '/Changes with nginx/{print$0}' | awk '{print $4}' | head -1`
+  [ -z "$Latest_nginx_ver" ] && Latest_nginx_ver=`curl -s http://nginx.org/en/CHANGES | awk '/Changes with nginx/{print$0}' | awk '{print $4}' | head -1`
   echo
-  echo "Current Nginx Version: ${CMSG}$OLD_Nginx_version${CEND}"
+  echo "Current Nginx Version: ${CMSG}$OLD_nginx_ver${CEND}"
   while :; do echo
-    read -p "Please input upgrade Nginx Version(default: $Latest_Nginx_version): " NEW_Nginx_version
-    [ -z "$NEW_Nginx_version" ] && NEW_Nginx_version=$Latest_Nginx_version
-    if [ "$NEW_Nginx_version" != "$OLD_Nginx_version" ]; then
-      [ ! -e "nginx-$NEW_Nginx_version.tar.gz" ] && wget --no-check-certificate -c http://nginx.org/download/nginx-$NEW_Nginx_version.tar.gz > /dev/null 2>&1
-      if [ -e "nginx-$NEW_Nginx_version.tar.gz" ]; then
-        src_url=https://www.openssl.org/source/openssl-$openssl_version.tar.gz && Download_src
-        src_url=http://mirrors.linuxeye.com/oneinstack/src/pcre-$pcre_version.tar.gz && Download_src
-        tar xzf openssl-$openssl_version.tar.gz
-        tar xzf pcre-$pcre_version.tar.gz
-        echo "Download [${CMSG}nginx-$NEW_Nginx_version.tar.gz${CEND}] successfully! "
+    read -p "Please input upgrade Nginx Version(default: $Latest_nginx_ver): " NEW_nginx_ver
+    [ -z "$NEW_nginx_ver" ] && NEW_nginx_ver=$Latest_nginx_ver
+    if [ "$NEW_nginx_ver" != "$OLD_nginx_ver" ]; then
+      [ ! -e "nginx-$NEW_nginx_ver.tar.gz" ] && wget --no-check-certificate -c http://nginx.org/download/nginx-$NEW_nginx_ver.tar.gz > /dev/null 2>&1
+      if [ -e "nginx-$NEW_nginx_ver.tar.gz" ]; then
+        src_url=https://www.openssl.org/source/openssl-$openssl_ver.tar.gz && Download_src
+        src_url=http://mirrors.linuxeye.com/oneinstack/src/pcre-$pcre_ver.tar.gz && Download_src
+        tar xzf openssl-$openssl_ver.tar.gz
+        tar xzf pcre-$pcre_ver.tar.gz
+        echo "Download [${CMSG}nginx-$NEW_nginx_ver.tar.gz${CEND}] successfully! "
         break
       else
         echo "${CWARNING}Nginx version does not exist! ${CEND}"
@@ -37,12 +37,12 @@ Upgrade_Nginx() {
     fi
   done
 
-  if [ -e "nginx-$NEW_Nginx_version.tar.gz" ]; then
-    echo "[${CMSG}nginx-$NEW_Nginx_version.tar.gz${CEND}] found"
+  if [ -e "nginx-$NEW_nginx_ver.tar.gz" ]; then
+    echo "[${CMSG}nginx-$NEW_nginx_ver.tar.gz${CEND}] found"
     echo "Press Ctrl+c to cancel or Press any key to continue..."
     char=`get_char`
-    tar xzf nginx-$NEW_Nginx_version.tar.gz
-    pushd nginx-$NEW_Nginx_version
+    tar xzf nginx-$NEW_nginx_ver.tar.gz
+    pushd nginx-$NEW_nginx_ver
     make clean
     sed -i 's@CFLAGS="$CFLAGS -g"@#CFLAGS="$CFLAGS -g"@' auto/cc/gcc # close debug
     $nginx_install_dir/sbin/nginx -V &> $$
@@ -57,8 +57,8 @@ Upgrade_Nginx() {
       sleep 1
       kill -QUIT `cat /var/run/nginx.pid.oldbin`
       popd > /dev/null
-      echo "You have ${CMSG}successfully${CEND} upgrade from ${CWARNING}$OLD_Nginx_version${CEND} to ${CWARNING}$NEW_Nginx_version${CEND}"
-      rm -rf nginx-$NEW_Nginx_version
+      echo "You have ${CMSG}successfully${CEND} upgrade from ${CWARNING}$OLD_nginx_ver${CEND} to ${CWARNING}$NEW_nginx_ver${CEND}"
+      rm -rf nginx-$NEW_nginx_ver
     else
       echo "${CFAILURE}Upgrade Nginx failed! ${CEND}"
     fi
@@ -80,10 +80,10 @@ Upgrade_Tengine() {
     if [ "$NEW_Tengine_version" != "$OLD_Tengine_version" ]; then
       [ ! -e "tengine-$NEW_Tengine_version.tar.gz" ] && wget --no-check-certificate -c http://tengine.taobao.org/download/tengine-$NEW_Tengine_version.tar.gz > /dev/null 2>&1
       if [ -e "tengine-$NEW_Tengine_version.tar.gz" ]; then
-        src_url=https://www.openssl.org/source/openssl-$openssl_version.tar.gz && Download_src
-        src_url=http://mirrors.linuxeye.com/oneinstack/src/pcre-$pcre_version.tar.gz && Download_src
-        tar xzf openssl-$openssl_version.tar.gz
-        tar xzf pcre-$pcre_version.tar.gz
+        src_url=https://www.openssl.org/source/openssl-$openssl_ver.tar.gz && Download_src
+        src_url=http://mirrors.linuxeye.com/oneinstack/src/pcre-$pcre_ver.tar.gz && Download_src
+        tar xzf openssl-$openssl_ver.tar.gz
+        tar xzf pcre-$pcre_ver.tar.gz
         echo "Download [${CMSG}tengine-$NEW_Tengine_version.tar.gz${CEND}] successfully! "
         break
       else
@@ -142,10 +142,10 @@ Upgrade_OpenResty() {
     if [ "$NEW_OpenResty_version" != "$OLD_OpenResty_version" ]; then
       [ ! -e "openresty-$NEW_OpenResty_version.tar.gz" ] && wget --no-check-certificate -c https://openresty.org/download/openresty-$NEW_OpenResty_version.tar.gz > /dev/null 2>&1
       if [ -e "openresty-$NEW_OpenResty_version.tar.gz" ]; then
-        src_url=https://www.openssl.org/source/openssl-$openssl_version.tar.gz && Download_src
-        src_url=http://mirrors.linuxeye.com/oneinstack/src/pcre-$pcre_version.tar.gz && Download_src
-        tar xzf openssl-$openssl_version.tar.gz
-        tar xzf pcre-$pcre_version.tar.gz
+        src_url=https://www.openssl.org/source/openssl-$openssl_ver.tar.gz && Download_src
+        src_url=http://mirrors.linuxeye.com/oneinstack/src/pcre-$pcre_ver.tar.gz && Download_src
+        tar xzf openssl-$openssl_ver.tar.gz
+        tar xzf pcre-$pcre_ver.tar.gz
         echo "Download [${CMSG}openresty-$NEW_OpenResty_version.tar.gz${CEND}] successfully! "
         break
       else
@@ -163,12 +163,12 @@ Upgrade_OpenResty() {
     tar xzf openresty-$NEW_OpenResty_version.tar.gz
     pushd openresty-$NEW_OpenResty_version
     make clean
-    openresty_version_tmp=${NEW_OpenResty_version%.*}
-    sed -i 's@CFLAGS="$CFLAGS -g"@#CFLAGS="$CFLAGS -g"@' bundle/nginx-$openresty_version_tmp/auto/cc/gcc # close debug
+    openresty_ver_tmp=${NEW_OpenResty_version%.*}
+    sed -i 's@CFLAGS="$CFLAGS -g"@#CFLAGS="$CFLAGS -g"@' bundle/nginx-$openresty_ver_tmp/auto/cc/gcc # close debug
     $openresty_install_dir/nginx/sbin/nginx -V &> $$
-    ./configure --prefix=$openresty_install_dir --user=$run_user --group=$run_user --with-http_stub_status_module --with-http_v2_module --with-http_ssl_module --with-http_gzip_static_module --with-http_realip_module --with-http_flv_module --with-http_mp4_module --with-openssl=../openssl-$openssl_version --with-pcre=../pcre-$pcre_version --with-pcre-jit --with-ld-opt='-ljemalloc' $nginx_modules_options 
+    ./configure --prefix=$openresty_install_dir --user=$run_user --group=$run_user --with-http_stub_status_module --with-http_v2_module --with-http_ssl_module --with-http_gzip_static_module --with-http_realip_module --with-http_flv_module --with-http_mp4_module --with-openssl=../openssl-$openssl_ver --with-pcre=../pcre-$pcre_ver --with-pcre-jit --with-ld-opt='-ljemalloc' $nginx_modules_options 
     make -j ${THREAD}
-    if [ -f "build/nginx-$openresty_version_tmp/objs/nginx" ]; then
+    if [ -f "build/nginx-$openresty_ver_tmp/objs/nginx" ]; then
       /bin/mv $openresty_install_dir/nginx/sbin/nginx{,`date +%m%d`}
       make install
       kill -USR2 `cat /var/run/nginx.pid`
@@ -187,24 +187,24 @@ Upgrade_OpenResty() {
 Upgrade_Apache() {
   pushd ${oneinstack_dir}/src > /dev/null
   [ ! -e "$apache_install_dir/bin/httpd" ] && echo "${CWARNING}Apache is not installed on your system! ${CEND}" && exit 1
-  OLD_Apache_version="`/usr/local/apache/bin/httpd -v | grep version | awk -F'/| ' '{print $4}'`"
-  Apache_flag="`echo $OLD_Apache_version | awk -F. '{print $1 $2}'`"
-  Latest_Apache_version=`curl -s http://httpd.apache.org/download.cgi | awk "/#apache$Apache_flag/{print $2}" | head -1 | grep -oE "2\.[24]\.[0-9]+"`
+  OLD_apache_ver="`/usr/local/apache/bin/httpd -v | grep version | awk -F'/| ' '{print $4}'`"
+  Apache_flag="`echo $OLD_apache_ver | awk -F. '{print $1 $2}'`"
+  Latest_apache_ver=`curl -s http://httpd.apache.org/download.cgi | awk "/#apache$Apache_flag/{print $2}" | head -1 | grep -oE "2\.[24]\.[0-9]+"`
   echo
-  echo "Current Apache Version: ${CMSG}$OLD_Apache_version${CEND}"
+  echo "Current Apache Version: ${CMSG}$OLD_apache_ver${CEND}"
   while :; do echo
-    read -p "Please input upgrade Apache Version(Default: $Latest_Apache_version): " NEW_Apache_version
-    [ -z "$NEW_Apache_version" ] && NEW_Apache_version=$Latest_Apache_version
-    if [ "$NEW_Apache_version" != "$OLD_Apache_version" ]; then
+    read -p "Please input upgrade Apache Version(Default: $Latest_apache_ver): " NEW_apache_ver
+    [ -z "$NEW_apache_ver" ] && NEW_apache_ver=$Latest_apache_ver
+    if [ "$NEW_apache_ver" != "$OLD_apache_ver" ]; then
       if [ "$Apache_flag" == '24' ]; then
-        src_url=http://archive.apache.org/dist/apr/apr-${apr_version}.tar.gz && Download_src
-        src_url=http://archive.apache.org/dist/apr/apr-util-${apr_util_version}.tar.gz && Download_src
-        tar xzf apr-${apr_version}.tar.gz
-        tar xzf apr-util-${apr_util_version}.tar.gz
+        src_url=http://archive.apache.org/dist/apr/apr-${apr_ver}.tar.gz && Download_src
+        src_url=http://archive.apache.org/dist/apr/apr-util-${apr_util_ver}.tar.gz && Download_src
+        tar xzf apr-${apr_ver}.tar.gz
+        tar xzf apr-util-${apr_util_ver}.tar.gz
       fi
-      [ ! -e "httpd-$NEW_Apache_version.tar.gz" ] && wget --no-check-certificate -c http://mirrors.linuxeye.com/apache/httpd/httpd-$NEW_Apache_version.tar.gz > /dev/null 2>&1
-      if [ -e "httpd-$NEW_Apache_version.tar.gz" ]; then
-        echo "Download [${CMSG}apache-$NEW_Apache_version.tar.gz${CEND}] successfully! "
+      [ ! -e "httpd-$NEW_apache_ver.tar.gz" ] && wget --no-check-certificate -c http://mirrors.linuxeye.com/apache/httpd/httpd-$NEW_apache_ver.tar.gz > /dev/null 2>&1
+      if [ -e "httpd-$NEW_apache_ver.tar.gz" ]; then
+        echo "Download [${CMSG}apache-$NEW_apache_ver.tar.gz${CEND}] successfully! "
         break
       else
         echo "${CWARNING}Apache version does not exist! ${CEND}"
@@ -214,16 +214,16 @@ Upgrade_Apache() {
     fi
   done
 
-  if [ -e "httpd-$NEW_Apache_version.tar.gz" ]; then
-    echo "[${CMSG}httpd-$NEW_Apache_version.tar.gz${CEND}] found"
+  if [ -e "httpd-$NEW_apache_ver.tar.gz" ]; then
+    echo "[${CMSG}httpd-$NEW_apache_ver.tar.gz${CEND}] found"
     echo "Press Ctrl+c to cancel or Press any key to continue..."
     char=`get_char`
-    tar xzf httpd-$NEW_Apache_version.tar.gz
-    pushd httpd-$NEW_Apache_version
+    tar xzf httpd-$NEW_apache_ver.tar.gz
+    pushd httpd-$NEW_apache_ver
     make clean
     if [ "$Apache_flag" == '24' ]; then
-      /bin/cp -R ../apr-${apr_version} ./srclib/apr
-      /bin/cp -R ../apr-util-${apr_util_version} ./srclib/apr-util
+      /bin/cp -R ../apr-${apr_ver} ./srclib/apr
+      /bin/cp -R ../apr-util-${apr_util_ver} ./srclib/apr-util
       LDFLAGS=-ldl LD_LIBRARY_PATH=${openssl_install_dir}/lib ./configure --prefix=${apache_install_dir} --with-mpm=prefork --with-included-apr --enable-headers --enable-deflate --enable-so --enable-dav --enable-rewrite --enable-ssl --with-ssl=${openssl_install_dir} --enable-http2 --with-nghttp2=/usr/local --enable-expires --enable-static-support --enable-suexec --enable-modules=all --enable-mods-shared=all
     elif [ "$Apache_flag" == '22' ]; then
       [ "${Ubuntu_version}" == "12" ] && sed -i '@SSL_PROTOCOL_SSLV2@d' modules/ssl/ssl_engine_io.c
@@ -237,8 +237,8 @@ Upgrade_Apache() {
       make install && unset LDFLAGS
       /etc/init.d/httpd start
       popd > /dev/null
-      echo "You have ${CMSG}successfully${CEND} upgrade from ${CWARNING}$OLD_Apache_version${CEND} to ${CWARNING}$NEW_Apache_version${CEND}"
-      rm -rf httpd-$NEW_Apache_version apr-${apr_version} apr-util-${apr_util_version}
+      echo "You have ${CMSG}successfully${CEND} upgrade from ${CWARNING}$OLD_apache_ver${CEND} to ${CWARNING}$NEW_apache_ver${CEND}"
+      rm -rf httpd-$NEW_apache_ver apr-${apr_ver} apr-util-${apr_util_ver}
     else
       echo "${CFAILURE}Upgrade Apache failed! ${CEND}"
     fi

+ 4 - 4
include/xcache.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -11,8 +11,8 @@
 Install_XCache() {
   pushd ${oneinstack_dir}/src
   phpExtensionDir=$(${php_install_dir}/bin/php-config --extension-dir)
-  tar xzf xcache-${xcache_version}.tar.gz
-  pushd xcache-${xcache_version}
+  tar xzf xcache-${xcache_ver}.tar.gz
+  pushd xcache-${xcache_ver}
   ${php_install_dir}/bin/phpize
   ./configure --enable-xcache --enable-xcache-coverager --enable-xcache-optimizer --with-php-config=${php_install_dir}/bin/php-config
   make -j ${THREAD} && make install
@@ -61,7 +61,7 @@ xcache.coverager_autostart = On
 xcache.coveragedump_directory = ""
 EOF
     echo "${CSUCCESS}Xcache module installed successfully! ${CEND}"
-    rm -rf xcache-${xcache_version}
+    rm -rf xcache-${xcache_ver}
   else
     echo "${CFAILURE}Xcache module install failed, Please contact the author! ${CEND}"
   fi

+ 4 - 4
include/zendopcache.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 5+ Debian 6+ and Ubuntu 12+
 #
@@ -14,8 +14,8 @@ Install_ZendOPcache() {
   PHP_detail_version=$(${php_install_dir}/bin/php -r 'echo PHP_VERSION;')
   PHP_main_version=${PHP_detail_version%.*}
   if [[ "${PHP_main_version}" =~ ^5.[3-4]$ ]]; then
-    tar xvf zendopcache-${zendopcache_version}.tgz
-    pushd zendopcache-${zendopcache_version}
+    tar xvf zendopcache-${zendopcache_ver}.tgz
+    pushd zendopcache-${zendopcache_ver}
   else
     tar xvf php-${PHP_detail_version}.tar.gz
     pushd php-${PHP_detail_version}/ext/opcache
@@ -64,7 +64,7 @@ EOF
     fi
 
     echo "${CSUCCESS}PHP OPcache module installed successfully! ${CEND}"
-    rm -rf zendopcache-${zendopcache_version} php-${PHP_detail_version}
+    rm -rf zendopcache-${zendopcache_ver} php-${PHP_detail_version}
   else
     echo "${CFAILURE}PHP OPcache module install failed, Please contact the author! ${CEND}"
   fi

+ 1 - 1
init.d/SS-python-init

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 ### BEGIN INIT INFO
 # Provides:          SS 
 # Required-Start:    $local_fs $remote_fs $network $syslog

+ 163 - 164
install.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #
@@ -36,21 +36,21 @@ mkdir -p $wwwroot_dir/default $wwwlogs_dir
 
 # Use default SSH port 22. If you use another SSH port on your server
 if [ -e "/etc/ssh/sshd_config" ]; then
-  [ -z "`grep ^Port /etc/ssh/sshd_config`" ] && ssh_port=22 || ssh_port=`grep ^Port /etc/ssh/sshd_config | awk '{print $2}'`
+  [ -z "`grep ^Port /etc/ssh/sshd_config`" ] && now_ssh_port=22 || now_ssh_port=`grep ^Port /etc/ssh/sshd_config | awk '{print $2}'`
   while :; do echo
-    read -p "Please input SSH port(Default: $ssh_port): " SSH_PORT
-    [ -z "$SSH_PORT" ] && SSH_PORT=$ssh_port
-    if [ $SSH_PORT -eq 22 >/dev/null 2>&1 -o $SSH_PORT -gt 1024 >/dev/null 2>&1 -a $SSH_PORT -lt 65535 >/dev/null 2>&1 ]; then
+    read -p "Please input SSH port(Default: $now_ssh_port): " ssh_port
+    [ -z "$ssh_port" ] && ssh_port=$now_ssh_port
+    if [ $ssh_port -eq 22 >/dev/null 2>&1 -o $ssh_port -gt 1024 >/dev/null 2>&1 -a $ssh_port -lt 65535 >/dev/null 2>&1 ]; then
       break
     else
       echo "${CWARNING}input error! Input range: 22,1025~65534${CEND}"
     fi
   done
 
-  if [ -z "`grep ^Port /etc/ssh/sshd_config`" -a "$SSH_PORT" != '22' ]; then
-    sed -i "s@^#Port.*@&\nPort $SSH_PORT@" /etc/ssh/sshd_config
+  if [ -z "`grep ^Port /etc/ssh/sshd_config`" -a "$ssh_port" != '22' ]; then
+    sed -i "s@^#Port.*@&\nPort $ssh_port@" /etc/ssh/sshd_config
   elif [ -n "`grep ^Port /etc/ssh/sshd_config`" ]; then
-    sed -i "s@^Port.*@Port $SSH_PORT@" /etc/ssh/sshd_config
+    sed -i "s@^Port.*@Port $ssh_port@" /etc/ssh/sshd_config
   fi
 fi
 
@@ -66,11 +66,11 @@ done
 
 # check Web server
 while :; do echo
-  read -p "Do you want to install Web server? [y/n]: " Web_yn
-  if [[ ! $Web_yn =~ ^[y,n]$ ]]; then
+  read -p "Do you want to install Web server? [y/n]: " web_yn
+  if [[ ! $web_yn =~ ^[y,n]$ ]]; then
     echo "${CWARNING}input error! Please only input 'y' or 'n'${CEND}"
   else
-    if [ "$Web_yn" == 'y' ]; then
+    if [ "$web_yn" == 'y' ]; then
       # Nginx/Tegine/OpenResty
       while :; do echo
         echo 'Please select Nginx server:'
@@ -78,14 +78,14 @@ while :; do echo
         echo -e "\t${CMSG}2${CEND}. Install Tengine"
         echo -e "\t${CMSG}3${CEND}. Install OpenResty"
         echo -e "\t${CMSG}4${CEND}. Do not install"
-        read -p "Please input a number:(Default 1 press Enter) " Nginx_version
-        [ -z "$Nginx_version" ] && Nginx_version=1
-        if [[ ! $Nginx_version =~ ^[1-4]$ ]]; then
+        read -p "Please input a number:(Default 1 press Enter) " nginx_ver
+        [ -z "$nginx_ver" ] && nginx_ver=1
+        if [[ ! $nginx_ver =~ ^[1-4]$ ]]; then
           echo "${CWARNING}input error! Please only input number 1~4${CEND}"
         else
-          [ "$Nginx_version" != '4' -a -e "$nginx_install_dir/sbin/nginx" ] && { echo "${CWARNING}Nginx already installed! ${CEND}"; Nginx_version=Other; }
-          [ "$Nginx_version" != '4' -a -e "$tengine_install_dir/sbin/nginx" ] && { echo "${CWARNING}Tengine already installed! ${CEND}"; Nginx_version=Other; }
-          [ "$Nginx_version" != '4' -a -e "$openresty_install_dir/nginx/sbin/nginx" ] && { echo "${CWARNING}OpenResty already installed! ${CEND}"; Nginx_version=Other; }
+          [ "$nginx_ver" != '4' -a -e "$nginx_install_dir/sbin/nginx" ] && { echo "${CWARNING}Nginx already installed! ${CEND}"; nginx_ver=Other; }
+          [ "$nginx_ver" != '4' -a -e "$tengine_install_dir/sbin/nginx" ] && { echo "${CWARNING}Tengine already installed! ${CEND}"; nginx_ver=Other; }
+          [ "$nginx_ver" != '4' -a -e "$openresty_install_dir/nginx/sbin/nginx" ] && { echo "${CWARNING}OpenResty already installed! ${CEND}"; nginx_ver=Other; }
           break
         fi
       done
@@ -95,12 +95,12 @@ while :; do echo
         echo -e "\t${CMSG}1${CEND}. Install Apache-2.4"
         echo -e "\t${CMSG}2${CEND}. Install Apache-2.2"
         echo -e "\t${CMSG}3${CEND}. Do not install"
-        read -p "Please input a number:(Default 3 press Enter) " Apache_version
-        [ -z "$Apache_version" ] && Apache_version=3
-        if [[ ! $Apache_version =~ ^[1-3]$ ]]; then
+        read -p "Please input a number:(Default 3 press Enter) " apache_ver
+        [ -z "$apache_ver" ] && apache_ver=3
+        if [[ ! $apache_ver =~ ^[1-3]$ ]]; then
           echo "${CWARNING}input error! Please only input number 1~3${CEND}"
         else
-          [ "$Apache_version" != '3' -a -e "$apache_install_dir/conf/httpd.conf" ] && { echo "${CWARNING}Aapche already installed! ${CEND}"; Apache_version=Other; }
+          [ "$apache_ver" != '3' -a -e "$apache_install_dir/conf/httpd.conf" ] && { echo "${CWARNING}Aapche already installed! ${CEND}"; apache_ver=Other; }
           break
         fi
       done
@@ -111,47 +111,47 @@ while :; do echo
         echo -e "\t${CMSG}2${CEND}. Install Tomcat-7"
         echo -e "\t${CMSG}3${CEND}. Install Tomcat-6"
         echo -e "\t${CMSG}4${CEND}. Do not install"
-        read -p "Please input a number:(Default 4 press Enter) " Tomcat_version
-        [ -z "$Tomcat_version" ] && Tomcat_version=4
-        if [[ ! $Tomcat_version =~ ^[1-4]$ ]]; then
+        read -p "Please input a number:(Default 4 press Enter) " tomcat_ver
+        [ -z "$tomcat_ver" ] && tomcat_ver=4
+        if [[ ! $tomcat_ver =~ ^[1-4]$ ]]; then
           echo "${CWARNING}input error! Please only input number 1~4${CEND}"
         else
-          [ "$Tomcat_version" != '4' -a -e "$tomcat_install_dir/conf/server.xml" ] && { echo "${CWARNING}Tomcat already installed! ${CEND}" ; Tomcat_version=Other; }
-          if [ "$Tomcat_version" == '1' ]; then
+          [ "$tomcat_ver" != '4' -a -e "$tomcat_install_dir/conf/server.xml" ] && { echo "${CWARNING}Tomcat already installed! ${CEND}" ; tomcat_ver=Other; }
+          if [ "$tomcat_ver" == '1' ]; then
             while :; do echo
               echo 'Please select JDK version:'
               echo -e "\t${CMSG}1${CEND}. Install JDK-1.8"
               echo -e "\t${CMSG}2${CEND}. Install JDK-1.7"
-              read -p "Please input a number:(Default 2 press Enter) " JDK_version
-              [ -z "$JDK_version" ] && JDK_version=2
-              if [[ ! $JDK_version =~ ^[1-2]$ ]]; then
+              read -p "Please input a number:(Default 2 press Enter) " jdk_version
+              [ -z "$jdk_version" ] && jdk_version=2
+              if [[ ! $jdk_version =~ ^[1-2]$ ]]; then
                 echo "${CWARNING}input error! Please only input number 1~2${CEND}"
               else
                 break
               fi
             done
-          elif [ "$Tomcat_version" == '2' ]; then
+          elif [ "$tomcat_ver" == '2' ]; then
             while :; do echo
               echo 'Please select JDK version:'
               echo -e "\t${CMSG}1${CEND}. Install JDK-1.8"
               echo -e "\t${CMSG}2${CEND}. Install JDK-1.7"
               echo -e "\t${CMSG}3${CEND}. Install JDK-1.6"
-              read -p "Please input a number:(Default 2 press Enter) " JDK_version
-              [ -z "$JDK_version" ] && JDK_version=2
-              if [[ ! $JDK_version =~ ^[1-3]$ ]]; then
+              read -p "Please input a number:(Default 2 press Enter) " jdk_version
+              [ -z "$jdk_version" ] && jdk_version=2
+              if [[ ! $jdk_version =~ ^[1-3]$ ]]; then
                 echo "${CWARNING}input error! Please only input number 1~3${CEND}"
               else
                 break
               fi
             done
-          elif [ "$Tomcat_version" == '3' ]; then
+          elif [ "$tomcat_ver" == '3' ]; then
             while :; do echo
               echo 'Please select JDK version:'
               echo -e "\t${CMSG}2${CEND}. Install JDK-1.7"
               echo -e "\t${CMSG}3${CEND}. Install JDK-1.6"
-              read -p "Please input a number:(Default 2 press Enter) " JDK_version
-              [ -z "$JDK_version" ] && JDK_version=2
-              if [[ ! $JDK_version =~ ^[2-3]$ ]]; then
+              read -p "Please input a number:(Default 2 press Enter) " jdk_version
+              [ -z "$jdk_version" ] && jdk_version=2
+              if [[ ! $jdk_version =~ ^[2-3]$ ]]; then
                 echo "${CWARNING}input error! Please only input number 2~3${CEND}"
               else
                 break
@@ -168,12 +168,12 @@ done
 
 # choice database
 while :; do echo
-  read -p "Do you want to install Database? [y/n]: " DB_yn
-  if [[ ! $DB_yn =~ ^[y,n]$ ]]; then
+  read -p "Do you want to install Database? [y/n]: " db_yn
+  if [[ ! $db_yn =~ ^[y,n]$ ]]; then
     echo "${CWARNING}input error! Please only input 'y' or 'n'${CEND}"
   else
-    if [ "$DB_yn" == 'y' ]; then
-      [ -d "$db_install_dir/support-files" -a -e "${pgsql_install_dir}/bin/psql" -a -e "${mongo_install_dir}/bin/mongo" ] && { echo "${CWARNING}Database already installed! ${CEND}"; DB_yn=Other; break; }
+    if [ "$db_yn" == 'y' ]; then
+      [ -d "$db_install_dir/support-files" -a -e "${pgsql_install_dir}/bin/psql" -a -e "${mongo_install_dir}/bin/mongo" ] && { echo "${CWARNING}Database already installed! ${CEND}"; db_yn=Other; break; }
       while :; do echo
         echo 'Please select a version of the Database:'
         echo -e "\t${CMSG} 1${CEND}. Install MySQL-5.7"
@@ -189,22 +189,22 @@ while :; do echo
         echo -e "\t${CMSG}11${CEND}. Install AliSQL-5.6"
         echo -e "\t${CMSG}12${CEND}. Install PostgreSQL"
         echo -e "\t${CMSG}13${CEND}. Install MongoDB"
-        read -p "Please input a number:(Default 2 press Enter) " DB_version
-        [ -z "$DB_version" ] && DB_version=2
-        [ "$DB_version" == '13' -a "$OS_BIT" == '32' ] && { echo "${CWARNING}By not supporting 32-bit! ${CEND}"; continue; }
-        if [[ "${DB_version}" =~ ^[1-9]$|^1[0-3]$ ]]; then
+        read -p "Please input a number:(Default 2 press Enter) " db_ver
+        [ -z "$db_ver" ] && db_ver=2
+        [ "$db_ver" == '13' -a "$OS_BIT" == '32' ] && { echo "${CWARNING}By not supporting 32-bit! ${CEND}"; continue; }
+        if [[ "${db_ver}" =~ ^[1-9]$|^1[0-3]$ ]]; then
           while :; do
-            if [ "$DB_version" == '12' ]; then
+            if [ "$db_ver" == '12' ]; then
               read -p "Please input the postgres password of database: " dbrootpwd
             else
               read -p "Please input the root password of database: " dbrootpwd
             fi
             [ -n "`echo $dbrootpwd | grep '[+|&]'`" ] && { echo "${CWARNING}input error,not contain a plus sign (+) and & ${CEND}"; continue; }
             if (( ${#dbrootpwd} >= 5 )); then
-              if [ "$DB_version" == '12' ]; then
+              if [ "$db_ver" == '12' ]; then
                 sed -i "s+^dbpostgrespwd.*+dbpostgrespwd='$dbrootpwd'+" ./options.conf
                 dbpostgrespwd="$dbrootpwd"
-              elif [ "$DB_version" == '13' ]; then
+              elif [ "$db_ver" == '13' ]; then
                 sed -i "s+^dbmongopwd.*+dbmongopwd='$dbrootpwd'+" ./options.conf
                 dbmongopwd="$dbrootpwd"
               else
@@ -217,14 +217,14 @@ while :; do echo
 
           done
           # choose install methods
-          if [[ "${DB_version}" =~ ^[1-9]$|^10$ ]]; then 
+          if [[ "${db_ver}" =~ ^[1-9]$|^10$ ]]; then 
             while :; do echo
               echo "Please choose installation of the database:"
               echo -e "\t${CMSG}1${CEND}. Install database from binary package."
               echo -e "\t${CMSG}2${CEND}. Install database from source package."
-              read -p "Please input a number:(Default 1 press Enter) " dbInstallMethods
-              [ -z "$dbInstallMethods" ] && dbInstallMethods=1
-              if [[ ! $dbInstallMethods =~ ^[1-2]$ ]]; then
+              read -p "Please input a number:(Default 1 press Enter) " dbinstallmethod
+              [ -z "$dbinstallmethod" ] && dbinstallmethod=1
+              if [[ ! $dbinstallmethod =~ ^[1-2]$ ]]; then
                 echo "${CWARNING}input error! Please only input number 1~2${CEND}"
               else
                 break
@@ -243,12 +243,12 @@ done
 
 # check PHP
 while :; do echo
-  read -p "Do you want to install PHP? [y/n]: " PHP_yn
-  if [[ ! $PHP_yn =~ ^[y,n]$ ]]; then
+  read -p "Do you want to install PHP? [y/n]: " php_yn
+  if [[ ! $php_yn =~ ^[y,n]$ ]]; then
     echo "${CWARNING}input error! Please only input 'y' or 'n'${CEND}"
   else
-    if [ "$PHP_yn" == 'y' ]; then
-      [ -e "$php_install_dir/bin/phpize" ] && { echo "${CWARNING}PHP already installed! ${CEND}"; PHP_yn=Other; break; }
+    if [ "$php_yn" == 'y' ]; then
+      [ -e "$php_install_dir/bin/phpize" ] && { echo "${CWARNING}PHP already installed! ${CEND}"; php_yn=Other; break; }
       while :; do echo
         echo 'Please select a version of the PHP:'
         echo -e "\t${CMSG}1${CEND}. Install php-5.3"
@@ -258,108 +258,108 @@ while :; do echo
         echo -e "\t${CMSG}5${CEND}. Install php-7.0"
         echo -e "\t${CMSG}6${CEND}. Install php-7.1"
         echo -e "\t${CMSG}7${CEND}. Install php-7.2"
-        read -p "Please input a number:(Default 5 press Enter) " PHP_version
-        [ -z "$PHP_version" ] && PHP_version=5
-        if [[ ! $PHP_version =~ ^[1-7]$ ]]; then
+        read -p "Please input a number:(Default 5 press Enter) " php_ver
+        [ -z "$php_ver" ] && php_ver=5
+        if [[ ! $php_ver =~ ^[1-7]$ ]]; then
           echo "${CWARNING}input error! Please only input number 1~7${CEND}"
         else
           while :; do echo
-            read -p "Do you want to install opcode cache of the PHP? [y/n]: " PHP_cache_yn
-            if [[ ! $PHP_cache_yn =~ ^[y,n]$ ]]; then
+            read -p "Do you want to install opcode cache of the PHP? [y/n]: " php_cache_yn
+            if [[ ! $php_cache_yn =~ ^[y,n]$ ]]; then
                 echo "${CWARNING}input error! Please only input 'y' or 'n'${CEND}"
             else
-              if [ "$PHP_cache_yn" == 'y' ]; then
-                if [ $PHP_version == 1 ]; then
+              if [ "$php_cache_yn" == 'y' ]; then
+                if [ $php_ver == 1 ]; then
                   while :; do
                     echo 'Please select a opcode cache of the PHP:'
                     echo -e "\t${CMSG}1${CEND}. Install Zend OPcache"
                     echo -e "\t${CMSG}2${CEND}. Install XCache"
                     echo -e "\t${CMSG}3${CEND}. Install APCU"
                     echo -e "\t${CMSG}4${CEND}. Install eAccelerator-0.9"
-                    read -p "Please input a number:(Default 1 press Enter) " PHP_cache
-                    [ -z "$PHP_cache" ] && PHP_cache=1
-                    if [[ ! $PHP_cache =~ ^[1-4]$ ]]; then
+                    read -p "Please input a number:(Default 1 press Enter) " php_cache
+                    [ -z "$php_cache" ] && php_cache=1
+                    if [[ ! $php_cache =~ ^[1-4]$ ]]; then
                       echo "${CWARNING}input error! Please only input number 1~4${CEND}"
                     else
                       break
                     fi
                   done
                 fi
-                if [ $PHP_version == 2 ]; then
+                if [ $php_ver == 2 ]; then
                   while :; do
                     echo 'Please select a opcode cache of the PHP:'
                     echo -e "\t${CMSG}1${CEND}. Install Zend OPcache"
                     echo -e "\t${CMSG}2${CEND}. Install XCache"
                     echo -e "\t${CMSG}3${CEND}. Install APCU"
                     echo -e "\t${CMSG}4${CEND}. Install eAccelerator-1.0-dev"
-                    read -p "Please input a number:(Default 1 press Enter) " PHP_cache
-                    [ -z "$PHP_cache" ] && PHP_cache=1
-                    if [[ ! $PHP_cache =~ ^[1-4]$ ]]; then
+                    read -p "Please input a number:(Default 1 press Enter) " php_cache
+                    [ -z "$php_cache" ] && php_cache=1
+                    if [[ ! $php_cache =~ ^[1-4]$ ]]; then
                       echo "${CWARNING}input error! Please only input number 1~4${CEND}"
                     else
                       break
                     fi
                   done
                 fi
-                if [ $PHP_version == 3 ]; then
+                if [ $php_ver == 3 ]; then
                   while :; do
                     echo 'Please select a opcode cache of the PHP:'
                     echo -e "\t${CMSG}1${CEND}. Install Zend OPcache"
                     echo -e "\t${CMSG}2${CEND}. Install XCache"
                     echo -e "\t${CMSG}3${CEND}. Install APCU"
-                    read -p "Please input a number:(Default 1 press Enter) " PHP_cache
-                    [ -z "$PHP_cache" ] && PHP_cache=1
-                    if [[ ! $PHP_cache =~ ^[1-3]$ ]]; then
+                    read -p "Please input a number:(Default 1 press Enter) " php_cache
+                    [ -z "$php_cache" ] && php_cache=1
+                    if [[ ! $php_cache =~ ^[1-3]$ ]]; then
                       echo "${CWARNING}input error! Please only input number 1~3${CEND}"
                     else
                       break
                     fi
                   done
                 fi
-                if [ $PHP_version == 4 ]; then
+                if [ $php_ver == 4 ]; then
                   while :; do
                     echo 'Please select a opcode cache of the PHP:'
                     echo -e "\t${CMSG}1${CEND}. Install Zend OPcache"
                     echo -e "\t${CMSG}2${CEND}. Install XCache"
                     echo -e "\t${CMSG}3${CEND}. Install APCU"
-                    read -p "Please input a number:(Default 1 press Enter) " PHP_cache
-                    [ -z "$PHP_cache" ] && PHP_cache=1
-                    if [[ ! $PHP_cache =~ ^[1-3]$ ]]; then
+                    read -p "Please input a number:(Default 1 press Enter) " php_cache
+                    [ -z "$php_cache" ] && php_cache=1
+                    if [[ ! $php_cache =~ ^[1-3]$ ]]; then
                       echo "${CWARNING}input error! Please only input number 1~3${CEND}"
                     else
                       break
                     fi
                   done
                 fi
-                if [[ $PHP_version =~ ^[5-6]$ ]]; then 
+                if [[ $php_ver =~ ^[5-6]$ ]]; then 
                   while :; do
                     echo 'Please select a opcode cache of the PHP:'
                     echo -e "\t${CMSG}1${CEND}. Install Zend OPcache"
                     echo -e "\t${CMSG}3${CEND}. Install APCU"
-                    read -p "Please input a number:(Default 1 press Enter) " PHP_cache
-                    [ -z "$PHP_cache" ] && PHP_cache=1
-                    if [[ ! $PHP_cache =~ ^[1,3]$ ]]; then
+                    read -p "Please input a number:(Default 1 press Enter) " php_cache
+                    [ -z "$php_cache" ] && php_cache=1
+                    if [[ ! $php_cache =~ ^[1,3]$ ]]; then
                       echo "${CWARNING}input error! Please only input number 1,3${CEND}"
                     else
                       break
                     fi
                   done
                 fi
-                [ $PHP_version == 7 ] && PHP_cache=1
+                [ $php_ver == 7 ] && php_cache=1
               fi
               break
             fi
           done
-          if [ "$PHP_cache" == '2' ]; then
+          if [ "$php_cache" == '2' ]; then
             while :; do
               read -p "Please input xcache admin password: " xcache_admin_pass
               (( ${#xcache_admin_pass} >= 5 )) && { xcache_admin_md5_pass=`echo -n "$xcache_admin_pass" | md5sum | awk '{print $1}'` ; break ; } || echo "${CFAILURE}xcache admin password least 5 characters! ${CEND}"
             done
           fi
-          if [[ $PHP_version =~ ^[1-4]$ ]] && [ "$PHP_cache" != '1' -a "${armPlatform}" != "y" ]; then
+          if [[ $php_ver =~ ^[1-4]$ ]] && [ "$php_cache" != '1' -a "${armplatform}" != "y" ]; then
             while :; do echo
-              read -p "Do you want to install ZendGuardLoader? [y/n]: " ZendGuardLoader_yn
-              if [[ ! $ZendGuardLoader_yn =~ ^[y,n]$ ]]; then
+              read -p "Do you want to install ZendGuardLoader? [y/n]: " zendguardloader_yn
+              if [[ ! $zendguardloader_yn =~ ^[y,n]$ ]]; then
                 echo "${CWARNING}input error! Please only input 'y' or 'n'${CEND}"
               else
                 break
@@ -370,8 +370,8 @@ while :; do echo
           # ionCube
           if [ "${TARGET_ARCH}" != "arm64" ]; then
             while :; do echo
-              read -p "Do you want to install ionCube? [y/n]: " ionCube_yn
-              if [[ ! $ionCube_yn =~ ^[y,n]$ ]]; then
+              read -p "Do you want to install ionCube? [y/n]: " ioncube_yn
+              if [[ ! $ioncube_yn =~ ^[y,n]$ ]]; then
                 echo "${CWARNING}input error! Please only input 'y' or 'n'${CEND}"
               else
                 break
@@ -381,22 +381,22 @@ while :; do echo
 
           # ImageMagick or GraphicsMagick
           while :; do echo
-            read -p "Do you want to install ImageMagick or GraphicsMagick? [y/n]: " Magick_yn
-            if [[ ! $Magick_yn =~ ^[y,n]$ ]]; then
+            read -p "Do you want to install ImageMagick or GraphicsMagick? [y/n]: " magick_yn
+            if [[ ! $magick_yn =~ ^[y,n]$ ]]; then
               echo "${CWARNING}input error! Please only input 'y' or 'n'${CEND}"
             else
               break
             fi
           done
 
-          if [ "$Magick_yn" == 'y' ]; then
+          if [ "$magick_yn" == 'y' ]; then
             while :; do
               echo 'Please select ImageMagick or GraphicsMagick:'
               echo -e "\t${CMSG}1${CEND}. Install ImageMagick"
               echo -e "\t${CMSG}2${CEND}. Install GraphicsMagick"
-              read -p "Please input a number:(Default 1 press Enter) " Magick
-              [ -z "$Magick" ] && Magick=1
-              if [[ ! $Magick =~ ^[1-2]$ ]]; then
+              read -p "Please input a number:(Default 1 press Enter) " magick
+              [ -z "$magick" ] && magick=1
+              if [[ ! $magick =~ ^[1-2]$ ]]; then
                 echo "${CWARNING}input error! Please only input number 1~2${CEND}"
               else
                 break
@@ -413,23 +413,23 @@ done
 
 # check Pureftpd
 while :; do echo
-  read -p "Do you want to install Pure-FTPd? [y/n]: " FTP_yn
-  if [[ ! $FTP_yn =~ ^[y,n]$ ]]; then
+  read -p "Do you want to install Pure-FTPd? [y/n]: " ftp_yn
+  if [[ ! $ftp_yn =~ ^[y,n]$ ]]; then
     echo "${CWARNING}input error! Please only input 'y' or 'n'${CEND}"
   else
-    [ "$FTP_yn" == 'y' -a -e "$pureftpd_install_dir/sbin/pure-ftpwho" ] && { echo "${CWARNING}Pure-FTPd already installed! ${CEND}"; FTP_yn=Other; }
+    [ "$ftp_yn" == 'y' -a -e "$pureftpd_install_dir/sbin/pure-ftpwho" ] && { echo "${CWARNING}Pure-FTPd already installed! ${CEND}"; ftp_yn=Other; }
     break
   fi
 done
 
 # check phpMyAdmin
-if [[ $PHP_version =~ ^[1-7]$ ]] || [ -e "$php_install_dir/bin/phpize" ]; then
+if [[ $php_ver =~ ^[1-7]$ ]] || [ -e "$php_install_dir/bin/phpize" ]; then
   while :; do echo
-    read -p "Do you want to install phpMyAdmin? [y/n]: " phpMyAdmin_yn
-    if [[ ! $phpMyAdmin_yn =~ ^[y,n]$ ]]; then
+    read -p "Do you want to install phpMyAdmin? [y/n]: " phpmyadmin_yn
+    if [[ ! $phpmyadmin_yn =~ ^[y,n]$ ]]; then
       echo "${CWARNING}input error! Please only input 'y' or 'n'${CEND}"
     else
-      [ "$phpMyAdmin_yn" == 'y' -a -d "$wwwroot_dir/default/phpMyAdmin" ] && { echo "${CWARNING}phpMyAdmin already installed! ${CEND}"; phpMyAdmin_yn=Other; }
+      [ "$phpmyadmin_yn" == 'y' -a -d "$wwwroot_dir/default/phpMyAdmin" ] && { echo "${CWARNING}phpMyAdmin already installed! ${CEND}"; phpmyadmin_yn=Other; }
       break
     fi
   done
@@ -456,12 +456,12 @@ while :; do echo
 done
 
 while :; do echo
-  read -p "Do you want to install HHVM? [y/n]: " HHVM_yn
-  if [[ ! $HHVM_yn =~ ^[y,n]$ ]]; then
+  read -p "Do you want to install HHVM? [y/n]: " hhvm_yn
+  if [[ ! $hhvm_yn =~ ^[y,n]$ ]]; then
     echo "${CWARNING}input error! Please only input 'y' or 'n'${CEND}"
   else
-    if [ "$HHVM_yn" == 'y' ]; then
-      [ -e "/usr/bin/hhvm" ] && { echo "${CWARNING}HHVM already installed! ${CEND}"; HHVM_yn=Other; break; }
+    if [ "$hhvm_yn" == 'y' ]; then
+      [ -e "/usr/bin/hhvm" ] && { echo "${CWARNING}HHVM already installed! ${CEND}"; hhvm_yn=Other; break; }
       if [ "$OS" == 'CentOS' -a "$OS_BIT" == '64' ] && [ -n "`grep -E ' 7\.| 6\.[5-9]' /etc/redhat-release`" ]; then
         break
       else
@@ -469,7 +469,7 @@ while :; do echo
         echo "${CWARNING}HHVM only support CentOS6.5+ 64bit, CentOS7 64bit! ${CEND}"
         echo "Press Ctrl+c to cancel or Press any key to continue..."
         char=`get_char`
-        HHVM_yn=Other
+        hhvm_yn=Other
       fi
     fi
     break
@@ -481,7 +481,6 @@ IPADDR=`./include/get_ipaddr.py`
 PUBLIC_IPADDR=`./include/get_public_ipaddr.py`
 IPADDR_COUNTRY_ISP=`./include/get_ipaddr_state.py $PUBLIC_IPADDR`
 IPADDR_COUNTRY=`echo $IPADDR_COUNTRY_ISP | awk '{print $1}'`
-[ "`echo $IPADDR_COUNTRY_ISP | awk '{print $2}'`"x == '1000323'x ] && IPADDR_ISP=aliyun
 
 # del openssl for jcloud
 [ -e "/usr/local/bin/openssl" ] && rm -rf /usr/local/bin/openssl
@@ -526,21 +525,21 @@ checkDownload 2>&1 | tee -a ${oneinstack_dir}/install.log
 installDepsBySrc 2>&1 | tee -a ${oneinstack_dir}/install.log
 
 # Jemalloc
-if [[ $Nginx_version =~ ^[1-3]$ ]] || [ "$DB_yn" == 'y' ]; then
+if [[ $nginx_ver =~ ^[1-3]$ ]] || [ "$db_yn" == 'y' ]; then
   . include/jemalloc.sh
   Install_Jemalloc | tee -a $oneinstack_dir/install.log
 fi
 
 # openSSL 
 . ./include/openssl.sh
-if [[ $Tomcat_version =~ ^[1-3]$ ]] || [[ $Apache_version =~ ^[1-2]$ ]] || [[ $PHP_version =~ ^[1-7]$ ]]; then
+if [[ $tomcat_ver =~ ^[1-3]$ ]] || [[ $apache_ver =~ ^[1-2]$ ]] || [[ $php_ver =~ ^[1-7]$ ]]; then
   Install_openSSL102 | tee -a $oneinstack_dir/install.log
 fi
 
 # Database
-case "${DB_version}" in
+case "${db_ver}" in
   1)
-    if [ "${dbInstallMethods}" == "2" ]; then
+    if [ "${dbinstallmethod}" == "2" ]; then
       . include/boost.sh
       installBoost 2>&1 | tee -a ${oneinstack_dir}/install.log
     fi
@@ -556,7 +555,7 @@ case "${DB_version}" in
     Install_MySQL55 2>&1 | tee -a ${oneinstack_dir}/install.log
     ;;
   4)
-    if [ "${dbInstallMethods}" == "2" ]; then
+    if [ "${dbinstallmethod}" == "2" ]; then
       . include/boost.sh
       installBoost 2>&1 | tee -a ${oneinstack_dir}/install.log
     fi
@@ -564,7 +563,7 @@ case "${DB_version}" in
     Install_MariaDB102 2>&1 | tee -a ${oneinstack_dir}/install.log
     ;;
   5)
-    if [ "${dbInstallMethods}" == "2" ]; then
+    if [ "${dbinstallmethod}" == "2" ]; then
       . include/boost.sh
       installBoost 2>&1 | tee -a ${oneinstack_dir}/install.log
     fi
@@ -580,7 +579,7 @@ case "${DB_version}" in
     Install_MariaDB55 2>&1 | tee -a ${oneinstack_dir}/install.log
     ;;
   8)
-    if [ "${dbInstallMethods}" == "2" ]; then
+    if [ "${dbinstallmethod}" == "2" ]; then
       . include/boost.sh
       installBoost 2>&1 | tee -a ${oneinstack_dir}/install.log
     fi
@@ -610,16 +609,16 @@ case "${DB_version}" in
 esac
 
 # Apache
-if [ "$Apache_version" == '1' ]; then
+if [ "$apache_ver" == '1' ]; then
   . include/apache-2.4.sh
   Install_Apache24 2>&1 | tee -a $oneinstack_dir/install.log
-elif [ "$Apache_version" == '2' ]; then
+elif [ "$apache_ver" == '2' ]; then
   . include/apache-2.2.sh
   Install_Apache22 2>&1 | tee -a $oneinstack_dir/install.log
 fi
 
 # PHP
-case "${PHP_version}" in
+case "${php_ver}" in
   1)
     . include/php-5.3.sh
     Install_PHP53 2>&1 | tee -a ${oneinstack_dir}/install.log
@@ -651,38 +650,38 @@ case "${PHP_version}" in
 esac
 
 # pecl_pgsql
-if [ "${DB_version}" == '12' -a -e "${php_install_dir}/bin/phpize" ]; then
+if [ "${db_ver}" == '12' -a -e "${php_install_dir}/bin/phpize" ]; then
   . include/pecl_pgsql.sh
   Install_pecl-pgsql 2>&1 | tee -a $oneinstack_dir/install.log
 fi
 
 # pecl_mongodb
-if [ "${DB_version}" == '13' -a -e "${php_install_dir}/bin/phpize" ]; then
+if [ "${db_ver}" == '13' -a -e "${php_install_dir}/bin/phpize" ]; then
   . include/pecl_mongodb.sh
   Install_pecl-mongodb 2>&1 | tee -a $oneinstack_dir/install.log
 fi
 
 # ImageMagick or GraphicsMagick
-if [ "$Magick" == '1' ]; then
+if [ "$magick" == '1' ]; then
   . include/ImageMagick.sh
   [ ! -d "/usr/local/imagemagick" ] && Install_ImageMagick 2>&1 | tee -a $oneinstack_dir/install.log
   [ ! -e "`$php_install_dir/bin/php-config --extension-dir`/imagick.so" ] && Install_php-imagick 2>&1 | tee -a $oneinstack_dir/install.log
-elif [ "$Magick" == '2' ]; then
+elif [ "$magick" == '2' ]; then
   . include/GraphicsMagick.sh
   [ ! -d "/usr/local/graphicsmagick" ] && Install_GraphicsMagick 2>&1 | tee -a $oneinstack_dir/install.log
   [ ! -e "`$php_install_dir/bin/php-config --extension-dir`/gmagick.so" ] && Install_php-gmagick 2>&1 | tee -a $oneinstack_dir/install.log
 fi
 
 # ionCube
-if [ "$ionCube_yn" == 'y' ]; then
+if [ "$ioncube_yn" == 'y' ]; then
   . include/ioncube.sh
   Install_ionCube 2>&1 | tee -a $oneinstack_dir/install.log
 fi
 
 # PHP opcode cache
-case "${PHP_cache}" in
+case "${php_cache}" in
   1)
-    if [[ "${PHP_version}" =~ ^[1,2]$ ]]; then
+    if [[ "${php_ver}" =~ ^[1,2]$ ]]; then
       . include/zendopcache.sh
       Install_ZendOPcache 2>&1 | tee -a ${oneinstack_dir}/install.log
     fi
@@ -696,7 +695,7 @@ case "${PHP_cache}" in
     Install_APCU 2>&1 | tee -a ${oneinstack_dir}/install.log
     ;;
   4)
-    if [[ "${PHP_version}" =~ ^[1,2]$ ]]; then
+    if [[ "${php_ver}" =~ ^[1,2]$ ]]; then
       . include/eaccelerator.sh
       Install_eAccelerator 2>&1 | tee -a ${oneinstack_dir}/install.log
     fi
@@ -704,13 +703,13 @@ case "${PHP_cache}" in
 esac
 
 # ZendGuardLoader (php <= 5.6)
-if [ "$ZendGuardLoader_yn" == 'y' ]; then
+if [ "$zendguardloader_yn" == 'y' ]; then
   . include/ZendGuardLoader.sh
   Install_ZendGuardLoader 2>&1 | tee -a $oneinstack_dir/install.log
 fi
 
 # Web server
-case "${Nginx_version}" in
+case "${nginx_ver}" in
   1)
     . include/nginx.sh
     Install_Nginx 2>&1 | tee -a ${oneinstack_dir}/install.log
@@ -726,7 +725,7 @@ case "${Nginx_version}" in
 esac
 
 # JDK
-case "${JDK_version}" in
+case "${jdk_version}" in
   1)
     . include/jdk-1.8.sh
     Install-JDK18 2>&1 | tee -a ${oneinstack_dir}/install.log
@@ -741,7 +740,7 @@ case "${JDK_version}" in
     ;;
 esac
 
-case "${Tomcat_version}" in
+case "${tomcat_ver}" in
   1)
     . include/tomcat-8.sh
     Install_Tomcat8 2>&1 | tee -a ${oneinstack_dir}/install.log
@@ -757,13 +756,13 @@ case "${Tomcat_version}" in
 esac
 
 # Pure-FTPd
-if [ "${FTP_yn}" == 'y' ]; then
+if [ "${ftp_yn}" == 'y' ]; then
   . include/pureftpd.sh
   Install_PureFTPd 2>&1 | tee -a ${oneinstack_dir}/install.log
 fi
 
 # phpMyAdmin
-if [ "${phpMyAdmin_yn}" == 'y' ]; then
+if [ "${phpmyadmin_yn}" == 'y' ]; then
   . include/phpmyadmin.sh
   Install_phpMyAdmin 2>&1 | tee -a ${oneinstack_dir}/install.log
 fi
@@ -784,7 +783,7 @@ if [ "${memcached_yn}" == 'y' ]; then
 fi
 
 # index example
-if [ ! -e "${wwwroot_dir}/default/index.html" -a "${Web_yn}" == 'y' ]; then
+if [ ! -e "${wwwroot_dir}/default/index.html" -a "${web_yn}" == 'y' ]; then
   . include/demo.sh
   DEMO 2>&1 | tee -a ${oneinstack_dir}/install.log
 fi
@@ -793,7 +792,7 @@ fi
 . include/check_dir.sh
 
 # HHVM
-if [ "${HHVM_yn}" == 'y' ]; then
+if [ "${hhvm_yn}" == 'y' ]; then
   . include/hhvm_CentOS.sh
   Install_hhvm_CentOS 2>&1 | tee -a ${oneinstack_dir}/install.log
 fi
@@ -805,38 +804,38 @@ endTime=`date +%s`
 ((installTime=($endTime-$startTime)/60))
 echo "####################Congratulations########################"
 echo "Total OneinStack Install Time: ${CQUESTION}${installTime}${CEND} minutes"
-[ "${Web_yn}" == 'y' -a "${Nginx_version}" != '4' -a "${Apache_version}" == '3' ] && echo -e "\n$(printf "%-32s" "Nginx install dir":)${CMSG}${web_install_dir}${CEND}"
-[ "${Web_yn}" == 'y' -a "${Nginx_version}" != '4' -a "${Apache_version}" != '3' ] && echo -e "\n$(printf "%-32s" "Nginx install dir":)${CMSG}${web_install_dir}${CEND}\n$(printf "%-32s" "Apache install  dir":)${CMSG}${apache_install_dir}${CEND}"
-[ "${Web_yn}" == 'y' -a "${Nginx_version}" == '4' -a "${Apache_version}" != '3' ] && echo -e "\n$(printf "%-32s" "Apache install dir":)${CMSG}${apache_install_dir}${CEND}"
-[[ "${Tomcat_version}" =~ ^[1,2]$ ]] && echo -e "\n$(printf "%-32s" "Tomcat install dir":)${CMSG}${tomcat_install_dir}${CEND}"
-[[ "${DB_version}" =~ ^[1-9]$|^1[0-1]$ ]] && echo -e "\n$(printf "%-32s" "Database install dir:")${CMSG}${db_install_dir}${CEND}"
-[[ "${DB_version}" =~ ^[1-9]$|^1[0-1]$ ]] && echo "$(printf "%-32s" "Database data dir:")${CMSG}${db_data_dir}${CEND}"
-[[ "${DB_version}" =~ ^[1-9]$|^1[0-1]$ ]] && echo "$(printf "%-32s" "Database user:")${CMSG}root${CEND}"
-[[ "${DB_version}" =~ ^[1-9]$|^1[0-1]$ ]] && echo "$(printf "%-32s" "Database password:")${CMSG}${dbrootpwd}${CEND}"
-[ "${DB_version}" == '12' ] && echo -e "\n$(printf "%-32s" "PostgreSQL install dir:")${CMSG}${pgsql_install_dir}${CEND}"
-[ "${DB_version}" == '12' ] && echo "$(printf "%-32s" "PostgreSQL data dir:")${CMSG}${pgsql_data_dir}${CEND}"
-[ "${DB_version}" == '12' ] && echo "$(printf "%-32s" "PostgreSQL user:")${CMSG}postgres${CEND}"
-[ "${DB_version}" == '12' ] && echo "$(printf "%-32s" "postgres password:")${CMSG}${dbpostgrespwd}${CEND}"
-[ "${DB_version}" == '13' ] && echo -e "\n$(printf "%-32s" "MongoDB install dir:")${CMSG}${mongo_install_dir}${CEND}"
-[ "${DB_version}" == '13' ] && echo "$(printf "%-32s" "MongoDB data dir:")${CMSG}${mongo_data_dir}${CEND}"
-[ "${DB_version}" == '13' ] && echo "$(printf "%-32s" "MongoDB user:")${CMSG}root${CEND}"
-[ "${DB_version}" == '13' ] && echo "$(printf "%-32s" "MongoDB password:")${CMSG}${dbmongopwd}${CEND}"
-[ "${PHP_yn}" == 'y' ] && echo -e "\n$(printf "%-32s" "PHP install dir:")${CMSG}${php_install_dir}${CEND}"
-[ "${PHP_cache}" == '1' ] && echo "$(printf "%-32s" "Opcache Control Panel URL:")${CMSG}http://${IPADDR}/ocp.php${CEND}"
-[ "${PHP_cache}" == '2' ] && echo "$(printf "%-32s" "xcache Control Panel URL:")${CMSG}http://${IPADDR}/xcache${CEND}"
-[ "${PHP_cache}" == '2' ] && echo "$(printf "%-32s" "xcache user:")${CMSG}admin${CEND}"
-[ "${PHP_cache}" == '2' ] && echo "$(printf "%-32s" "xcache password:")${CMSG}${xcache_admin_pass}${CEND}"
-[ "${PHP_cache}" == '3' ] && echo "$(printf "%-32s" "APC Control Panel URL:")${CMSG}http://${IPADDR}/apc.php${CEND}"
-[ "${PHP_cache}" == '4' ] && echo "$(printf "%-32s" "eAccelerator Control Panel URL:")${CMSG}http://${IPADDR}/control.php${CEND}"
-[ "${PHP_cache}" == '4' ] && echo "$(printf "%-32s" "eAccelerator user:")${CMSG}admin${CEND}"
-[ "${PHP_cache}" == '4' ] && echo "$(printf "%-32s" "eAccelerator password:")${CMSG}eAccelerator${CEND}"
-[ "${FTP_yn}" == 'y' ] && echo -e "\n$(printf "%-32s" "Pure-FTPd install dir:")${CMSG}${pureftpd_install_dir}${CEND}"
-[ "${FTP_yn}" == 'y' ] && echo "$(printf "%-32s" "Create FTP virtual script:")${CMSG}./pureftpd_vhost.sh${CEND}"
-[ "${phpMyAdmin_yn}" == 'y' ] && echo -e "\n$(printf "%-32s" "phpMyAdmin dir:")${CMSG}${wwwroot_dir}/default/phpMyAdmin${CEND}"
-[ "${phpMyAdmin_yn}" == 'y' ] && echo "$(printf "%-32s" "phpMyAdmin Control Panel URL:")${CMSG}http://${IPADDR}/phpMyAdmin${CEND}"
+[ "${web_yn}" == 'y' -a "${nginx_ver}" != '4' -a "${apache_ver}" == '3' ] && echo -e "\n$(printf "%-32s" "Nginx install dir":)${CMSG}${web_install_dir}${CEND}"
+[ "${web_yn}" == 'y' -a "${nginx_ver}" != '4' -a "${apache_ver}" != '3' ] && echo -e "\n$(printf "%-32s" "Nginx install dir":)${CMSG}${web_install_dir}${CEND}\n$(printf "%-32s" "Apache install  dir":)${CMSG}${apache_install_dir}${CEND}"
+[ "${web_yn}" == 'y' -a "${nginx_ver}" == '4' -a "${apache_ver}" != '3' ] && echo -e "\n$(printf "%-32s" "Apache install dir":)${CMSG}${apache_install_dir}${CEND}"
+[[ "${tomcat_ver}" =~ ^[1,2]$ ]] && echo -e "\n$(printf "%-32s" "Tomcat install dir":)${CMSG}${tomcat_install_dir}${CEND}"
+[[ "${db_ver}" =~ ^[1-9]$|^1[0-1]$ ]] && echo -e "\n$(printf "%-32s" "Database install dir:")${CMSG}${db_install_dir}${CEND}"
+[[ "${db_ver}" =~ ^[1-9]$|^1[0-1]$ ]] && echo "$(printf "%-32s" "Database data dir:")${CMSG}${db_data_dir}${CEND}"
+[[ "${db_ver}" =~ ^[1-9]$|^1[0-1]$ ]] && echo "$(printf "%-32s" "Database user:")${CMSG}root${CEND}"
+[[ "${db_ver}" =~ ^[1-9]$|^1[0-1]$ ]] && echo "$(printf "%-32s" "Database password:")${CMSG}${dbrootpwd}${CEND}"
+[ "${db_ver}" == '12' ] && echo -e "\n$(printf "%-32s" "PostgreSQL install dir:")${CMSG}${pgsql_install_dir}${CEND}"
+[ "${db_ver}" == '12' ] && echo "$(printf "%-32s" "PostgreSQL data dir:")${CMSG}${pgsql_data_dir}${CEND}"
+[ "${db_ver}" == '12' ] && echo "$(printf "%-32s" "PostgreSQL user:")${CMSG}postgres${CEND}"
+[ "${db_ver}" == '12' ] && echo "$(printf "%-32s" "postgres password:")${CMSG}${dbpostgrespwd}${CEND}"
+[ "${db_ver}" == '13' ] && echo -e "\n$(printf "%-32s" "MongoDB install dir:")${CMSG}${mongo_install_dir}${CEND}"
+[ "${db_ver}" == '13' ] && echo "$(printf "%-32s" "MongoDB data dir:")${CMSG}${mongo_data_dir}${CEND}"
+[ "${db_ver}" == '13' ] && echo "$(printf "%-32s" "MongoDB user:")${CMSG}root${CEND}"
+[ "${db_ver}" == '13' ] && echo "$(printf "%-32s" "MongoDB password:")${CMSG}${dbmongopwd}${CEND}"
+[ "${php_yn}" == 'y' ] && echo -e "\n$(printf "%-32s" "PHP install dir:")${CMSG}${php_install_dir}${CEND}"
+[ "${php_cache}" == '1' ] && echo "$(printf "%-32s" "Opcache Control Panel URL:")${CMSG}http://${IPADDR}/ocp.php${CEND}"
+[ "${php_cache}" == '2' ] && echo "$(printf "%-32s" "xcache Control Panel URL:")${CMSG}http://${IPADDR}/xcache${CEND}"
+[ "${php_cache}" == '2' ] && echo "$(printf "%-32s" "xcache user:")${CMSG}admin${CEND}"
+[ "${php_cache}" == '2' ] && echo "$(printf "%-32s" "xcache password:")${CMSG}${xcache_admin_pass}${CEND}"
+[ "${php_cache}" == '3' ] && echo "$(printf "%-32s" "APC Control Panel URL:")${CMSG}http://${IPADDR}/apc.php${CEND}"
+[ "${php_cache}" == '4' ] && echo "$(printf "%-32s" "eAccelerator Control Panel URL:")${CMSG}http://${IPADDR}/control.php${CEND}"
+[ "${php_cache}" == '4' ] && echo "$(printf "%-32s" "eAccelerator user:")${CMSG}admin${CEND}"
+[ "${php_cache}" == '4' ] && echo "$(printf "%-32s" "eAccelerator password:")${CMSG}eAccelerator${CEND}"
+[ "${ftp_yn}" == 'y' ] && echo -e "\n$(printf "%-32s" "Pure-FTPd install dir:")${CMSG}${pureftpd_install_dir}${CEND}"
+[ "${ftp_yn}" == 'y' ] && echo "$(printf "%-32s" "Create FTP virtual script:")${CMSG}./pureftpd_vhost.sh${CEND}"
+[ "${phpmyadmin_yn}" == 'y' ] && echo -e "\n$(printf "%-32s" "phpMyAdmin dir:")${CMSG}${wwwroot_dir}/default/phpMyAdmin${CEND}"
+[ "${phpmyadmin_yn}" == 'y' ] && echo "$(printf "%-32s" "phpMyAdmin Control Panel URL:")${CMSG}http://${IPADDR}/phpMyAdmin${CEND}"
 [ "${redis_yn}" == 'y' ] && echo -e "\n$(printf "%-32s" "redis install dir:")${CMSG}${redis_install_dir}${CEND}"
 [ "${memcached_yn}" == 'y' ] && echo -e "\n$(printf "%-32s" "memcached install dir:")${CMSG}${memcached_install_dir}${CEND}"
-[ "${Web_yn}" == 'y' ] && echo -e "\n$(printf "%-32s" "Index URL:")${CMSG}http://${IPADDR}/${CEND}"
+[ "${web_yn}" == 'y' ] && echo -e "\n$(printf "%-32s" "Index URL:")${CMSG}http://${IPADDR}/${CEND}"
 while :; do echo
   echo "${CMSG}Please restart the server and see if the services start up fine.${CEND}"
   read -p "Do you want to restart OS ? [y/n]: " restart_yn

+ 1 - 1
pureftpd_vhost.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #

+ 1 - 1
reset_db_root_password.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #

+ 2 - 2
ss.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #        Install SS Server
@@ -163,7 +163,7 @@ Install_SS-libev() {
       /bin/cp ../init.d/SS-libev-init-CentOS /etc/init.d/shadowsocks
       chkconfig --add shadowsocks
       chkconfig shadowsocks on
-    elif [[ "${OS}" =~ ^Ubuntu$|^Debian$ ]];then
+    elif [[ "${OS}" =~ ^Ubuntu$|^Debian$ ]]; then
       /bin/cp ../init.d/SS-libev-init-Ubuntu /etc/init.d/shadowsocks
       update-rc.d shadowsocks defaults
     fi

+ 1 - 1
tools/ckssh.py

@@ -1,6 +1,6 @@
 #!/usr/bin/python
 # Author:  yeho <lj2007331 AT gmail.com>
-# Blog:  http://blog.linuxeye.com
+# Blog:  http://blog.linuxeye.cn
 
 import socket,sys
 sk = socket.socket(socket.AF_INET, socket.SOCK_STREAM)

+ 3 - 3
tools/db_bk.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #
@@ -22,14 +22,14 @@ OldFile=$backup_dir/DB_${DBname}_$(date +%Y%m%d --date="$expired_days days ago")
 DB_tmp=`$db_install_dir/bin/mysql -uroot -p$dbrootpwd -e "show databases\G" | grep $DBname`
 [ -z "$DB_tmp" ] && { echo "[$DBname] not exist" >> $LogFile ;  exit 1 ; }
 
-if [ -n "`ls $OldFile 2>/dev/null`" ];then
+if [ -n "`ls $OldFile 2>/dev/null`" ]; then
   /bin/rm -f $OldFile
   echo "[$OldFile] Delete Old File Success" >> $LogFile
 else
   echo "[$OldFile] Delete Old Backup File" >> $LogFile
 fi
 
-if [ -e "$NewFile" ];then
+if [ -e "$NewFile" ]; then
   echo "[$NewFile] The Backup File is exists, Can't Backup" >> $LogFile
 else
   $db_install_dir/bin/mysqldump -uroot -p$dbrootpwd --databases $DBname > $DumpFile

+ 1 - 1
tools/mabs.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# Blog:  http://blog.linuxeye.com
+# Blog:  http://blog.linuxeye.cn
 
 ######################  proc defination  ########################
 # ignore rule

+ 1 - 1
tools/thread.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# Blog:  http://blog.linuxeye.com
+# Blog:  http://blog.linuxeye.cn
 
 # Default Parameters
 myIFS=":::"

+ 4 - 4
tools/website_bk.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #
@@ -17,15 +17,15 @@ OldFile=$backup_dir/Web_${WebSite}_$(date +%Y%m%d --date="$expired_days days ago
 [ ! -e "$backup_dir" ] && mkdir -p $backup_dir
 [ ! -e "$wwwroot_dir/$WebSite" ] && { echo "[$wwwroot_dir/$WebSite] not exist" >> $LogFile ;  exit 1 ; }
 
-if [ `du -sm "$wwwroot_dir/$WebSite" | awk '{print $1}'` -lt 1024 ];then
-  if [ -n "`ls $OldFile 2>/dev/null`" ];then
+if [ `du -sm "$wwwroot_dir/$WebSite" | awk '{print $1}'` -lt 1024 ]; then
+  if [ -n "`ls $OldFile 2>/dev/null`" ]; then
     /bin/rm -f $OldFile
     echo "[$OldFile] Delete Old File Success" >> $LogFile
   else
     echo "[$OldFile] Delete Old Backup File" >> $LogFile
   fi
 
-  if [ -e "$NewFile" ];then
+  if [ -e "$NewFile" ]; then
     echo "[$NewFile] The Backup File is exists, Can't Backup" >> $LogFile
   else
     pushd $wwwroot_dir > /dev/null

+ 2 - 2
uninstall.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #
@@ -112,7 +112,7 @@ Print_MongoDB() {
 
 Uninstall_MySQL() {
   # uninstall mysql,mariadb,percona,alisql 
-  if [ -d "${db_install_dir}/support-files" ];then
+  if [ -d "${db_install_dir}/support-files" ]; then
     service mysqld stop > /dev/null 2>&1
     rm -rf ${db_install_dir} /etc/init.d/mysqld /etc/my.cnf /etc/ld.so.conf.d/{mysql,mariadb,percona,alisql}*.conf
     id -u mysql >/dev/null 2>&1 ; [ $? -eq 0 ] && userdel mysql

+ 1 - 1
upgrade.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #

+ 76 - 76
versions.txt

@@ -1,106 +1,106 @@
-# newest software version
+# newest software ver
 # Web
-nginx_version=1.12.2
-tengine_version=2.2.2
-openresty_version=1.13.6.1
-openssl_version=1.0.2n
-
-tomcat8_version=8.5.28
-tomcat7_version=7.0.85
-tomcat6_version=6.0.53
-
-apache24_version=2.4.29
-apache22_version=2.2.34
-pcre_version=8.41
-apr_version=1.6.3
-apr_util_version=1.6.1
-nghttp2_version=1.30.0
+nginx_ver=1.12.2
+tengine_ver=2.2.2
+openresty_ver=1.13.6.1
+openssl_ver=1.0.2n
+
+tomcat8_ver=8.5.28
+tomcat7_ver=7.0.85
+tomcat6_ver=6.0.53
+
+apache24_ver=2.4.29
+apache22_ver=2.2.34
+pcre_ver=8.41
+apr_ver=1.6.3
+apr_util_ver=1.6.1
+nghttp2_ver=1.30.0
 
 # DB
-mysql57_version=5.7.21
-mysql56_version=5.6.39
-mysql55_version=5.5.59
+mysql57_ver=5.7.21
+mysql56_ver=5.6.39
+mysql55_ver=5.5.59
 
-mariadb102_version=10.2.13
-mariadb101_version=10.1.31
-mariadb100_version=10.0.34
-mariadb55_version=5.5.59
+mariadb102_ver=10.2.13
+mariadb101_ver=10.1.31
+mariadb100_ver=10.0.34
+mariadb55_ver=5.5.59
 
-percona57_version=5.7.21-20
-percona56_version=5.6.39-83.1
-percona55_version=5.5.59-38.11
+percona57_ver=5.7.21-20
+percona56_ver=5.6.39-83.1
+percona55_ver=5.5.59-38.11
 
-alisql56_version=5.6.32-8
+alisql_ver=5.6.32-8
 
-pgsql_version=10.3
+pgsql_ver=10.3
 
-mongodb_version=3.6.3
+mongodb_ver=3.6.3
 
 # JDK
-jdk18_version=1.8.0_162
-jdk17_version=1.7.0_80
-jdk16_version=1.6.0_45
+jdk18_ver=1.8.0_162
+jdk17_ver=1.7.0_80
+jdk16_ver=1.6.0_45
 
 # PHP
-php72_version=7.2.3
-php71_version=7.1.15
-php70_version=7.0.28
-php56_version=5.6.34
-php55_version=5.5.38
-php54_version=5.4.45
-php53_version=5.3.29
-
-libiconv_version=1.15
-curl_version=7.58.0
-libmcrypt_version=2.5.8
-mcrypt_version=2.6.8
-mhash_version=0.9.9.9
-ImageMagick_version=6.9.9-36
-imagick_version=3.4.3
-GraphicsMagick_version=1.3.28
+php72_ver=7.2.3
+php71_ver=7.1.15
+php70_ver=7.0.28
+php56_ver=5.6.34
+php55_ver=5.5.38
+php54_ver=5.4.45
+php53_ver=5.3.29
+
+libiconv_ver=1.15
+curl_ver=7.58.0
+libmcrypt_ver=2.5.8
+mcrypt_ver=2.6.8
+mhash_ver=0.9.9.9
+imagemagick_ver=6.9.9-37
+imagick_ver=3.4.3
+graphicsmagick_ver=1.3.28
 gmagick_for_php7_version=2.0.5RC1
 gmagick_version=1.1.7RC3
-zendopcache_version=7.0.5
-xcache_version=3.2.0
-apcu_version=4.0.11
-apcu_for_php7_version=5.1.10
-eaccelerator_version=0.9.6.1
-swoole_version=2.1.0
-xdebug_version=2.5.5
+zendopcache_ver=7.0.5
+xcache_ver=3.2.0
+apcu_ver=4.0.11
+apcu_for_php7_ver=5.1.10
+eaccelerator_ver=0.9.6.1
+swoole_ver=2.1.0
+xdebug_ver=2.5.5
 
 # Ftp
-pureftpd_version=1.0.47
+pureftpd_ver=1.0.47
 
 # Redis
-redis_version=4.0.8
-redis_pecl_version=3.1.6
+redis_ver=4.0.8
+redis_pecl_ver=3.1.6
 
 # Memcached
-memcached_version=1.5.6
-libmemcached_version=1.0.18
-memcached_pecl_version=2.2.0
-memcached_pecl_php7_version=3.0.4
-memcache_pecl_version=3.0.8
+memcached_ver=1.5.6
+libmemcached_ver=1.0.18
+memcached_pecl_ver=2.2.0
+memcached_pecl_php7_ver=3.0.4
+memcache_pecl_ver=3.0.8
 
 # MongoDB
-mongodb_pecl_version=1.4.0
-mongo_pecl_version=1.6.16
+mongodb_pecl_ver=1.4.0
+mongo_pecl_ver=1.6.16
 
 # phpMyadmin
-phpMyAdmin_version=4.4.15.10
+phpmyadmin_ver=4.4.15.10
 
 # jemalloc
-jemalloc_version=5.0.1
+jemalloc_ver=5.0.1
 
 # boost
-boost_version=1.59.0
+boost_ver=1.59.0
 
 # Others
-libevent_version=2.0.22-stable
-tmux_version=2.6
-htop_version=2.1.0
-bison_version=2.7.1
-python_version=2.7.14
-setuptools_version=32.0.0
-pip_version=9.0.1
-fail2ban_version=0.10.2
+libevent_ver=2.0.22-stable
+tmux_ver=2.6
+htop_ver=2.1.0
+bison_ver=2.7.1
+python_ver=2.7.14
+setuptools_ver=32.0.0
+pip_ver=9.0.1
+fail2ban_ver=0.10.2

+ 1 - 1
vhost.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 # Author:  yeho <lj2007331 AT gmail.com>
-# BLOG:  https://blog.linuxeye.com
+# BLOG:  https://blog.linuxeye.cn
 #
 # Notes: OneinStack for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
 #