Getting error when trying to set a value in Spectrum using curl

book

Article ID: 5716

calendar_today

Updated On:

Products

CA Spectrum

Issue/Introduction

Getting the following error when trying to set a value in Spectrum using curl:

[[email protected] ~]$ /usr/bin/curl -X PUT -u spectrum:spectrum http://spectrum:8080/spectrum/restful/model/0x100060?attr=0x67600d9&val=2

[1] 64320

[[email protected] ~]$ attr and val parameters are not proportionate

Environment

Linux

Resolution

The resolution is to enclose the http in double quotes:

 

[[email protected] ~]$ /usr/bin/curl -X PUT -u spectrum:spectrum "http://spectrum:8080/spectrum/restful/model/0x100060?attr=0x67600d9&val=2"

<?xml version="1.0" encoding="UTF-8" standalone="yes"?><model-update-response-list xmlns="http://www.ca.com/spectrum/restful/schema/response"><model-responses><model error="Success" mh="0x100060"><attribute error="Success" id="0x67600d9"/></model></model-responses></model-update-response-list>[[email protected] ~]