Forum Discussion

sprashanthac_81's avatar
sprashanthac_81
Icon for Nimbostratus rankNimbostratus
Dec 09, 2010

Is .ucs file editable, if so how to compress it back ??

We copied the .ucs file from one 6900 machine to another lab 6900 machine. The changes we see are that of the License and the Registration key... now if we want to replicate just the configuration is it possible... one thing we did was we extracted one of the ucs file and then changed the details of the registrationkey file and the bigip.license file in the /config folder of the extracted .ucs. How to compress it back and use this file....

8 Replies

  • Hamish's avatar
    Hamish
    Icon for Cirrocumulus rankCirrocumulus
    It's a gzipped tar file... Should be simply...

     

     

    1. Create a directory to old the contents of the archive

     

    mkdir ucs

     

     

    2. Change to the new ucs directory

     

    cd ucs

     

     

    3. extract the files from the archive

     

    gzip -dc /full/path/to/whatever.ucs | tar xvpf -

     

     

    2. Edit whichever files you want...

     

     

    3. Create a new ucs file

     

    tar cvf - * | gzip -c > /full/path/to/whatever_new.ucs

     

     

     

    Note.

     

    * The ucs directory is empty, so when/if the ucs file contents change, this method will still work (Because it'll all be relative to this new empty directory).

     

     

    H
  • Should simply be an archive. Try zipping it up with winzip/winrar and changing the file extension to .ucs.
  • As Chris said, a UCS is a tar archive, but I've had difficulties in the past trying to edit a file and rebuild the UCS archive. If you try it and it doesn't work, you could potentially use a single configuration file instead.

     

     

    Keep in mind that if you copy a UCS from one unit to another with a different host name, only the shared configuration will be loaded during a 'b config install'. So the existing license and bigip_base.conf would be preserved. This should be a cleaner solution than manually editing the UCS files.

     

     

    Aaron
  • Sorry for my late reply which probably makes this post defunct, I have to agree with Hoolio, I too have had problems recompressing a .ucs archive and getting it to load back to the BigIP. The SCF is a good idea, but if you do want to work with the UCS, I normally take the approach of modifying the individual files (bigip.conf or whatever) and copying these back to the /config folder.

     

     

    Then do a 'b verify load' - if any errors with the file we just copied over check the syntax, otherwise 'b load' to get the config running. Job done.

     

     

    Chris
  • hey there, I want to use a ucs file as i'm using a GTM in the lab and want to populate the wide ip conf info from a prod box (as well as all its other config and an SCF won't give me the wide ip details).

     

     

    re your suggestion of editing the conf files. Do you do this on a production box? I don't quite get how you pull this off on a live box.
  • Couldn't you just copy in the new wideip.conf and it will get synched to the other members of the group as the timestamp is newer?

     

     

    Aaron
  • I just want to say (Resurecting this post from the dead)

     

    Hamish's method worked for an issue we were facing where somehow the ucs contained

     

    pool and snatpool config (Bad practice by a previous engineer) that was named the same.

     

    This method allowed me to edit the bigip.conf file and rezip it.