Well, I changed swap from 2G to 4G, and rebuilding went thru. So mayby it was again matter of amount of RAM. Or it was a fluke.
And then we are back in FAQ-topic: how much RAM does Discourse really need — because swapfile is de facto part of total amount RAM, and now it looks like the actual need is 11+ GB for small forum