UFW

在 Ubuntu 中安装 Apache、MySQL、PHP(LAMP)套件

删除回忆录丶 提交于 2021-01-23 09:35:27
LAMP 套件是一种流行的开源 Web 开发平台,可用于运行和部署动态网站和基于 Web 的应用程序。通常,LAMP 套件由 Apache Web 服务器、MariaDB/MySQL 数据库、PHP/Python/Perl 程序设计(脚本)语言组成。 LAMP 是 L inux, M ariaDB/ M YSQL, P HP/ P ython/ P erl 的缩写。 本教程描述了如何在 Ubuntu 18.04 LTS 服务器中安装 Apache、MySQL、PHP(LAMP 套件)。 就本教程而言,我们将使用以下 Ubuntu 测试。 操作系统 :Ubuntu 18.04.1 LTS Server Edition IP 地址 :192.168.225.22/24 1. 安装 Apache Web 服务器 首先,利用下面命令更新 Ubuntu 服务器: $ sudo apt update $ sudo apt upgrade 然后,安装 Apache Web 服务器(命令如下): $ sudo apt install apache2 检查 Apache Web 服务器是否已经运行: $ sudo systemctl status apache2 输出结果大概是这样的: ● apache2.service - The Apache HTTP Server Loaded: loaded

Ubuntu18.04安装xrdp 桌面远程服务

做~自己de王妃 提交于 2021-01-09 09:53:55
终端改目录改英文 export LANG=en_US xdg-user-dirs-gtk-update export LANG=zh_CN.UTF-8 xdg-user-dirs-gtk-update ================================================= xrdp是原生方案,兼容性是最好的,也不需要太多额外的软件支持。 sudo apt install xrdp sudo systemctl enable xrdp 第49行,new_cursors=true改为false sudo sed -e 's/^new_cursors=true/new_cursors=false/g' \ -i /etc/xrdp/xrdp.ini sudo systemctl restart xrdp 创建 ~/.xsessionrc vi ~/.xsessionrc export GNOME_SHELL_SESSION_MODE=ubuntu export XDG_CURRENT_DESKTOP=ubuntu:GNOME export XDG_DATA_DIRS=/usr/share/ubuntu:/usr/local/share:/usr/share:/var/lib/snapd/desktop export XDG_CONFIG_DIRS=/etc

SSH back to AWS Lightsail after UFW enabling

泄露秘密 提交于 2021-01-05 09:11:24
问题 I've enabled the UFW service without allowing SSH access before then logging off. I am now unable to ssh back to the instance. The steps I have already taken: Made a snapshot and create a new instance from it 回答1: The general point: try to execute a command ( firewall disabling ) while creating a new instance. I was able to do it with the usage of AWS CLI: aws lightsail create-instances-from-snapshot --region eu-central-1 --instance-snapshot-name TEST_SSH_FIX-1591429003 --instance-names TEST

SSH back to AWS Lightsail after UFW enabling

随声附和 提交于 2021-01-05 09:11:07
问题 I've enabled the UFW service without allowing SSH access before then logging off. I am now unable to ssh back to the instance. The steps I have already taken: Made a snapshot and create a new instance from it 回答1: The general point: try to execute a command ( firewall disabling ) while creating a new instance. I was able to do it with the usage of AWS CLI: aws lightsail create-instances-from-snapshot --region eu-central-1 --instance-snapshot-name TEST_SSH_FIX-1591429003 --instance-names TEST

SSH back to AWS Lightsail after UFW enabling

主宰稳场 提交于 2021-01-05 09:10:53
问题 I've enabled the UFW service without allowing SSH access before then logging off. I am now unable to ssh back to the instance. The steps I have already taken: Made a snapshot and create a new instance from it 回答1: The general point: try to execute a command ( firewall disabling ) while creating a new instance. I was able to do it with the usage of AWS CLI: aws lightsail create-instances-from-snapshot --region eu-central-1 --instance-snapshot-name TEST_SSH_FIX-1591429003 --instance-names TEST

SSH back to AWS Lightsail after UFW enabling

旧时模样 提交于 2021-01-05 09:10:41
问题 I've enabled the UFW service without allowing SSH access before then logging off. I am now unable to ssh back to the instance. The steps I have already taken: Made a snapshot and create a new instance from it 回答1: The general point: try to execute a command ( firewall disabling ) while creating a new instance. I was able to do it with the usage of AWS CLI: aws lightsail create-instances-from-snapshot --region eu-central-1 --instance-snapshot-name TEST_SSH_FIX-1591429003 --instance-names TEST

