AdguardTeam / AdguardForAndroid

Open bug tracker for Android version of AdGuard.
https://adguard.com/
1.35k stars 90 forks source link

AdGuard blocks Internet connection #2842

Closed Chinaski1 closed 4 years ago

Chinaski1 commented 5 years ago

When the user switching from Wi/Fi to LTE internet connection is lost. Need relaunch protection to reconnect.

"pref.vpn.disable.reconfigure" : true "pref.vpn.disable.pause" : true

User ID

2228088

Logs

Your environment

ameshkov commented 5 years ago

@Chinaski1 "record everything"-level logs are required to troubleshoot

Chinaski1 commented 5 years ago

Same problem : 1557976 Logs in NCloud 18:25 27|06

And another one: 2240216 Logs in NCloud

Chinaski1 commented 5 years ago

When switching from 4G to Wi / Fi, the Internet connection is lost

User ID

1889438

Logs in NCloud

Your Environment

Adguard version: 3.1.0 Device model: Xiaomi Mi A1 Operating system and version: 9 Adguard filtering mode: Local VPN

Chinaski1 commented 5 years ago

One more user @ev_klzn User update from 8 to 9 Android. From time to time the Internet connection is lost (Both Wi / Fi and LTE) Device model: Xiaomi Redmi note 5. Logs in Ncloud

dnovitskyi commented 5 years ago

Same issue for user 2240216. Samsung G960F, Wi-Fi/LTE, issues began quite recently.

Chinaski1 commented 5 years ago

Another one user: 1254045 Connection lost on Wi/Fi and LTE Device model: SM-G975F Logs in Ncloud

ameshkov commented 5 years ago

Also this one: https://github.com/AdguardTeam/AdguardForAndroid/issues/2872

My device : Samsung A8 2018
OS : Android pie
Adguard V. : 3.1.0
Dns filtering : ON ( cloudflare server )
Adguard filtering method : Local VPN
Antivirus : Kaspersky mobile security
Root access : No
ameshkov commented 5 years ago

@Chinaski1 @TheHasagi to figure out what's wrong, we need to get the logcat log: https://kb.adguard.com/en/android/solving-problems/logcat

It needs to be exported right after the issue is reproduced.

Eugene-Savenko commented 5 years ago

Another report here - 2045896

На устройстве android после установки adguard начались перебои с работой интернета (не грузятся страницы в браузере гугл хром, не работают приложения, требующие интернет соединения), но при выключении и повторном включении AdGuard, работа восстанавливается.

My device : Samsung Galaxy M20 (SM-M205FN)
OS : Android 9
Adguard V. : 3.1.0
Dns filtering : false
Adguard filtering method : Local VPN
Antivirus : n/a
Root access : n/a

And here - 1562409

My device : Samsung Galaxy S10 Plus (SM-G975F)
OS : Android 9
Adguard V. : 3.1.0
DNS filtering : false
Adguard filtering method : Local VPN
Antivirus : n/a
Root access : n/a
ameshkov commented 5 years ago

We cannot reproduce this even on the same test devices.

Here's what we need to troubleshoot:

  1. Wait until the issue happens again
  2. Get logcat: https://kb.adguard.com/en/android/solving-problems/logcat
  3. Get AdGuard's own log files (settings -> advanced -> export logs)
  4. Remember the exact time when it happened
patrickdrd commented 5 years ago

it happens to me too, I'm attaching logcat and log files:

adguard_logs_3.2.95_1407_183159.zip

2019-07-14-18-29-42.txt

the time it happened should be around 18:25: java.lang.RuntimeException: javax.net.ssl.SSLHandshakeException: Connection closed by peer

I restarted AG and connection was restored

I'm running latest nightly on local proxy (root) with cloudflare dns (regular)

patrickdrd commented 5 years ago

what are all these

`TLS connection is not HTTPS, adding 'com.facebook.katana#157.240.20.15:443#graph.facebook.com' to exceptions

TLS connection is not HTTPS, adding 'com.facebook.katana#157.240.20.35:443#b-api.facebook.com' to exceptions

TLS connection is not HTTPS, adding 'com.facebook.katana#157.240.20.35:443#b-graph.facebook.com' to exceptions

TLS connection is not HTTPS, adding 'com.facebook.katana#157.240.20.15:443#api.facebook.com' to exceptions

TLS connection may not be filtered because CA cert is not recognized by application, adding 'com.facebook.katana#157.240.20.10:443#edge-mqtt.facebook.com' to exceptions

TLS connection is not HTTPS, adding 'com.instagram.android#157.240.20.63:443#i.instagram.com' to exceptions

TLS connection may not be filtered because CA cert is not recognized by application, adding 'com.instagram.android#157.240.20.19:443#connect.facebook.net' to exceptions`

