PUT method fails with '404 error' while applying erraa/errata's using Satellite 6 API

Solution In Progress - Updated -

Environment

  • Red Hat Satellite 6.1

Issue

  • PUT method fails with '404 error' while applying erraa/errata's using Satellite 6 API
  • curl -H "Accept: application/json" -X PUT -u admin:password http://satellite.example.com/katello/api/v2/systems//errata
<!DOCTYPE html>
<html>
<head>
  <title>The page you were looking for doesn't exist (404)</title>
  <style type="text/css">
    body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
    div.dialog {
      width: 25em;
      padding: 0 4em;
      margin: 4em auto 0 auto;
      border: 1px solid #ccc;
      border-right-color: #999;
      border-bottom-color: #999;
    }
    h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
  </style>
</head>

<body>
  <!-- This file lives in public/404.html -->
  <div class="dialog">
    <h1>The page you were looking for doesn't exist.</h1>
    <p>You may have mistyped the address or the page may have moved.</p>
  </div>
</body>
</html>
  • Using GET method erratas are listing for the system
  • curl -H "Accept: application/json" -X GET -u admin:password http://satellite.example.com/katello/api/v2/systems/f6e83cfd-f4a6-4134-9d14-cdf680282650/errata/
{"total":15,"subtotal":15,"page":null,"per_page":null,"search":null,"sort":{"by":null,"order":null},"results":[{"title":"Moderate: pam security update","version":null,"description":null,"status":null,"id":"4ff4e06d-9fe4-48f3-b914-7a323ec96458","errata_id...[...]

Resolution

  • There is dokumentation error, the call needs to be :
PUT /katello/api/v2/systems/:system_id/errata/apply

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.

Comments