Article 5BPSQ ext4 journaling process constantly accessing hard drive - does not go into sleep mode

ext4 journaling process constantly accessing hard drive - does not go into sleep mode

by
retiem
from LinuxQuestions.org on (#5BPSQ)
Hi there,

I connected my new WD Elements 4TB hard drive to my Ubuntu 18.04 LTS server and eventually noticed that it never goes to sleep (normally happens after 30 min. idle time).

I filled up the disk to 93% capacity already, so it now has lots of fresh new data.

I looked around a bit and noticed that the journaling process seems to be the one keeping the disk awake.
user@server:~$ sudo lsof | grep sdb1
jbd2/sdb1 793 root cwd DIR 8,2 4096 2 /
jbd2/sdb1 793 root rtd DIR 8,2 4096 2 /
jbd2/sdb1 793 root txt unknown /proc/793/exe
user@server:~$ sudo ps -ef|grep jbd2
root 332 2 0 16:22 ? 00:00:00 [jbd2/sda2-8]
root 793 2 0 16:22 ? 00:00:00 [jbd2/sdb1-8]
user 3795 3597 0 22:26 pts/0 00:00:00 grep --color=auto jbd2
user@server:~$ sudo iotop -obtqqq | grep jbd2
22:26:22 332 be/3 root 0.00 B/s 15.62 K/s 0.00 % 0.34 % [jbd2/sda2-8]
22:26:47 332 be/3 root 0.00 B/s 3.90 K/s 0.00 % 0.33 % [jbd2/sda2-8]
22:26:52 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.32 % [jbd2/sda2-8]
22:27:07 332 be/3 root 0.00 B/s 3.91 K/s 0.00 % 0.31 % [jbd2/sda2-8]
22:27:13 332 be/3 root 0.00 B/s 23.44 K/s 0.00 % 0.33 % [jbd2/sda2-8]
22:27:23 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.31 % [jbd2/sda2-8]
22:27:54 332 be/3 root 0.00 B/s 3.90 K/s 0.00 % 0.32 % [jbd2/sda2-8]
22:28:12 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.30 % [jbd2/sda2-8]
22:28:26 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.31 % [jbd2/sda2-8]
22:28:50 332 be/3 root 0.00 B/s 11.72 K/s 0.00 % 0.19 % [jbd2/sda2-8]
22:29:03 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.30 % [jbd2/sda2-8]
22:29:17 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.31 % [jbd2/sda2-8]
22:29:26 332 be/3 root 0.00 B/s 3.91 K/s 0.00 % 0.32 % [jbd2/sda2-8]
22:29:32 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.31 % [jbd2/sda2-8]
22:29:57 332 be/3 root 0.00 B/s 3.90 K/s 0.00 % 0.31 % [jbd2/sda2-8]
22:30:23 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.32 % [jbd2/sda2-8]
22:30:28 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.31 % [jbd2/sda2-8]
22:30:58 332 be/3 root 0.00 B/s 3.91 K/s 0.00 % 0.33 % [jbd2/sda2-8]
22:31:23 332 be/3 root 0.00 B/s 46.82 K/s 0.00 % 0.38 % [jbd2/sda2-8]
22:31:29 332 be/3 root 0.00 B/s 35.11 K/s 0.00 % 0.35 % [jbd2/sda2-8]
22:31:44 332 be/3 root 0.00 B/s 15.62 K/s 0.00 % 0.32 % [jbd2/sda2-8]
22:32:15 332 be/3 root 0.00 B/s 3.91 K/s 0.00 % 0.33 % [jbd2/sda2-8]
22:32:33 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.33 % [jbd2/sda2-8]
22:32:46 332 be/3 root 0.00 B/s 3.91 K/s 0.00 % 0.32 % [jbd2/sda2-8]
22:33:17 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.30 % [jbd2/sda2-8]
22:33:37 332 be/3 root 0.00 B/s 3.90 K/s 0.00 % 0.36 % [jbd2/sda2-8]
22:33:47 332 be/3 root 0.00 B/s 0.00 B/s 0.00 % 0.32 % [jbd2/sda2-8]
22:34:18 332 be/3 root 0.00 B/s 3.90 K/s 0.00 % 0.31 % [jbd2/sda2-8]
^C
user@server:~$ sudo parted /dev/sdb
GNU Parted 3.2
Using /dev/sdb
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) p
Model: WD Elements 107C (scsi)
Disk /dev/sdb: 4001GB
Sector size (logical/physical): 4096B/4096B
Partition Table: gpt
Disk Flags:

Number Start End Size File system Name Flags
1 1049kB 4001GB 4001GB ext4 WDElements4TB

(parted) q
user@server:~$cat /etc/fstab
UUID=8fcf0067-3ecc-4672-bad6-076dab726b74 / ext4 defaults 0 0
UUID=C983-3DF9 /boot/efi vfat defaults 0 0
/swap.img none swap sw 0 0

UUID=2daf5453-0334-412e-be77-d00367b93ba0 /media/usbhdd ext4 auto,rw,nodev,noatime,nofail 0 0
.
.
.
So, I'm wondering, is this normal? Is the file system just doing the initial journaling on all this new data, and it is taking very long because it is a large amount? Or is this nonsense?

What's going on? I'm wondering if I am waiting in vain for the disk to eventually go to sleep... :confused:

BTW, as a reference, I have another WD Elements drive connected to this same machine, and it is working just fine (goes to sleep after about 30 min. of idle time), the only difference is that, when I set up this other one, I kept the default file system on it (NTFS, I think?)

Any feedback from you guys would be really appreciated! :hattip:

Best regards!latest?d=yIl2AUoC8zA latest?i=e2vYX49fo_Q:WPhSAS44SPA:F7zBnMy latest?i=e2vYX49fo_Q:WPhSAS44SPA:V_sGLiP latest?d=qj6IDK7rITs latest?i=e2vYX49fo_Q:WPhSAS44SPA:gIN9vFwe2vYX49fo_Q
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments