0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

本番環境にて、複数画像投稿したら、413 Request Entity Too Largeと出る

Posted at

###経緯
本番環境で複数枚の画像を上げようとしたら、標題のエラーが出て、困っていた。
調べたら、対処法が出てきたので、備忘録として、まとめる

###設定方法
EC2サーバーで設定するためのファイルを開く

sudo vi /etc/nginx/nginx.conf

容量を増やすための記述をする。

http{

    keepalive_timeout   65;
    types_hash_max_size 2048;
    client_max_body_size 20M; #追加
    以下略*******************

nginxに適用させるために下記のコードを実行。

sudo /etc/init.d/nginx reload

参考にした記事
https://qiita.com/dir_sh0606/items/74a51389fc24344cbc48

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?