TimesTen 安装完之后,缺省是已经起来了的。页可以通过命令来确定TimesTen是否已经启动。
[tt1@west-mountain bin]$ ps -au tt1|grep timesten
5123 ? 00:00:00 timestend
5126 ? 00:00:00 timestensubd
5129 ? 00:00:00 timestensubd
5132 ? 00:00:00 timestensubd
5133 ? 00:00:00 timestensubd
5134 ? 00:00:00 timestenws
[tt1@west-mountain bin]$ ttstatus
TimesTen status report as of Thu Jun 14 20:39:43 2007
Daemon pid 5123 port 17000 instance tt70
TimesTen server pid 5158 started on port 17002
TimesTen webserver pid 5134 started on port 17004
————————————————————————
Access control enabled.
End of report
可以看到有几个TimesTen的后台守护进程(timestensubd)已经启动了,还可以通过TimesTen的ttstatus命令来查看具体的一些信息,比如端口,进程号等。缺省的有TimesTen的主守护进程(Daemon)、Client/Server中的Server守护进程 以及 TimesTen的一个WebServer 进程。
如果ps 命令没有返回信息,或者ttStatus 命令返回TimesTen未启动:
[tt1@west-mountain bin]$ ps -au tt1|grep timesten
[tt1@west-mountain bin]$ ttstatus
ttStatus: Could not connect to the TimesTen daemon.
If the TimesTen daemon is not running, please start it
by running “ttDaemonAdmin -start”.
则通过命令 ttDaemonAdmin 来启动TimesTen:
[tt1@west-mountain bin]$ ttdaemonadmin -start
TimesTen Daemon startup OK.
[tt1@west-mountain bin]$ ttstatus
TimesTen status report as of Thu Jun 14 20:44:01 2007
Daemon pid 5354 port 17000 instance tt70
TimesTen server pid 5374 started on port 17002
TimesTen webserver pid 5370 started on port 17004
————————————————————————
Access control enabled.
End of report
相应的关闭TimesTen的命令则为:
[tt1@west-mountain bin]$ ttdaemonadmin -stop
TimesTen Daemon stopped.
[tt1@west-mountain bin]$ ttstatus
ttStatus: Could not connect to the TimesTen daemon.
If the TimesTen daemon is not running, please start it
by running “ttDaemonAdmin -start”.
关闭TimesTen前,建议先断开所有连接到TimesTen的应用,如果启动了Cache Agent和Replication Agent,建议也都先停掉。