Project

General

Profile

Bug #3092

dumpon: sysctl: kern.dumpdev: Device busy

Added by liweitianux 26 days ago. Updated 24 days ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Kernel
Target version:
-
Start date:
10/23/2017
Due date:
% Done:

0%


Description

Hello, I had the problem that "dumpon" couldn't let me change the dump device, which complained "Device busy", as shown below:

dfly# dumpon /dev/serno/WD-WCAS25235448.s1b
dumpon: sysctl: kern.dumpdev: Device busy

(I previously wrongly configured the "dumpdev" to be "/dev/mapper/swap", which is the mapped name of the dm-crypt'ed swap device. Therefore I used "dumpon" to change the dump device the underlying swap device but failed, as shown here.)

In addition, I also did such a test within a virtual machine using DFly-5.0. After partitioned the swap partition, I can "dumpon" to it successfully at the first time, but later it fails with "Device busy" error. See also the attached screenshot.

I suspect this issue exists in the "setdumpdev()" function in "sys/kern/kern_shutdown.c".

Cheers,
Aly

dfly.dumpon.devicebusy.png View (10.3 KB) liweitianux, 10/23/2017 02:42 AM

History

#1 Updated by swildner 24 days ago

I think once set, you first have to 'dumpon off' before being able to set it again.

#2 Updated by liweitianux 24 days ago

swildner wrote:
> I think once set, you first have to 'dumpon off' before being able to set it again.

True. Once I "dumpon off", I can "dumpon" another device to make the change. Thanks.

However, the current error message is unhelpful, which should be improved... And the dumpon(8) man page needs a note, something like:

Once the dump device is set, it must be first turned off using "dumpon off" before the new dump device can be set.

Maybe a new option can be added to take care of this. In addition, the "dumpon off" seems a bit wired... I think a symlink as "dumpoff" may be a good choice.

Cheers,
Aly

Also available in: Atom PDF