在 16.04 中停止 LAMP

use*_*495 3 lamp mysql apache2 16.04

我使用 LAMP 在本地环境中进行测试。我想尝试 AMPPS,但 LAMP 正在干扰它。是否有任何命令可以停止 LAMP ?如果我对 AMPPS 的体验不如预期,我想知道如何启动 LAMP。谢谢。

Rin*_*ind 6

是否有任何命令可以停止 LAMP ?

LAMP 不是服务,而是 Linux、Apache、MySQL、PHP 的首字母缩写词。“停止灯泡”是不可能的。您可以停止 LAMP 堆栈的 2 个组件:apache 和 mysql。

systemctl stop apache2.service
systemctl stop mysqld
Run Code Online (Sandbox Code Playgroud)

和 ...

systemctl is-enabled apache2.service
systemctl is-enabled mysqld
Run Code Online (Sandbox Code Playgroud)

将显示它是否正在运行。

Linux 和 PHP 不是服务,因此不需要停止。

如果我对 AMPPS 的体验不如预期,我想知道如何启动 LAMP。

现在,对于您身边的问题或误解:

AMPPS 是 Apache、MySQL、MongoDB、PHP、Perl、Python。我没有看到与 LAMP 的任何冲突:您需要做的是安装 Mongodb,因为 AMPPS = LAMP + MongoDB。Perl、Python 是 Linux 原生的,所以你缺少的只是 MongoDB。

所以

sudo apt install lamp-server^
Run Code Online (Sandbox Code Playgroud)

并按照MongoDB安装指南安装 AMPPS。