Bug 1588941 - location of core files generated in gluster container images is not persistent
Summary: location of core files generated in gluster container images is not persistent
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat Storage
Component: rhgs-server-container
Version: cns-3.10
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: CNS 3.10
Assignee: Saravanakumar
QA Contact: krishnaram Karthick
URL:
Whiteboard:
Depends On:
Blocks: 1568862 1598411
TreeView+ depends on / blocked
 
Reported: 2018-06-08 07:27 UTC by krishnaram Karthick
Modified: 2023-09-15 00:09 UTC (History)
17 users (show)

Fixed In Version: rhgs3/rhgs-server-rhel7:3.3.1-23
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-09-12 10:54:03 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1596284 1 None None None 2021-12-10 16:29:38 UTC
Red Hat Product Errata RHBA-2018:2688 0 None None None 2018-09-12 10:55:15 UTC

Internal Links: 1596284

Description krishnaram Karthick 2018-06-08 07:27:54 UTC
Description of problem:
When gluster-blockd process crashes, the core file is generated in / dir. However, in the rhgs-container image / directory is not persistent. We should be pointing all the core files to a persistent directory, probably /var/log/glusterfs/gluster-block?

Version-Release number of selected component (if applicable):
gluster-block-0.2.1-18.el7rhgs.x86_64

How reproducible:
always

Steps to Reproduce:
1. crash gluster-blockd

Actual results:
core file is generated in / directory

Expected results:
core file should be in a persistent directory, probably /var/log/glusterfs/gluster-block

Additional info:

Comment 16 Niels de Vos 2018-07-24 08:48:04 UTC
The selected approach is that the administrator has to configure the kernel.core_pattern on the systems themselves. Because this is a system-wide configuration, it is not appropriate for CNS to configure a default (that may be different from other components).

The CNS containers now should contain a /var/log/core/ directory. Administrators can take the following steps to capture cores:

1. sysctl -w kernel.core_pattern=/var/log/core/%e_%p
   (%e and %p are just examples, see 'man 5 core' for more options)

Now the admin can copy-out the core after a segfault.

2. configure a bind-mount so that /var/log/core/ is persistent on the host

With this, even if the container exits, the core stays available (probably need to change the core_pattern to include other %-options, maybe %t?).


Karthick, what were the exact steps that you tried to verify the change?

Comment 17 krishnaram Karthick 2018-07-26 17:07:28 UTC
(In reply to Niels de Vos from comment #16)
> The selected approach is that the administrator has to configure the
> kernel.core_pattern on the systems themselves. Because this is a system-wide
> configuration, it is not appropriate for CNS to configure a default (that
> may be different from other components).
> 
> The CNS containers now should contain a /var/log/core/ directory.
> Administrators can take the following steps to capture cores:
> 
> 1. sysctl -w kernel.core_pattern=/var/log/core/%e_%p
>    (%e and %p are just examples, see 'man 5 core' for more options)
> 
> Now the admin can copy-out the core after a segfault.
> 
> 2. configure a bind-mount so that /var/log/core/ is persistent on the host
> 
Is this directory not bind mounted by default? I don't see so in the latest rhgs-server-container image.

> With this, even if the container exits, the core stays available (probably
> need to change the core_pattern to include other %-options, maybe %t?).
> 
> 
> Karthick, what were the exact steps that you tried to verify the change?

What is the fix that we are providing as part of this bug? Is it just the /var/log/core/ directory that is being created within the container? and rest would be configuration changes that we are suggesting? 

I believe we should at least provide a fix with automatic bind mounting of /var/log/core/ directory.

Finally, the information on configuring how to configure core needs to be documented or our document should point to an existing document.

Comment 25 errata-xmlrpc 2018-09-12 10:54:03 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:2688

Comment 26 Red Hat Bugzilla 2023-09-15 00:09:54 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 500 days


Note You need to log in before you can comment on or make changes to this bug.