达梦DMHS 控制台中文一直显示乱码,修改终端字符集也没有生效:
[ddave@www.cndba.cn USTC]$ pwd
/dm/dmhs/INST_HS/USTC
[ddave@www.cndba.cn USTC]$ ./dmhs_console
DMHS console tool: V4.3.04-Build(2023.01.11-122276trunc)_64_2301
Copyright (c) 2020, DMHS. All rights reserved.
Type ? or "help" for help, type "quit" to quit console.
▒▒ӵ▒DMHS▒▒127.0.0.1:5345
▒гɹ▒
Dameng HS Server V4.3.04-Build(2023.01.11-122276trunc)_64_2301
DMHS> ?
"help [cmd]"▒▒ʾ▒▒▒▒▒▒▒▒ʹ▒÷▒▒▒▒▒
? ▒▒ʾ▒▒▒▒̨▒▒▒
@ ִ▒п▒▒▒̨▒▒▒▒ű▒▒▒
all_link ▒▒ʾվ▒▒▒▒▒˹▒ϵ▒▒
apply ǿ▒Ʒ▒▒▒▒▒▒͵▒ǰ▒▒־▒▒
clear ▒▒▒Ŀ▒▒▒▒▒▒▒▒▒Ϣ▒▒
commit ▒ύָ▒▒▒▒▒▒▒▒
conf ▒▒▒▒▒Ҫ▒▒▒▒▒▒▒▒ļ▒ģ▒塣
connect ▒▒▒DMHS▒▒▒▒ģ▒顣
continue ▒▒▒▒ִ▒ж˵▒DDL▒▒▒▒▒▒▒ִ▒С▒
copy ִ▒▒װ▒ز▒▒▒
cp ▒▒ʾ▒▒־▒▒▒▒ģ▒▒▒▒▒Ϣ▒▒
cpt ▒▒ʾ▒▒▒▒ģ▒▒▒״̬ͳ▒▒▒▒Ϣ▒▒
decrypt ▒▒▒▒ENCRYPT▒▒▒▒▒▒ɵ▒▒▒▒▒Ϊ▒▒▒ġ▒
deltrace ȡ▒▒▒ָ▒▒▒▒▒ͬ▒▒▒▒▒١▒
encrypt ▒▒ָ▒▒▒ַ▒▒▒м▒▒ܡ▒
epoch ת▒▒һ▒▒ʱ▒▒▒ֵΪ▒▒▒ڸ▒ʽ▒▒
exec ▒鿴Ŀ▒▒ִ▒▒ģ▒▒▒ͳ▒▒▒▒Ϣ▒▒
exit ▒˳▒▒▒▒̨▒▒▒▒
get ▒▒ȡָ▒▒վ▒▒ļ▒▒▒LSNֵ▒▒
help ▒▒ʾ▒▒▒▒̨▒▒▒
help [cmd] ▒▒ʾָ▒▒▒▒▒▒▒▒▒ϸ▒▒▒▒▒▒Ϣ▒▒
lag ▒▒ȡͬ▒▒▒▒▒▒ӳ▒ʱ▒䡣
ld ▒▒ȡ▒▒ǰװ▒▒▒▒▒▒Ľ▒ȡ▒
lic ▒▒ȡ▒▒Ȩ▒▒KEY▒▒Ϣ▒▒
mem_check ▒鿴▒ڴ▒ʹ▒▒▒▒▒
pack ▒▒ʾ▒汾▒▒▒▒▒▒Ϣ
print ▒▒ӡĿ▒▒▒ͬ▒▒▒▒▒▒▒▒▒▒▒▒Ϣ▒▒
quit ▒˳▒▒▒▒̨▒▒▒▒
rollback ▒ع▒ָ▒▒▒▒▒▒▒▒
save_arch ▒▒ָ▒▒▒鵵▒▒▒▒▒▒▒▒ء▒
seq ִ▒▒▒▒▒▒ͬ▒▒▒▒
set ▒▒▒ÿ▒▒▒̨▒▒ʾ▒▒▒▒▒▒▒▒▒▒▒▒▒õȡ▒
show ▒鿴▒▒Ϣ▒▒▒▒▒▒▒½▒▒Ϣ▒ȡ▒
start ▒▒ͬ▒▒▒▒▒▒
state ▒▒ʾͬ▒▒▒▒ģ▒▒▒▒Ϣ▒▒
stop ֹͣͬ▒▒▒▒▒▒
tableinfo ▒▒ʾͬ▒▒▒▒▒ִ▒▒▒▒Ϣ▒▒
thr ▒▒ʾĿ▒▒▒ִ▒▒▒߳▒▒▒Ϣ▒▒
trace ▒▒▒▒ָ▒▒▒▒▒ͬ▒▒▒▒̡▒
trx ▒▒ʾִ▒ж˻▒▒▒▒▒▒▒▒▒▒Ϣ▒▒
tsk ▒▒ʾִ▒ж˻▒▒▒▒▒▒▒▒SQL▒▒䡣
upgrade ▒▒KEY▒ļ▒▒▒▒▒▒▒▒▒▒▒
version ▒▒ʾ▒▒▒▒▒▒汾▒▒Ϣ▒▒
vpool ▒▒ʾ▒ڴ▒ص▒▒▒Ϣ▒▒
DMHS> exit
最后只能修改dmhs.hs
配置文件,将字符集从ch
改成 en
,用英文显示了:
[ddave@www.cndba.cn USTC]$ pwd
/dm/dmhs/INST_HS/USTC
[ddave@www.cndba.cn USTC]$ ls
dmhs_2022-12-22-8-38-5.xml dmhs.hs libcpt_dm8.so libdmhs_cvt.so libdmhs_ld_dm8.so libdmhs_pub.so libdmuts.so
dmhs_bak.conf dmhs.key libcpt_dsc.so libdmhs_dm_obj.so libdmhs_lic_dll.so libdmhs_ucvt.so libexec_ins_dm8.so
dmhs.conf dmhs_server libdmhs_api.so libdmhs_exec.so libdmhs_lic.so libdmhs_xml.so log
dmhs_console DmhsServiceUSTC libdmhs_bool_parse.so libdmhs_exp.so libdmhs_net.so libdmoci.so pids
[ddave@www.cndba.cn USTC]$ vim dmhs.hs
[ddave@www.cndba.cn USTC]$ cat dmhs.hs
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<dmhs>
<base>
<lang>en</lang>
<mgr_port>5345</mgr_port>
<name>USTC</name>
<ckpt_interval>60</ckpt_interval>
<siteid>2</siteid>
<version>2.0</version>
</base>
<cpt>
<enable>1</enable>
<name>cpt</name>
<db_type>DM8</db_type>
<db_server>192.168.56.102</db_server>
<db_user>SYSDBA</db_user>
<db_pwd>SYSDBA</db_pwd>
<char_code>PG_GB18030</char_code>
<db_port>5237</db_port>
<ddl_mask>TABLE:CREATE:DROP:TRUNCATE:ALTER</ddl_mask>
<cpt_mask/>
<send>
<ip>192.168.56.103</ip>
<mgr_port>5345</mgr_port>
<data_port>5346</data_port>
<filter>
<enable>
<item>SYSDBA.*</item>
<item>*.*</item>
</enable>
</filter>
<map/>
</send>
</cpt>
</dmhs>
[ddave@www.cndba.cn USTC]$
[ddave@www.cndba.cn USTC]$ ./dmhs_console
DMHS console tool: V4.3.04-Build(2023.01.11-122276trunc)_64_2301
Copyright (c) 2020, DMHS. All rights reserved.
Type ? or "help" for help, type "quit" to quit console.
Connected to DMHS: 127.0.0.1:5345
execute success
Dameng HS Server V4.3.04-Build(2023.01.11-122276trunc)_64_2301
DMHS> ?
Use "help [cmd]" to get a description of the command.
? Show the console command.
@ Execute the command scripts.
all_link Show data synchronization topology.
apply Force analysis and push current log.
clear Clear target transaction information table.
commit Commit the specified transaction.
conf Generate profile template
connect Connect to DMHS manager.
continue Ignore the DDL error and continue execution.
copy Execute load operation.
cp Show log analysis information.
cpt Show the capture module statistic information.
decrypt Decrypt ciphertext generated by ENCRYPT command as plaintext.
deltrace Cancels synchronous tracking of the specified table.
encrypt Encrypts the specified string.
epoch Convert a timestamp value to date format.
exec Show the execution statistic information.
exit Exit the console.
get Get checkpoint LSN of specified site.
help Show console command.
help [cmd] Show a detailed description of the specified command.
lag Get delay time of synchronization table.
ld Get the progress of the current loading task.
lic Get authorized key information.
mem_check Show the memory usage information.
pack Show server pack information.
print Print the transaction of synchronization error.
quit quit the console.
rollback Rollback specified transaction.
save_arch Save specified archive log files.
seq Execute sequence synchronization.
set Set console display properties such as language setting and so on.
show Show message traffic and login information.
start Start synchronization service.
state Show the module information.
stop Stop synchronization service.
tableinfo Show the table execution information.
thr Show the target execution thread information.
trace Trace the synchronization process of the specified table.
trx Show the target cached transaction information.
tsk Show SQL statement of specified transaction.
upgrade Upgrade the key file online.
version Show the version information.
vpool Show the memory pool information.
DMHS>
版权声明:本文为博主原创文章,未经博主允许不得转载。