LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-24-2019, 09:52 PM   #1
shinanqu
Member
 
Registered: Dec 2018
Posts: 33

Rep: Reputation: Disabled
Long delay when opening new websites


Hello,

When I open a new website, the browser stays blank for about 5 to 15 seconds and nothing happens. And then suddenly the website loads very quickly. My internet is very fast and reliable, sometimes up to 10MB/s. And with Windows 10 all websites load instantly. Just with Linux I have this issue. I tried it with Vivaldi as well as Firefox, no difference.

I tried
sudo dpkg-reconfigure resolvconf
I get the error message
/home/erik/.gtkrc-2.0:1: Unable to find include file: ".local/share/mx-tweak-data/no-ellipse-desktop-filenames.rc"

And a new window opens. I click twice on "next" and the windows closes. After rebooting the computer, the issue hasn't changed.

Sometimes the websites load a bit faster, about 5 seconds. But at the moment I often have to wait over 10 seconds and using the computer becomes unbearable. I am connected over wifi.
When the website is already fully loaded and I click on a link, usually it loads quickly (without any delay), but that's not always the case.

I disabled IPv6 in the /etc/sysctl.conf already, but it did not help.


Code:
System:    Host: b3-2019-01 Kernel: 4.19.0-1-amd64 x86_64 bits: 64 compiler: gcc v: 6.3.0 
           Desktop: Xfce 4.12.3 Distro: MX-18.1_x64 Continuum Dec 20  2018 
           base: Debian GNU/Linux 9 (stretch) 
Machine:   Type: Desktop System: Intel product: KBL-R MRD v: 0.1 serial: <filter> 
           Mobo: Intel model: MIR1 v: RVP7 serial: <filter> UEFI [Legacy]: American Megatrends 
           v: 5.12 date: 07/12/2018 
Battery:   Device-1: hidpp_battery_0 model: Logitech Wireless Keyboard K270 charge: Normal 
           status: Discharging 
           Device-2: hidpp_battery_1 model: Logitech Wireless Mouse M185 charge: Normal 
           status: Discharging 
CPU:       Topology: Quad Core model: Intel Core i7-8650U bits: 64 type: MT MCP arch: Kaby Lake 
           rev: A L2 cache: 8192 KiB 
           flags: lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx bogomips: 33792 
           Speed: 1766 MHz min/max: 400/4200 MHz Core speeds (MHz): 1: 831 2: 833 3: 784 4: 798 
           5: 831 6: 833 7: 800 8: 800 
Graphics:  Device-1: Intel driver: i915 v: kernel bus ID: 00:02.0 
           Display: x11 server: X.Org 1.19.2 driver: intel resolution: 1920x1080~60Hz 
           OpenGL: renderer: Mesa DRI Intel UHD Graphics 620 (Kabylake GT2) v: 4.5 Mesa 18.2.6 
           direct render: Yes 
Audio:     Device-1: Intel driver: snd_hda_intel v: kernel bus ID: 00:1f.3 
           Sound Server: ALSA v: k4.19.0-1-amd64 
Network:   Device-1: Intel Wireless 3165 driver: iwlwifi v: kernel port: f040 bus ID: 01:00.0 
           IF: wlan0 state: up mac: <filter> 
           Device-2: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet driver: r8169 
           v: kernel port: e000 bus ID: 02:00.0 
           IF: eth0 state: down mac: <filter> 
Drives:    Local Storage: total: 942.70 GiB used: 434.48 GiB (46.1%) 
           ID-1: /dev/sda vendor: Seagate model: ST500LT012-9WS142 size: 465.76 GiB temp: 49 C 
           ID-2: /dev/sdb vendor: SanDisk model: SD8SN8U512G1027 size: 476.94 GiB temp: 53 C 
Partition: ID-1: / size: 19.10 GiB used: 7.96 GiB (41.7%) fs: ext4 dev: /dev/sdb6 
           ID-2: /home size: 400.62 GiB used: 132.69 GiB (33.1%) fs: ext4 dev: /dev/sdb7 
Sensors:   System Temperatures: cpu: 58.0 C mobo: N/A 
           Fan Speeds (RPM): N/A 
