Thanks for your help, but, if I logout from wordpress.com, all the modules are disabled, aren't they?
Sorry, I should have been more clear. I meant logging out of your self-hosted WordPress site.
About the traceroute, the hosting server is in Iceland, but I'm in Norway. The traceroute will be done from Norway, not from Iceland. Is it useful?
I think you should run the traceroute from the computer where you're experiencing issues, and where you're running the tests. So doing it from your own computer is totally fine.
about the PHP settings, memory_limit is 256MB and max_execution_time is 30s. Isn't it enough?
That should be more than enough, but some hosts sometimes limit the memory that can be used per site, so I would be worth contacting them about it to make sure.
You can also check your server error logs around the time where you experienced the 502 errors, to find out more about what's causing the issue.