Forum Discussion

Christopher_Wo2's avatar
Christopher_Wo2
Icon for Altocumulus rankAltocumulus
Feb 27, 2015
Solved

what's REST for "save /sys config"?

I'm currently on 11.5, trying to do this in the REST interface to have a separate "write config files" step.

 

  • tmsh save /sys config

https://support.f5.com/kb/en-us/solutions/public/14000/500/sol14564.html

 

I don't think I've quite grasped which method to use, or what constitutes the module or submodule or object of the REST call.

 

I've come this far:

 

  • url:
  • method: POST
  • payload: {"save":{"/sys":"config"}}

However, this gives me a message of "Missing name" with a 400 return code. What bit is it referring to when it asks for the name? Any other hints?

 

I found this thing but it seems to be unrelated given that it's UCS:

 

Edit: fix the brackets around the url.

 

4 Replies

  • Interesting to note is that you currently can't create an SCF via iControl SOAP, only a UCS.

     

    • Andrew_Le_12873's avatar
      Andrew_Le_12873
      Icon for Nimbostratus rankNimbostratus
      In version 12.0 of BIGIP/REST, you can save and load SCF file, using this format for your data/payload and using POST method: payload = {"command": "load", "options": [{"file":"/var/local/scf/medium_saving_config.scf"}]} payload = {"command": "save", "options": [{"file":"/var/local/scf/medium_saving_config.scf"}]}
  • That was it, thank you. The same section is in the documentation for the 11.5 api. (I was searching for "save /sys config" and "sys config" and other strings, I'm a bit unfamiliar with tmsh.)

     

    Now:

     

    • url:
    • method: POST
    • payload: {"command":"save"}