http – WordPress Rest API Error 502

My website was having attachment processing problems (the download often resulted in an HTTP error) so I searched a bit.

The development tools have shown that /wp-admin/async-upload.php returns a 502 error (at least for larger images and maybe all in jpeg).

I've also tried rebuilding the thumbnails manually, but ajax calls to plugins (I've used two of them) have also returned 502.

I've already disabled all plugins, nothing has changed. The only idea is that maybe the size of the media can be problematic, but I do not remember having changed anything in that direction, it just stopped working … Although it is possible that there was a major major update at this time

List of sizes:

thumbnail: 150 × 150 Px
average: 300 × 300 Px
medium_large: 768 × 0 Px
large: 1024 × 1024 Px
iphone: 320 × 9999 Px
iphone_2x: 640 × 9999 Px
ipad_hoch: 768 × 9999 Px
ipad_hoch_2x: 1536 × 5999 Px
ipad_quer: 1024 × 9999 Px
ipad_quer_2x: 2048 × 9999 Px
custom1: 1400 × 9999 Px
custom2: 1700 × 9999 Px
Custom3: 1850 × 9999 Px
custom4: 2100 × 9999 Px
Klein: 360 × 5999 Px
mittel: 720 × 5999 Px
Riesig: 1139 × 5999 Px
riesig_2x: 2278 × 5999 Px
sow-carousel-default: 272 × 182 Px

(medium_large seems to have height 0?)