Excerpt |
---|
Discusses how to manage the Trafodion test environment. |
...
Table of Contents | ||||
---|---|---|---|---|
|
...
Manage Trafodion
The following table provides an overview of the different Trafodion management scripts.
Component | Start | Stop | Status |
---|---|---|---|
All of Trafodion | sqstart | sqstop | sqcheck |
DCS (Database Connectivity Services) | dcsstart | dcsstop | dcscheck |
REST Server | reststart | reststop | - |
LOB Server | lobstart | lobstop | - |
RMS Server | rmsstart | rmsstop | rmscheck |
Code Block | ||||
---|---|---|---|---|
| ||||
cd $TRAF_HOME/sql/scripts
sqstart
sqcheck |
Validate Trafodion Installation
You can use sqlci
(part of the base product) or trafci
(requires separate install; see Trafodion Client Installation Guide) to validate your installation.
Code Block | ||||
---|---|---|---|---|
| ||||
get schemas;
create table table1 (a int);
invoke table1;
insert into table1 values (1), (2), (3), (4);
select * from table1;
drop table table1;
exit; |
Assuming no errors, your installation has been successful. You can start working on your modifications.
Troubleshooting Tips
If you are not able to start up the environment or if there are problems running sqlci
or trafci
, then verify that the all the processes are up and running.
swstatus
should show at 6 java servers and 2 MySQL processes.sqcheck
should indicate all processes are running.
If processes are not running as expected, then:
sqstop
to shut down Trafodion. If some Trafodion processes do not terminate cleanly, then runckillall
.swstopall
to shut down the Hadoop ecosystem.swstartall
to restart the Hadoop ecosystem.sqstart
to restart Trafodion.
If problems persist please review logs:
Start with the log file with the recent modification time and traverse from any event backwards to the root cause of the problem
$TRAF_HOME/sql/local_hadoop/*/log
: Hadoop, HBase, and Hive logs.$TRAF_HOME/logs
: Trafodion logs.- In Trafodion 2.1 TM has been improved to log all critical events into tm_<nid>.log
- Look for TM core files in directory /proc/sys/kernel/core_pattern or in $TRAF_HOME/sql/scripts
- Look at the stdout_<traf_component> files in $TRAF_HOME/sql/scripts
Manage Hadoop Environment
Pre-Existing Hadoop
If you are doing Trafodion development on a pre-existing Hadoop distribution, then do the following:
- Distribution: Use the distribution management too. For example: Apache Ambari or Cloudera Manager.
- Regular Hadoop: Use the start/stop script for each Hadoop environment.
Local Hadoop
Use the following commands to manage the Hadoop environment.
Command | Usage |
---|---|
swstartall | Start the complete Hadoop environment. |
swstopall | Stops the complete Hadoop environment. |
swstatus | Checks the status of the Hadoop environment. |
swuninstall_local_hadoop | Removes the Hadoop installation. |
Downloading New Source Code
You need to do the following each time you download new source code.
Code Block | ||
---|---|---|
| ||
cd <Trafodion source directory>
source ./env.sh
cd $MY_SQROOT/etc
# delete ms.env, if it exists
rm ms.env
cd $MY_SQROOT/sql/scripts
sqgen |
Code Block | ||||
---|---|---|---|---|
| ||||
cd mysource/trafidion
source ./env.sh
cd $MY_SQROOT/etc
# delete ms.env, if it exists
rm ms.env
cd $MY_SQROOT/sql/scripts
sqgen |