Hello,
Sorry for the delay....
The test works.. but not for all the files. it works with commands file and timeperiod, but it not worked with contacts file. I tried to add a test contact following the same method, but it not works... Same issue with hosts, services...
Configuration Import not working
Re: Configuration Import not working
Can you give us an example of a contacts config, that you are trying to import? You mentioned that you didn't have issues importing commands and timeperiods. What about contact templates? They need to be imported prior to contacts.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Configuration Import not working
I just upgrade to last nagiosxi version, now I'm seeing errors I did not see before the upgrade. After to try to import the contacts file, for every contact that the file contains this error appears.
Entry contact_name::xxxxxx inside tbl_contact could not be inserted: Filed 'name' doesn't have a default value
Entry contact_name::xxxxxx inside tbl_contact could not be inserted: Filed 'name' doesn't have a default value
Re: Configuration Import not working
In addition to this, run the following command and show us the output.Can you give us an example of a contacts config, that you are trying to import? You mentioned that you didn't have issues importing commands and timeperiods. What about contact templates? They need to be imported prior to contacts.
Code: Select all
echo 'desc tbl_contact;' | mysql -t -pnagiosxi nagiosql | grep nameBe sure to check out our Knowledgebase for helpful articles and solutions!
Re: Configuration Import not working
A contact example:
define contact {
contact_name adm
alias Administrator
host_notification_period 24x7
service_notification_period 24x7
host_notification_options d,r
service_notification_options w,c,r
host_notification_commands host-notify-by-email
service_notification_commands notify-by-email
email [email protected]
}
We're using default contact template, there are not customized contact templates.
And the output of the command:
echo 'desc tbl_contact;' | mysql -t -pnagiosxi nagiosql | grep name
| contact_name | varchar(255) | NO | MUL | NULL | |
| name | varchar(255) | NO | MUL | NULL | |
define contact {
contact_name adm
alias Administrator
host_notification_period 24x7
service_notification_period 24x7
host_notification_options d,r
service_notification_options w,c,r
host_notification_commands host-notify-by-email
service_notification_commands notify-by-email
email [email protected]
}
We're using default contact template, there are not customized contact templates.
And the output of the command:
echo 'desc tbl_contact;' | mysql -t -pnagiosxi nagiosql | grep name
| contact_name | varchar(255) | NO | MUL | NULL | |
| name | varchar(255) | NO | MUL | NULL | |
Re: Configuration Import not working
Problem solved! The problem was related to DB. character set text fields (char, text) was configured in latin1, normally we configure it in utf8, after to change this fields to utf8 the import worked correctly.
Thanks for the support.
Thanks for the support.