Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
For bugs related to Red Hat Enterprise Linux 5 product line. The current stable release is 5.10. For Red Hat Enterprise Linux 6 and above, please visit Red Hat JIRA https://issues.redhat.com/secure/CreateIssue!default.jspa?pid=12332745 to report new issues.

Bug 533565

Summary: Read-only nfs mount point is configured, kdump service can still be started successfully.
Product: Red Hat Enterprise Linux 5 Reporter: Igor Zhang <yugzhang>
Component: kexec-toolsAssignee: Neil Horman <nhorman>
Status: CLOSED ERRATA QA Contact: Red Hat Kernel QE team <kernel-qe>
Severity: low Docs Contact:
Priority: low    
Version: 5.4CC: qcai
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
previously, kdump did not test to see whether an NFS location was writeable before commencing a dump. When an unwriteable NFS location was specified in kdump.conf, kdump would therefore start the dump anyway, which would inevitably fail. Kdump now checks that NFS locations are writeable before dumping, and therefore avoids performing dumps that are destined to fail.
Story Points: ---
Clone Of:
: 600572 (view as bug list) Environment:
Last Closed: 2010-03-30 07:47:58 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
patch to check for writability
none
new version of patch none

Description Igor Zhang 2009-11-07 11:15:22 UTC
Description of problem:
A read-only nfs mount point is configured as dump target in /etc/kdump.conf. 
Then kdump service can still be started successfully although mkdir test on the mount point is failed.

Version-Release number of selected component (if applicable):
kexec-tools-1.102pre-77.el5.1

How reproducible:
Configure a read-only nfs mount point in /etc/kdump.conf.
service kdump start

Actual results:
Kdump service is started OK.

Expected results:
Kdump service should fail. Because afterwards the dump process will definitely fail. And mkdir test already shows failure.

Comment 1 Neil Horman 2009-11-11 19:39:04 UTC
Created attachment 369095 [details]
patch to check for writability

here you go, this should validate thta the nfs mount can be written.  Please verify this patch fixes the issue.  Thanks!

Comment 2 Neil Horman 2009-11-19 16:13:42 UTC
ping, any feedback?

Comment 3 Igor Zhang 2010-02-06 04:50:28 UTC
With your patch line, it seems still no r/w checking and the service can still be started with a ro nfs mountpoint.

Comment 4 Neil Horman 2010-02-11 16:20:37 UTC
Created attachment 390288 [details]
new version of patch

here, try this version.

Comment 5 Igor Zhang 2010-02-20 02:52:21 UTC
With new patch, it works:
[root@dhcp-65-30 ~]# service kdump start
No kdump initial ramdisk found.                            [WARNING]
Rebuilding /boot/initrd-2.6.18-164.el5kdump.img
touch: cannot touch `/tmp/tmp.hIBoZq4191//var/crash/testfile': Read-only file system
/etc/kdump.conf: Read only NFS mount 10.66.65.148:/nfs1
Failed to run mkdumprd
[root@dhcp-65-30 ~]#

Comment 7 Neil Horman 2010-02-22 17:25:26 UTC
I'm re-proposing this bug as an exception, since the patch just missed the test deadline.  Its very low impact, and it would be nice to square it away before 5.5

Comment 9 Neil Horman 2010-02-23 18:24:40 UTC
fixed in -94.el5

Comment 13 Ruediger Landmann 2010-03-21 15:11:57 UTC
Technical note added. If any revisions are required, please edit the "Technical Notes" field
accordingly. All revisions will be proofread by the Engineering Content Services team.

New Contents:
previously, kdump did not test to see whether an NFS location was
writeable before commencing a dump. When an unwriteable NFS location was 
specified in kdump.conf, kdump would therefore start the dump anyway, which
would inevitably fail. Kdump now checks that NFS locations are writeable 
before dumping, and therefore avoids performing dumps that are destined to
fail.

Comment 14 errata-xmlrpc 2010-03-30 07:47:58 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2010-0179.html