在高并发场景中,删除 OpenStack 用户可能会间歇性失败。

问题

尝试删除 OpenStack 用户时,显示以下错误消息:

无法使用队列中的任务: 网关超时 (HTTP 504): GatewayTimeout: 网关超时 (HTTP 504) (Failed to consume a task from the queue: Gateway Timeout (HTTP 504): GatewayTimeout: Gateway Timeout (HTTP 504))

要解决此问题,请修改数据库的锁定等待超时。

解决方案

  1. root 用户身份登录到 Integrated OpenStack Manager
    ssh root@mgmt-server-ip
  2. 修改 MariaDB 配置。
    viocli update mariadb
  3. conf 部分中,添加 innodb_lock_wait_timeout 参数并将其值设置为 1000

    配置文件包括:

    conf:
      innodb_lock_wait_timeout: 1000