Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Linux configure a http web page

2025-02-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

Use apache to build a web page and be able to access it normally

Using the yum install httpd -y command will automatically go to the yum source to get the required rpm package

Wait for installation success prompt complete

Because the firewall is turned on, you need to edit the firewall with the command vi /etc/sysconfig/iptables, adding a rule to allow http port 80

Restart firewall after saving service iptables restart

http web files are generally stored in the/var/www/html folder, here use the touch index.html command to create an index.htm file

Use vi to edit the new file and write something random in the file to test it.

Write, save, exit edit mode.

Restart http service using the command service httpd restart

Restart successfully, you can use the browser to enter the server ip browsing just created a web file

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report