I followed the step by step tutorial
Created a module with the module creation wizard
Made sure that when I created the module I respected the dependencies! I called it addfield
When a module modifies an existing class, it must be loaded after the module that declared the class to be modified. To achieve this, make sure that the first module is listed in the dependencies of your new module.
For example if you want to alter the definition of the VirtualMachine class, your custom module must depend on itop-virtualization-mgmt/2.0.0
The toolkit doesn't install new modules, so the first time you have to run a setup and select your custom module on the last step. Did you already did that?
Hope it helps,
Guillaume
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
In iTop, in the navigation menu, if you open the user menu and select "About iTop", then open the "Support information" section; do you see your module there?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Would you happen to have other modules installed as well? What if you go through the iTop setup wizard?
Mind that you actually only need to use the delta attribute on XML parts that you want to (re)define or alter in another way. There's no need to redefine the whole presentation, you can simply add the node to show your field and set a rank :)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
This is a clean install of itop. I have another instance in which I also installed an extension but extension only contains classes that are derived from another class, while here it's an attempt to redefine a existing class.
The tutorial shows two ways to define the presentation part:
Note for advanced users: you could write differently the above file. Instead of a redefine on the whole “presentation” tag, just add the “note” field exactly where it need to be in the tree structure. It's not really simpler as you still need to know that tree structure, but this solution allow to have 2 different extensions which both add a new field on the Server class somewhere in the tree structure and get a working result. If you redefine the full tag, then the last extension, overwrites what others could have done before.
I'm mainly surprised why the toolkit does not detect that there is a new field to be added to the server table
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I just installed your module on a 3.2 and it works well. I just changed:
- The presentation to be more precise instead of redefining the whole list. That way you don't conflict with other extensions.
- The XML version to 1.7 (compatible with iTop 2.7+)
I just installed your module on a 3.2 and it works well. I just changed:
- The presentation to be more precise instead of redefining the whole
list. That way you don't conflict with other extensions.
- The XML version to 1.7 (compatible with iTop 2.7+)
Hi,
I followed the step by step tutorial
Created a module with the module creation wizard
Made sure that when I created the module I respected the dependencies! I called it addfield
When a module modifies an existing class, it must be loaded after the module that declared the class to be modified. To achieve this, make sure that the first module is listed in the dependencies of your new module.
For example if you want to alter the definition of the VirtualMachine class, your custom module must depend on itop-virtualization-mgmt/2.0.0
module.addfield.php:
'dependencies' => array(
'itop-config-mgmt/2.0.0'
),
My datamodel.addfield.php looks like this:
<itop_design xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0">
<classes>
<class id="Server" _delta="if_exists">
<fields>
<field id="notes" xsi:type="AttributeText" _delta="define">
<sql>notes</sql>
<default_value>
<is_null_allowed>true</is_null_allowed>
</default_value></field>
</fields>
<presentation>
</presentation></class></classes></itop_design>
<items>
<item id="softwares_list">
<rank>10</rank>
</item>
<item id="contacts_list">
<rank>20</rank>
</item>
<item id="documents_list">
<rank>30</rank>
</item>
<item id="tickets_list">
<rank>40</rank>
</item>
<item id="physicalinterface_list">
<rank>50</rank>
</item>
<item id="fiberinterfacelist_list">
<rank>60</rank>
</item>
<item id="networkdevice_list">
<rank>70</rank>
</item>
<item id="san_list">
<rank>80</rank>
</item>
<item id="logicalvolumes_list">
<rank>90</rank>
</item>
<item id="providercontracts_list">
<rank>100</rank>
</item>
<item id="services_list">
<rank>110</rank>
</item>
<item id="col:col1">
<rank>120</rank>
<items>
<item id="fieldset:Server:baseinfo">
<rank>10</rank>
<items>
<item id="name">
<rank>10</rank>
</item>
<item id="org_id">
<rank>20</rank>
</item>
<item id="status">
<rank>30</rank>
</item>
<item id="business_criticity">
<rank>40</rank>
</item>
<item id="location_id">
<rank>50</rank>
</item>
<item id="rack_id">
<rank>60</rank>
</item>
<item id="enclosure_id">
<rank>70</rank>
</item>
</items>
</item>
<item id="fieldset:Server:moreinfo">
<rank>20</rank>
<items>
<item id="brand_id">
<rank>10</rank>
</item>
<item id="model_id">
<rank>20</rank>
</item>
<item id="osfamily_id">
<rank>30</rank>
</item>
<item id="osversion_id">
<rank>40</rank>
</item>
<item id="oslicence_id">
<rank>50</rank>
</item>
<item id="cpu">
<rank>60</rank>
</item>
<item id="ram">
<rank>70</rank>
</item>
<item id="nb_u">
<rank>80</rank>
</item>
<item id="serialnumber">
<rank>90</rank>
</item>
<item id="asset_number">
<rank>100</rank>
</item>
</items>
</item>
</items>
</item>
<item id="col:col2">
<rank>130</rank>
<items>
<item id="fieldset:Server:Date">
<rank>10</rank>
<items>
<item id="move2production">
<rank>10</rank>
</item>
<item id="purchase_date">
<rank>20</rank>
</item>
<item id="end_of_warranty">
<rank>30</rank>
</item>
</items>
</item>
<item id="fieldset:Server:otherinfo">
<rank>20</rank>
<items>
<item id="powerA_id">
<rank>10</rank>
</item>
<item id="powerB_id">
<rank>20</rank>
</item>
<item id="description">
<rank>30</rank>
</item>
<item id="notes">
<rank>40</rank>
</item>
</items>
</item>
</items>
</item>
</items>
But when I run the toolkit it doesn't detect any db changes.
Afterwards the server table in my mysql db does not contain the notes field.
I'm running iTop-3.1.1-1-12561 and itop-toolkit-community-3.1.
Any ideas about what I'm doing wrong?
Hello Johan,
The toolkit doesn't install new modules, so the first time you have to run a setup and select your custom module on the last step. Did you already did that?
Hope it helps,
Guillaume
Hi Guillaume, I did perform the setup step to install the addfield module and afterwards I ran the toolkit checks
In iTop, in the navigation menu, if you open the user menu and select "About iTop", then open the "Support information" section; do you see your module there?
yes the module extension is in the installation options list
yes the module extension is in the installation options list
Could you share your module's zip file so I can check locally? :)
Extension module is in the attachment
Would you happen to have other modules installed as well? What if you go through the iTop setup wizard?
Mind that you actually only need to use the delta attribute on XML parts that you want to (re)define or alter in another way. There's no need to redefine the whole presentation, you can simply add the node to show your field and set a rank :)
This is a clean install of itop. I have another instance in which I also installed an extension but extension only contains classes that are derived from another class, while here it's an attempt to redefine a existing class.
The tutorial shows two ways to define the presentation part:
Note for advanced users: you could write differently the above file. Instead of a redefine on the whole “presentation” tag, just add the “note” field exactly where it need to be in the tree structure. It's not really simpler as you still need to know that tree structure, but this solution allow to have 2 different extensions which both add a new field on the Server class somewhere in the tree structure and get a working result. If you redefine the full tag, then the last extension, overwrites what others could have done before.
I'm mainly surprised why the toolkit does not detect that there is a new field to be added to the server table
The reason to minimize the "redefining" of XML nodes, is to avoid conflicts with other modules.
Did you try running the setup instead? It may tell you more.
I tried setup againg. No errors. This is the output of setup.log:
2024-08-12 16:01:32 | Ok | | Info - CheckPHPVersion | SetupLog |||
2024-08-12 16:01:32 | Ok | | Info - php.ini file(s): '/etc/php/8.1/apache2/php.ini, /etc/php/8.1/apache2/conf.d/10-mysqlnd.ini, /etc/php/8.1/apache2/conf.d/10-opcache.ini, /etc/php/8.1/apache2/conf.d/10-pdo.ini, /etc/php/8.1/apache2/conf.d/15-xml.ini, /etc/php/8.1/apache2/conf.d/20-bcmath.ini, /etc/php/8.1/apache2/conf.d/20-calendar.ini, /etc/php/8.1/apache2/conf.d/20-ctype.ini, /etc/php/8.1/apache2/conf.d/20-curl.ini, /etc/php/8.1/apache2/conf.d/20-dom.ini, /etc/php/8.1/apache2/conf.d/20-exif.ini, /etc/php/8.1/apache2/conf.d/20-ffi.ini, /etc/php/8.1/apache2/conf.d/20-fileinfo.ini, /etc/php/8.1/apache2/conf.d/20-ftp.ini, /etc/php/8.1/apache2/conf.d/20-gd.ini, /etc/php/8.1/apache2/conf.d/20-gettext.ini, /etc/php/8.1/apache2/conf.d/20-iconv.ini, /etc/php/8.1/apache2/conf.d/20-ldap.ini, /etc/php/8.1/apache2/conf.d/20-mbstring.ini, /etc/php/8.1/apache2/conf.d/20-mysqli.ini, /etc/php/8.1/apache2/conf.d/20-pdo_mysql.ini, /etc/php/8.1/apache2/conf.d/20-phar.ini, /etc/php/8.1/apache2/conf.d/20-posix.ini, /etc/php/8.1/apache2/conf.d/20-readline.ini, /etc/php/8.1/apache2/conf.d/20-shmop.ini, /etc/php/8.1/apache2/conf.d/20-simplexml.ini, /etc/php/8.1/apache2/conf.d/20-soap.ini, /etc/php/8.1/apache2/conf.d/20-sockets.ini, /etc/php/8.1/apache2/conf.d/20-sysvmsg.ini, /etc/php/8.1/apache2/conf.d/20-sysvsem.ini, /etc/php/8.1/apache2/conf.d/20-sysvshm.ini, /etc/php/8.1/apache2/conf.d/20-tokenizer.ini, /etc/php/8.1/apache2/conf.d/20-xmlreader.ini, /etc/php/8.1/apache2/conf.d/20-xmlwriter.ini, /etc/php/8.1/apache2/conf.d/20-xsl.ini, /etc/php/8.1/apache2/conf.d/20-zip.ini' | SetupLog |||
2024-08-12 16:01:32 | Ok | | Info - Temporary directory for files upload (/tmp) is writable. | SetupLog |||
2024-08-12 16:01:32 | Ok | | Info - upload_max_filesize: 2M | SetupLog |||
2024-08-12 16:01:32 | Ok | | Info - post_max_size: 8M | SetupLog |||
2024-08-12 16:01:32 | Ok | | Info - max_file_uploads: 20 | SetupLog |||
2024-08-12 16:01:32 | Ok | | Info - memory_limit is 128M, ok. | SetupLog |||
2024-08-12 16:01:32 | Ok | | Info - session.save_path is: '/var/lib/php/sessions'. | SetupLog |||
2024-08-12 16:01:32 | Ok | | The current PHP Version (8.1.29) is greater than the minimum version required to run iTop, which is (7.4.0) | SetupLog |||
2024-08-12 16:01:32 | Ok | | The current PHP Version (8.1.29) is greater than the minimum version required to run next iTop major release, which is (8.1.0) | SetupLog |||
2024-08-12 16:01:32 | Ok | | The temp directory is writable by the application. | SetupLog |||
2024-08-12 16:01:32 | Ok | | Required PHP extension(s): curl, dom, fileinfo, gd, hash, iconv, json, mbstring, mysqli, pcre, session, simplexml, soap, zip, zlib. | SetupLog |||
2024-08-12 16:01:32 | Ok | | Optional PHP extension(s): ldap, sodium, openssl. | SetupLog |||
2024-08-12 16:01:32 | Ok | | Loaded php.ini files: /etc/php/8.1/apache2/php.ini, /etc/php/8.1/apache2/conf.d/10-mysqlnd.ini, /etc/php/8.1/apache2/conf.d/10-opcache.ini, /etc/php/8.1/apache2/conf.d/10-pdo.ini, /etc/php/8.1/apache2/conf.d/15-xml.ini, /etc/php/8.1/apache2/conf.d/20-bcmath.ini, /etc/php/8.1/apache2/conf.d/20-calendar.ini, /etc/php/8.1/apache2/conf.d/20-ctype.ini, /etc/php/8.1/apache2/conf.d/20-curl.ini, /etc/php/8.1/apache2/conf.d/20-dom.ini, /etc/php/8.1/apache2/conf.d/20-exif.ini, /etc/php/8.1/apache2/conf.d/20-ffi.ini, /etc/php/8.1/apache2/conf.d/20-fileinfo.ini, /etc/php/8.1/apache2/conf.d/20-ftp.ini, /etc/php/8.1/apache2/conf.d/20-gd.ini, /etc/php/8.1/apache2/conf.d/20-gettext.ini, /etc/php/8.1/apache2/conf.d/20-iconv.ini, /etc/php/8.1/apache2/conf.d/20-ldap.ini, /etc/php/8.1/apache2/conf.d/20-mbstring.ini, /etc/php/8.1/apache2/conf.d/20-mysqli.ini, /etc/php/8.1/apache2/conf.d/20-pdo_mysql.ini, /etc/php/8.1/apache2/conf.d/20-phar.ini, /etc/php/8.1/apache2/conf.d/20-posix.ini, /etc/php/8.1/apache2/conf.d/20-readline.ini, /etc/php/8.1/apache2/conf.d/20-shmop.ini, /etc/php/8.1/apache2/conf.d/20-simplexml.ini, /etc/php/8.1/apache2/conf.d/20-soap.ini, /etc/php/8.1/apache2/conf.d/20-sockets.ini, /etc/php/8.1/apache2/conf.d/20-sysvmsg.ini, /etc/php/8.1/apache2/conf.d/20-sysvsem.ini, /etc/php/8.1/apache2/conf.d/20-sysvshm.ini, /etc/php/8.1/apache2/conf.d/20-tokenizer.ini, /etc/php/8.1/apache2/conf.d/20-xmlreader.ini, /etc/php/8.1/apache2/conf.d/20-xmlwriter.ini, /etc/php/8.1/apache2/conf.d/20-xsl.ini, /etc/php/8.1/apache2/conf.d/20-zip.ini | SetupLog |||
2024-08-12 16:01:32 | Ok | | The value for session.save_path (/var/lib/php/sessions) is writable for the web server. | SetupLog |||
2024-08-12 16:01:35 | Ok | | Info - CheckBackupPrerequisites | SetupLog |||
2024-08-12 16:01:35 | Ok | | Info - PHP functions disabled: | SetupLog |||
2024-08-12 16:01:35 | Ok | | Info - mysqldump -V said: mysqldump Ver 10.19 Distrib 10.11.8-MariaDB, for debian-linux-gnu (x86_64) | SetupLog |||
2024-08-12 16:01:35 | Info | | operation 'async_action', peak memory usage. 891688 | SetupLog |||
2024-08-12 16:01:38 | Info | | GetApplicationVersion returns: product_name: iTop, product_version: 3.1.1-1-12561 | SetupLog |||
2024-08-12 16:01:39 | Ok | | Info - CheckGraphviz | SetupLog |||
2024-08-12 16:01:39 | Ok | | Info - PHP functions disabled: | SetupLog |||
2024-08-12 16:01:39 | Ok | | Info - /usr/bin/dot -V said: dot - graphviz version 2.43.0 (0) | SetupLog |||
2024-08-12 16:01:39 | Info | | operation 'async_action', peak memory usage. 838240 | SetupLog |||
2024-08-12 16:01:51 | Info | | ##### STEP start | SetupLog |||
2024-08-12 16:01:51 | Info | | ----> Entering read only mode | SetupLog |||
2024-08-12 16:01:51 | Info | | ======= Installation starts =======
Parameters:
<installation>
<mode>upgrade</mode>
<preinstall>
<copies type="array">
<backup>
<destination>/var/www/html/itop/data/backups/manual/setup-2024-08-12_16_01</destination>
<configuration_file>/var/www/html/itop//conf/production/config-itop.php</configuration_file>
</backup>
</copies></preinstall>
<source_dir>datamodels/2.x/</source_dir>
<datamodel_version>3.1.1</datamodel_version>
<previous_configuration_file>/var/www/html/itop//conf/production/config-itop.php</previous_configuration_file>
<extensions_dir>extensions</extensions_dir>
<target_env>production</target_env>
<workspace_dir></workspace_dir>
<database>
<server>localhost</server>
<user>itop</user>
<pwd>removed</pwd>
<name>itop</name>
<db_tls_enabled></db_tls_enabled>
<db_tls_ca></db_tls_ca>
<prefix></prefix>
</database>
<url>http://localhost/itop/</url>
<graphviz_path>/usr/bin/dot</graphviz_path>
<admin_account>
<user></user>
<pwd>removed</pwd>
<language></language>
</admin_account>
<language></language>
<selected_modules type="array">
<item>authent-cas</item>
<item>authent-external</item>
<item>authent-ldap</item>
<item>authent-local</item>
<item>combodo-backoffice-darkmoon-theme</item>
<item>itop-backup</item>
<item>itop-config</item>
<item>itop-files-information</item>
<item>itop-portal-base</item>
<item>itop-profiles-itil</item>
<item>itop-sla-computation</item>
<item>itop-structure</item>
<item>itop-welcome-itil</item>
<item>authent-token</item>
<item>combodo-db-tools</item>
<item>combodo-password-expiration</item>
<item>combodo-webhook-integration</item>
<item>itop-attachments</item>
<item>itop-config-mgmt</item>
<item>itop-core-update</item>
<item>itop-hub-connector</item>
<item>itop-oauth-client</item>
<item>itop-themes-compat</item>
<item>itop-tickets</item>
<item>itop-datacenter-mgmt</item>
<item>itop-endusers-devices</item>
<item>itop-storage-mgmt</item>
<item>itop-virtualization-mgmt</item>
<item>itop-bridge-cmdb-ticket</item>
<item>itop-bridge-virtualization-storage</item>
<item>itop-service-mgmt</item>
<item>itop-bridge-cmdb-services</item>
<item>itop-bridge-datacenter-mgmt-services</item>
<item>itop-bridge-endusers-devices-services</item>
<item>itop-bridge-storage-mgmt-services</item>
<item>itop-bridge-virtualization-mgmt-services</item>
<item>itop-request-mgmt-itil</item>
<item>itop-incident-mgmt-itil</item>
<item>itop-portal</item>
<item>itop-full-itil</item>
<item>itop-change-mgmt-itil</item>
<item>itop-faq-light</item>
<item>itop-knownerror-mgmt</item>
<item>itop-problem-mgmt</item>
<item>addfield</item>
</selected_modules>
<selected_extensions type="array">
<item>itop-config-mgmt-core</item>
<item>itop-config-mgmt-datacenter</item>
<item>itop-config-mgmt-end-user</item>
<item>itop-config-mgmt-storage</item>
<item>itop-config-mgmt-virtualization</item>
<item>itop-service-mgmt-enterprise</item>
<item>itop-ticket-mgmt-itil</item>
<item>itop-ticket-mgmt-itil-user-request</item>
<item>itop-ticket-mgmt-itil-incident</item>
<item>itop-ticket-mgmt-itil-enhanced-portal</item>
<item>itop-change-mgmt-itil</item>
<item>itop-kown-error-mgmt</item>
<item>itop-problem-mgmt</item>
<item>addfield</item>
</selected_extensions>
<sample_data></sample_data>
<old_addon></old_addon>
<options type="array">
<mysql_bindir></mysql_bindir>
</options></installation>
| SetupLog |||
2024-08-12 16:01:51 | Info | | ##### STEP duration: 0.01s | SetupLog |||
2024-08-12 16:01:51 | Info | | operation 'async_action', peak memory usage. 847496 | SetupLog |||
2024-08-12 16:01:51 | Info | | ##### STEP copy start | SetupLog |||
2024-08-12 16:01:51 | Info | | ##### STEP copy duration: 0s | SetupLog |||
2024-08-12 16:01:51 | Info | | operation 'async_action', peak memory usage. 847120 | SetupLog |||
2024-08-12 16:01:51 | Info | | ##### STEP backup start | SetupLog |||
2024-08-12 16:01:51 | Ok | | Info - Creating backup: '/var/www/html/itop/data/backups/manual/setup-2024-08-12_16_01.tar.gz' | SetupLog |||
2024-08-12 16:01:51 | Ok | | Info - backup: creating tmp dir '/var/www/html/itop/data/tmp-backup-1050918195' | SetupLog |||
2024-08-12 16:01:51 | Ok | | Info - backup: adding resource '/var/www/html/itop//conf/production/config-itop.php' | SetupLog |||
2024-08-12 16:01:51 | Ok | | Info - Starting backup of localhost/itop(suffix:'') | SetupLog |||
2024-08-12 16:01:51 | Ok | | Info - backup: generate data file with command: mysqldump --defaults-extra-file="/tmp/itop-mysqldump-0oNKHr" --opt --skip-lock-tables --default-character-set=utf8mb4 --add-drop-database --single-transaction --host='localhost' --port='3306' --protocol=tcp --user=xxxxx --result-file='/var/www/html/itop/data/tmp-backup-1050918195/itop-dump.sql' 'itop' | SetupLog |||
2024-08-12 16:01:52 | Ok | | Info - backup: adding to archive files 'array (
0 => '/var/www/html/itop/data/tmp-backup-1050918195/config-itop.php',
1 => '/var/www/html/itop/data/tmp-backup-1050918195/itop-dump.sql',
)' | SetupLog |||
2024-08-12 16:01:52 | Ok | | Info - backup: removing tmp folder '/var/www/html/itop/data/tmp-backup-1050918195' | SetupLog |||
2024-08-12 16:01:52 | Info | | ##### STEP backup duration: 0.91s | SetupLog |||
2024-08-12 16:01:52 | Info | | operation 'async_action', peak memory usage. 3814128 | SetupLog |||
2024-08-12 16:01:52 | Info | | ##### STEP compile start | SetupLog |||
2024-08-12 16:01:52 | Info | | Compiling data model. | SetupLog |||
2024-08-12 16:01:52 | Info | | ----> Entering maintenance mode | SetupLog |||
2024-08-12 16:01:57 | Warning | | CompileThemes: Theme #test-red has an import (#css-variables) without explicit xsi:type, it will be ignored. Check Datamodel XML Reference to fix it. | SetupLog |||
2024-08-12 16:01:57 | Warning | | CompileThemes: Theme #light-grey has an import (#css-variables) without explicit xsi:type, it will be ignored. Check Datamodel XML Reference to fix it. | SetupLog |||
2024-08-12 16:01:57 | Info | | For theme 'darkmoon' precompiled file used: '/var/www/html/itop/data/precompiled_styles/darkmoon.css' | SetupLog |||
2024-08-12 16:01:57 | Warning | | Cannot find /var/www/html/itop/env-production/branding/themes/darkmoon/images/arrow.png (images/arrow.png) during SCSS darkmoon precompilation | SetupLog |||
2024-08-12 16:01:57 | Info | | No theme 'darkmoon' compilation was required during setup. | SetupLog |||
2024-08-12 16:01:57 | Info | | For theme 'fullmoon' precompiled file used: '/var/www/html/itop/data/precompiled_styles/fullmoon.css' | SetupLog |||
2024-08-12 16:01:57 | Info | | No theme 'fullmoon' compilation was required during setup. | SetupLog |||
2024-08-12 16:01:57 | Info | | For theme 'test-red' precompiled file used: '/var/www/html/itop/data/precompiled_styles/test-red.css' | SetupLog |||
2024-08-12 16:01:57 | Info | | No theme 'test-red' compilation was required during setup. | SetupLog |||
2024-08-12 16:01:57 | Info | | For theme 'light-grey' precompiled file used: '/var/www/html/itop/data/precompiled_styles/light-grey.css' | SetupLog |||
2024-08-12 16:01:57 | Info | | No theme 'light-grey' compilation was required during setup. | SetupLog |||
2024-08-12 16:01:57 | Info | | Data model successfully compiled to '/var/www/html/itop/env-production'. | SetupLog |||
2024-08-12 16:01:57 | Info | | <---- Exiting maintenance mode | SetupLog |||
2024-08-12 16:01:58 | Info | | ##### STEP compile duration: 5.14s | SetupLog |||
2024-08-12 16:01:58 | Info | | operation 'async_action', peak memory usage. 61110992 | SetupLog |||
2024-08-12 16:01:58 | Info | | ##### STEP db-schema start | SetupLog |||
2024-08-12 16:01:58 | Info | | Update Database Schema for environment 'production'. | SetupLog |||
2024-08-12 16:01:58 | Info | | MetaModel::Startup (ModelOnly = 1) | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming 'priv_internalUser' into 'priv_internaluser' (lowercase) | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming 'priv_internalUser' failed (already done in a previous upgrade?) | SetupLog |||
2024-08-12 16:01:58 | Info | | Cleanup of 'priv_change' to remove orphan records | SetupLog |||
2024-08-12 16:01:58 | Info | | There is a total of 12 records in priv_change. | SetupLog |||
2024-08-12 16:01:58 | Info | | There are 0 useless records in priv_change (0.00%) | SetupLog |||
2024-08-12 16:01:58 | Info | | Ok, nothing to cleanup. | SetupLog |||
2024-08-12 16:01:58 | Info | | Calling Module Handler: AuthentLDAPInstaller::BeforeDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:58 | Info | | Calling Module Handler: AttachmentInstaller::BeforeDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:58 | Info | | No orphan attachment found. | SetupLog |||
2024-08-12 16:01:58 | Info | | Calling Module Handler: StructureInstaller::BeforeDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'DBserver' to 'DBServer': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'OSfamily' to 'OSFamily': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'OSversion' to 'OSVersion': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'Webserver' to 'WebServer': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'OSpatch' to 'OSPatch': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'OsLicence' to 'OSLicence': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'IOSversion' to 'IOSVersion': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'IPinterface' to 'IPInterface': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Calling Module Handler: TicketsInstaller::BeforeDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:58 | Info | | Calling Module Handler: ConfigMgmtInstaller::BeforeDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'DBserver' to 'DBServer': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'OSfamily' to 'OSFamily': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'OSversion' to 'OSVersion': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'Webserver' to 'WebServer': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'OSpatch' to 'OSPatch': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'OsLicence' to 'OSLicence': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'IOSversion' to 'IOSVersion': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'IPinterface' to 'IPInterface': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Calling Module Handler: EndUserMgmtInstaller::BeforeDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:58 | Info | | Renaming class in DB - final class from 'IpPhone' to 'IPPhone': 0 rows affected | SetupLog |||
2024-08-12 16:01:58 | Info | | Calling Module Handler: FAQLightInstaller::BeforeDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:58 | Info | | Calling Module Handler: ServiceMgmtInstaller::BeforeDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:58 | Info | | Calling Module Handler: StorageMgmtInstaller::BeforeDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:58 | Info | | Creating the structure in 'itop'. | SetupLog |||
2024-08-12 16:01:58 | Info | | 0.020s - query: ALTER TABLE
priv_sync_att_linkset
CHANGEattribute_qualifier
attribute_qualifier
VARCHAR(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT '\'' | SetupLog |||2024-08-12 16:01:59 | Ok | | Database structure successfully updated. | SetupLog |||
2024-08-12 16:01:59 | Ok | | Start of rebuilt of hierchical keys. If you have problems with this step, you can skip it by creating a ".setup-rebuild-hkeys-never" file in data | SetupLog |||
2024-08-12 16:01:59 | Ok | | Hierchical keys rebuilt: The attribute parent_id from Organization is a hierarchical key.
Rebuilding the fields parent_id_right and parent_id_left from table 'organization'...
Ok, table 'organization' successfully updated.
The attribute parent_id from Group is a hierarchical key.
Rebuilding the fields parent_id_right and parent_id_left from table 'group'...
Ok, table 'group' successfully updated.
| SetupLog |||
2024-08-12 16:01:59 | Ok | | Data sources checked: There are no Data Sources in the database.
Ok.
| SetupLog |||
2024-08-12 16:01:59 | Ok | | Meta enums rebuilt: Executing query: UPDATE
ticket
JOINticket_incident
ONticket_incident
.id =ticket
.id SETticket
.operational_status
= 'ongoing' WHEREticket_incident
.status
IN ('new', 'assigned', 'pending', 'escalated_tto', 'escalated_ttr') ANDticket
.operational_status
!= 'ongoing'Executing query: UPDATE
ticket
JOINticket_incident
ONticket_incident
.id =ticket
.id SETticket
.operational_status
= 'resolved' WHEREticket_incident
.status
IN ('resolved') ANDticket
.operational_status
!= 'resolved'Executing query: UPDATE
ticket
JOINticket_incident
ONticket_incident
.id =ticket
.id SETticket
.operational_status
= 'closed' WHEREticket_incident
.status
IN ('closed') ANDticket
.operational_status
!= 'closed'Executing query: UPDATE
ticket
JOINticket_problem
ONticket_problem
.id =ticket
.id SETticket
.operational_status
= 'ongoing' WHEREticket_problem
.status
IN ('new', 'assigned') ANDticket
.operational_status
!= 'ongoing'Executing query: UPDATE
ticket
JOINticket_problem
ONticket_problem
.id =ticket
.id SETticket
.operational_status
= 'resolved' WHEREticket_problem
.status
IN ('resolved') ANDticket
.operational_status
!= 'resolved'Executing query: UPDATE
ticket
JOINticket_problem
ONticket_problem
.id =ticket
.id SETticket
.operational_status
= 'closed' WHEREticket_problem
.status
IN ('closed') ANDticket
.operational_status
!= 'closed'Executing query: UPDATE
ticket
JOINticket_request
ONticket_request
.id =ticket
.id SETticket
.operational_status
= 'ongoing' WHEREticket_request
.status
IN ('new', 'waiting_for_approval', 'approved', 'assigned', 'pending', 'escalated_tto', 'escalated_ttr') ANDticket
.operational_status
!= 'ongoing'Executing query: UPDATE
ticket
JOINticket_request
ONticket_request
.id =ticket
.id SETticket
.operational_status
= 'closed' WHEREticket_request
.status
IN ('rejected', 'closed') ANDticket
.operational_status
!= 'closed'Executing query: UPDATE
ticket
JOINticket_request
ONticket_request
.id =ticket
.id SETticket
.operational_status
= 'resolved' WHEREticket_request
.status
IN ('resolved') ANDticket
.operational_status
!= 'resolved'Executing query: UPDATE
ticket
JOINchange
ONchange
.id =ticket
.id SETticket
.operational_status
= 'ongoing' WHEREchange
.status
IN ('new', 'validated', 'assigned', 'plannedscheduled', 'approved', 'notapproved', 'implemented', 'monitored') ANDticket
.operational_status
!= 'ongoing'Executing query: UPDATE
ticket
JOINchange
ONchange
.id =ticket
.id SETticket
.operational_status
= 'closed' WHEREchange
.status
IN ('rejected', 'closed') ANDticket
.operational_status
!= 'closed'| SetupLog |||
2024-08-12 16:01:59 | Info | | 'priv_change.origin' already initialized, nothing to do. | SetupLog |||
2024-08-12 16:01:59 | Info | | 'priv_async_task.status' already initialized, nothing to do. | SetupLog |||
2024-08-12 16:01:59 | Info | | Database Schema Successfully Updated for environment 'production'. | SetupLog |||
2024-08-12 16:01:59 | Info | | ##### STEP db-schema duration: 0.96s | SetupLog |||
2024-08-12 16:01:59 | Info | | operation 'async_action', peak memory usage. 30914784 | SetupLog |||
2024-08-12 16:01:59 | Info | | ##### STEP after-db-create start | SetupLog |||
2024-08-12 16:01:59 | Info | | After Database Creation | SetupLog |||
2024-08-12 16:01:59 | Info | | MetaModel::Startup (ModelOnly = 1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: AuthentLDAPInstaller::AfterDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: AttachmentInstaller::AfterDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Initializing attachment/item_org_id - null to zero | SetupLog |||
2024-08-12 16:01:59 | Info | | Initializing attachment/item_org_id - zero to the container | SetupLog |||
2024-08-12 16:01:59 | Info | | Initializing attachment/item_org_id - 0 records have been adjusted | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: StructureInstaller::AfterDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: TicketsInstaller::AfterDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: ConfigMgmtInstaller::AfterDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: EndUserMgmtInstaller::AfterDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: FAQLightInstaller::AfterDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: ServiceMgmtInstaller::AfterDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: StorageMgmtInstaller::AfterDatabaseCreation(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | URP_Profiles::GetPredefinedObjects() returned 13 elements. | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: AuthentLDAPInstaller::AfterDatabaseSetup(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: AttachmentInstaller::AfterDatabaseSetup(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: StructureInstaller::AfterDatabaseSetup(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: TicketsInstaller::AfterDatabaseSetup(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: ConfigMgmtInstaller::AfterDatabaseSetup(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: EndUserMgmtInstaller::AfterDatabaseSetup(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: FAQLightInstaller::AfterDatabaseSetup(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: ServiceMgmtInstaller::AfterDatabaseSetup(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: StorageMgmtInstaller::AfterDatabaseSetup(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | ##### STEP after-db-create duration: 0.09s | SetupLog |||
2024-08-12 16:01:59 | Info | | operation 'async_action', peak memory usage. 5384096 | SetupLog |||
2024-08-12 16:01:59 | Info | | ##### STEP load-data start | SetupLog |||
2024-08-12 16:01:59 | Info | | MetaModel::Startup (ModelOnly = ) | SetupLog |||
2024-08-12 16:01:59 | Info | | starting data load session | SetupLog |||
2024-08-12 16:01:59 | Info | | Loading file: /var/www/html/itop/env-production/itop-config-mgmt/data/en_us.data.itop-brand.xml (just to get the keys mapping) | SetupLog |||
2024-08-12 16:01:59 | Info | | loading of en_us.data.itop-brand.xml done. | SetupLog |||
2024-08-12 16:01:59 | Info | | Loading file: /var/www/html/itop/env-production/itop-config-mgmt/data/en_us.data.itop-osfamily.xml (just to get the keys mapping) | SetupLog |||
2024-08-12 16:01:59 | Info | | loading of en_us.data.itop-osfamily.xml done. | SetupLog |||
2024-08-12 16:01:59 | Info | | Loading file: /var/www/html/itop/env-production/itop-config-mgmt/data/en_us.data.itop-osversion.xml (just to get the keys mapping) | SetupLog |||
2024-08-12 16:01:59 | Info | | loading of en_us.data.itop-osversion.xml done. | SetupLog |||
2024-08-12 16:01:59 | Info | | Loading file: /var/www/html/itop/env-production/combodo-webhook-integration/data.struct.remote_application_type.xml (just to get the keys mapping) | SetupLog |||
2024-08-12 16:01:59 | Info | | loading of data.struct.remote_application_type.xml done. | SetupLog |||
2024-08-12 16:01:59 | Info | | ending data load session | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: AuthentLDAPInstaller::AfterDataLoad(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: AttachmentInstaller::AfterDataLoad(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: StructureInstaller::AfterDataLoad(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: TicketsInstaller::AfterDataLoad(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: ConfigMgmtInstaller::AfterDataLoad(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: EndUserMgmtInstaller::AfterDataLoad(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: FAQLightInstaller::AfterDataLoad(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: ServiceMgmtInstaller::AfterDataLoad(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | Calling Module Handler: StorageMgmtInstaller::AfterDataLoad(oConfig, 3.1.1, 3.1.1) | SetupLog |||
2024-08-12 16:01:59 | Info | | ##### STEP load-data duration: 0.26s | SetupLog |||
2024-08-12 16:01:59 | Info | | operation 'async_action', peak memory usage. 6202776 | SetupLog |||
2024-08-12 16:01:59 | Info | | ##### STEP create-config start | SetupLog |||
2024-08-12 16:01:59 | Info | | MetaModel::Startup from /var/www/html/itop//conf/production/config-itop.php (ModelOnly = 1) | SetupLog |||
2024-08-12 16:02:00 | Info | | <---- Exiting read only mode | SetupLog |||
2024-08-12 16:02:00 | Info | | ##### STEP create-config duration: 0.64s | SetupLog |||
2024-08-12 16:02:00 | Info | | operation 'async_action', peak memory usage. 8428696 | SetupLog |||
2024-08-12 16:02:00 | Info | | MetaModel::Startup from /var/www/html/itop/conf/production/config-itop.php (ModelOnly = 1) | SetupLog |||
Last edit: Johan De Graeve 2024-08-12
Something else to try. Update the version at the top of the document from 1.0 to 1.7.
https://www.itophub.io/wiki/page?id=2_7_0:customization:xml_reference - "if_exists" was introduced in a later version ( 1.3 ) .
I just installed your module on a 3.2 and it works well. I just changed:
- The presentation to be more precise instead of redefining the whole list. That way you don't conflict with other extensions.
- The XML version to 1.7 (compatible with iTop 2.7+)
Can you try with this XML?
Hi Guillaume,
Works like a charm. Thanks a lot for all the assistance!
You guys rock!
Johan
On Tue, Aug 13, 2024 at 9:31 AM Guillaume Lajarige glajarige@users.sourceforge.net wrote:
Glad to see it works! :)
Take care,
Guillaume