should I do something about them?

dnovitskyi commented 5 years ago

Progress update:

2228088 reports that the issue cannot be reproduced when his phone is connected to a PC. Asked for clean logcat logs, just for the case. 1557976 had encountered problems while installing ADB/Fastboot; ADB fails to recognize his device.

2240216, 1889438, 1254045, 2045896, 1562409: logs requested. Waiting for response.

Eugene-Savenko commented 5 years ago

Find a logcat here (two instances collected in a different time): 2228088

dnovitskyi commented 5 years ago

One more user with this issue: 2075818. Requested logcats, waiting for reply.

Eugene-Savenko commented 5 years ago

We have logcat from 1889438

ameshkov commented 5 years ago

@AdguardTeam/support-team guys, next time please request this instead of logcat.

It contains all the necessary information + logcat. Besides that, we'll need to get AdGuard logs.

Also, we'll need to know the time when the issue happened.

Template:

To troubleshoot this issue, we need to get the additional logs.

When the issue happens again, please do the following:

  1. Remember the exact time when the issue happened, we will need it to find the corresponding records in the log file.
  2. Export AdGuard log: settings -> advanced -> export logs
  3. Additionally, capture the system bug report after reproducing the issue. Here's the instruction.
  4. Send both files to us, and please mention the exact time when the issue was reproduced.
ameshkov commented 5 years ago

I'm running latest nightly on local proxy (root) with cloudflare dns (regular)

Root is different. Most likely, AdGuard was killed by Android.

should I do something about them?

Nope, these are okay.

ameshkov commented 5 years ago

2228088

Too late to record the logcat:(

Please ask the user to do this: https://github.com/AdguardTeam/AdguardForAndroid/issues/2842#issuecomment-515050041

Considering that capturing Android bug report is not as complicated and does not require connecting to a computer, it'd be much easier to collect the necessary information.

ameshkov commented 5 years ago

1889438

This one looks very relevant actually:

07-18 07:32:42.029 16681 16881 E com.adguard.android.filtering.api.LocalVpnService: [tcpip-stack-pool-3-thread-4] TCP id=919 Unexpected exception in the onTcpConnectRequest handler
07-18 07:32:42.029 16681 16881 E com.adguard.android.filtering.api.LocalVpnService: java.lang.IllegalStateException: Network filter is already closed
07-18 07:32:42.029 16681 16881 E com.adguard.android.filtering.api.LocalVpnService:     at com.adguard.filter.NativeNetworkFilterImpl.a(NativeNetworkFilterImpl.java:9) ~[na:0.0]
07-18 07:32:42.029 16681 16881 E com.adguard.android.filtering.api.LocalVpnService:     at com.adguard.android.filtering.filter.d$a.a(ConnectionFilter.java:2) ~[na:0.0]
07-18 07:32:42.029 16681 16881 E com.adguard.android.filtering.api.LocalVpnService:     at com.adguard.android.filtering.api.LocalVpnService$a.a(LocalVpnService.java:35) ~[na:0.0]
07-18 07:32:42.029 16681 16881 E com.adguard.android.filtering.api.LocalVpnService:     at com.adguard.android.filtering.api.LocalVpnService$a.onTcpConnectRequest(LocalVpnService.java:15) ~[na:0.0]
07-18 07:32:42.029 16681 16881 E com.adguard.android.filtering.api.LocalVpnService:     at com.adguard.corelibs.tcpip.NativeTcpIpStackImpl$Callbacks$1.run(NativeTcpIpStackImpl.java:1) ~[na:0.0]
07-18 07:32:42.029 16681 16881 E com.adguard.android.filtering.api.LocalVpnService:     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167) ~[na:0.0]
07-18 07:32:42.029 16681 16881 E com.adguard.android.filtering.api.LocalVpnService:     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641) ~[na:0.0]
07-18 07:32:42.029 16681 16881 E com.adguard.android.filtering.api.LocalVpnService:     at java.lang.Thread.run(Thread.java:764) ~[na:0.0]
patrickdrd commented 5 years ago

Root is different. Most likely, AdGuard was killed by Android.

I didn't say that AG was killed, but my internet connection did, it has happened twice lately if I'm not mistaken, very rare issue, but awfully annoying when it happens

ameshkov commented 5 years ago

Fix for 1889438 is in adguard-android/pull-requests/1378

I am not sure if it resolves other cases because I suspect that we collected several different issues there.

@AdguardTeam/support-team so I am still waiting for https://github.com/AdguardTeam/AdguardForAndroid/issues/2842#issuecomment-515050041

Chinaski1 commented 5 years ago

Forum Logs added to NCLoud

Chinaski1 commented 5 years ago

