Re: Imported asset data is gone after Provisioning Requisitions Sync

Marc Doesburg <[email protected]> Fri, 4 Jan 2019 16:41:58 +0000
Newsgroups gmane.network.opennms.general
Message-ID <CAE_XvpbmBPLjHGRdM+e8Q-i27i7nupcUU+P6XHfT61Rr3vod+A@mail.gmail.com>
--===============5636806750144576983==
Content-Type: multipart/alternative; boundary="0000000000007186bb057ea48fb8"

--0000000000007186bb057ea48fb8
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Hi Eduardo,

That looks way more doable then manually adding all the individual assets.
Thanks for pointing this out. But this does create 2 new questions :-)

- What would happen if I try to add an asset that's already added to
the <foreign-source> <foreign-id>. I just tested "address1" for 1 node,
what would happen if I try to add "address1" again?
- I tried 1 asset on 1 node and all nodes showed up again as if I did an
import. But after the sync, they were all gone again. Is this normal
behavior or?

--=20
Marc D.

Real is just a matter of perception

On Fri, 4 Jan 2019 at 14:04, Eduardo <[email protected]> wrote:

> 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 transferre=
d to the node.
>
> I use the provision.pl script:
>
> /opt/opennms/bin/provision.pl asset set "$REQUISITION" "$FOREIGNID" "$ASS=
ETFIELD" "$VALUE"
>
> Regards,
> John
>
>
> -----Original Message-----
> From: Eduardo [mailto:[email protected] <[email protected]=
ov.ar>]
> 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 c=
lick 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 optio=
ns.
> 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 asset=
s.
>
> 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 dat=
a
> 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 t=
his page:https://lists.sourceforge.net/lists/listinfo/opennms-discuss
>
> --
> Lic. Eduardo Rodolfo Colombres
> Director de Comunicaciones y Redes de datos
> Secretar=C3=ADa de Inform=C3=A1tica Jur=C3=ADdica
> Poder Judicial del Chubut
> Tel:0280-4482333 - RPP 3333/3332 - int 141
> Cel:0280-15-4410201
>
> ________________________________________________________________
> 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

--0000000000007186bb057ea48fb8
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div dir=3D"ltr"><div dir=3D"ltr">Hi Eduardo,</div><div di=
r=3D"ltr"><br></div><div>That looks way more doable=C2=A0then=C2=A0manually=
 adding all the individual assets. Thanks for pointing this out. But this d=
oes create 2 new questions :-)</div><div><br></div><div>- What would happen=
 if I try to add an asset that&#39;s already added to the=C2=A0&lt;foreign-=
source&gt; &lt;foreign-id&gt;.=C2=A0I just tested &quot;address1&quot; for =
1 node, what would happen if I try to add &quot;address1&quot; again?</div>=
<div>- I tried 1 asset on 1 node and all nodes showed up again as if I did =
an import. But after the sync, they were all gone again. Is this normal beh=
avior or?</div><div><br></div><div>--=C2=A0<br></div><div><div dir=3D"ltr" =
class=3D"gmail_signature"><div>Marc D.<br><br>Real is just a matter of perc=
eption</div><div><br></div></div></div><div class=3D"gmail_quote"><div dir=
=3D"ltr">On Fri, 4 Jan 2019 at 14:04, Eduardo &lt;<a href=3D"mailto:ecolomb=
[email protected]">[email protected]</a>&gt; wrote:<br></div><=
blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-l=
eft:1px solid rgb(204,204,204);padding-left:1ex">
 =20
   =20
 =20
  <div bgcolor=3D"#FFFFFF">
    <p>Hi Marc, I asked the same question=C2=A0 two months ago. The answer,
      from John D.Blackburn is=C2=A0 below.</p>
    <p>Eduardo</p>
    <pre class=3D"gmail-m_-2715513782853517796moz-quote-pre">You need to de=
fine the asset values in the requisition not in the node.  Then when the re=
quisition synchronizes, all the asset values get transferred to the node.

I use the <a href=3D"http://provision.pl" target=3D"_blank">provision.pl</a=
> script:

/opt/opennms/bin/<a href=3D"http://provision.pl" target=3D"_blank">provisio=
n.pl</a> asset set &quot;$REQUISITION&quot; &quot;$FOREIGNID&quot; &quot;$A=
SSETFIELD&quot; &quot;$VALUE&quot;

Regards,
John


-----Original Message-----
From: Eduardo [<a class=3D"gmail-m_-2715513782853517796moz-txt-link-freetex=
t" href=3D"mailto:[email protected]" target=3D"_blank">mailto:eco=
[email protected]</a>]=20
Sent: Wednesday, 21 November 2018 10:45 AM
To: <a class=3D"gmail-m_-2715513782853517796moz-txt-link-abbreviated" href=
=3D"mailto:[email protected]" target=3D"_blank">opennms=
[email protected]</a>
Subject: [opennms-discuss] How to persist assets&#39;s value

