Linux学习笔记3 xshell(lnmp)

xshell能连接虚拟机的前提是真机能够ping通虚拟机网址
进入xshell初始页面
xshell传输文件页面
图形化拖动传输方式
文件路径传输方式

ls显示文件
tar解压文件夹
cd进入该目录文件路径 pwd显示目录路径

解压缩另外一个文件,没有指定路径 就在默认目录

操作要在该目录文件下才可以

yum -y install pcre装一个库
装OpenSSL依赖文件 [root@localhost nginx-1.12.2]# yum -y install openssl pcre-devel
依赖检测[root@localhost nginx-1.12.2]# ./configure
禁用
[root@localhost nginx-1.12.2]# yum -y install zlib
complete安装成功

[root@localhost nginx-1.12.2]# ./configure --without-http_gzip_module
依赖检测通过标志配置总结
[root@localhost nginx-1.12.2]# make && make install
四个配置文件显示 安装成功
[root@localhost nginx-1.12.2]# ls /usr/local/nginx/
conf html logs sbin
[root@localhost nginx-1.12.2]# cd /usr/local/nginx/
[root@localhost nginx]# pwd
/usr/local/nginx
[root@localhost nginx]# ls sbin/
nginx
[root@localhost nginx]# sbin/nginx
[root@localhost nginx]# ss -antulp | grep :80
tcp LISTEN 0 128 *:80 : users:((“nginx”,pid=59064,fd=6),(“nginx”,pid=59063,fd=6))
[root@localhost nginx]#
80 服务启动
关闭防火墙[root@localhost nginx]# systemctl stop firewalld.service
真机访问
内容与网页一样
装[root@localhost nginx]# yum -y install mariadb
在这里插入图片描述
yum安装的用systemd来起服务
源码安装用绝对路径来起服务
源码安装:
下载对应操作系统的源码,exec,rpm
解压缩
安装对应依赖
./configure
make && make install

安装[root@localhost nginx]# yum -y install mariadb-server mariadb-devel
在这里插入图片描述

[root@localhost nginx]# systemctl start mariadb.service
[root@localhost nginx]# !ss
bash: !ss: command not found…
[root@localhost nginx]# !ss
ss -antulp | grep :80
tcp LISTEN 0 128 *:80 : users:((“nginx”,pid=59064,fd=6),(“nginx”,pid=59063,fd=6))
[root@localhost nginx]#
在这里插入图片描述
成功安装php
在这里插入图片描述
修改配置文件[root@localhost nginx]# vim conf/nginx.conf

:set nu 设置行号
u撤销前一步操作
60 gg瞬移行
Ctrl+V
s删除#
I shift+# esc批量加
dd删除

sbin/nginx -s reload重启服务
手写页面vim html/test.php

  • 9
    点赞
  • 7
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值