嘟嘟社区

[疑问] cyberpanel使用官方的数据库优化命令进行优化后面版直接500


cyberpanel使用官方的数据库优化命令进行优化后面版直接500,手动改回又可以用了,请问是什么原因?

优化后报错
** (pkttyagent:1941): WARNING **: 23:16:56.677: Unable to register authentication agent: GDBus.Errorrg.freedesktop.PolicyKit1.Error.Failed: Cannot determine user of subject
Error registering authentication agent: GDBus.Errorrg.freedesktop.PolicyKit1.Error.Failed: Cannot determine user of subject (polkit-error-quark, 0)
Job for mariadb.service failed because the control process exited with error code. See "systemctl status mariadb.service" and "journalctl -xe" for details.

手工改回后
** (pkttyagent:21000): WARNING **: 23:19:17.473: Unable to register authentication agent: GDBus.Errorrg.freedesktop.PolicyKit1.Error.Failed: Cannot determine user of subject
Error registering authentication agent: GDBus.Errorrg.freedesktop.PolicyKit1.Error.Failed: Cannot determine user of subject (polkit-error-quark, 0)

谁帮忙看看怎么解决,谢谢

使用命令
  1. groupadd -g 23 nohidproc
  2. usermod -a -G nohidproc polkitd
  3. mount -o remount,rw,hidepid=2,gid=nohidproc /proc
  4. systemctl restart polkit

复制代码

不行,还是500,输完命令后
** (pkttyagent:22743): WARNING **: 23:47:29.050: Unable to register authentication agent: GDBus.Errorrg.freedesktop.PolicyKit1.Error.Failed: Cannot determine user of subject

用service mysqld restart,重启数据库
Redirecting to /bin/systemctl restart mysqld.service
Job for mariadb.service failed because the control process exited with error code. See "systemctl status mariadb.service" and "journalctl -xe" for details.

cyberpanel 真难用- –

官方提供的优化数据
[mysqld]

# GENERAL #
user                           = mysql
default-storage-engine         = InnoDB
#socket                         = /var/lib/mysql/mysql.sock
#pid-file                       = /var/lib/mysql/mysqld.pid

# MyISAM #
# key-buffer-size                = 32M
# myisam-recover                 = FORCE,BACKUP

# SAFETY #
max-allowed-packet             = 16M
max-connect-errors             = 1000000
sql-mode                       = NO_ENGINE_SUBSTITUTION,NO_AUTO_CREATE_USER
sysdate-is-now                 = 1
innodb-strict-mode             = 1

# DATA STORAGE #
datadir                        = /var/lib/mysql

# SERVER ID #
server-id                      = 677161

# CACHES AND LIMITS #
max-connections                = 500
tmp-table-size                 = 32M
max-heap-table-size            = 32M
query-cache-type               = 0
query-cache-size               = 0
thread-cache-size              = 50
open-files-limit               = 65535
table-definition-cache         = 1024
table-open-cache               = 2048

# INNODB #
innodb-flush-method            = O_DIRECT
innodb-log-files-in-group      = 2
innodb-log-file-size           = 128M
innodb-flush-log-at-trx-commit = 1
innodb-file-per-table          = 1
innodb-buffer-pool-size        = 1228M

# LOGGING #
log-error                      = /var/lib/mysql/mysqld.log
slow-query-log                 = 1
slow-query-log-file            = /var/lib/mysql/mysqld-slow.log
log-queries-not-using-indexes  = OFF
long_query_time                = 30

[mysqldump]
max-allowed-packet             = 16M

!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mariadb.conf.d/

原始的数据
#
# This group is read both by the client and the server
# use it for options that affect everything
#
[client-server]

#
# include *.cnf from the config directory
#
!includedir /etc/my.cnf.d