0

Prologue: I would like to make my site live from my PC(Just for some testing). In Windows, I just click on the WAMP icon in my tray and it gives me an option to "Put Online", meaning anyone on the internet can access the site if I give them the link(with my ip in it)

Current Situation: I have switched to CentOS and can't find an option to make it online. I thought that there will be a switch in httpd.exe like /etc/init.d/httpd restart But I cant find proper answer with google. Help me out

4

3 に答える 3

0

1つの質問、ローカルサーバーは機能しますか?

もしそうなら、iptablesとポート80の小さな概要を見てください

于 2012-07-24T07:51:05.700 に答える
0

それを達成するには、スーパーユーザーである必要があります。

/etc/sysconfig/iptables ファイルを開きます。

vi /etc/sysconfig/iptables

これは標準的な手順です 次の行を追加して保存します

-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 80 -j ACCEPT

ただし、これはうまくいかなかったので、「REJECT」が含まれている行を削除するとうまくいきました

iptablesサービスを再起動することを忘れないでください

service iptables restart

donald123 に感謝

于 2012-07-27T05:03:52.213 に答える
0

まず、以下が与えられていることを確認してください。

I) httpd.conf で以下を探します。

#リッスン12.34.56.78:80
リッスン 80

Listen 80 がアクティブであること (または使用するポート) を確認します。

II) ポート 80 が自由に接続できるかどうか、IPTABLES またはファイアウォールを確認します。

于 2012-07-24T07:25:35.073 に答える