PowerVM

Power Virtualization

Connect, learn, share, and engage with IBM Power.


#Power
#TechXchangeConferenceLab
 View Only
  • 1.  /rest/api/uom/VirtualIOServer return null

    Posted Tue March 28, 2017 04:22 AM

    Originally posted by: 87F8_sadf_sdf


    This is my test code.

     

    public <T> ResponseEntity<T> getByContetType(String url, Class<T> clazz,String contentType,
                Object... args) {
            HttpHeaders head = new HttpHeaders();
            head.add("Content-Type", contentType);
            head.add("X-API-Session", this.getSession());
            head.add("Accept", "*/*");
            HttpEntity<String> requestEntity = new HttpEntity<>(head);
            return this.getRest().exchange(url, HttpMethod.GET, requestEntity, clazz);
        }

     

            String xml = getByContetType(url, String.class, "application/vnd.ibm.powervm.uom+xml;type=VirtualIOServer",args).getBody();

     

    JSONObject r=session.getFullPathxml("https://10.20.32.90:12443/rest/api/uom/ManagedSystem/e41dbc2b-2389-3c45-9fea-4c8e109b06b2/LogicalPartition");
            AP.testPrintLpar(r);
            String link="https://10.20.32.90:12443/rest/api/uom/VirtualIOServer";
            JSONObject j=session.viosServer(link);
    //        
            System.err.println(j);

    result:

    2017-03-28 16:16:32 INFO [com.cyancloud.manager.powervm.session.SessionFactory] - create session to host:10.20.32.90
    id:47E66CBA-8ED7-4611-94B7-000C39DB0259;name:TestAlex{application/vnd.ibm.powervm.uom+xml; type=LogicalPartition}
    id:55E9ECF3-5469-4935-9FD3-D10F85386FF0;name:AIX6100-01{application/vnd.ibm.powervm.uom+xml; type=LogicalPartition}
    id:5BEADFE4-4F1D-4AED-86AE-8FD717DD6B3E;name:TESt_lpar{application/vnd.ibm.powervm.uom+xml; type=LogicalPartition}
    id:3356B447-6145-4CCF-88F5-E9764FF6EA8F;name:Demo_sunyy{application/vnd.ibm.powervm.uom+xml; type=LogicalPartition}
    id:456AF685-BA4C-42E6-A530-2EA310BB1CBE;name:DemoSunyy{application/vnd.ibm.powervm.uom+xml; type=LogicalPartition}
    id:71CBEE0E-4E1B-4FFF-AA1C-BD48DBAD322D;name:VIOS{application/vnd.ibm.powervm.uom+xml; type=LogicalPartition}
    null

     

    why  /rest/api/uom/VirtualIOServer return null?


    #Power-Hardware-Management-Console-Programmers
    #HMCandCMC


  • 2.  Re: /rest/api/uom/VirtualIOServer return null

    Posted Tue March 28, 2017 04:25 AM

    Originally posted by: 87F8_sadf_sdf


    my hmc version is V8R8.2.0.0


    #HMCandCMC
    #Power-Hardware-Management-Console-Programmers


  • 3.  Re: /rest/api/uom/VirtualIOServer return null

    Posted Tue March 28, 2017 09:59 PM

    Originally posted by: 87F8_sadf_sdf


    i found a problem。/opt/pmc/log/wlp/FFDC.log  always output:

    <1024>1 2017-03-29T09:54:18.972+08:00 localhost REST - ERROR [pmc.viosapi@2 C="com.ibm.pmc.rest.viosapi.PostProcessor$12" F="PostProcessor.java" L="3026" M="sparseFetchFromRemoteSystem" P="ERROR" T="Liberty PMC-thread-27"] Number of network bridges: 0
    <1024>1 2017-03-29T09:54:18.973+08:00 localhost REST - ERROR [pmc.viosapi@2 C="com.ibm.pmc.rest.viosapi.PostProcessor$12" F="PostProcessor.java" L="3026" M="sparseFetchFromRemoteSystem" P="ERROR" T="Liberty PMC-thread-27"] Bridges are: []
    <1024>1 2017-03-29T09:55:19.106+08:00 localhost REST - ERROR [pmc.viosapi@2 C="com.ibm.pmc.rest.viosapi.PostProcessor$12" F="PostProcessor.java" L="3026" M="sparseFetchFromRemoteSystem" P="ERROR" T="Liberty PMC-thread-27"] Number of network bridges: 0
    <1024>1 2017-03-29T09:55:19.106+08:00 localhost REST - ERROR [pmc.viosapi@2 C="com.ibm.pmc.rest.viosapi.PostProcessor$12" F="PostProcessor.java" L="3026" M="sparseFetchFromRemoteSystem" P="ERROR" T="Liberty PMC-thread-27"] Bridges are: []
    <1024>1 2017-03-29T09:55:19.121+08:00 localhost REST - ERROR [pmc.viosapi@2 C="com.ibm.pmc.rest.viosapi.PostProcessor$12" F="PostProcessor.java" L="3026" M="sparseFetchFromRemoteSystem" P="ERROR" T="Liberty PMC-thread-27"] Number of network bridges: 0
    <1024>1 2017-03-29T09:55:19.121+08:00 localhost REST - ERROR [pmc.viosapi@2 C="com.ibm.pmc.rest.viosapi.PostProcessor$12" F="PostProcessor.java" L="3026" M="sparseFetchFromRemoteSystem" P="ERROR" T="Liberty PMC-thread-27"] Bridges are: []

     

    why this?

    how to slove?


    #HMCandCMC
    #Power-Hardware-Management-Console-Programmers


  • 4.  Re: /rest/api/uom/VirtualIOServer return null

    Posted Thu March 30, 2017 06:00 AM

    Originally posted by: manjunathns


    Hi, 

    The message you are seeing in the FFDC can be ignored. Though it is marked Error, it is just some debug statements. Thanks!

    -Manju


    #HMCandCMC
    #Power-Hardware-Management-Console-Programmers


  • 5.  Re: /rest/api/uom/VirtualIOServer return null

    Posted Thu March 30, 2017 07:00 AM

    Originally posted by: manjunathns


    Hi,

    It is not clear to me on the operation you are trying to perform using the test program. Is that to get the VirtualIOServer under specific System?

    The URI /rest/api/uom/VirtualIOServer will return all the VIOSs across systems managed by the HMC.

    The URI /rest/api/uom/ManagedSystem/{UUID}/VirtualIOServer will return VIOSs info from the specific system.

     

    Since you mentioned that the URI did not return VIOS info, it could be possible that the URI would have resulted in error. Could you please run the URI in browser and ensure that it returned the response? Please ensure that the http code is 200 for the successful URI execution.

    You could also use /rest/api/uom/VirtualIOServer/quick/All to list the quick response of the VIOSs. This will have minimal information in Json format. Thanks!

    -Manju


    #HMCandCMC
    #Power-Hardware-Management-Console-Programmers


  • 6.  Re: /rest/api/uom/VirtualIOServer return null

    Posted Thu March 30, 2017 09:56 PM

    Originally posted by: 87F8_sadf_sdf


    thanks for your reply.

    i run the url in browser.the result is :

     


    #Power-Hardware-Management-Console-Programmers
    #HMCandCMC


  • 7.  Re: /rest/api/uom/VirtualIOServer return null

    Posted Fri March 31, 2017 09:09 AM

    Originally posted by: manjunathns


    Hi,

    I am surprised to see that you are getting 404 error for the quick call. But from the response looks like you are having HMC 820 or 830 level.

    And from the second REST response, the call is returned with http-204. Which means there is no VIOS in the HMC. Just wanted to check with you if the HMC in question is managing any VIOSs? Could you please validate that with the HMC command line. You will have to use "lssyscfg -r lpar -m <CEC name> -Fname,state,lpar_env" to check that. The lpar_env will be "vioserver".

     

    If the HMC is managing the VIOSs then it could be a some issue in HMC. We will need logs to debug the issue. You might need to open a PMR for it. One suggestion : Is it possible for you to update the HMC to latest level (current GAed version of the HMC is 860 and Service Pack1). Thanks!

    -Manju


    #Power-Hardware-Management-Console-Programmers
    #HMCandCMC


  • 8.  Re: /rest/api/uom/VirtualIOServer return null

    Posted Sat April 01, 2017 05:01 AM

    Originally posted by: 87F8_sadf_sdf


    thank you very much.

    i tried refer to this website, http://www-01.ibm.com/support/docview.wss?uid=nas8N1018878 .

    The problem should be out of hmc deploy.i will redeploy a new hmc.

    i will use ssh to manage it.


    #HMCandCMC
    #Power-Hardware-Management-Console-Programmers


  • 9.  Re: /rest/api/uom/VirtualIOServer return null

    Posted Sat April 01, 2017 06:14 AM

    Originally posted by: manjunathns


    Thanks.

    Yes, the link you mentioned should be used for collecting the HMC logs.

    Please let us know if you still see the issue even after updating the HMC. Thanks!

    -Manju


    #Power-Hardware-Management-Console-Programmers
    #HMCandCMC


  • 10.  Re: /rest/api/uom/VirtualIOServer return null

    Posted Fri April 21, 2017 05:09 AM

    Originally posted by: 87F8_sadf_sdf


    hi

    I   tried again using HMC8.6.It's ok.


    #HMCandCMC
    #Power-Hardware-Management-Console-Programmers