安装源
yum install http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm
yum install scl-utils
yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
yum install http://rpms.remirepo.net/enterprise/remi-release-7.rpm
接下来
yum install -y httpd mysql-community-server mysql-community-client mysql-community-bench mysql-community-devel php70 php70-build php70-php php70-php-ast php70-php-bcmath php70-php-cli php70-php-common php70-php-dba php70-php-dbg php70-php-devel php70-php-embedded php70-php-enchant php70-php-fpm php70-php-gd php70-php-geos php70-php-gmp php70-php-imap php70-php-interbase php70-php-intl php70-php-ioncube-loader php70-php-json php70-php-ldap php70-php-libvirt php70-php-libvirt-doc.noarch php70-php-litespeed php70-php-lz4 php70-php-mbstring php70-php-mcrypt php70-php-mysqlnd php70-php-oci8 php70-php-odbc php70-php-opcache php70-php-pdo php70-php-pdo-dblib php70-php-pear.noarch php70-php-pecl-amqp php70-php-pecl-apcu php70-php-pecl-apcu-bc php70-php-pecl-apcu-devel php70-php-pecl-apfd php70-php-pecl-apm php70-php-pecl-bitset php70-php-pecl-cassandra php70-php-pecl-couchbase2 php70-php-pecl-crypto php70-php-pecl-dbase php70-php-pecl-dio php70-php-pecl-druid php70-php-pecl-ds php70-php-pecl-eio php70-php-pecl-env php70-php-pecl-ev php70-php-pecl-event php70-php-pecl-fann php70-php-pecl-gearman php70-php-pecl-gender php70-php-pecl-geoip php70-php-pecl-geospatial php70-php-pecl-gnupg php70-php-pecl-grpc php70-php-pecl-hdr-histogram php70-php-pecl-hprose php70-php-pecl-hrtime php70-php-pecl-http php70-php-pecl-http-devel php70-php-pecl-igbinary php70-php-pecl-igbinary-devel php70-php-pecl-imagick php70-php-pecl-imagick-devel php70-php-pecl-inotify php70-php-pecl-json-post php70-php-pecl-krb5 php70-php-pecl-krb5-devel php70-php-pecl-libsodium php70-php-pecl-lua php70-php-pecl-lzf php70-php-pecl-mailparse php70-php-pecl-memcache php70-php-pecl-memcached php70-php-pecl-memprof php70-php-pecl-mogilefs php70-php-pecl-mongodb php70-php-pecl-mosquitto php70-php-pecl-msgpack php70-php-pecl-msgpack-devel php70-php-pecl-mysql php70-php-pecl-oauth php70-php-pecl-pcs php70-php-pecl-pcs-devel php70-php-pecl-pdflib php70-php-pecl-pq php70-php-pecl-propro php70-php-pecl-propro-devel php70-php-pecl-radius php70-php-pecl-raphf php70-php-pecl-raphf-devel php70-php-pecl-rdkafka php70-php-pecl-redis php70-php-pecl-ref php70-php-pecl-request php70-php-pecl-rrd php70-php-pecl-scrypt php70-php-pecl-seaslog php70-php-pecl-selinux php70-php-pecl-solr2 php70-php-pecl-ssdeep php70-php-pecl-ssh2 php70-php-pecl-stats php70-php-pecl-stomp php70-php-pecl-swoole php70-php-pecl-swoole-serialize php70-php-pecl-sync php70-php-pecl-taint php70-php-pecl-tcpwrap php70-php-pecl-termbox php70-php-pecl-trace php70-php-pecl-trader php70-php-pecl-ui php70-php-pecl-uopz php70-php-pecl-uploadprogress php70-php-pecl-uuid php70-php-pecl-uv php70-php-pecl-varnish php70-php-pecl-vips php70-php-pecl-vld php70-php-pecl-weakref php70-php-pecl-xattr php70-php-pecl-xdebug php70-php-pecl-xdiff php70-php-pecl-xmldiff php70-php-pecl-xmldiff-devel php70-php-pecl-xxtea php70-php-pecl-yac php70-php-pecl-yaf php70-php-pecl-yaml php70-php-pecl-yar php70-php-pecl-yaz php70-php-pecl-zip php70-php-pecl-zmq php70-php-pgsql php70-php-phalcon3 php70-php-phpiredis php70-php-pinba php70-php-process php70-php-pspell php70-php-recode php70-php-smbclient php70-php-snappy php70-php-snmp php70-php-soap php70-php-sqlsrv php70-php-tarantool php70-php-tidy php70-php-xml php70-php-xmlrpc php70-runtime php70-scldevel php70-zephir.noarch php70-zephir-parser
##可以抽根烟出去溜达溜达...
安装完成后,使用 systemctl 命令启动,并设置为开机自动启动。
systemctl start httpd.service
systemctl enable httpd.service
systemctl start mysql.service
systemctl enable mysql.service
配置mysql
mysql -uroot -p
//修改root密码
UPDATE user SET password=PASSWORD('password') WHERE user='root';
//创建用户
CREATE USER 'username'@'%' IDENTIFIED BY 'password';
//设置用户权限
GRANT ALL ON *.* TO 'coder'@'%';
网友评论