Bug 1064296
| Summary: | Reserved Oracle word used for repo-sync | ||
|---|---|---|---|
| Product: | [Community] Spacewalk | Reporter: | Mike <michael.frank> |
| Component: | Server | Assignee: | Michael Mráka <mmraka> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Red Hat Satellite QA List <satqe-list> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 2.0 | CC: | jpazdziora, michael.frank |
| Target Milestone: | --- | Keywords: | Reopened |
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | spacewalk-backend-2.1.51-1 | Doc Type: | Bug Fix |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2014-03-04 13:07:03 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
| Bug Depends On: | |||
| Bug Blocks: | 1069560 | ||
|
Description
Mike
2014-02-12 11:27:24 UTC
Can you please check if applying the following patch fixes the issue?
diff --git a/backend/satellite_tools/reposync.py b/backend/satellite_tools/reposync.py
index f3e2352..d336a88 100644
--- a/backend/satellite_tools/reposync.py
+++ b/backend/satellite_tools/reposync.py
@@ -620,7 +620,7 @@ class RepoSync(object):
insert_h = rhnSQL.prepare("""
insert into rhnKSTreeFile (kstree_id, relative_filename, checksum_id, file_size, last_modified, created, modified)
- values (:id, :path, lookup_checksum('sha256', :checksum), :size, epoch_seconds_to_timestamp_tz(:st_time), current_timestamp, current_timestamp)
+ values (:id, :path, lookup_checksum('sha256', :checksum), :st_size, epoch_seconds_to_timestamp_tz(:st_time), current_timestamp, current_timestamp)
""")
dirs = [ '' ]
while len(dirs) > 0:
@@ -646,7 +646,7 @@ class RepoSync(object):
print "Retrieving %s" % d + s
plug.get_file(d + s, os.path.join(CFG.MOUNT_POINT, ks_path))
st = os.stat(local_path)
- insert_h.execute(id = ks_id, path = d + s, checksum = getFileChecksum('sha256', local_path), size = st.st_size, st_time = st.st_mtime)
+ insert_h.execute(id = ks_id, path = d + s, checksum = getFileChecksum('sha256', local_path), st_size = st.st_size, st_time = st.st_mtime)
rhnSQL.commit()
I've checked that above patch fixes the issue. Thanks.
Committed to spacewalk master as
commit fe9029fe397336c561f1be28deb5d9a2ad9fe6e7
1064296 - rename variable so it doesn't colide with reserved word
Spacewalk 2.1 has been released. https://fedorahosted.org/spacewalk/wiki/ReleaseNotes21 Spacewalk 2.1 has been released. https://fedorahosted.org/spacewalk/wiki/ReleaseNotes21 Hello, That works for me. Thanks Michael |