Multibit-Legacy / multibit-hd

Deprecated Bitcoin Wallet
https://multibit.org/blog/2017/07/26/multibit-shutdown.html
Other
169 stars 124 forks source link

"PeerDiscoveryException, No peer discovery returned any results" due to IPv6 #967

Open Forage opened 7 years ago

Forage commented 7 years ago

Since a week or two, MB all of a sudden stopped working, being unable to connect after unlocking my wallet.

The error repeatedly showing up in the console is just: [2017-03-03 14:23:39,391] ERROR [PeerGroup Thread] o.b.c.PeerGroup - Peer discovery failure, class:org.bitcoinj.net.discovery.PeerDiscoveryException, message:No peer discovery returned any results: check internet connection?

It can hardly be the cause of a transaction, since I was able to launch MB properly multiple times after the last transaction. My internet connection is up and running just fine.

Using MB HD 0.4.1 on Ubuntu 16.10 with Java 1.8.0_121-b13.

What can be the cause of the problem and how can I fix it? I'd like to be able to access my bitcoins again.

Let me know if you need any more information.

Forage commented 7 years ago

A few days after I reported the issue, things started working again all of a sudden. It could get a connection again. Now, yet again a few days later, I'm stuck with the same problem again. This in the fresh 0.5.1 release as well. What's going on?

Forage commented 7 years ago

Anyone? I'd like to access my bitcoins again...

Forage commented 7 years ago

Found the cause: IPv6. If I add "-Djava.net.preferIPv4Stack=true" to line 475 of multibit-hd, to force Java to use IPv4, all is fine. Apparently I'm not the only one: https://bitcointalk.org/index.php?topic=43616.880

The line above now reads: $INSTALL4J_JAVA_PREFIX exec "$app_java_home/bin/java" "-splash:$app_home/.install4j/s_17j5gi5.png" -Dinstall4j.jvmDir="$app_java_home" -Dexe4j.moduleName="$prg_dir/$progname" "-Dinstall4j.launcherId=24" "-Dinstall4j.swt=false" "$vmov_1" "$vmov_2" "$vmov_3" "$vmov_4" "$vmov_5" $INSTALL4J_ADD_VM_PARAMS -classpath "$local_classpath" com.install4j.runtime.launcher.UnixLauncher launch 8ee9dd18 "$prg_dir/error.log" "" org.multibit.hd.ui.MultiBitHD "$@"

Change this into: $INSTALL4J_JAVA_PREFIX exec "$app_java_home/bin/java" "-splash:$app_home/.install4j/s_17j5gi5.png" "-Djava.net.preferIPv4Stack=true" -Dinstall4j.jvmDir="$app_java_home" -Dexe4j.moduleName="$prg_dir/$progname" "-Dinstall4j.launcherId=24" "-Dinstall4j.swt=false" "$vmov_1" "$vmov_2" "$vmov_3" "$vmov_4" "$vmov_5" $INSTALL4J_ADD_VM_PARAMS -classpath "$local_classpath" com.install4j.runtime.launcher.UnixLauncher launch 8ee9dd18 "$prg_dir/error.log" "" org.multibit.hd.ui.MultiBitHD "$@"

Note that it will still take some time for it to connect properly this way, but at least it will now as a work-around until the issue is fixed.

Thank you for the overwhelming help and support...

Struppi commented 7 years ago

I got the same problems and this helps.