Elgg upgrade from 1.9 to 1.10 gives "Elgg cannot connect to itself to test rewrite rules properly. Check that curl is working and there are no IP restrictions preventing localhost connections."

I try upgrade from elgg 1.9.8 to 1.10.5.

I copy elgg files (new directory, no overewrite). I updated htaccess and settings files.

I run upgrade.php and I get:

Elgg cannot connect to itself to test rewrite rules properly. Check that curl is working and there are no IP restrictions preventing localhost connections.

Curl is enabled. I have php 5.4.x

How can I check "there are no IP restrictions preventing localhost connections."?

Any ideas? Thanks.