CAUTION: This email originated from outside of the organization. Do not cli=
ck links or open attachments unless you recognize the sender and know the c=
ontent is safe.


Hi everyone
I have an issue related with asset&#39;s data persistence. I have
provisioned all my nodes using provisioning requisitions via Web UI options=
.
Then I modified node&#39;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&#39;s values persistent despite requisitions
synchronization ? I&#39; ll like still use sql queries to update node&#39;s=
 assets.

Thanks in advance


Eduardo

</pre>
    <div class=3D"gmail-m_-2715513782853517796moz-cite-prefix"><br>
    </div>
    <div class=3D"gmail-m_-2715513782853517796moz-cite-prefix"><br>
    </div>
    <div class=3D"gmail-m_-2715513782853517796moz-cite-prefix">On 4/1/19 08=
:30, Marc Doesburg wrote:<br>
    </div>
    <blockquote type=3D"cite">
     =20
      <div dir=3D"ltr">
        <div dir=3D"ltr">Hi All,
          <div><br>
          </div>
          <div>I&#39;m trying to import asset data for around=C2=A050 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&#39;t there after the import.=C2=A0</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=C2=A0it the Provisioning Requisition overrules node
            asset data. And since the asset data isn&#39;t in the
            Provisioning=C2=A0Requisitions it&#39;s removed.</div>
          <div><br>
          </div>
          <div>Is there an extra step I need to perform before the asset
            data becomes permanent?<br clear=3D"all">
            <div><br>
            </div>
            -- <br>
            <div dir=3D"ltr" class=3D"gmail-m_-2715513782853517796gmail_sig=
nature">
              <div>Marc D.<br>
                <br>
                Real is just a matter of perception</div>
              <div>=C2=A0</div>
            </div>
          </div>
        </div>
      </div>
      <br>
      <fieldset class=3D"gmail-m_-2715513782853517796mimeAttachmentHeader">=
</fieldset>
      <br>
      <fieldset class=3D"gmail-m_-2715513782853517796mimeAttachmentHeader">=
</fieldset>
      <pre class=3D"gmail-m_-2715513782853517796moz-quote-pre">____________=
____________________________________________________
Note that this mailing list is not as active as other resources.

Visit <a class=3D"gmail-m_-2715513782853517796moz-txt-link-freetext" href=
=3D"https://opennms.discourse.group/" target=3D"_blank">https://opennms.dis=
course.group/</a> for the forum, and
visit <a class=3D"gmail-m_-2715513782853517796moz-txt-link-freetext" href=
=3D"https://chat.opennms.com" target=3D"_blank">https://chat.opennms.com</a=
> for real-time chat.
________________________________________________________________

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of thi=
s page:
<a class=3D"gmail-m_-2715513782853517796moz-txt-link-freetext" href=3D"http=
s://lists.sourceforge.net/lists/listinfo/opennms-discuss" target=3D"_blank"=
>https://lists.sourceforge.net/lists/listinfo/opennms-discuss</a></pre>
    </blockquote>
    <pre class=3D"gmail-m_-2715513782853517796moz-signature" cols=3D"72">--=
=20
Lic. Eduardo Rodolfo Colombres
Director de Comunicaciones y Redes de datos
Secretar=C3=ADa de Inform=C3=A1tica Jur=C3=ADdica
Poder Judicial del Chubut
Tel:0280-4482333 - RPP 3333/3332 - int 141
Cel:0280-15-4410201
</pre>
  </div>

________________________________________________________________<br>
Note that this mailing list is not as active as other resources.<br>
<br>
Visit <a href=3D"https://opennms.discourse.group/" rel=3D"noreferrer" targe=
t=3D"_blank">https://opennms.discourse.group/</a> for the forum, and<br>
visit <a href=3D"https://chat.opennms.com" rel=3D"noreferrer" target=3D"_bl=
ank">https://chat.opennms.com</a> for real-time chat.<br>
________________________________________________________________<br>
<br>
opennms-discuss mailing list<br>
<br>
To *unsubscribe* or change your subscription options, see the bottom of thi=
s page:<br>
<a href=3D"https://lists.sourceforge.net/lists/listinfo/opennms-discuss" re=
l=3D"noreferrer" target=3D"_blank">https://lists.sourceforge.net/lists/list=
info/opennms-discuss</a></blockquote></div><br clear=3D"all"><div><br></div=
></div></div>

--0000000000007186bb057ea48fb8--


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


--===============5636806750144576983==
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
--===============5636806750144576983==--