XAMPP after installation, add Apache, MySQL service

Source: Internet
Author: User

Configuring the MySQL Service

[Email protected] ~]# Find/-name mysql.server
/opt/lampp/share/mysql/mysql.server
/opt/lampp/bin/mysql.server # #mysql启动文件


[[email protected] ~]# ln-s/opt/lampp/bin/mysql.server/etc/rc.d/init.d/mysql # #软连接 (understood as shortcut keys)
[Email protected] ~]# Vi/etc/rc.d/init.d/mysql # #大概看了一眼


[Email protected] ~]# chkconfig--add MySQL # #增加mysql的系统服务
[Email protected] ~]# chkconfig--list MySQL # #列出mysql服务的设置情况
MySQL 0: off 1: Off 2: Enable 3: Enable 4: Enable 5: Enable 6: Off


[email protected] ~]# netstat-an|grep:3306
TCP 0 0::: 3306:::* LISTEN
[[email protected] ~]# ps-aux|grep MySQL
Warning:bad syntax, perhaps a bogus '-'? See/usr/share/doc/procps-3.2.8/faq
root 2436 0.0 0.2 3044 1340 pts/0 S 11:46 0:00/bin/sh/opt/lampp/bin/mysqld_safe--datadir=/opt/lam Pp/var/mysql--pid-file=/opt/lampp/var/mysql/centos1.pid
MySQL 2797 0.6 19.0 330620 97348 pts/0 Sl 11:46 0:00/opt/lampp/sbin/mysqld--basedir=/opt/lampp--datadir =/opt/lampp/var/mysql--plugin-dir=/opt/lampp/lib/mysql/plugin/--user=mysql--log-error=/opt/lampp/var/mysql/ Centos1.err--pid-file=/opt/lampp/var/mysql/centos1.pid--socket=/opt/lampp/var/mysql/mysql.sock--port=3306
root 2830 0.0 0.1 5980 756 pts/0 s+ 11:48 0:00 grep mysql
[Email protected] ~]#

Configure Apache Services

[Email protected] ~]# Find/-name apachectl
/opt/lampp/bin/apachectl

[Email protected] ~]# ln-s/opt/lampp/bin/mysql.server/etc/rc.d/init.d/mysql
[Email protected] ~]# vi/etc/rc.d/init.d/mysql # #加入 #chkconfig:2345


[[email protected] ~]# chkconfig--add MySQL
[[email protected] ~]# chkconfig--list MySQL
MySQL 0: off 1: Off 2: Enable 3: Enable 4: Enable 5: Enable 6: Off
[[Email protected] ~]# service MySQL stop
Shutting down MySQL. success!

[[Email protected] ~]# service MySQL start
Starting MySQL. success!
[[email protected] ~]# ps-aux|grep MySQL
Warning:bad syntax, perhaps a bogus '-'? See/usr/share/doc/procps-3.2.8/faq
root 2436 0.0 0.2 3044 1340 pts/0 S 11:46 0:00/bin/sh/opt/lampp/bin/mysqld_safe--datadir=/opt/lam Pp/var/mysql--pid-file=/opt/lampp/var/mysql/centos1.pid
MySQL 2797 0.8 19.0 330620 97348 pts/0 Sl 11:46 0:00/opt/lampp/sbin/mysqld--basedir=/opt/lampp--datadir =/opt/lampp/var/mysql--plugin-dir=/opt/lampp/lib/mysql/plugin/--user=mysql--log-error=/opt/lampp/var/mysql/ Centos1.err--pid-file=/opt/lampp/var/mysql/centos1.pid--socket=/opt/lampp/var/mysql/mysql.sock--port=3306
root 2824 0.0 0.1 5980 756 pts/0 s+ 11:48 0:00 grep mysql

XAMPP after installation, add Apache, MySQL service

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.