当前位置:网站首页>Gbase 8C server signal function
Gbase 8C server signal function
2022-07-28 01:55:00 【Dazhuang twelve】
The server signal function sends control signals to other server processes . Only system administrators can use these functions .
pg_cancel_backend(pid int)
describe : Cancel the current query of a backend .
return type :Boolean
remarks :pg_cancel_backend Go from pid The identified backend process sends a query to cancel (SIGINT) The signal . Of an active backend process PID It can be downloaded from pg_stat_activity View's pid Field found , Or use it on the server ps List database processes . have SYSADMIN Privileged user , The owner of the database to which the backend process is connected , The owner of the back-end process or inherits the built-in role gs_role_signal_backend Users with permission have the right to use this function .
pg_reload_conf()
describe : Cause all server processes to reload their configuration files ( System administrator role is required ).
return type :Boolean
remarks :pg_reload_conf Send a... To the server SIGHUP The signal , Cause all server processes to reload configuration files .
pg_rotate_logfile()
describe : Scroll the log files of the server ( System administrator role is required ).
return type :Boolean
remarks :pg_rotate_logfile Send a signal to the log file manager , Tell it to switch to a new output file immediately . This function can only be used in redirect_stderr It is only useful for log output , Otherwise, there is no log file manager subprocess .
pg_terminate_backend(pid int)
describe : Terminate a background thread .
return type :Boolean
remarks : If it works , The function returns true, Otherwise return to false. have SYSADMIN Privileged user , The owner of the database to which the backend process is connected , The owner of the back-end process or inherits the built-in role gs_role_signal_backend Users with permission have the right to use this function .
Example :
gbase=# SELECT pid from pg_stat_activity;
pid
-----------------
140573611915008
140573668599552
140574052771584
140573954000640
140574121588480
140574004344576
140573970781952
140573987563264
(8 rows)
gbase=# SELECT pg_terminate_backend(140573987563264);
pg_terminate_backend
----------------------
t
(1 row)
pg_terminate_session(pid int64, sessionid int64)
describe : Terminate a background session.
return type :Boolean
remarks : If it works , The function returns true, Otherwise return to false. have SYSADMIN Privileged user , The owner of the database to which the session is connected , The owner of the session or inherits the built-in role gs_role_signal_backend Users with permission have the right to use this function .
边栏推荐
猜你喜欢

企业运维实践-使用Aliyun容器镜像服务对海外gcr、quay仓库镜像进行镜像拉取构建

Open source flight control (Px4, ardupilot)

"Do you" want to be a test / development programmer? We strive to sprout

Matlab 44 animation gradient drawing programs

LeetCode高频题128. 最长连续序列,经常被互联网大厂面试考到

leetcode: 515. 在每个树行中找最大值

嵌入式经典通信协议

以“数字化渠道”撬动家用电器消费蓝海,经销商在线系统让企业生意更进一步

Prediction of charitable donation behavior by EEG multivariate model analysis

物企大变局时代,SRM供应商采购系统助力企业打造物业采购数字化标杆
随机推荐
HRD 1. a simple and reliable HRD detection method
Linux系统彻底删除Mysql
Enterprise operation and maintenance practice - using aliyun container image service to pull and build images of overseas GCR and quay warehouses
Cap principle of [distributed development]
QT setting Icon
2022软件测试技能 Robotframework + SeleniumLibrary + Jenkins web关键字驱动自动化实战教程
MPLS 隧道实验
实时数仓:美团的实时数仓建设实践
处理数据 给数据换名字
自定义类型:结构体,枚举,联合
递归相关习题
企业运维实践-使用Aliyun容器镜像服务对海外gcr、quay仓库镜像进行镜像拉取构建
Content bypass sharing
Discussion on PHP using some functions bypass WAF
The story of amen
GBase 8c 配置设置函数
GBase 8c 事务ID和快照(三)
数字经济才是未来经济发展的核心
Summary: Prometheus storage
股票问题5连