Installation and Deployment Guide 中关于导入导出
导入导出作用:
1. 方便重复的安装。
2. 导出一组功能(事件菜单或工具),再导入到另一个事件服务器。
3. 备份。
列出要导出的项,存入confpack.list中,此文件可以按需修改。保留需要导出的项。
[root@hejun /opt/netcool/omnibus/bin]# ./nco_confpack -list -file /tmp/confpack.list -server HEJUN -user root
[root@hejun /opt/netcool/omnibus/bin]# ls -l /tmp/confpack.list
-rw-r--r-- 1 root root 26933 Nov 11 02:35 /tmp/confpack.list
The exclusions file contains a listing of files and directories to exclude when exporting any configuration package. The exclusions filename is $NCHOME/omnibus/etc/exclusions.xml.
Exclusions.xml文件中的行在导出时排除在外。不进行导出。可以在里面进行增加或者减少。此文件默认的项表示那些标准的目录和文件。
[root@hejun /opt/netcool/omnibus/bin]# nco_confpack -export -file /tmp/confpack.list -package HEJUN.jar -user root
[root@hejun /opt/netcool/omnibus/bin]# ls -l HEJUN.jar
-rw-r--r-- 1 root root 28183 Nov 11 02:36 HEJUN.jar
[root@hejun /opt/netcool/omnibus/bin]#
可以查看导出包的内容,用-file参数重定向到文件。不用标准输出
[root@hejun /opt/netcool/omnibus/bin]# ./nco_confpack -contents -package HEJUN.jar -file /tmp/contents.txt
导入
nco_confpack -import -package HEJUN.jar -server NCOMS
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/22775238/viewspace-619420/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/22775238/viewspace-619420/