This errors shows an issue on the network. It could be an issue on the network driver, the network adapter itself, the network cable, the router/modem, or (most probably) the ISP.
ISPs normally don't measure or check RTMP protocol, which is the one used for streaming.
Use this tool to better measure your internet connection against Twitch servers:
TwitchTest | r1ch.net
Anything bellow 90 quality is bad and represents an issue on the network, most probably on the ISP.
In case the issue is on the router or the modem, change the port where the network cable is connected to and test.
Based on the results of the Twitch Test, if are bad, you can contact you ISP regarding this issue on the RTMP protocol. Do more than one test with the Twitch Test starting with the time is set to test and if you don't see any problem set it to test for a longer time. As you explained the issues happen after 5 minutes.