Description of problem: I'm unable to use reactivation key in SWnightly Version-Release number of selected component (if applicable): SWnightly as of 2012-02-01 How reproducible: 1 of 1 attempt Steps to Reproduce: 1. Register system, base channel set to some custom channel X, provisioning add-on entitlement granted 2. Details -> Reactivation -> Generate New Key 3. Try to use that key: # rhnreg_ks --force --activationkey=9ca01f470d8ffc28123bfa30ebef221d An error has occurred: Error Message: Your account does not have access to any channels matching (release='5Server', arch='x86_64-redhat-linux') Error Class Code: 19 Error Class Info: Architecture and OS version combination is not supported. Explanation: An error has occurred while processing your request. If this problem persists please enter a bug report at bugzilla.redhat.com. If you choose to submit the bug report, please be sure to include details of what you were trying to do when this error occurred and details on how to reproduce this problem. See /var/log/up2date for more information 4. Take a look at the key which was generated (I have not found way how to go there through WebUI, you have to edit URL when editing different AK) https://<fqdn>/rhn/activationkeys/Edit.do?tid=<your_reactivation_key_id> -> it says "Base Channels: Spacewalk Default" although original registration was into my custom channel X Actual results: Reactivation key do not respect base channel set. Expected results: Reactivation key should work. System should be in same channel after it as it was before it (in my case it was custom channel).
Traceback in /var/log/up2date log, but it is probably not related, just a consequence of incorrect key: [Thu Feb 2 02:40:59 2012] up2date Traceback (most recent call last): File "/usr/sbin/rhnreg_ks", line 218, in ? cli.run() File "/usr/share/rhn/up2date_client/rhncli.py", line 83, in run sys.exit(self.main() or 0) File "/usr/sbin/rhnreg_ks", line 135, in main other = other) File "/usr/share/rhn/up2date_client/rhnreg.py", line 348, in registerSystem ret = s.registration.new_system(auth_dict) File "/usr/share/rhn/up2date_client/rhnserver.py", line 50, in __call__ return rpcServer.doCall(method, *args, **kwargs) File "/usr/share/rhn/up2date_client/rpcServer.py", line 196, in doCall ret = method(*args, **kwargs) File "/usr/lib64/python2.4/xmlrpclib.py", line 1096, in __call__ return self.__send(self.__name, args) File "/usr/share/rhn/up2date_client/rpcServer.py", line 37, in _request1 ret = self._request(methodname, params) File "/usr/lib/python2.4/site-packages/rhn/rpclib.py", line 381, in _request self._handler, request, verbose=self._verbose) File "/usr/lib/python2.4/site-packages/rhn/transports.py", line 184, in request return self._process_response(fd, connection) File "/usr/lib/python2.4/site-packages/rhn/transports.py", line 212, in _process_response return self.parse_response(fd) File "/usr/lib/python2.4/site-packages/rhn/transports.py", line 236, in parse_response return u.close() File "/usr/lib64/python2.4/xmlrpclib.py", line 744, in close raise Fault(**self._stack[0]) up2date_client.up2dateErrors.NoBaseChannelError: Error Message: Your account does not have access to any channels matching (release='5Server', arch='x86_64-redhat-linux') Error Class Code: 19 Error Class Info: Architecture and OS version combination is not supported. Explanation: An error has occurred while processing your request. If this problem persists please enter a bug report at bugzilla.redhat.com. If you choose to submit the bug report, please be sure to include details of what you were trying to do when this error occurred and details on how to reproduce this problem.
So is this a regression? Against Spacewalk 1.6, Satellite 5.4.1 ... or is this a long-present bug?
Got almost same bug after updating channel minor version (ScientificLinux 6.1->6.2) Not sure is it the same bug or not?
I have checked this scenario on Satellite 5.4.1 (+all erratas) and bug is there as well. 1. Register system, base channel set to some custom channel X, provisioning add-on entitlement granted 2. Details -> Reactivation -> Generate New Key 3. Take a look at the key which was generated https://<fqdn>/rhn/activationkeys/Edit.do?tid=<your_reactivation_key_id> -> it says "Base Channels: RHN Satellite Default" instead of my custom channel X being selected
(In reply to comment #4) > Got almost same bug after updating channel minor version (ScientificLinux > 6.1->6.2) > Not sure is it the same bug or not? Depends on what you did. This bug is about reactivation key. Traceback in comment #1 is side effect.
Ive run into the same bug in both 1.6 and 1.7 with deploying several distros . its actually a bigger problem than it first seems because it causes rhnreg_ks to fail when you re-kickstart a host as a result its impossible to redeploy a host without manually duplicating its profile. Note I am using PostgreSQL as my database back end. Here is the matching error message from rhn_server_xmlrpc.log during Scientific Linux 6.2 re-registration " 2012/03/14 10:00:54 -04:00 25101 <CLIENT IP>: server/rhnChannel.guess_channels_for_server('ERROR', 'No available channels for (server, org)', (1000010011, 1), '6.2', 'x86_64') "
I've identified a table that should be alterable to work around the issue and make a key with the "spacewalk default" channel work rhndistchannelmap (os, release, channel_arch_id, channel_id) but I haven't had time to test it or come up with the right query to make it work smoothly
Ok Ive made progress but hit a new bug here is what i did i logged in to postgresql and ran the following two queries " spaceschema=# select id,channel_arch_id from rhnChannel where label ='sci-linux-6_2'; id | channel_arch_id -----+----------------- 109 | 513 (1 row) spaceschema=# insert into rhnDistChannelMap (os,release,channel_arch_id,channel_id) VALUES ('sl-release','6.2','513','109'); " this got me initially past the problem but a new one poped up here is the error from the postgresql log " ERROR: new row for relation "rhnserverhistory" violates check constraint "vn_rhnserverhistory_details" STATEMENT: insert into rhnServerHistory (id, server_id, summary, details) values (sequence_nextval('rhn_event_id_seq'), 1000010018, E'Updated system release from 6.2 to 6.2', E'') " here is the traceback email it sent " Exception reported from server.ip.was.here Time: Wed Mar 21 12:19:08 2012 Exception type <class 'psycopg2.IntegrityError'> Exception while handling function registration.new_system Request object information: URI: /XMLRPC Remote Host: client.ip.was.here Server Name: server.ip.was.here:443 Headers passed in: Accept-Encoding: identity CONTENT_LENGTH: 1562 CONTENT_TYPE: text/xml DOCUMENT_ROOT: /var/www/html GATEWAY_INTERFACE: CGI/1.1 HTTPS: 1 HTTP_ACCEPT_ENCODING: identity HTTP_HOST: server.ip.was.here HTTP_USER_AGENT: rhn.rpclib.py/$Revision$ HTTP_X_CLIENT_VERSION: 1 HTTP_X_INFO: RPC Processor (C) Red Hat, Inc (version $Revision$) HTTP_X_RHN_CLIENT_CAPABILITY: kickstart_guest.initiate(1)=1,osad.ping(1)=1,scap.xccdf_eval(1)=1,packages.verify(1)=1,packages.extended_profile(2)=1,osad.rhn_check(1)=1,configfiles.base64_enc(1)=1,reboot.reboot(1)=1,configfiles.deploy(1)=1,caneatCheese(1)=1,packages.rollBack(1)=1,configfiles.mtime_upload(1)=1,configfiles.diff(1)=1,packages.update(2)=2,script.run(1)=1,kickstart.initiate(1)=1,configfiles.upload(1)=1,packages.runTransaction(1)=1 HTTP_X_RHN_TRANSPORT_CAPABILITY: follow-redirects=3 HTTP_X_TRANSPORT_INFO: Extended Capabilities Transport (C) Red Hat, Inc (version $Revision$) HTTP_X_UP2DATE_VERSION: 1.7.14-1.el6 Host: server.ip.was.here PATH_INFO: QUERY_STRING: REMOTE_ADDR: client.ip.was.here REMOTE_PORT: 35952 REQUEST_METHOD: POST REQUEST_URI: /XMLRPC SCRIPT_FILENAME: /usr/share/rhn/wsgi/xmlrpc.py SCRIPT_NAME: /XMLRPC SCRIPT_URI: https://server.ip.was.here/XMLRPC SCRIPT_URL: /XMLRPC SERVER_ADDR: server.ip.was.here SERVER_ADMIN: root@localhost SERVER_NAME: server.ip.was.here SERVER_PORT: 443 SERVER_PROTOCOL: HTTP/1.1 SERVER_SIGNATURE: <address>Apache Server at server.ip.was.here Port 443</address> SERVER_SOFTWARE: Apache User-Agent: rhn.rpclib.py/$Revision$ X-Client-Version: 1 X-Info: RPC Processor (C) Red Hat, Inc (version $Revision$) X-RHN-Client-Capability: kickstart_guest.initiate(1)=1,osad.ping(1)=1,scap.xccdf_eval(1)=1,packages.verify(1)=1,packages.extended_profile(2)=1,osad.rhn_check(1)=1,configfiles.base64_enc(1)=1,reboot.reboot(1)=1,configfiles.deploy(1)=1,caneatCheese(1)=1,packages.rollBack(1)=1,configfiles.mtime_upload(1)=1,configfiles.diff(1)=1,packages.update(2)=2,script.run(1)=1,kickstart.initiate(1)=1,configfiles.upload(1)=1,packages.runTransaction(1)=1 X-RHN-Transport-Capability: follow-redirects=3 X-Transport-Info: Extended Capabilities Transport (C) Red Hat, Inc (version $Revision$) X-Up2Date-Version: 1.7.14-1.el6 mod_wsgi.application_group: server.ip.was.here|/xmlrpc mod_wsgi.callable_object: application mod_wsgi.handler_script: mod_wsgi.input_chunked: 0 mod_wsgi.listener_host: mod_wsgi.listener_port: 443 mod_wsgi.process_group: mod_wsgi.request_handler: wsgi-script mod_wsgi.script_reloading: 1 mod_wsgi.version: (3, 2) wsgi.errors: <mod_wsgi.Log object at 0x7f5d784fa8f0> wsgi.file_wrapper: <built-in method file_wrapper of mod_wsgi.Adapter object at 0x7f5d77870828> wsgi.input: <mod_wsgi.Input object at 0x7f5d784fa8b0> wsgi.multiprocess: True wsgi.multithread: False wsgi.run_once: False wsgi.url_scheme: https wsgi.version: (1, 1) Exception Handler Information Traceback (most recent call last): File "/usr/lib/python2.6/site-packages/spacewalk/server/apacheRequest.py", line 122, in call_function response = apply(func, params) File "/usr/share/rhn/server/handlers/xmlrpc/registration.py", line 502, in new_system architecture, data) File "/usr/share/rhn/server/handlers/xmlrpc/registration.py", line 298, in create_system newserv.change_base_channel(release) File "/usr/lib/python2.6/site-packages/spacewalk/server/rhnServer/server_class.py", line 231, in change_base_channel self.save_history_byid(self.server["id"]) File "/usr/lib/python2.6/site-packages/spacewalk/server/rhnServer/server_history.py", line 54, in save_history_byid details = details) File "/usr/lib/python2.6/site-packages/spacewalk/server/rhnSQL/sql_base.py", line 172, in executemany return apply(self._execute_wrapper, (self._executemany, ) + p, kw) File "/usr/lib/python2.6/site-packages/spacewalk/server/rhnSQL/driver_postgresql.py", line 282, in _execute_wrapper retval = apply(function, p, kw) File "/usr/lib/python2.6/site-packages/spacewalk/server/rhnSQL/driver_postgresql.py", line 318, in _executemany self._real_cursor.executemany(self.sql, all_kwargs) IntegrityError: new row for relation "rhnserverhistory" violates check constraint "vn_rhnserverhistory_details" Local variables by frame Frame _executemany in /usr/lib/python2.6/site-packages/spacewalk/server/rhnSQL/driver_postgresql.py at line 318 val = <type 'str'> Updated system release from 6.2 to 6.2 all_kwargs = <type 'list'> [{'server_id': 1000010018, 'details': '', 'summary': 'Updated system release from 6.2 to 6.2'}] i = <type 'int'> 1 self = <type 'instance'> <spacewalk.server.rhnSQL.driver_postgresql.Cursor instance at 0x7f5d7868fe18> args = <type 'tuple'> () params = <type 'instance'> {'server_id': [1000010018], 'details': [''], 'summary': ['Updated system release from 6.2 to 6.2']} key = <type 'str'> summary kwargs = <type 'dict'> {'server_id': [1000010018], 'details': [''], 'summary': ['Updated system release from 6.2 to 6.2']} Frame _execute_wrapper in /usr/lib/python2.6/site-packages/spacewalk/server/rhnSQL/driver_postgresql.py at line 287 function = <type 'instancemethod'> <bound method Cursor._executemany of <spacewalk.server.rhnSQL.driver_postgresql.Cursor instance at 0x7f5d7868fe18>> self = <type 'instance'> <spacewalk.server.rhnSQL.driver_postgresql.Cursor instance at 0x7f5d7868fe18> value = <type 'list'> ['Updated system release from 6.2 to 6.2'] p = <type 'tuple'> () kw = <type 'dict'> {'server_id': [1000010018], 'details': [''], 'summary': ['Updated system release from 6.2 to 6.2']} key = <type 'str'> summary params = <type 'str'> server_id: [1000010018],details: [''],summary: ['Updated system release from 6.2 to 6.2'] Frame executemany in /usr/lib/python2.6/site-packages/spacewalk/server/rhnSQL/sql_base.py at line 172 p = <type 'tuple'> () self = <type 'instance'> <spacewalk.server.rhnSQL.driver_postgresql.Cursor instance at 0x7f5d7868fe18> kw = <type 'dict'> {'server_id': [1000010018], 'details': [''], 'summary': ['Updated system release from 6.2 to 6.2']} Frame save_history_byid in /usr/lib/python2.6/site-packages/spacewalk/server/rhnServer/server_history.py at line 54 server_id = <type 'int'> 1000010018 self = <class 'spacewalk.server.rhnServer.server_class.Server'> <Server Class at 140039427389584: {'self.cert': None, 'self.server': {'info': (None, 0), 'creator_id': (1, 0), 'provision_state_id': (None, 0), 'name': ('localhost.localdomain', 0), 'created': (datetime.datetime(2012, 3, 21, 11, 26, 14, 33908, tzinfo=<psycopg2.tz.FixedOffsetTimezone object at 0x7f5d7852fe50>), 0), 'auto_update': ('N', 0), 'running_kernel': ('2.6.32-220.el6.x86_64', 0), 'description': ('Initial Registration Parameters:\nOS: sl-release\nRelease: 6.2\nCPU Arch: x86_64', 0), 'org_id': (1, 0), 'modified': (datetime.datetime(2012, 3, 21, 11, 26, 16, 310096, tzinfo=<psycopg2.tz.FixedOffsetTimezone object at 0x7f5d7852fd50>), 0), 'server_arch_id': (1023, 0), 'secret': ('1495c0cc3ebe06a05b100c386c7491b5', 1), 'last_boot': (1332343247.327136, 0), 'digital_server_id': ('ID-1000010018', 0), 'release': ('6.2', 0), 'channels_changed': (datetime.datetime(2012, 3, 21, 11, 26, 14, 33908, tzinfo=< psycopg2.tz.FixedOffsetTimezone object at 0x7f5d7852fd90>), 0), 'auto_deliver': ('N', 0), 'os': ('sl-release', 0), 'id': (1000010018, 0), 'cobbler_id': (None, 0)}}> hist = <type 'instance'> <spacewalk.server.rhnSQL.driver_postgresql.Cursor instance at 0x7f5d7868fe18> details = <type 'list'> [''] server_ids = <type 'list'> [1000010018] summaries = <type 'list'> ['Updated system release from 6.2 to 6.2'] Frame change_base_channel in /usr/lib/python2.6/site-packages/spacewalk/server/rhnServer/server_class.py at line 231 c = <type 'dict'> {'available_subscriptions': '', 'name': 'Scientific Linux 6.2', 'org_id': '1', 'label': 'sci-linux-6_2', 'last_modified': '20120321111413', 'parent_channel': '', 'summary': 'Scientific Linux 6.2', 'arch': 'channel-x86_64', 'id': '109', 'description': ''} hash = <type 'dict'> {'115': {'gpg_key_url': '', 'description': '', 'org_id': '1', 'label': 'sci-confidential-firewall', 'last_modified': '20120314090851', 'local_channel': '1', 'parent_channel': '109', 'summary': 'Additional packages for a confidential MDC firewall', 'arch': 'channel-x86_64', 'id': '115', 'name': 'Sci linux confidential Firewall'}, '114': {'gpg_key_url': '', 'description': '', 'org_id': '1', 'label': 'sci-linux-6_2-bugs', 'last_modified': '20120321104946', 'local_channel': '1', 'parent_channel': '109', 'summary': 'Scientific Linux Bug Fixes', 'arch': 'channel-x86_64', 'id': '114', 'name': 'Scientific Linux Bug Fixes'}, '111': {'gpg_key_url': 'http://ftp.scientificlinux.org/linux/scientific/6.2/x86_64/os/RPM-GPG-KEY-sl6', 'description': '', 'org_id': '1', 'label': 'sci-linux-6_2-updates', 'last_modified': '20120321110825', 'local_channel': '1', 'parent_channel': '109', 'summary': 'Scientific Linux 6.2 security updates', 'arch': 'channel-x86_64', 'id': '111', 'name': 'S cientific Linux 6.2 security updates'}, '113': {'gpg_key_url': 'https://fedoraproject.org/static/0608B895.txt', 'description': '', 'org_id': '1', 'label': 'clone-epel-repo', 'last_modified': '20120313164346', 'local_channel': '1', 'parent_channel': '109', 'summary': 'EPEL', 'arch': 'channel-x86_64', 'id': '113', 'name': 'Extra Packages for Scientific Linux'}, '112': {'gpg_key_url': '', 'description': '', 'org_id': '1', 'label': 'clone-spacewalk-client-rhel6', 'last_modified': '20120313154139', 'local_channel': '1', 'parent_channel': '109', 'summary': 'Spacewalk client for Scientific Linux', 'arch': 'channel-x86_64', 'id': '112', 'name': 'Spacewalk client for Scientific Linux 6'}} channels_to_subscribe = <type 'list'> [] old_base = <type 'dict'> {'gpg_key_url': '', 'description': '', 'org_id': '1', 'label': 'sci-linux-6_2', 'last_modified': '20120321111413', 'local_channel': '1', 'parent_channel': '', 'summary': 'Scientific Linux 6.2', 'arch': 'channel-x86_64', 'id': '109', 'name': 'Scientific Linux 6.2'} self = <class 'spacewalk.server.rhnServer.server_class.Server'> <Server Class at 140039427389584: {'self.cert': None, 'self.server': {'info': (None, 0), 'creator_id': (1, 0), 'provision_state_id': (None, 0), 'name': ('localhost.localdomain', 0), 'created': (datetime.datetime(2012, 3, 21, 11, 26, 14, 33908, tzinfo=<psycopg2.tz.FixedOffsetTimezone object at 0x7f5d7852fe50>), 0), 'auto_update': ('N', 0), 'running_kernel': ('2.6.32-220.el6.x86_64', 0), 'description': ('Initial Registration Parameters:\nOS: sl-release\nRelease: 6.2\nCPU Arch: x86_64', 0), 'org_id': (1, 0), 'modified': (datetime.datetime(2012, 3, 21, 11, 26, 16, 310096, tzinfo=<psycopg2.tz.FixedOffsetTimezone object at 0x7f5d7852fd50>), 0), 'server_arch_id': (1023, 0), 'secret': ('1495c0cc3ebe06a05b100c386c7491b5', 1), 'last_boot': (1332343247.327136, 0), 'digital_server_id': ('ID-1000010018', 0), 'release': ('6.2', 0), 'channels_changed': (datetime.datetime(2012, 3, 21, 11, 26, 14, 33908, tzinfo=< psycopg2.tz.FixedOffsetTimezone object at 0x7f5d7852fd90>), 0), 'auto_deliver': ('N', 0), 'os': ('sl-release', 0), 'id': (1000010018, 0), 'cobbler_id': (None, 0)}}> old_rel = <type 'str'> 6.2 channel_id = <type 'str'> 109 s = <type 'instance'> <LiteServer instance at 140039427392360: attributes={'release': '6.2', 'arch': 'x86_64', 'org_id': 1, 'id': 1000010018}> new_rel = <type 'str'> 6.2 base_channels_count = <type 'int'> 1 target_channels = <type 'list'> [{'available_subscriptions': '', 'name': 'Scientific Linux 6.2', 'org_id': '1', 'label': 'sci-linux-6_2', 'last_modified': '20120321111413', 'parent_channel': '', 'summary': 'Scientific Linux 6.2', 'arch': 'channel-x86_64', 'id': '109', 'description': ''}] channels_to_unsubscribe = <type 'list'> [] current_channels = <type 'list'> [{'gpg_key_url': '', 'description': '', 'org_id': '1', 'label': 'sci-linux-6_2', 'last_modified': '20120321111413', 'local_channel': '1', 'parent_channel': '', 'summary': 'Scientific Linux 6.2', 'arch': 'channel-x86_64', 'id': '109', 'name': 'Scientific Linux 6.2'}, {'gpg_key_url': 'http://ftp.scientificlinux.org/linux/scientific/6.2/x86_64/os/RPM-GPG-KEY-sl6', 'description': '', 'org_id': '1', 'label': 'sci-linux-6_2-updates', 'last_modified': '20120321110825', 'local_channel': '1', 'parent_channel': '109', 'summary': 'Scientific Linux 6.2 security updates', 'arch': 'channel-x86_64', 'id': '111', 'name': 'Scientific Linux 6.2 security updates'}, {'gpg_key_url': '', 'description': '', 'org_id': '1', 'label': 'clone-spacewalk-client-rhel6', 'last_modified': '20120313154139', 'local_channel': '1', 'parent_channel': '109', 'summary': 'Spacewalk client for Scientific Linux', 'arch': 'channel-x86_64', 'id': '112', 'name': 'Spacewalk client for Scientific Linux 6'}, {'gpg_key_url': 'https://fedoraproject.org/static/0608B895.txt', 'description': '', 'org_id': '1', 'label': 'clone-epel-repo', 'last_modified': '20120313164346', 'local_channel': '1', 'parent_channel': '109', 'summary': 'EPEL', 'arch': 'channel-x86_64', 'id': '113', 'name': 'Extra Packages for Scientific Linux'}, {'gpg_key_url': '', 'description': '', 'org_id': '1', 'label': 'sci-linux-6_2-bugs', 'last_modified': '20120321104946', 'local_channel': '1', 'parent_channel': '109', 'summary': 'Scientific Linux Bug Fixes', 'arch': 'channel-x86_64', 'id': '114', 'name': 'Scientific Linux Bug Fixes'}, {'gpg_key_url': '', 'description': '', 'org_id': '1', 'label': 'sci-confidential-firewall', 'last_modified': '20120314090851', 'local_channel': '1', 'parent_channel': '109', 'summary': 'Additional packages for a confidential MDC firewall', 'arch': 'channel-x86_64', 'id': '115', 'name': 'Sci linux confidential Firewall'}] target_base = <type 'dict'> {'available_subscriptions': '', 'name': 'Scientific Linux 6.2', 'org_id': '1', 'label': 'sci-linux-6_2', 'last_modified': '20120321111413', 'parent_channel': '', 'summary': 'Scientific Linux 6.2', 'arch': 'channel-x86_64', 'id': '109', 'description': ''} Frame create_system in /usr/share/rhn/server/handlers/xmlrpc/registration.py at line 298 release_version = <type 'str'> 6.2 user = <type 'NoneType'> None log_item = <type 'str'> token = 're-1-8f1eff725a1b82e2a41915b068619c23,1-60d32f2598a59e002e0d2ebc4c7b35d9,1-ae09964bee160367ae8c774cadae64bf' self = <type 'instance'> <server.handlers.xmlrpc.registration.Registration instance at 0x7f5d7852cfc8> applet_uuid = <type 'NoneType'> None profile_name = <type 'str'> localhost.localdomain channel = <type 'NoneType'> None release = <type 'str'> 6.2 token_string = <type 'str'> re-1-8f1eff725a1b82e2a41915b068619c23,1-60d32f2598a59e002e0d2ebc4c7b35d9,1-ae09964bee160367ae8c774cadae64bf up2date_uuid = <type 'NoneType'> None data = <type 'dict'> {'token': 're-1-8f1eff725a1b82e2a41915b068619c23,1-60d32f2598a59e002e0d2ebc4c7b35d9,1-ae09964bee160367ae8c774cadae64bf', 'profile_name': 'localhost.localdomain', 'architecture': 'x86_64', 'os_release': '6.2', 'smbios': {'smbios.system.serial': 'USE802N1F4', 'smbios.system.product': 'ProLiant DL380 G5', 'smbios.system.family': 'ProLiant', 'smbios.bios.vendor': 'HP', 'smbios.system.manufacturer': 'HP', 'smbios.system.skunumber': '470064-511', 'smbios.system.version': 'Not Specified', 'smbios.system.uuid': '34373030-3634-5553-4538-30324e314634'}, 'release_name': 'sl-release'} newserv = <class 'spacewalk.server.rhnServer.server_class.Server'> <Server Class at 140039427389584: {'self.cert': None, 'self.server': {'info': (None, 0), 'creator_id': (1, 0), 'provision_state_id': (None, 0), 'name': ('localhost.localdomain', 0), 'created': (datetime.datetime(2012, 3, 21, 11, 26, 14, 33908, tzinfo=<psycopg2.tz.FixedOffsetTimezone object at 0x7f5d7852fe50>), 0), 'auto_update': ('N', 0), 'running_kernel': ('2.6.32-220.el6.x86_64', 0), 'description': ('Initial Registration Parameters:\nOS: sl-release\nRelease: 6.2\nCPU Arch: x86_64', 0), 'org_id': (1, 0), 'modified': (datetime.datetime(2012, 3, 21, 11, 26, 16, 310096, tzinfo=<psycopg2.tz.FixedOffsetTimezone object at 0x7f5d7852fd50>), 0), 'server_arch_id': (1023, 0), 'secret': ('1495c0cc3ebe06a05b100c386c7491b5', 1), 'last_boot': (1332343247.327136, 0), 'digital_server_id': ('ID-1000010018', 0), 'release': ('6.2', 0), 'channels_changed': (datetime.datetime(2012, 3, 21, 11, 26, 14, 33908, tzinfo=< psycopg2.tz.FixedOffsetTimezone object at 0x7f5d7852fd90>), 0), 'auto_deliver': ('N', 0), 'os': ('sl-release', 0), 'id': (1000010018, 0), 'cobbler_id': (None, 0)}}> tokens_obj = <type 'instance'> <spacewalk.server.rhnServer.server_token.ReRegistrationActivationToken instance at 0x7f5d785301b8> architecture = <type 'str'> x86_64 Frame new_system in /usr/share/rhn/server/handlers/xmlrpc/registration.py at line 502 self = <type 'instance'> <server.handlers.xmlrpc.registration.Registration instance at 0x7f5d7852cfc8> release_version = <type 'str'> 6.2 profile_name = <type 'str'> localhost.localdomain architecture = <type 'str'> x86_64 data = <type 'dict'> {'token': 're-1-8f1eff725a1b82e2a41915b068619c23,1-60d32f2598a59e002e0d2ebc4c7b35d9,1-ae09964bee160367ae8c774cadae64bf', 'profile_name': 'localhost.localdomain', 'architecture': 'x86_64', 'os_release': '6.2', 'smbios': {'smbios.system.serial': 'USE802N1F4', 'smbios.system.product': 'ProLiant DL380 G5', 'smbios.system.family': 'ProLiant', 'smbios.bios.vendor': 'HP', 'smbios.system.manufacturer': 'HP', 'smbios.system.skunumber': '470064-511', 'smbios.system.version': 'Not Specified', 'smbios.system.uuid': '34373030-3634-5553-4538-30324e314634'}, 'release_name': 'sl-release'} user = <type 'NoneType'> None Frame call_function in /usr/lib/python2.6/site-packages/spacewalk/server/apacheRequest.py at line 174 self = <type 'instance'> <spacewalk.server.apacheRequest.apachePOST instance at 0x7f5d7852cd88> params = <type 'tuple'> ({'token': 're-1-8f1eff725a1b82e2a41915b068619c23,1-60d32f2598a59e002e0d2ebc4c7b35d9,1-ae09964bee160367ae8c774cadae64bf', 'profile_name': 'localhost.localdomain', 'architecture': 'x86_64', 'os_release': '6.2', 'smbios': {'smbios.system.serial': 'USE802N1F4', 'smbios.system.product': 'ProLiant DL380 G5', 'smbios.system.family': 'ProLiant', 'smbios.bios.vendor': 'HP', 'smbios.system.manufacturer': 'HP', 'smbios.system.skunumber': '470064-511', 'smbios.system.version': 'Not Specified', 'smbios.system.uuid': '34373030-3634-5553-4538-30324e314634'}, 'release_name': 'sl-release'},) force_rollback = <type 'int'> 1 func = <type 'instancemethod'> <bound method Registration.new_system of <server.handlers.xmlrpc.registration.Registration instance at 0x7f5d7852cfc8>> method = <type 'unicode'> registration.new_system Frame process in /usr/lib/python2.6/site-packages/spacewalk/server/apacheRequest.py at line 476 fd = <type 'instance'> <cStringIO.StringO object at 0x7f5d78524d50> _body = <type 'str'> <?xml version='1.0'?> <methodCall> <methodName>registration.new_system</methodName> <params> <param> <value><struct> <member> <name>token</name> <value><string>re-1-8f1eff725a1b82e2a41915b068619c23,1-60d32f2598a59e002e0d2ebc4c7b35d9,1-ae09964bee160367ae8c774cadae64bf</string></value> </member> <member> <name>profile_name</name> <value><string>localhost.localdomain</string></value> </member> <member> <name>architecture</name> <value><string>x86_64</string></value> </member> <member> <name>os_release</name> <value><string>6.2</string></value> </member> <member> <name>smbios</name> <value><struct> <member> <name>smbios.system.serial</name> <value><string>USE802N1F4</string></value> </member> <member> <name>smbios.system.product</name> <value><string>ProLiant DL380 G5</string></value> </member> <member> <name>smbios.system.family</name> <value><string>ProLiant</string></value> </member> <member> <name>smbios.bios.vendor</name> <value><string>HP</string></value> </member> <member> <name>smbios.system.manufacturer</name> <value><string>HP</string></value> </member> <member> <name>smbios.system.skunumber</name> <value><string>470064-511</string></value> </member> <member> <name>smbios.system.version</name> <value><string>Not Specified</string></value> </member> <member> <name>smbios.system.uuid</name> <value><string>34373030-3634-5553-4538-30324e314634</string></value> </member> </struct></value> </member> <member> <name>release_name</name> <value><string>sl-release</string></value> </member> </struct></value> </param> </params> </methodCall> params = <type 'tuple'> ({'token': 're-1-8f1eff725a1b82e2a41915b068619c23,1-60d32f2598a59e002e0d2ebc4c7b35d9,1-ae09964bee160367ae8c774cadae64bf', 'profile_name': 'localhost.localdomain', 'architecture': 'x86_64', 'os_release': '6.2', 'smbios': {'smbios.system.serial': 'USE802N1F4', 'smbios.system.product': 'ProLiant DL380 G5', 'smbios.system.family': 'ProLiant', 'smbios.bios.vendor': 'HP', 'smbios.system.manufacturer': 'HP', 'smbios.system.skunumber': '470064-511', 'smbios.system.version': 'Not Specified', 'smbios.system.uuid': '34373030-3634-5553-4538-30324e314634'}, 'release_name': 'sl-release'},) method = <type 'unicode'> registration.new_system self = <type 'instance'> <spacewalk.server.apacheRequest.apachePOST instance at 0x7f5d7852cd88> Frame handler in /usr/lib/python2.6/site-packages/spacewalk/server/apacheHandler.py at line 196 h = <type 'instance'> <spacewalk.server.rhnSQL.driver_postgresql.Cursor instance at 0x7f5d7852cc68> self = <type 'instance'> <spacewalk.server.apacheHandler.apacheHandler instance at 0x7f5d77328bd8> req = <type 'instance'> <wsgi.wsgiRequest.WsgiRequest instance at 0x7f5d784f49e0> ret = <type 'int'> 0 templateStrings = <type 'dict'> {'email_account_info': '\nAccount Information:\n Your Spacewalk login: <login />\n Your Spacewalk email address: <email-address />', 'email_footer': '--the Spacewalk Team', 'hostname': 'server.ip.was.here'} row = <type 'NoneType'> None Frame handle in /usr/share/rhn/wsgi/wsgiHandler.py at line 45 replacements = <type 'dict'> {'Xml': 'XML', 'Actualuri': 'ActualURI', 'Md5Sum': 'MD5sum', '_': '-', 'Rhn': 'RHN'} component_type = <type 'str'> server.xmlrpc start_response = <type 'builtin_function_or_method'> <built-in method start_response of mod_wsgi.Adapter object at 0x7f5d77870828> k = <type 'str'> Rhn req = <type 'instance'> <wsgi.wsgiRequest.WsgiRequest instance at 0x7f5d784f49e0> parseServ = <type 'instancemethod'> <bound method apacheHandler.headerParserHandler of <spacewalk.server.apacheHandler.apacheHandler instance at 0x7f5d77328bd8>> ret = <type 'int'> 0 server = <type 'str'> xmlrpc environ = <type 'dict'> {'mod_wsgi.listener_port': '443', 'X-RHN-Client-Capability': 'kickstart_guest.initiate(1)=1,osad.ping(1)=1,scap.xccdf_eval(1)=1,packages.verify(1)=1,packages.extended_profile(2)=1,osad.rhn_check(1)=1,configfiles.base64_enc(1)=1,reboot.reboot(1)=1,configfiles.deploy(1)=1,caneatCheese(1)=1,packages.rollBack(1)=1,configfiles.mtime_upload(1)=1,configfiles.diff(1)=1,packages.update(2)=2,script.run(1)=1,kickstart.initiate(1)=1,configfiles.upload(1)=1,packages.runTransaction(1)=1', 'SERVER_SOFTWARE': 'Apache', 'SCRIPT_NAME': '/XMLRPC', 'HTTP_X_TRANSPORT_INFO': 'Extended Capabilities Transport (C) Red Hat, Inc (version $Revision$)', 'mod_wsgi.handler_script': '', 'SERVER_SIGNATURE': '<address>Apache Server at server.ip.was.here Port 443</address>\n', 'REQUEST_METHOD': 'POST', 'PATH_INFO': '', 'SERVER_PROTOCOL': 'HTTP/1.1', 'QUERY_STRING': '', 'X-Info': 'RPC Processor (C) Red Hat, Inc (version $Revision$)', 'CONTENT_LENGTH': '1562', 'HTTP_USER_AGENT': 'rhn.rpclib.py/$Revision$', 'HTTP_X_UP2DATE_VERSION': '1.7.14-1.el6', 'SERVER_NAME': 'server.ip.was.here', 'REMOTE_ADDR': 'client.ip.was.here', 'mod_wsgi.request_handler': 'wsgi-script', 'User-Agent': 'rhn.rpclib.py/$Revision$', 'wsgi.url_scheme': 'https', 'Host': 'server.ip.was.here', 'X-RHN-Transport-Capability': 'follow-redirects=3', 'mod_wsgi.callable_object': 'application', 'SERVER_PORT': '443', 'wsgi.multiprocess': True, 'mod_wsgi.input_chunked': '0', 'SERVER_ADDR': 'server.ip.was.here', 'DOCUMENT_ROOT': '/var/www/html', 'mod_wsgi.process_group': '', 'Accept-Encoding': 'identity', 'HTTP_X_RHN_CLIENT_CAPABILITY': 'kickstart_guest.initiate(1)=1,osad.ping(1)=1,scap.xccdf_eval(1)=1,packages.verify(1)=1,packages.extended_profile(2)=1,osad.rhn_check(1)=1,configfiles.base64_enc(1)=1,reboot.reboot(1)=1,configfiles.deploy(1)=1,caneatCheese(1)=1,packages.rollBack(1)=1,configfiles.mtime_upload(1)=1,configfiles.diff(1)=1,packages.update(2)=2,script.run(1)=1,kickstart.initiate(1)=1,configfiles.upload( 1)=1,packages.runTransaction(1)=1', 'SCRIPT_FILENAME': '/usr/share/rhn/wsgi/xmlrpc.py', 'SERVER_ADMIN': 'root@localhost', 'X-Up2Date-Version': '1.7.14-1.el6', 'X-Transport-Info': 'Extended Capabilities Transport (C) Red Hat, Inc (version $Revision$)', 'SCRIPT_URI': 'https://server.ip.was.here/XMLRPC', 'HTTP_X_CLIENT_VERSION': '1', 'wsgi.input': <mod_wsgi.Input object at 0x7f5d784fa8b0>, 'HTTP_HOST': 'server.ip.was.here', 'SCRIPT_URL': '/XMLRPC', 'HTTPS': '1', 'wsgi.multithread': False, 'REQUEST_URI': '/XMLRPC', 'X-Client-Version': '1', 'wsgi.version': (1, 1), 'GATEWAY_INTERFACE': 'CGI/1.1', 'wsgi.run_once': False, 'wsgi.errors': <mod_wsgi.Log object at 0x7f5d784fa8f0>, 'REMOTE_PORT': '35952', 'mod_wsgi.listener_host': '', 'mod_wsgi.version': (3, 2), 'HTTP_X_RHN_TRANSPORT_CAPABILITY': 'follow-redirects=3', 'CONTENT_TYPE': 'text/xml', 'mod_wsgi.application_group': 'server.ip.was.here|/xmlrpc', 'mod_wsgi.script_reloading': '1', 'wsgi.file_wrapper': <built-in method file_wrapper of mod_wsgi.Ad apter object at 0x7f5d77870828>, 'HTTP_ACCEPT_ENCODING': 'identity', 'HTTP_X_INFO': 'RPC Processor (C) Red Hat, Inc (version $Revision$)'} key = <type 'str'> HTTP_X_INFO v = <type 'str'> RHN servertype = <type 'str'> spacewalk.server.apacheServer new_key = <type 'str'> X-Info appServ = <type 'instancemethod'> <bound method apacheHandler.handler of <spacewalk.server.apacheHandler.apacheHandler instance at 0x7f5d77328bd8>> Frame application in /usr/share/rhn/wsgi/xmlrpc.py at line 22 start_response = <type 'builtin_function_or_method'> <built-in method start_response of mod_wsgi.Adapter object at 0x7f5d77870828> environ = <type 'dict'> {'mod_wsgi.listener_port': '443', 'X-RHN-Client-Capability': 'kickstart_guest.initiate(1)=1,osad.ping(1)=1,scap.xccdf_eval(1)=1,packages.verify(1)=1,packages.extended_profile(2)=1,osad.rhn_check(1)=1,configfiles.base64_enc(1)=1,reboot.reboot(1)=1,configfiles.deploy(1)=1,caneatCheese(1)=1,packages.rollBack(1)=1,configfiles.mtime_upload(1)=1,configfiles.diff(1)=1,packages.update(2)=2,script.run(1)=1,kickstart.initiate(1)=1,configfiles.upload(1)=1,packages.runTransaction(1)=1', 'SERVER_SOFTWARE': 'Apache', 'SCRIPT_NAME': '/XMLRPC', 'HTTP_X_TRANSPORT_INFO': 'Extended Capabilities Transport (C) Red Hat, Inc (version $Revision$)', 'mod_wsgi.handler_script': '', 'SERVER_SIGNATURE': '<address>Apache Server at server.ip.was.here Port 443</address>\n', 'REQUEST_METHOD': 'POST', 'PATH_INFO': '', 'SERVER_PROTOCOL': 'HTTP/1.1', 'QUERY_STRING': '', 'X-Info': 'RPC Processor (C) Red Hat, Inc (version $Revision$)', 'CONTENT_LENGTH': '1562', 'HTTP_USER_AGENT': 'rhn.rpclib.py/$Revision$', 'HTTP_X_UP2DATE_VERSION': '1.7.14-1.el6', 'SERVER_NAME': 'server.ip.was.here', 'REMOTE_ADDR': 'client.ip.was.here', 'mod_wsgi.request_handler': 'wsgi-script', 'User-Agent': 'rhn.rpclib.py/$Revision$', 'wsgi.url_scheme': 'https', 'Host': 'server.ip.was.here', 'X-RHN-Transport-Capability': 'follow-redirects=3', 'mod_wsgi.callable_object': 'application', 'SERVER_PORT': '443', 'wsgi.multiprocess': True, 'mod_wsgi.input_chunked': '0', 'SERVER_ADDR': 'server.ip.was.here', 'DOCUMENT_ROOT': '/var/www/html', 'mod_wsgi.process_group': '', 'Accept-Encoding': 'identity', 'HTTP_X_RHN_CLIENT_CAPABILITY': 'kickstart_guest.initiate(1)=1,osad.ping(1)=1,scap.xccdf_eval(1)=1,packages.verify(1)=1,packages.extended_profile(2)=1,osad.rhn_check(1)=1,configfiles.base64_enc(1)=1,reboot.reboot(1)=1,configfiles.deploy(1)=1,caneatCheese(1)=1,packages.rollBack(1)=1,configfiles.mtime_upload(1)=1,configfiles.diff(1)=1,packages.update(2)=2,script.run(1)=1,kickstart.initiate(1)=1,configfiles.upload( 1)=1,packages.runTransaction(1)=1', 'SCRIPT_FILENAME': '/usr/share/rhn/wsgi/xmlrpc.py', 'SERVER_ADMIN': 'root@localhost', 'X-Up2Date-Version': '1.7.14-1.el6', 'X-Transport-Info': 'Extended Capabilities Transport (C) Red Hat, Inc (version $Revision$)', 'SCRIPT_URI': 'https://server.ip.was.here/XMLRPC', 'HTTP_X_CLIENT_VERSION': '1', 'wsgi.input': <mod_wsgi.Input object at 0x7f5d784fa8b0>, 'HTTP_HOST': 'server.ip.was.here', 'SCRIPT_URL': '/XMLRPC', 'HTTPS': '1', 'wsgi.multithread': False, 'REQUEST_URI': '/XMLRPC', 'X-Client-Version': '1', 'wsgi.version': (1, 1), 'GATEWAY_INTERFACE': 'CGI/1.1', 'wsgi.run_once': False, 'wsgi.errors': <mod_wsgi.Log object at 0x7f5d784fa8f0>, 'REMOTE_PORT': '35952', 'mod_wsgi.listener_host': '', 'mod_wsgi.version': (3, 2), 'HTTP_X_RHN_TRANSPORT_CAPABILITY': 'follow-redirects=3', 'CONTENT_TYPE': 'text/xml', 'mod_wsgi.application_group': 'server.ip.was.here|/xmlrpc', 'mod_wsgi.script_reloading': '1', 'wsgi.file_wrapper': <built-in method file_wrapper of mod_wsgi.Ad apter object at 0x7f5d77870828>, 'HTTP_ACCEPT_ENCODING': 'identity', 'HTTP_X_INFO': 'RPC Processor (C) Red Hat, Inc (version $Revision$)'} Environment for PID=31782 on exception: LANG = C PATH = /sbin:/usr/sbin:/bin:/usr/bin PWD = / SHLVL = 2 TERM = xterm _ = /usr/sbin/httpd "
doing a the following query works around the new bug but again its just a workaround it doesn't fix the underlying problem spaceschema=# alter table rhnserverhistory drop constraint "vn_rhnserverhistory_details";
(In reply to comment #11) > doing a the following query works around the new bug but again its just a > workaround it doesn't fix the underlying problem > > spaceschema=# alter table rhnserverhistory drop constraint > "vn_rhnserverhistory_details"; Dropping constraint is rarely a good idea. Be prepared to random unexpected errors in future. Moreover you might not be able to upgrade schema in the future. I strongly discourage anyone from doing such modifications.
well at the very least any one who does implement this work around should re-implement the constraint after the underlying bug has been fixed or before schema updates with the following query ' ALTER TABLE ADD CONSTRAINT vn_rhnserverhistory_details CHECK(((details)::text <> ''::text)); ' however this particular constraint is in a text description field in the server profile history log and shouldn't cause any sever issues.
I posted a script to the development mailing list that updates and lists the default distribution map via the XMLRPC API https://www.redhat.com/archives/spacewalk-devel/2012-March/msg00085.html Note: This script does NOT do the more controversial part of my workaround namely dropping the constraint on the description field in the rhnserverhistory table which may or may not be a PostgreSQL specific bug. If some one could try this script with Oracle please let me know if it resolves the issue completely or not so I can include the relevant information in a new ticket for description update bug. Thank You
In bug 809936, we've fixed the insert issue. This bug remain to track the Architecture and OS version combination is not supported. problem.
I believe this is merely a configuration issue. We have a configuration option: reset_base_channel = [0,1] that is available in rhn_server.conf (in /etc/rhn/ on the server running spacewalk). If you want it to reset your base channel to the default for your OS then set it to 1. If you want it to preserve the custom channel associated with the activation key then set it to 0. I believe the error you reported is due to the fact that your organization does not have any Red Hat provided base channels for your release / architecture combination. If you set the reset_base_channel option properly it should not happen. As far as I can see the only bug here is that (for spacewalk at least) the default for this option should be to preserve base channel, not to reset it. I will change the default.
Committed config default change to Spacewalk master: af0c6d7a1697c6d21cff41d64c5b6f2bd73aceb0
I have checked on yesterdays SWnightly and I can nicely use reactivation key for re-registration of system with custom channel. I have not found that option: # grep -r reset_base_channel /etc/rhn/ <no_output> Also will this affect reactivations of system in kickstarts? I mean, when I have RHEL5-i386 (on x86_64 capable machine) and I re-install it to RHEL5-x86_64, there might be problem. I'll test this.
Moving ON_QA. Packages that address this bugzilla should now be available in yum repos at http://yum.spacewalkproject.org/nightly/
Spacewalk 1.8 has been released: https://fedorahosted.org/spacewalk/wiki/ReleaseNotes18