You are not logged in.

#1 2021-12-20 12:11:45

j1simon
Member
From: Denmark
Registered: 2016-01-28
Posts: 189

38 seconds to mount a BTRFS hard disk drive seems too long to me

Hard disk: 16TB SEAGATE IRONWOLF PRO 3.5", 7200 RPM 256MB CACHE

I have formatted it as BTRFS and the mounting options (fstab) are:

/multimedia     btrfs rw,noatime,autodefrag,compress-force=zstd,nossd,space_cache=v2    0 0

The disk works fine, I have not detected any problems but every time I reboot the system takes a long time due to the mounting of this drive:

$ systemd-analyze blame
38.432s multimedia.mount
11.853s systemd-networkd-wait-online.service
589ms plymouth-quit-wait.service
588ms plymouth-quit.service
...

I find it too long to mount a drive, is this normal, is it because of one of the mounting options, or because of the size of the hard drive?

Offline

#2 2021-12-20 22:18:51

ayr-ton
Member
From: Brazil
Registered: 2015-09-14
Posts: 29
Website

Re: 38 seconds to mount a BTRFS hard disk drive seems too long to me

Does it happen when you try to mount manually? Have you run disk diagnostics for confirming is everything okay with your disk?


Fork it all! Fork it all!

Offline

#3 2021-12-21 08:25:02

j1simon
Member
From: Denmark
Registered: 2016-01-28
Posts: 189

Re: 38 seconds to mount a BTRFS hard disk drive seems too long to me

When I mount it manually it takes the same time.
The smartctl output is correct and the disk works fine:

smartctl 7.2 2020-12-30 r5155 [x86_64-linux-5.15.10-xanmod1-tt-1] (local build)
Copyright (C) 2002-20, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     Seagate IronWolf Pro
Device Model:     ST16000NE000-2RW103
Serial Number:    ZL277D53
LU WWN Device Id: 5 000c50 0c68770bb
Firmware Version: EN02
User Capacity:    16.000.900.661.248 bytes [16,0 TB]
Sector Sizes:     512 bytes logical, 4096 bytes physical
Rotation Rate:    7200 rpm
Form Factor:      3.5 inches
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   ACS-4 (minor revision not indicated)
SATA Version is:  SATA 3.3, 6.0 Gb/s (current: 6.0 Gb/s)
Local Time is:    Tue Dec 21 09:20:55 2021 CET
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED

General SMART Values:
Offline data collection status:  (0x82)	Offline data collection activity
					was completed without error.
					Auto Offline Data Collection: Enabled.
Self-test execution status:      (   0)	The previous self-test routine completed
					without error or no self-test has ever 
					been run.
Total time to complete Offline 
data collection: 		(  567) seconds.
Offline data collection
capabilities: 			 (0x7b) SMART execute Offline immediate.
					Auto Offline data collection on/off support.
					Suspend Offline collection upon new
					command.
					Offline surface scan supported.
					Self-test supported.
					Conveyance Self-test supported.
					Selective Self-test supported.
SMART capabilities:            (0x0003)	Saves SMART data before entering
					power-saving mode.
					Supports SMART auto save timer.
Error logging capability:        (0x01)	Error logging supported.
					General Purpose Logging supported.
Short self-test routine 
recommended polling time: 	 (   1) minutes.
Extended self-test routine
recommended polling time: 	 (1412) minutes.
Conveyance self-test routine
recommended polling time: 	 (   2) minutes.
SCT capabilities: 	       (0x50bd)	SCT Status supported.
					SCT Error Recovery Control supported.
					SCT Feature Control supported.
					SCT Data Table supported.

SMART Attributes Data Structure revision number: 10
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x000f   082   064   044    Pre-fail  Always       -       165353740
  3 Spin_Up_Time            0x0003   090   087   000    Pre-fail  Always       -       0
  4 Start_Stop_Count        0x0032   100   100   020    Old_age   Always       -       63
  5 Reallocated_Sector_Ct   0x0033   100   100   010    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x000f   086   060   045    Pre-fail  Always       -       387809178
  9 Power_On_Hours          0x0032   088   088   000    Old_age   Always       -       10744
 10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
 12 Power_Cycle_Count       0x0032   100   100   020    Old_age   Always       -       62
 18 Head_Health             0x000b   100   100   050    Pre-fail  Always       -       0
