Cov txheej txheem:

Kuv yuav pib Apache ntawm lwm qhov chaw nres nkoj li cas?
Kuv yuav pib Apache ntawm lwm qhov chaw nres nkoj li cas?

Video: Kuv yuav pib Apache ntawm lwm qhov chaw nres nkoj li cas?

Video: Kuv yuav pib Apache ntawm lwm qhov chaw nres nkoj li cas?
Video: Ntshe yog kuv tsis txawj hlub koj. 10/5/2017 2024, Tej zaum
Anonim

Hloov Apache default chaw nres nkoj mus rau qhov chaw nres nkoj kev cai

  1. Hloov Apache chaw nres nkoj ntawm Debian / Ubuntu. Kho kom raug /etc/ apache 2 / chaw nres nkoj .conf cov ntaub ntawv, $ sudo vi /etc/ apache 2 / chaw nres nkoj .conf. Nrhiav cov kab hauv qab no: Mloog 80.
  2. Hloov Apache chaw nres nkoj ntawm RHEL/CentOS. Xyuas kom tseeb tias koj tau nruab Apache webserver ua ntej.

Ib yam li ntawd, tib neeg nug, Kuv tuaj yeem hloov tus lej chaw nres nkoj hauv Apache li cas?

Txhawm rau hloov XAMPP Apache server chaw nres nkoj ntawm no cov txheej txheem:

  1. Xaiv tus lej chaw nres nkoj dawb. Qhov chaw nres nkoj siv los ntawm Apache yog 80.
  2. Kho cov ntaub ntawv " httpd. conf"
  3. Kho cov ntaub ntawv "http-ssl. conf"
  4. Configure XAMPP Apache server settings. Yog tias koj xav nkag mus rau localhost yam tsis qhia tus lej chaw nres nkoj hauv URL.

Ib yam li ntawd, cov txheej txheem tuaj yeem mloog ntawm ntau qhov chaw nres nkoj? 1 Teb. Yog, ib leeg txheej txheem tuaj yeem mloog ntawm ntau qhov chaw nres nkoj , ib yam li 80 + 443 ua tiav. Feem ntau koj muaj ib leeg txheej txheem thiab tom qab ntawd ntau threads tuav cov kev thov thaum lawv tab tom tuaj.

Ua li no, kuv yuav ua li cas khiav ib lub localhost ntawm ib qhov chaw nres nkoj sib txawv?

Qhib C: xamppapacheconf, nrhiav qhov httpd. conf cov ntaub ntawv thiab qhib nrog notepad ++. Nrhiav cov kab no thiab hloov 80 nyob rau hauv kab kawg lwm yam chaw nres nkoj , piv txwv li 8080. Qhov no peb yuav ua tau khiav Apache tab sis localhost /url yuav tsis ua haujlwm rau qhov koj xav tau ntxiv chaw nres nkoj tus lej rau hauv URL.

Kuv yuav ua li cas thiaj paub tias qhov chaw nres nkoj Apache tab tom ua haujlwm li cas?

HTTP server, los ntawm lub neej ntawd, khiav ntawm chaw nres nkoj 80 rau kev tsim khoom. Rau kuaj , koj tuaj yeem xaiv a chaw nres nkoj tus lej ntawm 1024 txog 65535, uas tsis yog siv los ntawm daim ntawv thov uas twb muaj lawm (koj tuaj yeem ua tau khiav txib "netstat" rau kuaj cov kev sib txuas uas twb muaj lawm). Peb yuav khiav tus Apache ntawm chaw nres nkoj 8000.

Pom zoo: