Menu

How to Add/modify attributes for a synchro data source

Chacha38
2023-04-18
2025-03-20
  • Chacha38

    Chacha38 - 2023-04-18

    Hi !
    I create a synchro data source 'Synchro Data pc OCSng' that contains 3 attributes : name, target_class and description. I like to add more attributes.
    I tried to make some change in 'Synchro Data pc OCSng, the table in my Itop database but nothing has changed when I look into Itop :

    Does anybody know how to do that ?

     
  • Pierre Goiffon

    Pierre Goiffon - 2023-04-19

    Hello,
    Not sure to understand. Did you create the datasynchro manually ?
    Where do you want to add more attributes ?

     
  • Chacha38

    Chacha38 - 2023-04-19

    I am trying to synchronize my Itop with the data that I got from OCS Inventory. So I read some documentation in ItopHub about the Data model and Data collector for OCS Inventory package .
    In the OCS Inventory documentation it is mentioned that I have to create a Synchronization Data source (which I did), and then I have to upload an .csv file containing all the PCs, Virtuals Machines that I got from OCS Inventory into Itop.

    My .csv has four attributs, however the Syncro Data I've created in the iTop automatically has created three attributs that don't match the initial attributs in my .csv file. I would like to know if it's possible to edit the names of these attributs, and to add new or delete some of them as well.
    My initial goal is to create the same attributs in both, my .csv file and the Syncro Data, so in the next step, the collected data could be correctly synchronized.

    I'm sorry if it's still difficult to understand I can't upload a screenshot here because I have to put an url and my screenshot is on my file exporer.

     
  • Pierre Goiffon

    Pierre Goiffon - 2023-06-30

    Hello,
    Sorry for the late answer, we were quite busy with the last steps of the 3.1.0 version devs

    To feed data into iTop we have the collectors : they automate most of the tasks (data extraction, transformation, datasynchro handling in iTop, etc)
    There is one collector for OCS, did you give it a try ? See https://www.itophub.io/wiki/page?id=extensions:ocsng-data-collector-v2

     
  • Lucien LUPIN

    Lucien LUPIN - 2025-03-19

    Hello, I am using the OCSng collector extension. All attributes on a computer object are locked. When I change the synchro data source 'synchro_data_pc_OCSng' which was automatically created by the connector, to make some attributes policy update 'Write if empty' my changes are reverted back as soon a synchro occur.
    How I can modify the OCS collector to allow me to change attribute's policy update on a Synchro Data Source ?
    Thank you

     
  • Lucien LUPIN

    Lucien LUPIN - 2025-03-19

    Hello, I am using the OCSng collector extension. All attributes on a computer object are locked. When I change the synchro data source 'synchro_data_pc_OCSng' which was automatically created by the connector, to make some attributes policy update 'Write if empty' my changes are reverted back as soon a synchro occur.
    How I can modify the OCS collector to allow me to change attribute's policy update on a Synchro Data Source ?
    Thank you

     

    Last edit: Lucien LUPIN 2025-03-19
  • Lucien LUPIN

    Lucien LUPIN - 2025-03-20

    OK I think I found it !
    On iTop change the Synchro Data Source as you want.
    On the OCS Collector server, go to the collector's directory.
    Make a backup of the original PCCollector config :
    mv collectors/OCSPCCollector.json collectors/OCSPCCollector.json.bak
    Then export Synchro Data Source parameters with this command :
    php toolkit/dump_tasks.php --task_name="OCSng:PC" > collectors/OCSPCCollector.json

    You can also change directly in the json files the update policy as you want : write_if_empty / master_unlocked

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.