Need a command to create message group in OVOU

can we create a message group through command line interface.I have to create around 100 message group so i think it will be easy to write a shell script if i get to know how to create message group through CLI.

Thanks much
Bans
Parents
  • Verified Answer

    There is no CLI.

    But,
    you can do this...
    $MYDIR is a tmp directory to user
    $MSGGRP is the name of the message group

    # cd $MYDIR
    # mkdir C
    # echo "MESSAGE_GROUP "$MSGGRP" ; >> download.dsf
    # echo "HEADER" >> C/$MYDIR.idx
    # echo "NAME \"$FULLPATH/C/$MYDIR.idx" >> C/$MYDIR.idx
    # echo "DATE \" bla bla date\"" >> C/$MYDIR.idx
    # echo "FROM \" management server name\" >> C/$MYDIR.idx
    # echo "CHARACTER_SET your-character-set" >> C/$MYDIR.idx
    # echo "ADMIN_UUID \" the uuid\"" >> C/$MYDIR.idx
    # echo "CONTENTS SELECTED;" >> C/$MYDIR.idx
    # echo "ENTITY MESSAGE GROUP SELECTED" >>
    # echo "PROCESSED \"$MSGGRP\"" >> C/$MYDIR.idx
    # echo ";" >> C/$MYDIR.idx
    # echo "." >> C/$MYDIR.idx

    # mkdir C/MSGGROUPS
    # echo "DOWNLOAD_DATA MESSAGE_GROUP" >> C/MSGGROUPS/msggroups.dat
    # echo "SYNTAX_VERSION 1" >> C/MSGGROUPS/msggroups.dat
    # echo "MESSAGE_GROUP \"$MSGGRP\"" >> C/MSGGROUPS/msggroups.dat
    # echo "SYMBOL \"Software:SNMP\" >> C/MSGGROUPS/msggroups.dat
    # echo "DESCRIPTION \"the description\"" >> C/MSGGROUPS/msggroups.dat
    # echo "LABEL \"$MSGGRP\"" >>C/MSGGROUPS/msggroups.dat
    # echo ";" >> C/MSGGROUPS/msggroups.dat

    And then...
    # opccfgupld -add `pwd`/

    You need to find the UUID of your management server, byut doing a simple configuration download and check it.
    Also, the icon "Software:SNMP" is one I picked from a test message group.

    Kind regards,
    alexk



Reply
  • Verified Answer

    There is no CLI.

    But,
    you can do this...
    $MYDIR is a tmp directory to user
    $MSGGRP is the name of the message group

    # cd $MYDIR
    # mkdir C
    # echo "MESSAGE_GROUP "$MSGGRP" ; >> download.dsf
    # echo "HEADER" >> C/$MYDIR.idx
    # echo "NAME \"$FULLPATH/C/$MYDIR.idx" >> C/$MYDIR.idx
    # echo "DATE \" bla bla date\"" >> C/$MYDIR.idx
    # echo "FROM \" management server name\" >> C/$MYDIR.idx
    # echo "CHARACTER_SET your-character-set" >> C/$MYDIR.idx
    # echo "ADMIN_UUID \" the uuid\"" >> C/$MYDIR.idx
    # echo "CONTENTS SELECTED;" >> C/$MYDIR.idx
    # echo "ENTITY MESSAGE GROUP SELECTED" >>
    # echo "PROCESSED \"$MSGGRP\"" >> C/$MYDIR.idx
    # echo ";" >> C/$MYDIR.idx
    # echo "." >> C/$MYDIR.idx

    # mkdir C/MSGGROUPS
    # echo "DOWNLOAD_DATA MESSAGE_GROUP" >> C/MSGGROUPS/msggroups.dat
    # echo "SYNTAX_VERSION 1" >> C/MSGGROUPS/msggroups.dat
    # echo "MESSAGE_GROUP \"$MSGGRP\"" >> C/MSGGROUPS/msggroups.dat
    # echo "SYMBOL \"Software:SNMP\" >> C/MSGGROUPS/msggroups.dat
    # echo "DESCRIPTION \"the description\"" >> C/MSGGROUPS/msggroups.dat
    # echo "LABEL \"$MSGGRP\"" >>C/MSGGROUPS/msggroups.dat
    # echo ";" >> C/MSGGROUPS/msggroups.dat

    And then...
    # opccfgupld -add `pwd`/

    You need to find the UUID of your management server, byut doing a simple configuration download and check it.
    Also, the icon "Software:SNMP" is one I picked from a test message group.

    Kind regards,
    alexk



Children
No Data