Repos:     Active apt repos in: /etc/apt/sources.list.d/antix.list 
           1: deb http://ftp.halifax.rwth-aachen.de/mxlinux/packages/antix/stretch/ stretch main
           Active apt repos in: /etc/apt/sources.list.d/debian-stable-updates.list 
           1: deb http://ftp.de.debian.org/debian/ stretch-updates main contrib non-free
           Active apt repos in: /etc/apt/sources.list.d/debian.list 
           1: deb http://ftp.de.debian.org/debian/ stretch main contrib non-free
           2: deb http://security.debian.org/ stretch/updates main contrib non-free
           Active apt repos in: /etc/apt/sources.list.d/headset.list 
           1: deb [arch=amd64] http://headsetapp.co/headset-electron/debian stable non-free
           Active apt repos in: /etc/apt/sources.list.d/mx.list 
           1: deb http://ftp.halifax.rwth-aachen.de/mxlinux/packages/mx/repo/ stretch main non-free
           Active apt repos in: /etc/apt/sources.list.d/teamviewer.list 
           1: deb http://linux.teamviewer.com/deb stable main
           No active apt repos in: /etc/apt/sources.list.d/various.list 
           Active apt repos in: /etc/apt/sources.list.d/vivaldi.list 
           1: deb http://repo.vivaldi.com/stable/deb/ stable main
Info:      Processes: 256 Uptime: 4m Memory: 15.46 GiB used: 1.61 GiB (10.4%) Init: SysVinit 
           runlevel: 5 Compilers: gcc: 6.3.0 Shell: bash v: 4.4.12 inxi: 3.0.29
Code:
$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
2: eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000
    link/ether 00:e0:4c:e1:09:3a brd ff:ff:ff:ff:ff:ff
3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
    link/ether c0:b6:f9:9c:8a:fb brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.97/24 brd 192.168.1.255 scope global dynamic wlan0
       valid_lft 85987sec preferred_lft 85987sec
Code:
$ ping google.com
PING google.com (216.58.199.110) 56(84) bytes of data.
64 bytes from hkg07s22-in-f14.1e100.net (216.58.199.110): icmp_seq=1 ttl=57 time=31.4 ms
64 bytes from hkg07s22-in-f14.1e100.net (216.58.199.110): icmp_seq=2 ttl=57 time=31.6 ms
^C
--- google.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 5090ms
rtt min/avg/max/mdev = 31.400/31.534/31.669/0.222 ms
Here you see that the ping took 5 seconds to react.

