title: nginx 1.18 on Bullseye: on_publish stopped working for upstreaming with rtmp after upgrading Debian, nginx and php
body: <p>I updated a server from Debian Buster (10) to Bullseye (11). With that php was updated from 7.3.x to 7.4.21 and nginx from 1.14 to 1.18.0 This server only is used for streaming.It holds two TLD where one is the frontend for the stream via https/SSL while the other is only for authentification of the streaming device against a php file using port 80 / http.</p>
  <p>In nginx.conf I do:</p>
  <pre><code>on_publish http://secret.domain.com/password.php;
  </code></pre>
  <p>This secret.php is accessible from the world.</p>
  <p>From a fresh start of the server everything works fine. /var/log/nginx/access.log says that there was a &quot;PUBLISH&quot; event. When I stop and start or reload nginx, it takes apr. 20 seconds, but does not fail. After restarting or reloading nginx the upstream cannot be authentificated. In /var/log/nginx/error.log I find</p>
  <pre><code>[error] 16141#16141: recv() failed (111: Connection refused)
  </code></pre>
  <p>But still I can open <a href="http://secret.domain.com/password.php" rel="nofollow noreferrer">http://secret.domain.com/password.php</a> in a browser.</p>
  <p>I'd like to stop here and not post any config files. That might kill the post. But who wants to see should get them ...</p>
  <p>Greetz
  Martin</p>