2021-02-25

DME builds and uses
three main functions
1. Client tool. Users can use the DEM tool to perform object management, status monitoring, SQL query and debugging of the Dameng database.
2. Monitoring and warning. This function is the core function of Dameng DEM tool. Through the remote host deployment agent, it is possible to monitor the status of the remote host and the status of the Dameng database instance on the remote host. The important thing is that the monitoring of DEM is not limited to a single database instance, it can monitor and manage database clusters (MPP, RAC, data guard).
3. System management. The DEM tool provides system configuration and authority management of the tool itself, which is convenient for different users to use the tool at the same time, and restricts the authority of non-admin users.

1. Setting up the environment
1.1 Setting up and configuring the back-end database
Build the back-end database. Create a database as the DEM background database, and optimize the database dm.ini parameter configuration.

There is no MAX_BUFFER parameter in DM8, it needs to be modified in DM7

1.2 Execute the following script
Execute Start /home/dmdba/web/dem_init.sql in the disql of the background database

1.3 Configure the connection information of the background database
Open dem.war with a compression tool, and then configure ip, port, user name, password, connection pool size, SSL login information, etc. in the file WEB-INF/db.xml. If you need SSL security to connect to the backend database, you need to configure SSLDir and SSLPassword. The key pair is stored in the WEB-INF/sslDir directory by default. WEB-INF/db.xml configures the key file (SSLDir) for client connection to WEB-INF/sslDir/client_ssl/SYSDBA, and the password (SSLPassword) is empty , Corresponding to the login user SYSDBA configured in WEB-INF/db.xml, at this time, just copy WEB-INF/sslDir/server_ssl to the back-end database execution code directory.

1.4 install tomcat

We can choose to install tomcat in the database directory /home/dmdba

. Copy the modified dem.war in the previous chapter to the webapps directory of tomcat, here will decompress the war package after starting tomcat once

The files in it will be automatically decompressed afterwards

1.5 Configure and deploy tomcat
in conf/server.xml <Connector port="8080" protocol="HTTP/1.1"... Add attribute field maxPostSize="-1";

Modify the /etc/init.d/tomcat configuration file

Modify the tomcat file to add the following information

(If an error is reported before ./startup.sh, use the unset CATALINA_HOME command)

1.6 Log error

Use ./catalina.sh run to start the front desk to view the error message. After
troubleshooting, modify the environment file and add at the end:
[dmdba@localhost dmdba]# vi /home/dmdba/.bash_profile
export JAVA_HOME="/opt/jdk_v1.8.0 _144"
export CATALINA_HOME="/opt/tomcat"
export PATH=" JAVAHOME / bin: JAVA_HOME/bin:JAVAHOME/bin:PATH”
export CLASSPATH=".: J A V A H O M E / l i b : JAVA_HOME/lib: JAVAHOME/lib:JAVA_HOME/lib/tools.jar: J A V A H O M E / l i b / d t . j a r : JAVA_HOME/lib/dt.jar: JAVAHOME/lib/dt.jar: CATALINA_HOME/lib/servlet-api.jar"
Restart the file:
[dmdba@localhost dmdba]# source /home/dmdba/.bash_profile
View java environment variable information:
[dmdba@localhost dmdba]# echo $JAVA_HOME
/opt/jdk_v1 .8.0_144

Modify database environment variables

After modifying the relevant environment variables, it is found that the JAVA_HOME of the machine is not configured, and the basic configuration information of JAVA is not configured.
Find the real installation directory of java, and start the JAVA directory found by which java is not the directory where JAVA is actually stored.
Start to find the real installation directory of JAVA

After finding the real path, rewrite /etc/profile and add the following information at the end

After the source takes effect, the
query found
that the JAVA_HOME path in the above file has been modified correctly , so I won’t repeat it
)))))************************* **********************************************
Restart tomcat Related Services

1.7 Use the front desk to check if there are any errors, log in to the browser without errors

Login (admin/888888)

Landed successfully

2. Client monitoring agent deployment
Deploy and enable dmagent on the monitored node. The installation directory of DM already contains dmagent. We are deploying on the same host here. That is, both DEM service and DEM agent dmagent are deployed on the same host.

2.1 Modify agent configuration parameters

vi config.properties
# [DEM]
center.url = http: //192.168.56.101: 8080 / dem
center.agent_servlet = dem / dma_agent

2.2 Install and start the agent

2.3 View monitoring
Enter the monitoring host to view

Database monitoring

Remote connection
modify vi config.properties

Guess you like

Origin blog.csdn.net/weixin_44999079/article/details/114108892