WGET / CURL stalls on a file

I have posted the same issue several months ago, but then as part of the integration that fails for me. The conclusion there was “a network problem”. Which it might be, but so far I have not been able to find out what it is. So I am trying it this way again. Making it a more generic issue.

The problem is with the Alpha2 integration (heating). It used to work but no longer does. The Alpha2 system has not changed in more than 10 years. The integration tries to get an xml file from the Alpha2. But it says connection failed. So together with the author of the integration we looked at the problem and we found that doing a WGET for that file from a terminal windows in HA shows that the transfer of the file stops after 24% (message “stalled”). Curl does the same thing. This is from the HA OS.
But I can get the file with no problems at all from any other computer in my network. Even using curl on windows. So somehow something only goes wrong with wget/curl when it is between my HA OS on the PI and the Alpha2 system. And I just cannot figure out what causes this. It feels to me like something being wrong at the NETWORK configuration on the PI. Like the receive/transmit buffer sizes or something like that. But I have no clue how to look at any of these kind of settings on linux.
So I hoping on some hints that help me solve the issue. I tried giving the Alpha2 different IP’s , but no luck there either.

It just sound like the other methods you use close the connection when an error have hit.
My bet is that the storage media on the Alpha2 is defective and soon it will all go down.

Check that the downloaded size of the file is correct in all places you download.
Compare the file between different downloads and if it is a human readable file, then open it up.
If it is not readable, then try to fed the file into the system from another download location.

I made the file on the alpha2 externally available. So I then asked a a friend to download the file on his HA instance. And it worked without a problem. So the problem is on my HA OS instance for certain, not on the alpha2.

That would mean either not enough storage space or a hardware failure.
If it is a hardware failure, then it can next to impossible to guess for us here on the forum.
Normal way to figure it out is to start replacing parts until it goes away.
I would start with the storage media.