免费注册 查看新帖 |

Chinaunix

广告
  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1990 | 回复: 7
打印 上一主题 下一主题

[Web] [启动] apache启动报错 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2005-12-12 16:00 |只看该作者 |倒序浏览
[root@localhost bin]# ./apachectl start
httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
httpd (pid 15923) already running

[root@localhost bin]# ./httpd --help
httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
(9Address already in use: make_sock: could not bind to address 192.168.10.200:80
no listening sockets available, shutting down
Unable to open logs





谁能给个方法怎么解决这个问题?为什么ServerName 不能用本机的ip:非得用127.0.0.1 或是主机的完整域名?

[ 本帖最后由 HonestQiao 于 2005-12-13 14:45 编辑 ]

论坛徽章:
62
2016科比退役纪念章
日期:2016-06-28 17:45:06奥兰多魔术
日期:2015-05-04 22:47:40菠菜神灯
日期:2015-05-04 22:35:07菠菜神灯
日期:2015-05-04 22:35:02NBA季后赛大富翁
日期:2015-05-04 22:33:34NBA常规赛纪念章
日期:2015-05-04 22:32:032015年亚洲杯纪念徽章
日期:2015-04-14 16:54:452015年亚洲杯之朝鲜
日期:2015-03-19 23:03:16明尼苏达森林狼
日期:2015-03-16 21:51:152015小元宵徽章
日期:2015-03-06 15:57:202015年迎新春徽章
日期:2015-03-04 09:55:282015年辞旧岁徽章
日期:2015-03-03 16:54:15
2 [报告]
发表于 2005-12-12 16:04 |只看该作者
配置ServerName就好。

httpd 的用法多看看手册。

论坛徽章:
0
3 [报告]
发表于 2005-12-12 16:22 |只看该作者
#apachect1 stop
#vi httpd.conf
ServerName =>ServerName 1270.0.1
#apachect1 start
ok?

论坛徽章:
0
4 [报告]
发表于 2005-12-12 18:44 |只看该作者
ok 就得用127.0.0.1  换成本地的就不行了

论坛徽章:
0
5 [报告]
发表于 2005-12-14 11:39 |只看该作者

版本:httpd2_2.2.0

又出问题了!!还是抱错
root@localhost bin]# ./httpd --help
(9 8 ) Address already in use: make_sock: could not bind to address 192.168.10.200:80
no listening sockets available, shutting down
Unable to open logs





我的虚拟主机做不了可能 就是这个原因:
我注释了这三项"
   #ServerAdmin
   #ServerName
   #DocumentRoot
配置虚拟主机如下:
NameVirtualHost 192.168.10.200:80
<VirtualHost 192.168.10.200:80>
    ServerAdmin webmaster@dummy-host.example.com
    DocumentRoot /var/www/html
    ServerName host1.test.cn
    ServerAlias html
    ErrorLog logs/host1.test.cn-error_log
    CustomLog logs/host1.test.cn-access_log common
</VirtualHost>

<VirtualHost 192.168.10.200:80>
    ServerAdmin webmaster@dummy-host2.example.com
    DocumentRoot /var/www/hr
    ServerName host2.test.cn
    ServerAlias hr
    ErrorLog logs/host2.test.cn-error_log
    CustomLog logs/host2.test.cn-access_log common
</VirtualHost>


求救啊?!!

[ 本帖最后由 lazy_bug 于 2005-12-14 11:40 编辑 ]

论坛徽章:
1
技术图书徽章
日期:2013-12-05 23:25:45
6 [报告]
发表于 2005-12-14 16:26 |只看该作者
你前面的Listen怎么设置的呢?

论坛徽章:
62
2016科比退役纪念章
日期:2016-06-28 17:45:06奥兰多魔术
日期:2015-05-04 22:47:40菠菜神灯
日期:2015-05-04 22:35:07菠菜神灯
日期:2015-05-04 22:35:02NBA季后赛大富翁
日期:2015-05-04 22:33:34NBA常规赛纪念章
日期:2015-05-04 22:32:032015年亚洲杯纪念徽章
日期:2015-04-14 16:54:452015年亚洲杯之朝鲜
日期:2015-03-19 23:03:16明尼苏达森林狼
日期:2015-03-16 21:51:152015小元宵徽章
日期:2015-03-06 15:57:202015年迎新春徽章
日期:2015-03-04 09:55:282015年辞旧岁徽章
日期:2015-03-03 16:54:15
7 [报告]
发表于 2005-12-14 17:50 |只看该作者
劝你好好看httpd   的语法,就是不看。

httpd  -help
就一个-

论坛徽章:
0
8 [报告]
发表于 2005-12-15 09:58 |只看该作者
呵呵 ,一定要再多看几遍!! 两个命令显示结果是不一样的,虚拟机器的问题我已经解决了.apache2.2的版本设置
虚拟机有点不同,呵呵!!  以下是, httpd -hlep 和httpd --help的不同的信息.
       [root@host1 bin]# ./httpd -help
Usage: ./httpd [-D name] [-d directory] [-f file]
               [-C "directive"] [-c "directive"]
               [-k start|restart|graceful|graceful-stop|stop]
               [-v] [-V] [-h] [-l] [-L] [-t] [-S]
Options:
  -D name            : define a name for use in <IfDefine name> directives
  -d directory       : specify an alternate initial ServerRoot
  -f file            : specify an alternate ServerConfigFile
  -C "directive"     : process directive before reading config files
  -c "directive"     : process directive after reading config files
  -e level           : show startup errors of level (see LogLevel)
  -E file            : log startup errors to file
  -v                 : show version number
  -V                 : show compile settings
  -h                 : list available command line options (this page)
  -l                 : list compiled in modules
  -L                 : list available configuration directives
  -t -D DUMP_VHOSTS  : show parsed settings (currently only vhost settings)
  -S                 : a synonym for -t -D DUMP_VHOSTS
  -t -D DUMP_MODULES : show all loaded modules
  -M                 : a synonym for -t -D DUMP_MODULES
  -t                 : run syntax check for config files
[root@host1 bin]# ./httpd --help
(9Address already in use: make_sock: could not bind to address 192.168.10.200:80
no listening sockets available, shutting down
Unable to open logs
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP