惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
V
V2EX
WordPress大学
WordPress大学
U
Unit 42
I
InfoQ
A
About on SuperTechFans
宝玉的分享
宝玉的分享
J
Java Code Geeks
博客园 - 司徒正美
爱范儿
爱范儿
Engineering at Meta
Engineering at Meta
G
Google Developers Blog
人人都是产品经理
人人都是产品经理
小众软件
小众软件
Microsoft Security Blog
Microsoft Security Blog
L
LangChain Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Hugging Face - Blog
Hugging Face - Blog
H
Hackread – Cybersecurity News, Data Breaches, AI and More
aimingoo的专栏
aimingoo的专栏
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Last Week in AI
Last Week in AI
腾讯CDC
Recent Announcements
Recent Announcements

博客园 - 冯东

Oracle问题诊断过程常用SQL Cognos10 RedHat5.4 X64 安装记录 不用JavaScript实现列表排序(利用钻取实现) 如何让列表实现任意字段类型的排序 如何使导出的excel和报表分页设置不一样 基于Oracle触发器的报表版本保存工具 Cognos重建CSK JS屏蔽Cognos报表右键菜单 - 冯东 - 博客园 利用JS重写Cognos右键菜单 Cognos亲和力解释 Java中Split函数的问题 - 冯东 - 博客园 修改Oracle数据库的字符集 Oracle锁定选出的结果集 面试题 北漂,真的来了 通过修改Linux服务自动启动指定应用程序 Oracle自动启动(解决了Failed to auto-start Oracle Net Listene和Message 1053 not found错误) 由于系统时间修改导致Oracle启动失败 - 冯东 - 博客园 Oracle中删除包含物化视图的表空间的方法
从命令行启动Cognos的方法
冯东 · 2010-11-07 · via 博客园 - 冯东

昨天朋友培训完cognos,客户说他们有台服务器有问题cognos服务启动不起来,他去帮忙解决了,本来是约好到培训楼下见面的,我上去帮忙看了一下。
启动过程一点日志信息都没有输出直接报0103错误,后来我发现在服务中有个IBM Cognos Content store(大概是这个,具体名字也记不清了)的服务,判断这个问题应该是安装过程中选中了Cognos Content Database,但是在Cognos Configuration中配置的content store却是Oracle导致的。因为如果安装过程中你选中了cognos content database组件,那么你配置的content store必须是 cognos content database,配置其他的都不行。所以把cognos卸载,重新安装,本以为这次应该没有问题了,但是还是报错,想着可能是环境变量的问题,又把环境变量改了改,还是不行,从cognos configuration启动还是报错,不过我感觉一切都没有问题了。
所以换了种方式,从命令行启动,通过调用cogbootstrapservice来启动cognos。在windows环境中cognos第一次启动会创建一个系统服务
 
从上图可以看到服务所调用的可执行文件就是cogbootstrapservice.exe,服务类型为自动,所以系统启动后会自动调用此服务,启动cognos。Ps:如果是服务器中启动类型最好是自动,省的有人再去启动它,如果是自己的机器安装仅是为了学习,最好设置为手动,要不然你的系统会在登录时等很长时间。
到命令行里,切到c8_localation/bin目录下,执行cogbootstrapservice.exe –help查看该命令的帮助

Manage the Cognos Bootstrap Service.

By default the service name is determined from startup configuration,
but may be overriden by -name.

Note that on Win32 CBS operates invisibly, with no console window
unless -console is specified.  -help, -d and -v are exceptions: they
always open a console.

The option -stdoutLog=DEBUG|INFO|WARN|ERROR|FATAL is optional for all
flavours of the command line.  It causes log messages that describe the
actvities of CBS to be written to stdout.

Usage:

 cogbootstrapservice -i[a|m] [-name=serviceName] [-console]
  Install as service.  Service is automatically started (-i or -ia) or manually (-im).

 cogbootstrapservice -u [-name=serviceName] [-console]
  Uninstall the service.

 cogbootstrapservice -isRegistered [-name=serviceName] [-console]
  Test if the service is installed.
  Exit code is 0 if the service is not installed, otherwise is the numeric value of the "Start" parameter:2 - auto, 3 - manual, 4 - disabled.

 cogbootstrapservice -start [-name=serviceName] [-timeLimitSec=nn] [-console]
  Start the service.  Note that the operation blocks until the service is started or the specified time limit is reached.

 cogbootstrapservice -stop [-name=serviceName] [-timeLimitSec=nn] [-console]
  Stop the service.  Note that the operation blocks until the service is stopped or the specified time limit is reached.

 cogbootstrapservice -isrunning [-name=serviceName] [-console]
  Test is the service is running.  Exit code of 0 indicates that the service is running.

 cogbootstrapservice -d
  Run the service as a console application.

其实最常用的也就是-d –start –stop这几个参数,-I –u –isRegistered这几个一般都是Cognos Configuration调用用来创建或删除服务用的
-d参数表示要启动一个控制台窗口
-start表示启动服务,帮助说这个操作是个阻塞型操作,知道服务启动才会往下执行,但是我在windows下调用时并有发现他是阻塞的。
-stop关闭服务器,同样的,我也没有发现它是阻塞的
如果我想启动服务执行 cogbootstraoservice.exe –start就可以了
如果想让它弹出个窗口 cogbootstrapservice.exe –d –start(如果在telnet调用的话服务器中不弹出窗口)
想关闭服务 执行 cogbootstrapservice.ext –stop
说到这里还有一种方式也是在可以在命令行里启动cognos服务,比cogbootstrapservice更简单,它就是c8/bin目录下的startup.bat和shutdown.bat
Cogbootstrapservice和startup.bat的区别在于,cogbootstrapservice会启动tomcat的同时还启动一个守护进程,当tomcat被意外终止,它还会再次调用,而startup.bat则没有守护进程