When using a vision model, if the uploaded image is slightly larger, it will freeze #13692

Closed
opened 2026-02-21 19:13:24 -05:00 by yindo · 5 comments
Owner

Originally created by @andery119 on GitHub (May 8, 2025).

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

1.2.0

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

When using the visual model, if the uploaded image is slightly larger, it will freeze. The gunicorn process of the dify-api container always occupies 100%, and the LLM model cannot return the content

✔️ Expected Behavior

No response

Actual Behavior

No response

Originally created by @andery119 on GitHub (May 8, 2025). ### Self Checks - [x] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general). - [x] I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones. - [x] I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)). - [x] [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:) - [x] Please do not modify this template :) and fill in all the required fields. ### Dify version 1.2.0 ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce When using the visual model, if the uploaded image is slightly larger, it will freeze. The gunicorn process of the dify-api container always occupies 100%, and the LLM model cannot return the content ### ✔️ Expected Behavior _No response_ ### ❌ Actual Behavior _No response_
yindo added the 🐞 bug label 2026-02-21 19:13:24 -05:00
yindo closed this issue 2026-02-21 19:13:24 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (May 8, 2025):

The issue you're experiencing with the visual model freezing and the gunicorn process occupying 100% CPU usage in Dify version 1.2.0 is a known problem. This occurs due to inefficient data handling by the plugin daemon, which repeatedly sends complete prompt messages, including the full image data, back to the API with every response chunk. This results in excessive network traffic and high CPU usage, especially with larger images. The Dify team has acknowledged this issue, and it has been fixed in a later commit [1].

To address this, you can update your setup to include the latest fixes. If you are self-hosting using Docker, you might want to consider updating the plugin daemon as well. Here are the steps to update the plugin daemon:

  1. Add the following settings to your .env file:

    PLUGIN_S3_USE_AWS_MANAGED_IAM=false
    PLUGIN_S3_USE_PATH_STYLE=false
    
  2. Update your docker-compose.yaml file with default values:

    plugin_daemon:
      environment:
        S3_USE_AWS_MANAGED_IAM: ${PLUGIN_S3_USE_AWS_MANAGED_IAM:-false}
        S3_USE_PATH_STYLE: ${PLUGIN_S3_USE_PATH_STYLE:-false}
    
  3. Rebuild and restart the Docker containers with these commands:

    docker compose down
    docker compose pull
    docker compose up -d
    
  4. Verify all containers are running correctly with:

    docker compose ps
    

These steps should help mitigate the issue until the new version with the fix is released [2][3].

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other

@dosubot[bot] commented on GitHub (May 8, 2025): <!-- Answer --> The issue you're experiencing with the visual model freezing and the gunicorn process occupying 100% CPU usage in Dify version 1.2.0 is a known problem. This occurs due to inefficient data handling by the plugin daemon, which repeatedly sends complete prompt messages, including the full image data, back to the API with every response chunk. This results in excessive network traffic and high CPU usage, especially with larger images. The Dify team has acknowledged this issue, and it has been fixed in a later commit <sup>[[1]](https://github.com/langgenius/dify/issues/17799)</sup>. To address this, you can update your setup to include the latest fixes. If you are self-hosting using Docker, you might want to consider updating the plugin daemon as well. Here are the steps to update the plugin daemon: 1. Add the following settings to your `.env` file: ```plaintext PLUGIN_S3_USE_AWS_MANAGED_IAM=false PLUGIN_S3_USE_PATH_STYLE=false ``` 2. Update your `docker-compose.yaml` file with default values: ```yaml plugin_daemon: environment: S3_USE_AWS_MANAGED_IAM: ${PLUGIN_S3_USE_AWS_MANAGED_IAM:-false} S3_USE_PATH_STYLE: ${PLUGIN_S3_USE_PATH_STYLE:-false} ``` 3. Rebuild and restart the Docker containers with these commands: ```bash docker compose down docker compose pull docker compose up -d ``` 4. Verify all containers are running correctly with: ```bash docker compose ps ``` These steps should help mitigate the issue until the new version with the fix is released <sup>[[2]](https://github.com/langgenius/dify/issues/18415)</sup><sup>[[3]](https://github.com/langgenius/dify/issues/13926)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.* --- <sup>Help Dosu learn! Give it feedback: [Great Response](https://app.dosu.dev/response-feedback/8356a76a-4af2-48b5-a48f-b362958ebc55?feedback_type=great_response) | [Irrelevant Answer](https://app.dosu.dev/response-feedback/8356a76a-4af2-48b5-a48f-b362958ebc55?feedback_type=irrelevant_answer) | [Incorrect Sources](https://app.dosu.dev/response-feedback/8356a76a-4af2-48b5-a48f-b362958ebc55?feedback_type=incorrect_sources) | [Too Verbose](https://app.dosu.dev/response-feedback/8356a76a-4af2-48b5-a48f-b362958ebc55?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/8356a76a-4af2-48b5-a48f-b362958ebc55?feedback_type=hallucination) | [Bug Report](https://app.dosu.dev/response-feedback/8356a76a-4af2-48b5-a48f-b362958ebc55?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/8356a76a-4af2-48b5-a48f-b362958ebc55?feedback_type=other)</sup>
Author
Owner

@crazywoola commented on GitHub (May 8, 2025):

There are several discussion and fixes regarding this issue when uploading images since v1.3.0, please upgrade to the latest version.

@crazywoola commented on GitHub (May 8, 2025): There are several discussion and fixes regarding this issue when uploading images since v1.3.0, please upgrade to the latest version.
Author
Owner

@CoderTylor commented on GitHub (May 9, 2025):

Hello, I encountered the same issue while uploading audio.
Here is my analysis and solution:
When I checked the Docker status, I found that the CPU usage of the plugin's Docker container was at 100%. To address this, I replaced the existing plugin image with a newer one from Docker Hub. This resolved the problem.

@CoderTylor commented on GitHub (May 9, 2025): Hello, I encountered the same issue while uploading audio. Here is my analysis and solution: When I checked the Docker status, I found that the CPU usage of the plugin's Docker container was at 100%. To address this, I replaced the existing plugin image with a newer one from Docker Hub. This resolved the problem.
Author
Owner
@kurokobo commented on GitHub (May 10, 2025): Maybe related to: - https://github.com/langgenius/dify-plugin-sdks/pull/128 - https://github.com/langgenius/dify-plugin-daemon/pull/260
Author
Owner

@devops-jiangxl commented on GitHub (May 12, 2025):

您好,我在上传音频时也遇到了同样的问题。 以下是我的分析和解决方案: 我检查 Docker 状态时,发现插件 Docker 容器的 CPU 使用率高达 100%。为了解决这个问题,我将现有的插件镜像替换为 Docker Hub 中更新的镜像。问题解决了。

多谢大佬,我也解决了

@devops-jiangxl commented on GitHub (May 12, 2025): > 您好,我在上传音频时也遇到了同样的问题。 以下是我的分析和解决方案: 我检查 Docker 状态时,发现插件 Docker 容器的 CPU 使用率高达 100%。为了解决这个问题,我将现有的插件镜像替换为 Docker Hub 中更新的镜像。问题解决了。 多谢大佬,我也解决了
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#13692