Hello,

I found an error navigating to:

https://<hostname>/rhn/systems/VirtualSystemsList.do

In my setup there is only one registered system that does not have a UUID and 
also
the virtual host system is unknown to the Spacewalk server in this case:

- current.getUuid() == null
- current.getHostSystemId() == null

So I think we should not actually do 
"current.setSystemId(current.getHostSystemId());"
here. The attached patch fixes the problem for me (in [1]) and also makes sense 
IMO.

Thank you and regards,
Johannes

[1] VirtualSystemsListSetupAction.java

-- 
SUSE LINUX Products GmbH, HRB 16746 (AG Nürnberg)
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer
>From 1e0f80e4b6f43ade890dd3dae2a71bb4544dff01 Mon Sep 17 00:00:00 2001
From: Johannes Renner <jren...@suse.de>
Date: Fri, 19 Jul 2013 13:39:51 +0200
Subject: [PATCH] Fix ISE when UUID and host ID is null

---
 .../rhn/frontend/action/systems/VirtualSystemsListSetupAction.java      | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/java/code/src/com/redhat/rhn/frontend/action/systems/VirtualSystemsListSetupAction.java b/java/code/src/com/redhat/rhn/frontend/action/systems/VirtualSystemsListSetupAction.java
index b6252ad..5e8a0fe 100644
--- a/java/code/src/com/redhat/rhn/frontend/action/systems/VirtualSystemsListSetupAction.java
+++ b/java/code/src/com/redhat/rhn/frontend/action/systems/VirtualSystemsListSetupAction.java
@@ -63,7 +63,7 @@ public class VirtualSystemsListSetupAction extends BaseSystemListSetupAction {
             if (current.isFakeNode()) {
                 continue;
             }
-            else if (current.getUuid() == null) {
+            else if (current.getUuid() == null && current.getHostSystemId() != null) {
                 current.setSystemId(current.getHostSystemId());
             }
             else {
-- 
1.8.1.4

_______________________________________________
Spacewalk-devel mailing list
Spacewalk-devel@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-devel

Reply via email to