Issue #639
closedpulp-manage-db does not handle missing /dev/log gracefully
Description
Description of problem:
If pulp-manage-db is run on a machine that does not have /dev/log, the user will see error messages that they do not understand (similar to "Nonetype has no attribute critical"). It would be better if we printed an informative error to stderr and exited with a non-zero exit code.
Version-Release number of selected component (if applicable):
2.4.3-1
How reproducible:
Every time.
Steps to Reproduce:
1. Take some action to remove /dev/log (stopping rsyslogd might do the trick)
2. Run pulp-manage-db
Actual results:
You will get difficult-to-understand error messages on the console (and obviously, no log messages).
Expected results:
You should get a meaningful error message on the console and a non-zero exit code. Obviously, still nothing should/could be logged.
+ This bug was cloned from Bugzilla Bug #1173310 +
Updated by tcarlin@redhat.com over 9 years ago
1173338 is related doc bz
+ This comment was cloned from Bugzilla #1173310 comment 1 +
Updated by amacdona@redhat.com over 9 years ago
- Status changed from NEW to ASSIGNED
- Assignee set to amacdona@redhat.com
Updated by amacdona@redhat.com over 9 years ago
- Status changed from ASSIGNED to POST
Updated by amacdona@redhat.com over 9 years ago
- Status changed from POST to MODIFIED
Updated by dkliban@redhat.com over 9 years ago
- Status changed from MODIFIED to 5
- Platform Release set to 2.6.1
Updated by pthomas@redhat.com over 9 years ago
- Status changed from 5 to 6
verified
[root@mgmt7 ~]#
[root@mgmt7 ~]# service rsyslog stop
Shutting down system logger: [ OK ]
[root@mgmt7 ~]#
[root@mgmt7 ~]#
[root@mgmt7 ~]#
[root@mgmt7 ~]# sudo -u apache pulp-manage-db
Unable to access to log, /dev/log.
[root@mgmt7 ~]#
[root@mgmt7 ~]#
[root@mgmt7 ~]# service rsyslog start
Starting system logger: [ OK ]
[root@mgmt7 ~]#
[root@mgmt7 ~]#
[root@mgmt7 ~]# sudo -u apache pulp-manage-db
Mongo database for connection is version 2.4.13
Loading content types.
Loading type descriptors [rpm_support.json, iso_support.json, puppet.json]
Parsing type descriptors
Validating type descriptor syntactic integrity
Validating type descriptor semantic integrity
Updating the database with types [distribution, drpm, erratum, package_group, package_category, package_environment, rpm, srpm, yum_repo_metadata_file, iso, puppet_module]
/usr/lib/python2.6/site-packages/pulp/server/db/connection.py:167: DeprecationWarning: The safe parameter is deprecated. Please use write concern options instead.
return method(*args, **kwargs)
Content types loaded.
Ensuring the admin role and user are in place.
Admin role and user are in place.
Beginning database migrations.
Migration package pulp.server.db.migrations is up to date at version 12
Migration package pulp_puppet.plugins.migrations is up to date at version 2
Migration package pulp_rpm.plugins.migrations is up to date at version 21
Database migrations complete.
<\pre>
Updated by dkliban@redhat.com about 9 years ago
- Status changed from 6 to CLOSED - CURRENTRELEASE