Bug 7985 - Dolphin/Konqueror causes the ntfs-3g daemon and gam_server to consume a lot of CPU when browsing an NTFS directory
Summary: Dolphin/Konqueror causes the ntfs-3g daemon and gam_server to consume a lot o...
Status: REOPENED
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: 6
Hardware: i586 Linux
Priority: Normal normal
Target Milestone: Mageia 6
Assignee: KDE maintainers
QA Contact:
URL: http://lists.kde.org/?l=kde-linux&m=1...
Whiteboard: MGA4TOO MGA5TOO MGA6TOO
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-05 16:50 CET by Shlomi Fish
Modified: 2018-02-16 13:35 CET (History)
5 users (show)

See Also:
Source RPM: dolphin-16.12.3-1.mga6.src.rpm udisks-1.0.5-8.mga6.src.rpm udisks2-2.1.8-2.mga6.src.rpm
CVE:
Status comment:


Attachments
with lokalize (6.70 KB, image/jpeg)
2016-10-17 21:28 CEST, nikos papadopoulos
Details

Description Shlomi Fish 2012-11-05 16:50:22 CET
Hi all,

I have a laptop with the following specifications:

«
I also have an Acer Aspire 5738DZG laptop with the following specs:

    Intel Pentium(R) Dual-Core CPU T4300 @ 2.10GHz. (x86-64).
    ATI Mobility Radeon⢠HD 4570 (r700)
    15.6×´ 3D HD LCD Screen.
    3 GB Memory
    320 GB Hard Disk Drive.
    âDVD Super Multi DL driveâ
    Acer Nplify⢠802.11b/g/n.

»

Now, it dual boots between Windows 7 x86-64 (which I hardly use) and
Mageia Linux 3 Cauldron x86-64 (previously Mageia Linux 2 x86-64). Since I have a lot of space in my Windows 7 partition, I decided to use it to store many of my music files, so they get stored at /media/win_d/Music/mp3 , which has this as its /etc/fstab
entry:

UUID=24A43690A4366488 /media/win_d ntfs-3g defaults,umask=022,noatime 0 0

Now, if I view this directory using a tab of KDE-4.8.x's Konqueror in
file manager mode (in order to select and drag and drop files to my
media player), I see
ntfs-3g constantly consuming roughly 50% of my CPU, which I suspect
causes the laptop to overheat.

I checked and ntfs-3g also consumes CPU if I run «ls -l
/media/win_d/Music/mp3/» on the command line, so
I guess that Konqueror constantly rescans that directory for detecting changes.

Can anyone tell me how I can prevent Konqueror from consuming a lot of
CPU this way? It also happens with Dolphin and happens as a new UNIX user account.

Also see this Linux-Israel thread for some insights about NTFS-3G:

* http://mailman.cs.huji.ac.il/pipermail/linux-il/2012-August/009501.html

And this KDE-linux mailing list thread:

* http://lists.kde.org/?l=kde-linux&m=134669276632514&w=2

Regards,

-- Shlomi Fish
Shlomi Fish 2012-11-05 16:51:11 CET

Whiteboard: (none) => MGA2TOO

Comment 1 Shlomi Fish 2012-11-05 17:28:43 CET
Assigning to neoclust who is the kdebase4 maintainer.

Assignee: bugsquad => nicolas.lecureuil

Comment 2 Sébastien Forestier 2013-03-01 21:10:13 CET
Having same symptoms here.

Machine is Dell OptiPlex 745 (Core 2 Duo E6600 @ 2.6GHz) with quite fast SATA-III WD20EARX 2.0TB HDD connected to SATA-II port in AHCI mode, 4 GB RAM, external AMD 6450 PCI-Express graphic card and running completely up-to-date Mageia 2 64bits.

NTFS-3G is therefore version 2012-01-25. Running in KDE, with 2 NTFS partitions: Windows 8 install (/mnt/windows) + 1.7TB media partition (/mnt/partage) with over 10000 audio files and a hundred of video files.

Amarok running, collection scanner set to auto-update library whose main source is /mnt/partage/Musique. Nepomuk is not indexing /mnt/partage (not instructed to do it).

top shows me >70% CPU usage in ntfs-3G and 35-50% in gam_server (since I have a dual-core CPU it is normal that total CPU usage goes above 200%; indeed it can go up to 200%). This is a permanent situation; machine is permanently a this level of usage.

Don't hesitate to contact me for more details, for helping investigation and/or for testing fixes. Email is the only way to go.

CC: (none) => sforestier

