Re: Imported asset data is gone after Provisioning Requisitions Sync

Eduardo <[email protected]> Fri, 4 Jan 2019 10:02:20 -0300
Newsgroups gmane.network.opennms.general
Message-ID <[email protected]>
This is a multi-part message in MIME format.
--===============8215726411433067246==
Content-Type: multipart/alternative;
 boundary="------------82FD0E800BB70154FEF4EA95"
Content-Language: en-US

This is a multi-part message in MIME format.
--------------82FD0E800BB70154FEF4EA95
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit

Hi Marc, I asked the same question  two months ago. The answer, from 
John D.Blackburn is  below.

Eduardo


You need to define the asset values in the requisition not in the node.  Then when the requisition synchronizes, all the asset values get transferred to the node.

I use the provision.pl script:

/opt/opennms/bin/provision.pl asset set "$REQUISITION" "$FOREIGNID" "$ASSETFIELD" "$VALUE"

Regards,
John


-----Original Message-----
From: Eduardo [mailto:[email protected]]
Sent: Wednesday, 21 November 2018 10:45 AM
To:[email protected]
Subject: [opennms-discuss] How to persist assets's value

CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.


Hi everyone
I have an issue related with asset's data persistence. I have
provisioned all my nodes using provisioning requisitions via Web UI options.
Then I modified node's assets fields using sql queries . The problem
rise when requisitions sinchronyze, if it does all my assets updates get
lost.

How can I keep asset's values persistent despite requisitions
synchronization ? I' ll like still use sql queries to update node's assets.

Thanks in advance


Eduardo



On 4/1/19 08:30, Marc Doesburg wrote:
> Hi All,
>
> I'm trying to import asset data for around 50 nodes. I exported the 
> current asset information to a CSV file (Admin -> Import and Export 
> Assets), updated/added the asset data in the CSV and uploaded the new 
> data into OpenNMS.
>
> When I look at the node assets information after the import, the data 
> is there, icons show up on the Geo map etc. But when the Provisioning 
> Requisitions sync, all the imported Asset data is gone. Asset data I 
> entered manually (Via Provisioning Requisitions) stays in the 
> database. When I look at the nodes via the Provisioning Requisitions 
> the asset data isn't there after the import.
>
> So it kinda makes sense that the asset data is removed during a 
> Provisioning Requisition sync because as I understand it the 
> Provisioning Requisition overrules node asset data. And since the 
> asset data isn't in the Provisioning Requisitions it's removed.
>
> Is there an extra step I need to perform before the asset data becomes 
> permanent?
>
> -- 
> Marc D.
>
> Real is just a matter of perception
>
>
> ________________________________________________________________
> Note that this mailing list is not as active as other resources.
>
> Visit https://opennms.discourse.group/ for the forum, and
> visit https://chat.opennms.com for real-time chat.
> ________________________________________________________________
>
> opennms-discuss mailing list
>
> To *unsubscribe* or change your subscription options, see the bottom of this page:
> https://lists.sourceforge.net/lists/listinfo/opennms-discuss

-- 
Lic. Eduardo Rodolfo Colombres
Director de Comunicaciones y Redes de datos
Secretaría de Informática Jurídica
Poder Judicial del Chubut
Tel:0280-4482333 - RPP 3333/3332 - int 141
Cel:0280-15-4410201


--------------82FD0E800BB70154FEF4EA95
Content-Type: text/html; charset=utf-8
Content-Transfer-Encoding: 8bit

<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <p>Hi Marc, I asked the same question  two months ago. The answer,
      from John D.Blackburn is  below.</p>
    <p>Eduardo</p>
    <pre class="moz-quote-pre" wrap="">

You need to define the asset values in the requisition not in the node.  Then when the requisition synchronizes, all the asset values get transferred to the node.

I use the provision.pl script:

/opt/opennms/bin/provision.pl asset set "$REQUISITION" "$FOREIGNID" "$ASSETFIELD" "$VALUE"

Regards,
John


-----Original Message-----
From: Eduardo [<a class="moz-txt-link-freetext" href="mailto:[email protected]">mailto:[email protected]</a>] 
Sent: Wednesday, 21 November 2018 10:45 AM
To: <a class="moz-txt-link-abbreviated" href="mailto:[email protected]">[email protected]</a>
Subject: [opennms-discuss] How to persist assets's value

CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.


Hi everyone
I have an issue related with asset's data persistence. I have
provisioned all my nodes using provisioning requisitions via Web UI options.
Then I modified node's assets fields using sql queries . The problem
rise when requisitions sinchronyze, if it does all my assets updates get
lost.

How can I keep asset's values persistent despite requisitions
synchronization ? I' ll like still use sql queries to update node's assets.

Thanks in advance


Eduardo

</pre>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">On 4/1/19 08:30, Marc Doesburg wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:CAE_XvpbscDB57=Pwr4L6CvqRjGAm096z0BvzBfqDDAEqvn4abw@mail.gmail.com">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <div dir="ltr">
        <div dir="ltr">Hi All,
          <div><br>
          </div>
          <div>I'm trying to import asset data for around 50 nodes. I
            exported the current asset information to a CSV file (Admin
            -&gt; Import and Export Assets), updated/added the asset
            data in the CSV and uploaded the new data into OpenNMS.</div>
          <div><br>
          </div>
          <div>When I look at the node assets information after the
            import, the data is there, icons show up on the Geo map etc.
            But when the Provisioning Requisitions sync, all the
            imported Asset data is gone. Asset data I entered manually
            (Via Provisioning Requisitions) stays in the database. When
            I look at the nodes via the Provisioning Requisitions the
            asset data isn't there after the import. </div>
          <div><br>
          </div>
          <div>So it kinda makes sense that the asset data is removed
            during a Provisioning Requisition sync because as I
            understand it the Provisioning Requisition overrules node
            asset data. And since the asset data isn't in the
            Provisioning Requisitions it's removed.</div>
          <div><br>
          </div>
          <div>Is there an extra step I need to perform before the asset
            data becomes permanent?<br clear="all">
            <div><br>
            </div>
            -- <br>
            <div dir="ltr" class="gmail_signature">
              <div>Marc D.<br>
                <br>
                Real is just a matter of perception</div>
              <div> </div>
            </div>
          </div>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <pre class="moz-quote-pre" wrap="">________________________________________________________________
Note that this mailing list is not as active as other resources.

Visit <a class="moz-txt-link-freetext" href="https://opennms.discourse.group/">https://opennms.discourse.group/</a> for the forum, and
visit <a class="moz-txt-link-freetext" href="https://chat.opennms.com">https://chat.opennms.com</a> for real-time chat.
________________________________________________________________

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
<a class="moz-txt-link-freetext" href="https://lists.sourceforge.net/lists/listinfo/opennms-discuss">https://lists.sourceforge.net/lists/listinfo/opennms-discuss</a></pre>
    </blockquote>
    <pre class="moz-signature" cols="72">-- 
Lic. Eduardo Rodolfo Colombres
Director de Comunicaciones y Redes de datos
Secretaría de Informática Jurídica
Poder Judicial del Chubut
Tel:0280-4482333 - RPP 3333/3332 - int 141
Cel:0280-15-4410201
</pre>
  </body>
</html>

--------------82FD0E800BB70154FEF4EA95--


--===============8215726411433067246==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline


--===============8215726411433067246==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

________________________________________________________________
Note that this mailing list is not as active as other resources.

Visit https://opennms.discourse.group/ for the forum, and
visit https://chat.opennms.com for real-time chat.
________________________________________________________________

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
--===============8215726411433067246==--