187 Reported_Uncorrect      0x0032   100   100   000    Old_age   Always       -       0
188 Command_Timeout         0x0032   100   001   000    Old_age   Always       -       98785821197
190 Airflow_Temperature_Cel 0x0022   065   045   040    Old_age   Always       -       35 (Min/Max 30/42)
192 Power-Off_Retract_Count 0x0032   100   100   000    Old_age   Always       -       21
193 Load_Cycle_Count        0x0032   098   098   000    Old_age   Always       -       5551
194 Temperature_Celsius     0x0022   035   044   000    Old_age   Always       -       35 (0 18 0 0 0)
197 Current_Pending_Sector  0x0012   100   100   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0010   100   100   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x003e   200   001   000    Old_age   Always       -       1049
200 Pressure_Limit          0x0023   100   100   001    Pre-fail  Always       -       0
240 Head_Flying_Hours       0x0000   100   253   000    Old_age   Offline      -       10053h+51m+27.896s
241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       75688688889
242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       350984768219

SMART Error Log Version: 1
No Errors Logged

SMART Self-test log structure revision number 1
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
# 1  Short offline       Completed without error       00%       937         -
# 2  Short offline       Completed without error       00%       937         -
# 3  Extended offline    Completed without error       00%       919         -

SMART Selective self-test log data structure revision number 1
 SPAN  MIN_LBA  MAX_LBA  CURRENT_TEST_STATUS
    1        0        0  Not_testing
    2        0        0  Not_testing
    3        0        0  Not_testing
    4        0        0  Not_testing
    5        0        0  Not_testing
Selective self-test flags (0x0):
  After scanning selected spans, do NOT read-scan remainder of disk.
If Selective self-test is pending on power-up, resume after 0 minute delay.
$ sudo btrfs inspect-internal dump-super /dev/sda1

superblock: bytenr=65536, device=/dev/sda1
---------------------------------------------------------
csum_type		0 (crc32c)
csum_size		4
csum			0xf83c0f0d [match]
bytenr			65536
flags			0x1
			( WRITTEN )
magic			_BHRfS_M [match]
fsid			256db611-dc2d-41d4-8374-b3c4e72bec00
metadata_uuid		256db611-dc2d-41d4-8374-b3c4e72bec00
label			multimedia
generation		70314
root			36814848
sys_array_size		129
chunk_root_generation	69937
root_level		0
chunk_root		23052288
chunk_root_level	1
log_root		0
log_root_transid	0
log_root_level		0
total_bytes		16000899592192
bytes_used		12418619920384
sectorsize		4096
nodesize		16384
leafsize (deprecated)	16384
stripesize		4096
root_dir		6
num_devices		1
compat_flags		0x0
compat_ro_flags		0x3
			( FREE_SPACE_TREE |
			  FREE_SPACE_TREE_VALID )
incompat_flags		0x171
			( MIXED_BACKREF |
			  COMPRESS_ZSTD |
			  BIG_METADATA |
			  EXTENDED_IREF |
			  SKINNY_METADATA )
cache_generation	0
uuid_tree_generation	70314
dev_item.uuid		a23a745d-ca61-4aa8-b1d0-2a96725472e1
dev_item.fsid		256db611-dc2d-41d4-8374-b3c4e72bec00 [match]
dev_item.type		0
dev_item.total_bytes	16000899592192
dev_item.bytes_used	12462946516992
dev_item.io_align	4096
dev_item.io_width	4096
dev_item.sector_size	4096
dev_item.devid		1
dev_item.dev_group	0
dev_item.seek_speed	0
dev_item.bandwidth	0
dev_item.generation	0

Last edited by j1simon (2021-12-21 08:29:58)

Offline

#4 2022-01-08 08:48:06

j1simon
Member
From: Denmark
Registered: 2016-01-28
Posts: 189

Re: 38 seconds to mount a BTRFS hard disk drive seems too long to me

I have asked on the btrfs mailing list and apparently it is a known problem with large disks the more full they are. In fact, it now takes 54 seconds to mount the unit.
https://lore.kernel.org/linux-btrfs/CAH … l.com/t/#u
https://lore.kernel.org/linux-btrfs/CAM … l.com/t/#u

Offline

Board footer

Powered by FluxBB