terraform-provider-fortios
terraform-provider-fortios copied to clipboard
Getting error -56: set timezone '' with terraform destroy
Description
I created following resource
"resource": {
"fortios_system_global": {
"global": {
"vdom_mode": "multi-vdom",
"timezone": "UTC",
"hostname": "fw1",
"lldp_transmission": "enable",
"lldp_reception": "enable"
}
}
}
but I'm getting error when trying to destroy it, i.e. terraform tries to set timezone empty string/'' which fails.
fortios_system_global.global: Destroying... [id=SystemGlobal]
╷
│ Error: Error clearing SystemGlobal resource: Internal Server Error - Internal error when processing the request (500)
│ Cli response:
│ [vdom-mode cannot be disabled when multiple vdoms are present. path=system, objname=global, size=3320, sz_attr=1 value parse error before '' Command fail. Return code -56 cmd_clean_context 0, abort=1 cmd_clean_context 0, abort=1 Command fail. Return code 1]
The same can be seen on the debug
[httpsd 3330 - 1730147891 info] api_unset_cmdb_node[2477] -- 'auth-session-auto-backup-interval'
[httpsd 3330 - 1730147891 info] api_unset_cmdb_node[2477] -- 'scim-https-port'
[httpsd 3330 - 1730147891 info] api_unset_cmdb_node[2477] -- 'scim-http-port'
0: config global
0: config system global
0: set gui-auto-upgrade-setup-warning enable
-56: set timezone ''
(skipped) set hostname "FortiGate-VM64-KVM"
(skipped) set lldp-transmission disable
(skipped) set lldp-reception disable
(skipped) set vdom-mode no-vdom
[httpsd 3330 - 1730147891 info] cmdb_save_with_children[280] -- appended main node (nret=-56, is_new=0)
[httpsd 3330 - 1730147891 error] cmdb_save_with_children[285] -- saving failed for main node: 'global' (err=-56)
[httpsd 3330 - 1730147891 error] cmdb_commit_from_json[2332] -- error saving request object to CLI (-56)
[httpsd 3330 - 1730147891 error] _api_cmdb_v2_config[2354] -- error editing object (nret=-56)
[httpsd 3330 - 1730147891 warning] api_return_http_result[1270] -- API error -56 raised
fw1 (global) # set timezone ''
value parse error before ''
Command fail. Return code -56