Bug 1360841 - `db-control backup` should log when it creates a backup and that log should be present in spacewalk-debug tarball
Summary: `db-control backup` should log when it creates a backup and that log should b...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Server
Version: unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: ---
Assignee: Tomáš Kašpárek
QA Contact: Lukáš Hellebrandt
URL:
Whiteboard:
Depends On:
Blocks: sat58-errata
TreeView+ depends on / blocked
 
Reported: 2016-07-27 15:45 UTC by Jan Hutař
Modified: 2020-09-20 12:52 UTC (History)
4 users (show)

Fixed In Version: spacewalk-web-2.5.2-14-sat
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-02-05 13:57:18 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:0274 0 normal SHIPPED_LIVE Red Hat Satellite 5.8.0 bug fix update 2018-02-09 23:18:15 UTC

Description Jan Hutař 2016-07-27 15:45:43 UTC
Description of problem:
`db-control backup` should log when it creates a backup and that log should be present in spacewalk-debug tarball


Version-Release number of selected component (if applicable):
Satellite 5.7.0+


How reproducible:
always


Steps to Reproduce:
1. # db-control backup
2. # db-control online-backup


Actual results:
It is not logged anywhere


Expected results:
Successful run should be recorded somewhere

Comment 2 Tomáš Kašpárek 2017-10-16 13:03:28 UTC
db-control already logs into /var/log/rhn/rhn_database.log which is packed with spacewalk-debug, I've just extended it by a bit to see whether the action completed successfully or not

spacewalk.git(master): 372963d390ce0ffa0b1cfb9591d4a12ddf0b703c

Comment 5 Lukáš Hellebrandt 2018-01-16 13:28:11 UTC
FailedQA with spacewalk-web-2.5.2-14.

db-control is indeed logged in /var/log/rhn/rhn_database.log. However, regardless of whether it completed successfully or unsuccessfully, it always says "Completed: db-control [...]" so there is no way to determine whether the backup was actually done or it failed. Please, just make the output say something about failure in case $?!=0.

Comment 6 Lukáš Hellebrandt 2018-01-16 13:32:27 UTC
Verified with spacewalk-web-2.5.2-14.

1) # db-control backup
2) # spacewalk-debug
3) untar + unbzip the resulting archive
4) # grep backup rhn_logs/rhn/rhn_database.log
5) ^ check time, it should be a few seconds ago when you ran the backup
6) repeat for db-control online-backup

In case of successful run, the log says "Invocation:" and then "Completed:" while in case of unsuccessfull run, it only says "Invocation:".

Comment 9 errata-xmlrpc 2018-02-05 13:57:18 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:0274


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