Modify ↓
Ticket #1068 (closed defect: fixed)
Malformed URL in Packages/config.xml Throws Traceback
Reported by: | rcuza | Owned by: | https://www.google.com/accounts/o8/id?id=AItOawnSjgovXZr-_V3vGkvMSR0pc5LDykRc1Nc |
---|---|---|---|
Priority: | minor | Milestone: | Bcfg2 1.2.1 Release (Bugfix) |
Component: | bcfg2-server | Version: | 1.0 |
Keywords: | v1.1.3 | Cc: | [email protected]… |
Description
When there is a URl that returns a 404 error in the Packages/config.xml file, running bcfg2 on a client throws a traceback error.
Here is an example
Failed to read file /var/lib/bcfg2/Packages/cache/http:@@[email protected]@[email protected]@[email protected]@[email protected] Packages: File read failed; falling back to file download Packages: Updating http://security.debian.org/debian/dists/squeeze/updates/main/binary-amd64/Packages.gz Packages: Failed to fetch url http://security.debian.org/debian/dists/squeeze/updates/main/binary-amd64/Packages.gz. code=404 Packages: Updating http://security.debian.org/debian/dists/squeeze/updates/main/binary-i386/Packages.gz Packages: Failed to fetch url http://security.debian.org/debian/dists/squeeze/updates/main/binary-i386/Packages.gz. code=404 Failed to read file /var/lib/bcfg2/Packages/cache/http:@@[email protected]@[email protected]@[email protected]@[email protected] Failed to update source Traceback (most recent call last): File "/usr/lib/pymodules/python2.6/Bcfg2/Server/Plugins/Packages.py", line 120, in setup_data self.read_files() File "/usr/lib/pymodules/python2.6/Bcfg2/Server/Plugins/Packages.py", line 403, in read_files reader = gzip.GzipFile(fname) File "/usr/lib/python2.6/gzip.py", line 79, in __init__ fileobj = self.myfileobj = __builtin__.open(filename, mode or 'rb') IOError: [Errno 2] No such file or directory: '/var/lib/bcfg2/Packages/cache/http:@@[email protected]@[email protected]@[email protected]@[email protected]' Loading experimental plugin(s): Packages
Expected result is no traceback. The "Failed to fetch" and 404 should be sufficient to get the sysadmin looking in the right direction.
Nice to have: suggested troubleshooting steps in error message.
Attachments
Change History
comment:1 Changed 12 years ago by solj
- Cc [email protected]… added
- Milestone changed from Bcfg2 1.3.0 Release to Bcfg2 1.2.1 Release (Bugfix)
comment:3 Changed 12 years ago by rcuza
- Keywords v1.1.3 added
This traceback was produced with version 1.1.3. I will update bug when I've had a chance to test it against HEAD.
Note: Plugins/Packages?.py was rebuilt from 1.1.3 to current HEAD.
comment:4 Changed 11 years ago by https://www.google.com/accounts/o8/id?id=AItOawnSjgovXZr-_V3vGkvMSR0pc5LDykRc1Nc
- Owner changed from desai to https://www.google.com/accounts/o8/id?id=AItOawnSjgovXZr-_V3vGkvMSR0pc5LDykRc1Nc
- Status changed from new to accepted
Note: See
TracTickets for help on using
tickets.
Can you reproduce this with the latest HEAD?