免费注册 查看新帖 |

Chinaunix

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

MC/SG脚本问题 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2003-03-12 14:26 |只看该作者 |倒序浏览
如果我想在MC/SG运行前,和IP地址切换(failover)前及IP地址切换后(failback)运行一段脚本,可以吗?应该加在什么地方?谢谢
比如我想在MC/SG运行前,停掉一个进程,MC/SG运行后再启动该进程;同样在IP切换前停掉进程,切换后再启动它。

论坛徽章:
0
2 [报告]
发表于 2003-03-16 05:04 |只看该作者

MC/SG脚本问题

Hi,

The general steps to setup MC/SG are as following:

1. Install MC/SG on all nodes.
2. Setup cluster :
Use "cmquery" to create an ascii configuration file, then vi this file; then use "cmcheckconf" to see if there is any error; then use "cmapplyconf" to distribute the binary.

3. Setup package:
Use "cmmakepkg -p" to create a package ascii configuration file, edit, cmcheckconf, cmapplyconf; then use "cmmakepkg -s" to create a package control file, this is a shell script.

Inside this shell script, there are two functions: "customer_defined_run_cmds" and "customer_defined_halt_cmds".

The customer_defined_run_cmds can let you put any commands/scripts, same thing with the customer_defined_halt_cmds.

The sequence when a package starts:
1) activate_volume_group
2) check_and_mount
3) add_ip_address
4) customer_defined_run_cmds
5) start_services
6) start_resources

The sequence when a package stops:
1) stop_resources
2) halt_services
3) customer_defined_halt_cmds
4) remove_ip_address
5) umount_fs
6) deactivate_volume_group

I suggest you to download the "Managing MC/ServiceGuard" from HP, here is the URL:   http://docs.hp.com/hpux/pdf/B3936-90065.pdf

Good luck.

论坛徽章:
0
3 [报告]
发表于 2003-03-17 13:47 |只看该作者

MC/SG脚本问题

谢谢Shad,我想再请教一下,如果想在Assigns package IP addresses to the LAN card on the node.前执行自己的脚本,而不是在Executes any customer-defined run commands中执行,可以吗。谢谢
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

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

清除 Cookies - ChinaUnix - Archiver - WAP - TOP