|
发表于 2007-3-7 22:49:04
|
显示全部楼层
原文:http://boinc.berkeley.edu/project_cookbook.php
[english version] last modified at 2007-03-07 22:42
Project creation cookbook
项目创建过程说明
--------------------------------------------------------------------------------
Make skeletal project
创建框架项目
Install and configure all prerequisite software (follow the directions carefully). Make sure MySQL is configured and running.
Get the BOINC
Compile the BOINC software, say into HOME/boinc.
Run HOME/boinc/tools/make_project
Append the contents of projects/PROJECT/PROJECT.httpd.conf to httpd.conf and restart Apache.
Use 'crontab' to insert a cron job to run the project's periodic tasks, e.g.
0,5,10,15,20,25,30,35,40,45,50,55 * * * * HOME/projects/PROJECT/bin/start --cron
(if cron cannot run 'start', try using a helper script to set PATH and PYTHONPATH)
Copy project.xml from HOME/boinc/tools to HOME/projects/PROJECT, edit it to reflect your applications and platforms, and run bin/xadd.
Edit html/project/project.inc, changing the master URL and copyright holder.
Protect the html/ops directory (e.g. by putting .htaccess and .htpasswd files there).
安装和配置所有必要的软件(严格按照说明进行)。确保MySQL数据库被正确配置和运行。
取得BOINC的源程序
编译BOINC软件,并且放到HOME/boinc。
添加文件/projects/PROJECT/PROJECT.httpd.conf的内容到httpd.conf,然后重新启动Apach服务。
使用'crontab'命令增加项目的需定期执行任务,例如:
0,5,10,15,20,25,30,35,40,45,50,55 * * * * HOME/projects/PROJECT/bin/start --cron
(如果cron不能运行'start',可以试试运行脚本来设置PATH和PYTHONPATH)
将project.xml从HOME/boinc/tools复制到HOME/projects/PROJECT,编辑project.xml以与你的应用和平台相适应,然后运行bin/xadd。
编辑html/project/project.inc,改变主URL路径和版权人。
保护目录html/ops(例如,放入.htaccess和.htpasswd文件)
Visible result: the project web site is up. The database 'platforms' table has several rows.
Troubleshooting: check the Apache access and error logs.
结果检查:项目网站正常运行。数据库表'platforms'存在几行数据。
错误处理:检查apache访问和错误日志
Create an application version
Create a BOINC application executable (if you're in a hurry, use the test application).
Copy the executable to HOME/projects/PROJECTNAME/apps/APPNAME
cd to HOME/projects/PROJECTNAME
run bin//update_versions, type y or return.
run ./stop && ./start
Visible result: the web site's Applications page has an entry.
建立应用版本
建立BOINC应用可执行程序(如果你比较忙,使用测试应用)
复制可执行程序到HOME/projects/PROJECTNAME/appls/appName
cd to HOME/projects/PROJECTNAME
运行bin/update_verisons,输入Y或返回
运行./stop && ./start
结果检查:网站Application页有一条记录
Create a work unit
Using a text editor, create a work unit template file and a result template file.
Run create_work
Edit config.xml to add <daemon> records for make_work, feeder, transitioner, file_deleter, the trivial validator, and the trivial assimilator. For example
<daemon>
<cmd>validate_test -app appname</cmd>
<output>validate_test.log</output>
<pid_file>validate_test.pid</pid_file>
</daemon>
Visible result: after a project restart, 'status' shows the above daemon processes running.
Troubleshooting: check the log files of all daemon processes.
创建工作单元
使用文本编辑器建立一个工作单元模板和一个结果模板文件。
运行create_work
编辑config.xml,为make_work,transitioner,file_deleter,trivial validator 和trivial assimilator建立daemon记录.例如:
<daemon>
<cmd>validate_test -app appname</cmd>
<output>validate_test.log</output>
<pid_file>validate_test.pid</pid_file>
</daemon>
结查检查:项目重启后,'status'显示上面的守候进程正在运行。
错误处理:检查错误日志和所有的守候进程。
Test the system
Create a client directory (on the same computer or different computer), say HOME/boinc_client. Copy the core client there.
Using the web interface, create an account on the project.
Run the core client; enter the project URL and the account key.
Visible result: the client does a stream of work; the web site shows credit accumulating.
Troubleshooting: check the log files of all daemon processes.
测试系统
建立客户端目录(可在相同或不同的计算机上),如/home/boinc_client。将核心客户端复制到这。
使用WEB接口建立账户
结果检查:客户端处理工作流;网站显示信用积分。
错误处理:检查错误日志和所有的守候进程。
Develop back end components
Write a work generator.
Write a validator.
Write an assimilator.
Edit the configuration file to use these programs instead of the place-holder programs.
Make sure everything works correctly.
开发后台程序组件
编写工作发生器
编写较验器
编写模拟器
编辑配置文件用这些程序取代place_holder程序。
确保所有工作正常完成
Extras
Add message board categories: see html/ops/create_forums.php
其它
增加留言版功能:参考html/ops/create_forums.php
--------------------------------------------------------------------------------
Return to BOINC main page
Last modified 9:17 PM UTC, September 12 2006.
Copyright © 2007 University of California. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation. |
评分
-
查看全部评分
|