NETGEAR is aware of a growing number of phone and online scams. To learn how to stay safe click here.
Forum Discussion
Stoffen
Feb 25, 2014Aspirant
RN104 - process "find" uses 100% cpu for several hours
Hi.
Hopefully some of you might be able to help me here :)
I have a ReadyNAS 104 with version 6.1.6
I have installed Cacti service to monitor my NAS and some other devices on my LAN.
Several times during the day, and for several hours, the CPU jumps to 100%.
When I ssh into the NAS, and check processes with "top", user "guest" runs the process "find", and it has been doing this for x number of hours with 99,9% cpu utilization.
Can anyone tell me what process might spawn "find as guest", and how to stop it?

Hopefully some of you might be able to help me here :)
I have a ReadyNAS 104 with version 6.1.6
I have installed Cacti service to monitor my NAS and some other devices on my LAN.
Several times during the day, and for several hours, the CPU jumps to 100%.
When I ssh into the NAS, and check processes with "top", user "guest" runs the process "find", and it has been doing this for x number of hours with 99,9% cpu utilization.
Can anyone tell me what process might spawn "find as guest", and how to stop it?

6 Replies
Replies have been turned off for this discussion
- fastfwdVirtuosoWith no other information, I'd guess that it's updatedb, running way too often because of a misconfigured cron job. But top can show you each process's parent so you won't have to guess.
- xeltrosApprenticeFind is used for various things. updateDB (used to update the list of files and folders for the command locate) is one of them.
The BTRFS defrag also uses find to locate the files and pass them to the defragger.
Maybe the scrub process or the snapshot features are calling it too ? not sure for those ones.
I also don't know for the virus scanner, I thinks it's all contained in ctscand but not sure. - StoffenAspirantThe CPU is currently at 100%
TOP looks like this:
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
27620 guest 30 10 5840 1964 884 R 73.1 0.4 350:40.89 find
4390 root 20 0 464m 64m 2256 S 23.3 13.1 101:15.32 java
3 root 20 0 0 0 0 S 0.3 0.0 0:51.66 ksoftirqd/0
6 root -2 0 0 0 0 S 0.3 0.0 3:24.45 rcu_kthread
12008 root 20 0 5372 1516 1052 R 0.3 0.3 0:00.10 top
1 root 20 0 5572 2828 1268 S 0.0 0.6 0:13.19 systemd
2 root 20 0 0 0 0 S 0.0 0.0 0:00.74 kthreadd
7 root rt 0 0 0 0 S 0.0 0.0 0:00.92 watchdog/0
8 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 khelper
177 root 20 0 0 0 0 S 0.0 0.0 0:00.00 sync_supers
179 root 20 0 0 0 0 S 0.0 0.0 0:00.00 bdi-default
181 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 kblockd
187 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 ata_sff
194 root 20 0 0 0 0 S 0.0 0.0 0:00.00 khubd
199 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 md
217 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 rpciod
234 root 20 0 0 0 0 S 0.0 0.0 3:56.43 kswapd0
283 root 20 0 0 0 0 S 0.0 0.0 0:00.00 fsnotify_mark
299 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 nfsiod
319 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 xfsalloc
320 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 xfs_mru_cache
321 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 xfslogd
322 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 xfsdatad
323 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 xfsconvertd
333 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 crypto
349 root 20 0 0 0 0 S 0.0 0.0 0:00.00 crypto
when I fetch more details with "ps aux" i get this:
guest 27620 95.4 0.2 5048 1256 ? RN 06:25 352:26 /usr/bin/find / -ignore_readdir_race ( -fstype NFS -o -fstype nfs -o -fstype nfs4 -o -fstype afs -o -fstype binfmt_misc -o -fstype proc -o -fstype smbfs -o -fstype autofs -o -fstype iso9660 -o -fstype ncpfs -o -fstype coda -o -fstype devpts -o -fstype ftpfs -o -fstype devfs -o -fstype mfs -o -fstype shfs -o -fstype sysfs -o -fstype cifs -o -fstype lustre_lite -o -fstype tmpfs -o -fstype usbfs -o -fstype udf -o -fstype ocfs2 -o -type d -regex \(^/tmp$\)\|\(^/usr/tmp$\)\|\(^/var/tmp$\)\|\(^/afs$\)\|\(^/amd$\)\|\(^/alex$\)\|\(^/var/spool$\)\|\(^/sfs$\)\|\(^/media$\)\|\(^/var/lib/schroot/mount$\) ) -prune -o -print0
I dont know if this gives you any clue.
UpdateDB is running, but with no CPU load
root 12310 0.0 0.1 4104 800 pts/0 S+ 12:37 0:00 grep update
root 27599 0.0 0.1 1752 520 ? SN 06:25 0:00 /bin/sh /usr/bin/updatedb.findutils
root 27607 0.0 0.0 1752 328 ? SN 06:25 0:00 /bin/sh /usr/bin/updatedb.findutils - fastfwdVirtuosoTry "killall updatedb" next time you see the CPU load spike. Killing the process won't corrupt the locate database; updatedb builds a temporary database as it runs, and only replaces the real database if the run successfully completes.
- StoffenAspirantHi. Thanks.
I've tried killall updatedb, but it fails as updatedb does not run any processes.
root@NAS01:~# top
top - 08:13:24 up 16 days, 20:33, 1 user, load average: 1.77, 1.89, 1.91
Tasks: 149 total, 2 running, 147 sleeping, 0 stopped, 0 zombie
%Cpu(s): 1.0 us, 54.4 sy, 43.0 ni, 0.0 id, 1.6 wa, 0.0 hi, 0.0 si, 0.0 st
KiB Mem: 507236 total, 466208 used, 41028 free, 2580 buffers
KiB Swap: 523708 total, 26508 used, 497200 free, 86900 cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
25942 guest 39 19 5012 1224 888 R 96.4 0.2 105:20.72 find
2120 root 19 -1 182m 13m 2916 S 1.0 2.7 49:08.38 readynasd
30304 root 20 0 5260 1496 1052 R 0.7 0.3 0:00.06 top
864 root 20 0 0 0 0 S 0.3 0.0 4:32.26 btrfs-endio-met
1 root 20 0 5572 2680 1120 S 0.0 0.5 0:13.92 systemd
root@NAS01:~# killall updatedb
updatedb: no process found
root@NAS01:~#
:? - StoffenAspirantI somewhat found a solution, or lowered the number of hours "find" runs in the system.
I modified the file /etc/cron.daily/locate
In the file, I pruned the following:
PRUNEPATHS="/data/._share/Documents/.snapshot/ ./data/._share/Music/.snapshot/ ./data/._share/Pictures/.snapshot/" as well as the original pruned paths.
This refers to my shares, of which I know contains alot of data.
The next time locate ran, it did the entire find and locate thingie in 10 hours insted of 23 or so..
I still feel that this is the wrong approach to the problem, but it seems indeed as the problem is within "locate"'s daily rutine in the combination of the way ReadyNas 104 creates shapshots.
More good ideas is more than welcome :)
Related Content
NETGEAR Academy
Boost your skills with the Netgear Academy - Get trained, certified and stay ahead with the latest Netgear technology!
Join Us!