Forum Time and Date: 28.07 | 21:28 Logs in Ncloud

ameshkov commented 5 years ago

Reassigned to v3.3

https://forum.adguard.com/index.php?threads/adguard-choking-internet-on-pixel-3-

This one is supposedly fixed in the latest nightly.

Forum Time and Date: 28.07 | 21:28

This one needs to be analyzed.

ameshkov commented 5 years ago

@Chinaski1 @TheHasagi guys, if there are new complaints or if there are any news on this, please post the update here

Eugene-Savenko commented 5 years ago

Столкнулся со следующей проблемой. Установил Adguard на новый телефон. После запуска Adguard сеть на телефоне полностью блокируется. Ни одно приложение сеть не видит. Если ставишь Adguard на паузу, то работа сети возобновляется.

ID: 2295144 (w/ adguard and system logs) AdGuard version: 3.2.140

ameshkov commented 5 years ago

@Eugene-Savenko is it still reproduced on the latest beta?

ocebir commented 5 years ago

I am having the same issue on my samsung s10e and my samsung tab a 10.5

ameshkov commented 5 years ago

@ocebir could you please collect logs as it's explained in this comment?

ocebir commented 5 years ago

I have updated to 3.2.150 yesterday, so far the issue has not happened if/when it does I will get the logs. Thanks

ocebir commented 5 years ago

I have emailed them to support@adguard.com. but if there is another email address i can email them to please let me know. Thanks

ocebir commented 5 years ago

@ameshkov please let me know if there is anything else i can do. Thanks

ameshkov commented 5 years ago

@ocebir thank you!

Plz forward the same email to devteam@adguard.com - this is a shortcut to the developers:)

ameshkov commented 5 years ago

@ocebir got the logs, thank you!

Unfortunately, it seems that the default AdGuard's logging level is not enough to figure what's going on. I see that connections are timing out, but I can't see why.

Could you please try using AdGuard with the logging level set to "record everything" for some time?

ocebir commented 5 years ago

@ameshkov no problem i will do this and get back with new logs, thanks

SynergiAios commented 5 years ago

Just to inform everyone, for me, I was able to solve this issue with what the support sent me. 1) Ensure Battery Save Tasks don't kill/sleep the Adguard Service 2) Make sure Notifications are enabled

For my device: OnePlus 6 - current OxygenOS

ocebir commented 5 years ago

@ameshkov I have emailed new logs to devteam@adguard.com. I hope this helps. If anything further is required please let me know. Thanks

AdiSimpson commented 5 years ago

I have also this Problem with Xiaomi Mi 9T Pro. Often after Wakeup there is WiFi Connection but no Dataflow. Cant Sync Emails, Playstore, Adguard Update and so on. After some Minutes something kicks in and its working like it should.

Interessting is i can fix it shortly by starting Firefox and loading some Pages. It opens the blockage and everything is working.

Every Batterysaving Options are disabled. I hope you guys find the cause.

Chinaski1 commented 5 years ago

One more user got this issue on model=Mi 9T brand=Xiaomi 2280133 Logs in NCloud

AdiSimpson commented 5 years ago

I think i have to unistall Adware, its blocking often my WiFi connection. On Mi 9T Pro its a pain in the Ass... Tested many Options in Adware that could be the cause, but was not successful. When even Adware cant Update his Filters, there must be something deeper faulty. Mobile Data works...

artemiv4nov commented 5 years ago

@AdiSimpson this is a very complicated issue, but we dig further. Can you test on AdGuard v3.3 nightly 12?

AdiSimpson commented 5 years ago

Iam on Nightly 13 now. I will look into it.

AdiSimpson commented 5 years ago

Nearly 5 Days without Problems, and now Adguard blocks itself again...i was thinking maybe its fixed. Workaround -> Open Firefox, load/reload Page. Adguard works again.

ameshkov commented 5 years ago

Workaround -> Open Firefox, load/reload Page. Adguard works again

Without even restarting AG?

AdiSimpson commented 5 years ago

When Adguard is blocking i just open Firefox, nothing else. Using Firefox unblocks it, or i can wait some time and Adguard unblocks itself.

Chinaski1 commented 5 years ago

One more user faced this issue: 1600636 Logs in NCloud.

AdiSimpson commented 5 years ago

i hope this fix helps... [Corelibs v1.5.94 Fix] LocalApiServer hanged after long sleep: AdguardTeam/CoreLibs#1060

Chinaski1 commented 5 years ago

Another complaint about this problem from our forum. Time: 06.11.2019 | 00:43 Logs in NCloud.

AdiSimpson commented 4 years ago

I updated to Android 10, was hoping that fixes the behaivor. 10 Days later this morning Data was again blocked with Wifi or slow like a 56K Modem.