国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 系統 > CentOS > 正文

[部署]CentOS安裝apache

2024-06-28 14:31:40
字體:
來源:轉載
供稿:網友

環境

虛擬機:VMWare10.0.1 build-1379776

操作系統:CentOS7 64位

步驟

1、使用yum安裝

yum install httpd httpd-devel

2、啟動

apachectl start

開機啟動服務安裝

1、在/etc/init.d目錄先建立httpd文件

vi /etc/rc.d/init.d/httpd

httpd文件內容

 

#!/bin/sh## Startup script for the Apache Web Server## chkconfig: 345 85 15# Description: Apache is a World Wide Web server.  It is used to serve /#           HTML files and CGI.# PRocessname: httpd# Source function library.. /etc/rc.d/init.d/functions# See how we were called.case "$1" instart)echo -n "Starting httpd:"/usr/sbin/apachectl start;;stop)echo -n "Shutting down httpd:";/usr/sbin/apachectl stop;;status)/usr/sbin/apachectl status;;restart)echo -n "Restarting httpd:";/usr/sbin/apachectl restart;;reload)echo -n "Reloading httpd: "/usr/sbin/apachectl restartecho;;*)echo "Usage: $0 {start|stop|restart|reload|status}"exit 1esacexit 0

2、修改/etc/rc.d/init.d/httpd的執行權限

chmod 755 /etc/rc.d/init.d/httpd

3、加入系統服務

chkconfig --add httpd
chkconfig --levels 2345 httpd on

發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 海伦市| 安平县| 临洮县| 桃园县| 两当县| 荔波县| 乐业县| 临邑县| 石门县| 疏附县| 漳平市| 图木舒克市| 察隅县| 牡丹江市| 曲阳县| 黔东| 丹巴县| 甘孜县| 玉山县| 公主岭市| 烟台市| 星子县| 虹口区| 靖远县| SHOW| 沂南县| 敖汉旗| 绥宁县| 石林| 策勒县| 出国| 大洼县| 西林县| 乳山市| 西乌珠穆沁旗| 固阳县| 蕲春县| 那曲县| 图片| 宁安市| 大港区|