boa 服务的启动

使用 buildroot 添加 boa 服务后,通过命令 boa 不能启动该服务,就研究了一下boa.conf的配置。

  • etc/boa/boa.conf
    # 更改user 和Group 为root.
    User root                                                                       
    Group root
  • 添加两个文件:
     mkdir /var/log/boa  -p
     touch /var/log/boa/error_log
     touch /var/log/boa/access_log
    # 因为他们对应 etc/boa/boa.conf 中的:
    ErrorLog /var/log/boa/error_log
    AccessLog /var/log/boa/access_log
    或者将该配置修改为:
    ErrorLog /var/log/error_log
    AccessLog /var/log/access_log
  • 添加一个测试网页:
    # /var/www/index.html
    # 写一个测试的html 文件:
    <html>                                                                          
    <body>                                                                          
                                                                                
    <h1>                                                                            
    mytest                                                                          
    </h1>                                                                           
                                                                                
    </body>                                                                         
    </html>
    #  他们对应的文件是在  etc/boa/boa.conf 中的:
    DocumentRoot /var/www
    DirectoryIndex index.html
  • 启动
    boa &

参考: http://blog.csdn.net/xxgxgx/article/details/51034652

原文地址:https://www.cnblogs.com/chenfulin5/p/6744850.html