fix(script): fix changing the system core pattern#358
fix(script): fix changing the system core pattern#358kmova merged 3 commits intoopenebs-archive:masterfrom
Conversation
earlier NDM used to rewrite the system core pattern so that the core dump is available in the persistent /var/openebs/sparse directory. But this will cause all process to write core files to that directory. Now NDM process will be launched from the openebs directory, so core files will get automatically written to the $PWD. This will help to remove changing the system core pattern. Signed-off-by: Akhil Mohan <akhil.mohan@mayadata.io>
Signed-off-by: Akhil Mohan <akhil.mohan@mayadata.io>
Signed-off-by: Akhil Mohan <akhil.mohan@mayadata.io>
Codecov Report
@@ Coverage Diff @@
## master #358 +/- ##
=========================================
- Coverage 51.51% 51.02% -0.5%
=========================================
Files 55 55
Lines 2634 2634
=========================================
- Hits 1357 1344 -13
- Misses 1170 1180 +10
- Partials 107 110 +3
Continue to review full report at Codecov.
|
| echo "[entrypoint.sh] creating /var/openebs/sparse if not exists." | ||
| mkdir -p /var/openebs/sparse | ||
| echo "[entrypoint.sh] changing directory to /var/openebs/sparse" | ||
| cd /var/openebs/sparse || exit |
There was a problem hiding this comment.
will it work if SPARSE_FILE_DIR env is different than /var/openebs/sparse? should we use SPARSE_FILE_DIR env instead /var/openebs/sparse?
There was a problem hiding this comment.
Only the mountPath is dependent. SPARSE_FILE_DIR is the directory inside the container .
There was a problem hiding this comment.
right, so if I have changed that path to something else what will happen? since in the entrypint.sh it is fixed to /var/openebs/sparse.
There was a problem hiding this comment.
if the mountPath is also changed, the core dump wont be persisted. Will raise a PR to fix it. The SPARSE_FILE_DIR and mountPath should always be the same.
…rchive#358) Earlier NDM used to rewrite the system core pattern so that the core dump is available in the persistent /var/openebs/sparse directory. But this will cause all process to write core files to that directory. Now NDM process will be launched from the openebs directory, so core files will get automatically written to the $PWD. This will help to remove changing the system core pattern. Signed-off-by: Akhil Mohan <akhil.mohan@mayadata.io>
Earlier NDM used to rewrite the system core pattern so that the core dump is available in the persistent /var/openebs/sparse directory. But this will cause all process to write core files to that directory. Now NDM process will be launched from the openebs directory, so core files will get automatically written to the $PWD. This will help to remove changing the system core pattern. Signed-off-by: Akhil Mohan <akhil.mohan@mayadata.io>
Earlier NDM used to rewrite the system core pattern so that the core
dump is available in the persistent
/var/openebs/sparsedirectory.But this will cause all process on the host to write core files to that directory.
Now NDM process will be launched from the openebs directory, so core
files will get automatically written to the
$PWD. This will help toremove changing the system core pattern.
Signed-off-by: Akhil Mohan akhil.mohan@mayadata.io