1

My Raspberry Pi has a 128GB SD Card with Arch ARM and

  • Apache
  • NextCloud

installed on it and it seemingly non-stop interfaces with the SD Card. With iotop I found out that mysqld is seemingly the process that writes most data to the disk. In the mysql shell I then found the following:

show processlist;
+------+--------------+-----------+-----------+---------+------+--------------------------+------------------+----------+
| Id   | User         | Host      | db        | Command | Time | State                    | Info             | Progress |
+------+--------------+-----------+-----------+---------+------+--------------------------+------------------+----------+
|    1 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge coordinator | NULL             |    0.000 |
|    2 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge worker      | NULL             |    0.000 |
|    3 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge worker      | NULL             |    0.000 |
|    4 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge worker      | NULL             |    0.000 |
|    5 | system user  |           | NULL      | Daemon  | NULL | InnoDB shutdown handler  | NULL             |    0.000 |
| 1846 | root         | localhost | NULL      | Query   |    0 | Init                     | show processlist |    0.000 |
| 1852 | oc_stdcerr13 | localhost | nextcloud | Sleep   |    0 |                          | NULL             |    0.000 |
| 1853 | oc_stdcerr13 | localhost | nextcloud | Sleep   |    0 |                          | NULL             |    0.000 |
+------+--------------+-----------+-----------+---------+------+--------------------------+------------------+----------+
8 rows in set (0.001 sec)

How can I give my SD Card a break? /var/log and /tmp are already on ramdisk (tmpfs)

Then when I continously executed the show processlist command, I also saw the following:

show processlist;
+------+--------------+-----------+-----------+---------+------+--------------------------+------------------------------------------------------------------------------------------------------+----------+
| Id   | User         | Host      | db        | Command | Time | State                    | Info                                                                                                 | Progress |
+------+--------------+-----------+-----------+---------+------+--------------------------+------------------------------------------------------------------------------------------------------+----------+
|    1 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge coordinator | NULL                                                                                                 |    0.000 |
|    2 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge worker      | NULL                                                                                                 |    0.000 |
|    3 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge worker      | NULL                                                                                                 |    0.000 |
|    4 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge worker      | NULL                                                                                                 |    0.000 |
|    5 | system user  |           | NULL      | Daemon  | NULL | InnoDB shutdown handler  | NULL                                                                                                 |    0.000 |
| 2061 | oc_stdcerr13 | localhost | nextcloud | Query   |    0 | Init                     | SELECT `filecache`.`fileid`, `storage`, `path`, `path_hash`, `filecache`.`parent`, `name`, `mimetype |    0.000 |
| 2062 | root         | localhost | NULL      | Query   |    0 | Init                     | show processlist                                                                                     |    0.000 |
| 2063 | oc_stdcerr13 | localhost | nextcloud | Sleep   |    0 |                          | NULL                                                                                                 |    0.000 |
+------+--------------+-----------+-----------+---------+------+--------------------------+------------------------------------------------------------------------------------------------------+----------+
8 rows in set (0.001 sec)

MariaDB [(none)]> show processlist;
+------+--------------+-----------+-----------+---------+------+--------------------------+------------------------------------------------------------------------------------------------------+----------+
| Id   | User         | Host      | db        | Command | Time | State                    | Info                                                                                                 | Progress |
+------+--------------+-----------+-----------+---------+------+--------------------------+------------------------------------------------------------------------------------------------------+----------+
|    1 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge coordinator | NULL                                                                                                 |    0.000 |
|    2 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge worker      | NULL                                                                                                 |    0.000 |
|    3 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge worker      | NULL                                                                                                 |    0.000 |
|    4 | system user  |           | NULL      | Daemon  | NULL | InnoDB purge worker      | NULL                                                                                                 |    0.000 |
|    5 | system user  |           | NULL      | Daemon  | NULL | InnoDB shutdown handler  | NULL                                                                                                 |    0.000 |
| 2061 | oc_stdcerr13 | localhost | nextcloud | Query   |    0 | Init                     | UPDATE `oc_filecache` SET `size` = '-1' WHERE (`fileid` = 15955) AND ((`size` <> '-1') OR (`size` IS |    0.000 |
| 2062 | root         | localhost | NULL      | Query   |    0 | Init                     | show processlist                                                                                     |    0.000 |
| 2063 | oc_stdcerr13 | localhost | nextcloud | Sleep   |    0 |                          | NULL                                                                                                 |    0.000 |
+------+--------------+-----------+-----------+---------+------+--------------------------+------------------------------------------------------------------------------------------------------+----------+
8 rows in set (0.001 sec)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.