Page 1 of 1

Endless Disk Activity QTS 4.4.1 [SOLVED]

Posted: Mon Mar 16, 2020 9:31 pm
by kicritos
Using QNap QTS 4.4.1

After installing docker-station i have noticed that my harddisks started to be continuosly active EVER :( . Disk activity never ends so i decided to investigate whats going on.


following the instrucions from qnap wiki i have downloaded and run script from:
https://wiki.qnap.com/wiki/Find_out_whi ... m_spindown

Running script

We have to look for lines like

Code: Select all

<7>[52475.727464] setcfg(9191): dirtied inode 7041 (CACHEDEV1_DATA.log) on md9
This means that process setcfg with pid 9191 have modified file CACHEDEV1_DATA.log on device md9

Code: Select all

<7>[52482.016599] jbd2/md9-8(2518): WRITE block 616080 on unknown-block(9,9) (8 sectors)
Like md9 device is updated, its journal have been written

Code: Select all

<7>[52482.027584] md9_raid1(2505): WRITE block 1060216 on unknown-block(8,0) (1 sectors)
Finally, datablock is written to device md9, preventing disk to sleep.


Analysing output i have found that docker.log is being updated several times a minute.

Code: Select all

<7>[52473.727438] python2(9191): dirtied inode 7046 (docker.log) on md9

With these logs.

Code: Select all

time="2020-03-16T01:50:18.680573251+01:00" level=debug msg="Calling GET /v1.32/containers/json" 
I 've noticed that Container-Station runs docker in debug mode :shock: , so i have edited file

Code: Select all

/share/CACHEDEV1_DATA/.qpkg/container-station/script/run-docker.sh
Wich is script used by container-station to run docker, look for Debug enabled options

And comment Debug option.
Changed

Code: Select all

DOCKER_OPTS="$DOCKER_OPTS -D"
to

Code: Select all

#DOCKER_OPTS="$DOCKER_OPTS -D"
container station uses redis too, and redis.log is updated frequently, so i have lowered log level from redis in order to reduce disk accesses

To do so, i have edited

Code: Select all

/share/CACHEDEV1_DATA/.qpkg/container-station/etc/redis.conf
and change:

Code: Select all

loglevel notify
to

Code: Select all

loglevel warning


After that i realised that smbstatus is being called every few seconds. As i don't use samba, and i don't know how to stop smb callings, i have renamed smbstatus binary

Code: Select all

/mnt/ext/opt/samba/bin/smbstatus


to

Code: Select all

/mnt/ext/opt/samba/bin/smbstatus_hidden
And now disc activity have stopped and my disks have a pleasant sleep :DD :DD .