Linux CentOS7 httpd 服務(wù)配置注釋_第1頁
已閱讀5頁,還剩3頁未讀, 繼續(xù)免費閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認(rèn)領(lǐng)

文檔簡介

1、linux centos7 httpd 服務(wù)配置注釋linux centos7 httpd 服務(wù)配置注釋apache 配置注釋serverroot "/etc/httpd" 指定服務(wù)配置根名目listen 80 監(jiān)聽端口include conf.modules.d/*.conf 包含模塊配置文件user apache 用法的用戶進程和組group apacheserveradmin rootlocalhost 服務(wù)器管理員郵箱,用于錯誤提醒。documentroot "/var/www/html" 指定服務(wù)網(wǎng)頁根名目 為指定名目設(shè)置不同權(quán)限 allowo

2、verride none 禁止用法.htaccess 中的命令 require all denied 禁止全部拜訪 allowoverride none require all granted 允許拜訪 options indexes followsymlinks 允許的參數(shù)(索引(建議禁用),尾隨軟銜接) allowoverride none require all granted directoryindex index.html 指定默認(rèn)首頁 require all denied 禁止拜訪該文件 errorlog "logs/error_log" 日志記錄loglev

3、el warn 日志配置 logformat "%h %l %u %t "%r" %s %b "%refereri" "%user-agenti"" combined logformat "%h %l %u %t "%r" %s %b" common logformat "%h %l %u %t "%r" %s %b "%refereri" "%user-agenti" %i %o" combin

4、edio customlog "logs/access_log" combined 指定日志文件名和格式(結(jié)合) scriptalias /cgi-bin/ "/var/www/cgi-bin/" 路徑別號 allowoverride none options none require all granted 指定文件格式和mime對應(yīng) typesconfig /etc/mime.types addtype application/x-compress .z addtype application/x-gzip .gz .tgz addtype text

5、/html .shtml addoutputfilter includes .shtml adddefaultcharset utf-8 指定默認(rèn)編碼 mimemagicfile conf/magic 指定mime enablesendfile on 開啟sendfile功能 sendfile功能必需在linux kernel 2.1版本以后內(nèi)核中才干開啟 sendfile功能挺直跳過了將內(nèi)容復(fù)制到用戶緩沖區(qū)的過程,挺直將文件內(nèi)容復(fù)制到了socket緩沖區(qū) 加快了文件的發(fā)送速度。 includeoptional conf.d/*.confconf.d/autoindex.confindexop

6、tions fancyindexing htmltable versionsort 索引選項alias /icons/ "/usr/share/httpd/icons/" options indexes multiviews followsymlinks allowoverride none require all granted addiconbyencoding (cmp,/icons/compressed.gif) x-compress x-gzip 按照文件編碼來分配圖標(biāo)addiconbytype (txt,/icons/text.gif) text/* 按照文件類

7、型來分配圖標(biāo)addiconbytype (img,/icons/image2.gif) image/*addiconbytype (snd,/icons/sound2.gif) audio/*addiconbytype (vid,/icons/movie.gif) video/*addicon /icons/binary.gif .bin .exe 按照文件后綴來分配圖標(biāo)addicon /icons/binhex.gif .hqxaddicon /icons/tar.gif .taraddicon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .ivadd

8、icon /icons/compressed.gif .z .z .tgz .gz .zipaddicon /icons/a.gif .ps .ai .epsaddicon /icons/layout.gif .html .shtml .htm .pdfaddicon /icons/text.gif .txtaddicon /icons/c.gif .caddicon /icons/p.gif .pl .pyaddicon /icons/f.gif .foraddicon /icons/dvi.gif .dviaddicon /icons/uuencoded.gif .uuaddicon /i

9、cons/script.gif .conf .sh .shar .csh .ksh .tcladdicon /icons/tex.gif .texaddicon /icons/bomb.gif /coreaddicon /icons/bomb.gif */core.*addicon /icons/back.gif .addicon /icons/hand.right.gif readmeaddicon /icons/folder.gif directoryaddicon /icons/blank.gif blankicondefaulticon /icons/unknown.gif 默認(rèn)的未知

10、文件readmename readme.html 和下面一個共同用于添加索引的上下文件內(nèi)容headername header.htmlindexignore .?* * * header* readme* rcs cvs *,v *,t 指定要躲藏的文件。conf.d/welcome.conf 僅將該規(guī)章用于規(guī)章匹配的url options -indexes 去除全部參數(shù) errordocument 403 /.noindex.html 錯誤返回代碼和網(wǎng)頁 allowoverride none require all granted alias /.noindex.html /usr/shar

11、e/httpd/noindex/index.htmlalias /noindex/css/bootstrap.min.css /usr/share/httpd/noindex/css/bootstrap.min.cssalias /noindex/css/open-sans.css /usr/share/httpd/noindex/css/open-sans.cssalias /images/apache_pb.gif /usr/share/httpd/noindex/images/apache_pb.gifalias /images/poweredby.png /usr/share/http

12、d/noindex/images/poweredby.pngconf.d/ssl.conflisten 443 httpssslpassphrasedialog exec:/usr/libexec/httpd-ssl-pass-dialog 加密私鑰的對話類型sslsessioncache shmcb:/run/httpd/sslcache(512000) ssl對話密鑰的存儲位置sslsessioncachetimeout 300 ssl對話密鑰的超時時光sslrandomseed startup file:/dev/urandom 256 隨機種子的獵取地址sslrandomseed co

13、nnect builtin 假如無法用法urandom則用法內(nèi)置隨機數(shù)生成器sslcryptodevice builtin 硬件加密策略,默認(rèn)用法內(nèi)置,可是用法openssl engine 插敘是否可是用法其他硬件加密策略sslcryptodevice rdrand 這個是intel的硬件加密引擎 errorlog logs/ssl_error_log 指定錯誤日志位置 transferlog logs/ssl_access_log 指定默認(rèn)日志位置 loglevel warn 指定日志級別 sslengine on 開啟 ssl 加密引擎 sslprotocol all -sslv2 配置所

14、加密策略可用,取消用法sslv2 sslciphersuite high:medium:!anull:!md5:!seed:!idea 密碼交換策略 high:用法全部triple-des的密碼 medium:全部具有128位加密的密碼 這里的 ! 是用于禁止指定的策略分離是anull(沒有身份驗證),md5(md5哈希函數(shù)),idea(idea加密) sslcertificatefile /etc/pki/tls/certs/localhost.crt 證書存儲位置 sslcertificatekeyfile /etc/pki/tls/private/localhost.key 密鑰存儲位置 ssloptions +stdenvvars 這里的選項是用于ssl銜接的額外配置 主要是給腳本提供一些其他的與ssl相關(guān)環(huán)境變量,不過會消耗部分系統(tǒng)資源,推舉關(guān)閉。下同。 ssloptions +stdenvvars browsermatch "msie 2-5" 這個是關(guān)于user-agent的相

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
  • 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論