Comment 3 kalagani kalagani 2013-07-13 19:42:09 CEST
Hello,
same pb on dual boot XP-Mageia3 surfing with Dolphin on a big photo folder (137Go)
on a partition NTFS
top shows 70% usage CPU:
1323 root      20   0  121m  15m  728 R   70  0.4   2:22.41 mount.ntfs-3g
fstab:
UUID=29C596F210E209F0 /mnt/commun ntfs-3g defaults,umask=000 0 0
versions:
ntfs-3g-2012.1.15-3.mga3
kernel-desktop-3.8.13.4-1.mga3-1-1.mga3

CC: (none) => kalagani

Comment 4 Samuel Verschelde 2015-05-17 21:14:42 CEST
Does this still happen in Mageia 4 & 5?

Keywords: (none) => NEEDINFO

Comment 5 Shlomi Fish 2015-05-18 17:16:26 CEST
(In reply to Samuel VERSCHELDE from comment #4)
> Does this still happen in Mageia 4 & 5?

I still see an issue with about 3%-10% CPU load on ntfs-3g when doing all that , but OTOH, the directory structure is different , and it's a new installation with fewer files. Updating the bug.

Whiteboard: MGA2TOO => MGA4TOO

Comment 6 kalagani kalagani 2015-05-26 10:04:02 CEST
Hello,
also in reply to Samuel VERSCHELDE from comment #4
on another PC but with same DD previously in my comment #3
dual boot XP-Mageia4 always surfing with Dolphin on the same big photo folder on a NTFS partition...
top shows 74% usage CPU:
 1359 root      20   0 16852 2328  704 S   74  0.1   5:10.00 mount.ntfs-3g   
 7151 kalagani  20   0 17280 4376 1128 S   43  0.1   2:53.79 gam_server                        
fstab
UUID=29C596F210E209F0 /mnt/commun ntfs-3g defaults,umask=000 0 0
df:
/dev/sdb5          336G    304G   32G  91% /mnt/commun
Versions;
ntfs-3g-2013.1.13-3.mga4
kernel-desktop-3.14.43-1.mga4-1-1.mga4

So, it seems pb is still existing in Mageia4...
Samuel Verschelde 2015-05-26 10:58:17 CEST

Whiteboard: MGA4TOO => MGA4TOO MGA5TOO
Keywords: NEEDINFO => (none)

Samuel Verschelde 2016-08-25 16:22:42 CEST

Assignee: mageia => kde

Comment 7 nikos papadopoulos 2016-10-17 21:28:30 CEST
Created attachment 8558 [details]
with lokalize

CC: (none) => 231036448

Comment 8 nikos papadopoulos 2016-10-17 21:51:28 CEST
It happens in my Mageia 5 (32bit) as well.
Usually when running kde applications.
See attachment "with lokalize".

Also, if running the xfe file manager,
although the cpu "consumption" is not so great constantly,
the file manager is slower, and sort of freezes for moments,
when going through the files of an ntfs partition.
Mount.ntfs-3g appears in the CPU list, 
when this happens.
Comment 9 Nicolas Lécureuil 2016-12-28 18:58:32 CET
is this still valid with current cauldron ?

CC: (none) => mageia

Comment 10 Shlomi Fish 2016-12-28 20:50:04 CET
(In reply to Nicolas Lécureuil from comment #9)
> is this still valid with current cauldron ?

I replaced my Mageia installation on the problematic laptop with Fedora (now version 25), so it will be harder for me to reproduce again, but I'll think about it.
Comment 11 Nicolas Lécureuil 2016-12-28 22:41:14 CET
then closing,  

Please reopen when you test if still valid

Resolution: (none) => OLD
Status: NEW => RESOLVED

Comment 12 Philippe Didier 2018-02-07 19:13:07 CET
The problem is still present in MGA6 
When exploring directories on a mounted NTFS partition Dolphin is very slow (quasi freezing and unresponsive for 30 seconds)
consuming lot of CPU

fstab extract :
# Entry for /dev/sdd1 :
UUID=2780BC61494AC609 /mnt/Seagate ntfs-3g defaults,nofail,umask=000 0 0

top for dolphin shows :

top - 12:54:08 up 12 min,  1 user,  load average: 1,11, 0,84, 0,62
Tâches: 179 total,   2 en cours, 133 en veille,   0 arrêté,   0 zombie
%Cpu(s): 17,3 ut,  6,9 sy,  0,5 ni, 67,1 id,  7,9 wa,  0,0 hi,  0,3 si,  0,0 st
KiB Mem :  4041756 total,   198320 libr,  1801480 util,  2041956 tamp/cache
KiB Éch : 23343096 total, 23343096 libr,        0 util.  1958372 dispo Mem 

  PID UTIL.     PR  NI    VIRT    RES    SHR S  %CPU %MEM    TEMPS+ COM.
  772 root      20   0   18564   3724   1748 S  75,0  0,1   0:38.81 mount.ntfs-3g
 4628 philippe  20   0   18244   6416   2484 R  37,5  0,2   0:20.49 gam_server
 6696 philippe  20   0   31452   3496   2892 R   6,2  0,1   0:00.02 top
    1 root      20   0   34968   5396   3732 S   0,0  0,1   0:02.36 systemd

This doesn't happen with Nautilus on the same directory
top for nautilus shows :

top - 12:58:36 up 16 min,  1 user,  load average: 1,28, 0,97, 0,73
Tâches: 188 total,   1 en cours, 142 en veille,   0 arrêté,   0 zombie
%Cpu(s): 16,8 ut,  7,5 sy,  0,4 ni, 68,4 id,  6,7 wa,  0,0 hi,  0,3 si,  0,0 st
KiB Mem :  4041756 total,   103928 libr,  1901904 util,  2035924 tamp/cache
KiB Éch : 23343096 total, 23343096 libr,        0 util.  1858568 dispo Mem 

  PID UTIL.     PR  NI    VIRT    RES    SHR S  %CPU %MEM    TEMPS+ COM.
 6860 philippe  20   0 1685444  93808  52024 S  12,5  2,3   0:13.03 nautilus
  772 root      20   0   18900   4304   1748 S   6,2  0,1   1:12.62 mount.ntfs-3g
 4240 philippe  20   0 4367552 392928 144664 S   6,2  9,7   0:49.30 plasmashell
    1 root      20   0  116896   5424   3732 S   0,0  0,1   0:02.38 systemd

Resolution: OLD => (none)
Status: RESOLVED => REOPENED
Source RPM: kdebase4-4.9.2-1.mga3.src.rpm => kdebase4-4.9.2-1.mga3.src.rpm dolphin-16.12.3-1.mga6.src.rpm
Version: Cauldron => 6
Whiteboard: MGA4TOO MGA5TOO => MGA4TOO MGA5TOO MGA6TOO
Target Milestone: --- => Mageia 6
CC: (none) => philippedidier

Comment 13 Philippe Didier 2018-02-07 19:40:31 CET
perhaps something similar here ?

https://bugzilla.redhat.com/show_bug.cgi?id=917848
Comment 14 Philippe Didier 2018-02-11 21:33:39 CET
Some more informations :

I did a fresh install of Mageia 6 (64 bits) on dedicated partitions

I still have Mageia 5 (32 bits) on other partitions

Beside Windows 7  and Windows XP

I use an external hard disk (NTFS) to store photos and music (but it is mounted by fstab with the same entry for both Mageia 5 or Mageia 6)

Same machine same graphic card (nvidia ) same motherboard 
Using proprietary driver for the graphic card

When I use Dolphin to see the content of the NTFS partitions :

With Mageia 5 
the 130 subdirectories of photos in the NTFS HDD are quickly populated (showing how many elements they contain)
 top reveals that mount.ntfs-3g + gam-server use 25% of CPU for 8 seconds and then disappear

With Mageia 6 
when trying to explore the same directory of photos Dolphin  becomes slower and slower when populating the subdirectories and finally get stuck and unresponsive

Top reveals mount.ntfs-3g and gam_server occupying the CPU without ending
When I reduce Dolphin and maximise it again its windows is transparent 
I have to kill it (with the X in the top of the window)

Worse ! if an other program was minimized (libreoffice for instance) when I try to maximise it the window stay transparent (I can see the wallpaper ...)
and I have to kill everything with Ctl+alt+del (no more access to the auto hiding bottom panel !)


(same problems when creating a new user, letting the default configuration : it is not caused by my personalisation of KDE)



Besides that

I did a fresh install of Mageia 6 on a laptop (formating the Mageia 5 partitions and copying some backedup files from home)
This laptop is dual boot (windows 7 Mageia 6) and has a data partition (NTFS) to allow access to music or photos from both Windows or Mageia
(the fstab is exqctly the same as it was for Mageia 5)


Dolphin is very slow there too when exploring this NTFS partition ! 
and mount.ntfs-3g and gam_server never stop using CPU until I quit Dolphin (I tried to wait for 10 minutes no change!!!)

I didn't have this problem with Mageia 5 on this laptop with the same NTFS partitions


Dolphin is not useable (the little popup service windows with right click is sometimes transparent too an Dolphin crashes without debugging info !)
Philippe Didier 2018-02-11 21:34:17 CET

Source RPM: kdebase4-4.9.2-1.mga3.src.rpm dolphin-16.12.3-1.mga6.src.rpm => dolphin-16.12.3-1.mga6.src.rpm

Comment 15 Philippe Didier 2018-02-12 00:43:07 CET
I think I have better surrounded the problem :

I have a second external new HDD that I synchronize from time to time with my HDD containing photos music and videos (to have a kind of backup if the first one dies)  I use FreeFileSync for this without difficulty


I plugged this disk and Plasma proposes to explore it with Dolphin : no problem
it appears in /run/media/...  and Dolphin shows quickly its content (Ksysguard shows a short activity of mount.ntfs-3g and gam_server that stop quickly


I modified the UUID in fstab to use this "copy" HDD (thinking it could be a problem of the original HDD getting old)  and booted again

Same problem for Dolphin when exploring this HDD mounted with fstab...

But if I plug the original HDD (now mounted in /run/media/...) Dolphin works OK
when exploring its content (mount.ntfs-3g and gam_server don't use the CPU for a long time and stop)

So when Dolphin explores a NTFS partitions mounted with fstab it leads to use excessively mount.ntfs-3g and gam_server until plasma is quite frozen
But if this partition is read after having been hotplugged it appears in /run/media/... and it's OK

NB I have no problem at all when I use Nautilus for both HDD (mounted by fstab or hotplugged)


What kind of info may I give to debug this
Comment 16 Philippe Didier 2018-02-14 12:46:01 CET
This problem already temporarily appeared with version 15.12.3  of Dolphin and disappeared 
https://bugs.kde.org/show_bug.cgi?id=362890


When in fine Dolphin has populated the folder list (without crashing)
an other problem occurs when trying to cut a file from ext4 partition and paste it to NTFS partition with dolphin (or vice versa) everything freezes... 

Maybe related with the gam_server too 

It has been reported upstream  but remains unconfirmed in spite of 30 duplicates

https://bugs.kde.org/show_bug.cgi?id=364039
Comment 17 Philippe Didier 2018-02-16 01:14:38 CET
Last investigations


It seems that Dolphin doesn't work always the same way for ntfs partitions on USB external disk:

It depends on the way this partition is mounted :

1) if it is mounted with fstab (in this case it apparently uses udisks2) we can explore the content on the mout point choosen in fstab but it freezes eating CPU with mout.ntfs-3g and gam_server 

2) if it is an hotplugged partition (in this case it seems to use udisks) a notification pop-up proposes to use Dolphin and it is OK : 
we explore it in /run/media/username/hddname 
(mount-ntfs-3g and gam_server use CPU for 3 seconds) and we get no freeze

Source RPM: dolphin-16.12.3-1.mga6.src.rpm => dolphin-16.12.3-1.mga6.src.rpm udisks-1.0.5-8.mga6.src.rpm udisks2-2.1.8-2.mga6.src.rpm

Comment 18 Philippe Didier 2018-02-16 02:06:01 CET
(In reply to Philippe Didier from comment #17)

Sorry for the typos
> Last investigations
> 
> 
> It seems that Dolphin doesn't work always the same way for ntfs partitions
> on USB external disk:
> 
> It depends on the way this partition is mounted :
> 
> 1) if it is mounted with fstab (in this case it apparently DOES NOT USE 
> udisks2) we can explore the content on the mout point choosen in fstab but it 
> freezes eating CPU with mout.ntfs-3g and gam_server 
> 
> 2) if it is an hotplugged partition (in this case it seems to use udisks2) a
> notification pop-up proposes to use Dolphin and it is OK : 
> we explore it in /run/media/username/hddname 
> (mount-ntfs-3g and gam_server use CPU for 3 seconds) and we get no freeze
Comment 19 Philippe Didier 2018-02-16 13:35:16 CET
I found some bugs apparently linked to this :

https://bugs.kde.org/show_bug.cgi?id=342056

particularly this comment (talking about plasma lock):
https://bugs.kde.org/show_bug.cgi?id=342056#c20

https://bugs.kde.org/show_bug.cgi?id=358231

Note You need to log in before you can comment on or make changes to this bug.