[Asterisk-code-review] ast coredumper: Minor fixes (asterisk[15])
George Joseph
asteriskteam at digium.com
Thu Mar 1 07:50:48 CST 2018
George Joseph has submitted this change and it was merged. ( https://gerrit.asterisk.org/8386 )
Change subject: ast_coredumper: Minor fixes
......................................................................
ast_coredumper: Minor fixes
* Fix --tarball-config so the option doesn't cause an error.
* Allow for missing /etc/os-release.
* Add a sleep between tarballing the coredump and removing the
output directory to allow the filesystem to settle.
Change-Id: I73e03b13087978bcc7f6bc9f45753990f82d9d77
---
M contrib/scripts/ast_coredumper
1 file changed, 6 insertions(+), 1 deletion(-)
Approvals:
Jenkins2: Verified
Kevin Harwell: Looks good to me, but someone else must approve
Corey Farrell: Looks good to me, but someone else must approve
Joshua Colp: Looks good to me, approved
George Joseph: Approved for Submit
diff --git a/contrib/scripts/ast_coredumper b/contrib/scripts/ast_coredumper
index 884ede7..38d95cc 100755
--- a/contrib/scripts/ast_coredumper
+++ b/contrib/scripts/ast_coredumper
@@ -216,6 +216,7 @@
RUNNING=false
latest=false
tarball_coredumps=false
+tarball_config=false
delete_coredumps_after=false
tarball_results=false
delete_results_after=false
@@ -280,6 +281,9 @@
;;
--tarball-coredumps)
tarball_coredumps=true
+ ;;
+ --tarball-config)
+ tarball_config=true
;;
--delete-coredumps-after)
delete_coredumps_after=true
@@ -436,7 +440,7 @@
ln -s ${cf} ${dest}/tmp/${cfname}
cp ${outputdir}/${cfname}*.txt ${dest}/tmp/
- cp /etc/os-release ${dest}/etc/
+ [ -f /etc/os-release ] && cp /etc/os-release ${dest}/etc/
if $tarball_config ; then
cp -a /etc/asterisk ${dest}/etc/
fi
@@ -445,6 +449,7 @@
cp -a /usr/sbin/asterisk ${dest}/usr/sbin
rm -rf ${tf}
tar -chzf ${tf} --transform="s/^[.]/${cfname}/" -C ${dest} .
+ sleep 3
rm -rf ${dest}
echo "Created $tf"
elif $tarball_results ; then
--
To view, visit https://gerrit.asterisk.org/8386
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-Project: asterisk
Gerrit-Branch: 15
Gerrit-MessageType: merged
Gerrit-Change-Id: I73e03b13087978bcc7f6bc9f45753990f82d9d77
Gerrit-Change-Number: 8386
Gerrit-PatchSet: 1
Gerrit-Owner: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180301/d84bf1a6/attachment-0001.html>
More information about the asterisk-code-review
mailing list