How To Install Nginx on Ubuntu 16.04 zz

送分小仙女□ 提交于 2020-11-25 08:08:04
Introduction Nginx is one of the most popular web servers in the world and is responsible for hosting some of the largest and highest-traffic sites on the internet. It is more resource-friendly than Apache in most cases and can be used as a web server or a reverse proxy. In this guide, we'll discuss how to get Nginx installed on your Ubuntu 16.04 server. Prerequisites Before you begin this guide, you should have a regular, non-root user with sudo privileges configured on your server. You can learn how to configure a regular user account by following our initial server setup guide for Ubuntu 16

Ubuntu 14.04在虚拟机上的桥接模式下设置静态IP

|▌冷眼眸甩不掉的悲伤 提交于 2020-11-11 10:51:40
1、虚拟机--->虚拟机设置 将虚拟机设置为桥接模式 2、查看window 网卡以及IP信息   cmd下输入 ipconfig -all   可以看到,我的网卡为Realtek PCIe GBE Family Controller   这里我要将虚拟机配置成5网段,如192.168.5.23, 记住主机IPV4地址:192.168.5.22 子网掩码:255.255.255.0 默认网关:192.168.1.1(一会要用)   注意:主机设置的网段地址必须为(首选)! 否则会出现主机无法ping通虚拟机的现象。 若是(复制),则是IP冲突,需要重新修改主机IP。 3、打开编辑--->虚拟网络编辑器--->更改设置   设置桥接网卡为Realtek PCIe GBE Family Controller 4、修改Ubuntu虚拟机网卡接口信息 打开终端,输入   sudo gedit /etc/network/interfaces 添加: auto eth0 iface eth0 inet static address 192.168 . 5.23 netmask 255.255 . 255.0 gateway 192.168 . 1.1 dns -nameservers 8.8 . 8.8   其中 eth0是网卡名字(有的是ens33),address是你要设置的IP

gitlab 安装、配置、清空、卸载、重装

拥有回忆 提交于 2020-10-09 11:46:45
20200702 自行搭建 git 服务器后,如何管理总是一个麻烦事,所以,还是要安装一个 gitlab 按照 gitlab 官网安装 ce 版,其实应该是很简单的事情,步骤也很少。 正常情况下,安装、配置、运行,再学习 gitlab 使用 没有想到我折腾了一大圈!来回卸载、重装、重新配置!几乎所有该出现的问题,全都遇见了一轮! 我的环境: virtualBox 虚拟机 ubuntu Server 1804 gitlab 官网 https://about.gitlab.com/install/#ubuntu gitlab ce 版本安装步骤 https://about.gitlab.com/install/#ubuntu?version=ce 清华大学开源软件镜像站 https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/ Gitlab Community Edition 镜像使用帮助 https://mirror.tuna.tsinghua.edu.cn/help/gitlab-ce/ 1、 安装 安装必要的依赖 sudo apt-get install -y curl openssh-server ca-certificates 非必须 ( 如果开始学习或者后续需要使用邮箱开放注册的话,请安装 ) sudo apt-get install

docker创建并运行ubuntu16.04容器

白昼怎懂夜的黑 提交于 2020-10-05 06:36:44
docker创建ubuntu16.04 容器 上文写到, docker创建并运行centos7容器 本篇主要是 docker创建并运行ubuntu16.04容器,依赖上文原有配置 宿主机创建容器前,准备工作 拉取ubuntu16.04镜像 sudo docker pull ubuntu:16.04 查看镜像列表 sudo docker images 创建容器前准备工作,先把宿主机系统防火墙起开,放通端口 可参考之前blog: Linux系统防火墙放行端口 此处是 查看系统防火墙状态 systemctl status firewalld 开启系统防火墙 systemctl start firewalld 放行端口 firewall-cmd --zone = public --add-port = 10023/tcp --permanent && \ firewall-cmd --zone = public --add-port = 10081/tcp --permanent && \ firewall-cmd --reload 查看放通的端口列表 firewall-cmd --list-port 若要再关闭系统防火墙 systemctl stop firewalld 创建并启动 ubuntu16.04容器 $ sudo docker run -it --name u16-d1 -