Code:
$ ifconfig -a
eth0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether 00:e0:4c:e1:09:3a  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 124  bytes 13040 (12.7 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 124  bytes 13040 (12.7 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.1.97  netmask 255.255.255.0  broadcast 192.168.1.255
        ether c0:b6:f9:9c:8a:fb  txqueuelen 1000  (Ethernet)
        RX packets 12432  bytes 7810022 (7.4 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 5192  bytes 893345 (872.4 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
Code:
$ traceroute google.com
traceroute to google.com (216.58.220.206), 30 hops max, 60 byte packets
 1  gateway (192.168.1.1)  2.760 ms  2.741 ms  2.714 ms
 2  static.vnpt.vn (123.29.8.28)  4.472 ms  4.589 ms  4.573 ms
 3  * * *
 4  static.vnpt.vn (113.171.37.233)  22.417 ms  22.558 ms  22.538 ms
 5  72.14.221.80 (72.14.221.80)  22.682 ms  25.854 ms  26.321 ms
 6  * * *
 7  * * *
 8  hkg12s16-in-f14.1e100.net (216.58.220.206)  20.245 ms  20.266 ms  20.456 ms
Code:
$ cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION_ID="9"
VERSION="9 (stretch)"
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"

Last edited by shinanqu; 02-25-2019 at 01:50 AM.
 
Old 02-24-2019, 11:35 PM   #2
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163
Did you have to install a driver for your nic/MX-18 install in order for the wifi to work?

OR did the wifi work right out of the box after your fresh install?

Last edited by Ztcoracat; 02-24-2019 at 11:38 PM.
 
Old 02-24-2019, 11:39 PM   #3
Honest Abe
Member
 
Registered: May 2018
Distribution: CentOS 7, OpenSUSE 15
Posts: 330
Blog Entries: 1

Rep: Reputation: 161Reputation: 161
Few things I would check first are -

1. if the slowness to load websites persists on a command line browser (lynx/elinks etc) also.
2. if you ping an IP instead of a hostname/domain name, does it still take ~5 second ?
3. Are you using a DNS resolver which is geographically close to you ?
4. Are you behind a proxy or VPN ?
 
Old 02-25-2019, 02:10 AM   #4
shinanqu
Member
 
Registered: Dec 2018
Posts: 33

Original Poster
Rep: Reputation: Disabled
I didn't install any drivers or anything wifi related (that I am aware of). It is just MX 18 almost "out of the box".

elinks is also slow. Most of the time the bar says "looking up host". I do not use any proxy or VPN. I used 1.1.1.1, but deactivated it now as a test. But before and now, it is all slow.

However, the idea with the IP seems to be interesting, because indeed, the ping is now instantly and I do not need to wait 10 seconds for a reaction. What does it mean and how can I use this information? I am in Vietnam at a shared office. Others don't have this issue and with Windows I also don't have this issue.

Code:
erik@b3-2019-01:~
$ ping 216.58.193.174
PING 216.58.193.174 (216.58.193.174) 56(84) bytes of data.
64 bytes from 216.58.193.174: icmp_seq=1 ttl=50 time=223 ms
^C
--- 216.58.193.174 ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 223.940/223.940/223.940/0.000 ms


erik@b3-2019-01:~
$ ping google.com
PING google.com (172.217.194.113) 56(84) bytes of data.
64 bytes from 172.217.194.113 (172.217.194.113): icmp_seq=1 ttl=49 time=38.9 ms
64 bytes from 172.217.194.113 (172.217.194.113): icmp_seq=2 ttl=49 time=39.0 ms
^C
--- google.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 10970ms
rtt min/avg/max/mdev = 38.972/38.997/39.022/0.025 ms

Just started Windows 10 on this computer, just to be sure. The websites load instantly and the ping is also normal:

Code:
PS C:\Users\shinanqu> ping google.com

Pinging google.com [74.125.200.100] with 32 bytes of data:
Reply from 74.125.200.100: bytes=32 time=55ms TTL=46
Reply from 74.125.200.100: bytes=32 time=56ms TTL=46
Reply from 74.125.200.100: bytes=32 time=55ms TTL=46

Ping statistics for 74.125.200.100:
    Packets: Sent = 3, Received = 3, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 55ms, Maximum = 56ms, Average = 55ms
Control-C

Last edited by shinanqu; 02-25-2019 at 02:39 AM.
 
Old 02-25-2019, 06:06 AM   #5
Honest Abe
Member
 
Registered: May 2018
Distribution: CentOS 7, OpenSUSE 15
Posts: 330
Blog Entries: 1

Rep: Reputation: 161Reputation: 161
That error with "Looking up host" is almost always (or, to my limited knowledge) an indication for slow DNS resolution.
So check your ifcfg/interface file and /etc/resolv.conf files to see your DNS resolver IPs. [Note that, DNS resolver can be specified on router too].

I suggest you check these two links to determine which resolver is geographically closest to you and use that. Hopefully switching to a faster dns resolver is all you need. [Note that you may have to play a bit with network.service & NetworkManager]

https://www.howtogeek.com/342330/how...ve-dns-server/
https://techwiser.com/best-dns-benchmarking-tools/


Sorry for not being able to provide more specific details due to lack of familiarity with debian and it's children.

Last edited by Honest Abe; 02-25-2019 at 06:12 AM. Reason: corrected
 
Old 02-25-2019, 03:15 PM   #6
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163
I googled DNS and it said:

DNS stands for Domain Name System. DNS is how domain names are translated into IP addresses, and DNS also controls email delivery. DNS is what allows you to use your web browser to find web sites as well as send and receive email.

If you don't mind me asking Honest Abe what could cause DNS to be so slow?

Is it possible the ISP could have a cap on it?
 
Old 02-25-2019, 09:05 PM   #7
Honest Abe
Member
 
Registered: May 2018
Distribution: CentOS 7, OpenSUSE 15
Posts: 330
Blog Entries: 1

Rep: Reputation: 161Reputation: 161
@ztcoracat, not sure why you asked me instead of OP. but dns can be slow for a multitude of reasons such as but not limited to -
1. OP's server is reaching to other IPs rather than an appropriate dns server. (OP, plz share your resolve.conf file )
2. It's an office environment, so the DNS server (guessing it's internal for their domain with forwarders/recursion to public dns) is just too busy at that time? (I'll admit this is unlikely)
3. RHEL & friends use nscd for keeping a cache of dns lookups, may be it (or whatever debian family uses) needs to be checked?
4. Maybe the resolver that is currently used is trying to reach an ipv6 address (and maybe the office internet is not using ipv6)?
5. The nsswitch.conf is not configured to check dns server first? ( OP, plz post your nsswitch.conf file )

As for if ISP can put a cap on number of dns queries, I frankly have no idea.
 
Old 02-25-2019, 09:19 PM   #8
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163
Quote:
Originally Posted by Honest Abe View Post
@ztcoracat, not sure why you asked me instead of OP. but dns can be slow for a multitude of reasons such as but not limited to -
1. OP's server is reaching to other IPs rather than an appropriate dns server. (OP, plz share your resolve.conf file )
2. It's an office environment, so the DNS server (guessing it's internal for their domain with forwarders/recursion to public dns) is just too busy at that time? (I'll admit this is unlikely)
3. RHEL & friends use nscd for keeping a cache of dns lookups, may be it (or whatever debian family uses) needs to be checked?
4. Maybe the resolver that is currently used is trying to reach an ipv6 address (and maybe the office internet is not using ipv6)?
5. The nsswitch.conf is not configured to check dns server first? ( OP, plz post your nsswitch.conf file )

As for if ISP can put a cap on number of dns queries, I frankly have no idea.
-:::-I asked you because you seem very knowledgeable in this area and wanted your take on this.-:::-
 
Old 02-25-2019, 09:22 PM   #9
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163Reputation: 1163
shinanqu,

When you get the time please post the output from your 'resolve.conf' and your 'nsswitch.conf' files.

Thanks for letting us know the wifi worked out of the box after the install:-
 
Old 02-25-2019, 09:59 PM   #10
shinanqu
Member
 
Registered: Dec 2018
Posts: 33

Original Poster
Rep: Reputation: Disabled
Thank you for so much information! Well, the research seems like a hacker changed my DNS? So here is the resolv.conf that I found in /etc/

Code:
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver 38.134.121.95
nameserver 8.8.8.8
I never entered these address anywhere, so I searched for the 38 address and found this site:
https://www.techrepublic.com/article...amming-attack/
Quote:
"Draytek also advises all of its router users to check their DNS settings right away. If there is any change, you may have been hit by an attacker using the exploit. Keep an eye out for the DNS server 38.134.121.95, which Draytek said is a known rogue server."
It seems to be an old exploit of the router here in the office. I told the admin about it and I try to change the resolvconf on my computer.
Do you suggest me to change my passwords? I always assume that most passwords are encrypted anyway, so nobody can see it and no need to change it. Or is that naive and I should better be cautious?

Last edited by shinanqu; 02-25-2019 at 10:16 PM.
 
Old 02-25-2019, 10:16 PM   #11
shinanqu
Member
 
Registered: Dec 2018
Posts: 33

Original Poster
Rep: Reputation: Disabled
Ok, the resolv.conf file always uses the DNS server of the current connection. When I don't type in any DNS server into the network manager applet, then the Draytek router automatically uses the rogue 38 server.
When I enter 1.1.1.1, 1.0.0.1 (Cloudflare) as the DNS server, then the resolv.conf will change accordingly. However, the internet stays super slow, no change at all. Not sure why, because I always use 1.1.1.1 and everything is always ok.

Anyway, now I changed the DNS server in the network manager applet to 8.8.8.8, 8.8.4.4 (Google) (or perhaps I will use 208.67.222.222, 208.67.220.220 Open DNS), the resolv.conf was changed accordingly, and the internet is finally super fast again! Awesome!

Hope the admin will update the firmware soon and then everything will be (hopefully) ok. Just worry a bit, that the hacker behind it might have some private information?

Thank you all for your helpful information! This forum is a blessing. Without you, somebody would spy on me for the next years and I would have to deal with super slow internet. And perhaps even more people in this office are compromised. So your helpful answer saved all 100 people in this office here. Thank you so so much!

Last edited by shinanqu; 02-25-2019 at 10:32 PM.
 
Old 02-25-2019, 10:41 PM   #12
Honest Abe
Member
 
Registered: May 2018
Distribution: CentOS 7, OpenSUSE 15
Posts: 330
Blog Entries: 1

Rep: Reputation: 161Reputation: 161
whoa, that's really something isn't it ? Looks like your in-house admin has a real job at hand.

For the time being, please open the resolv.conf via your preferred editor (such as vim) and comment out the first line (the one with the 38 series IP) by putting a hash (#) to the start of the line. You may need admin privileges (aka sudo) for editing the file.
Do not reboot or restart network service after this and check the performance (ping , http etc.)

Now that we know what the issue is, someone more familiar with debian family should be able to help you better in regards with configuration.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Atril - long delay in opening pdf taylorkh Linux - Software 2 03-03-2017 09:38 AM
Aboout "with very long lines",how long is very long? yun1st Linux - Newbie 4 07-20-2012 04:38 PM
long long long: Too long for GCC Kenny_Strawn Programming 5 09-18-2010 02:14 AM
Installed new NIC and now Firefox crawls to websites...long cbjhawks Linux - Hardware 4 02-05-2010 04:55 PM
Websites that sell websites..? mScDeX General 2 12-29-2003 04:01 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:33 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration