[ovirt-users] Hosted engine notifications don't work after upgrading ovirt from 3.5 to 3.6

Martin Sivak msivak at redhat.com
Mon Nov 9 12:32:08 UTC 2015


Btw, please check the template file
(/etc/ovirt-hosted-engine-ha/notifications/state_transition.txt) and
make sure it does not start with an empty line.

Martin

On Mon, Nov 9, 2015 at 1:25 PM, Martin Sivak <msivak at redhat.com> wrote:
> Hi,
>
> can you please tell us the Python version you are using? We are using
> the smtplib and email.mime.text standard libraries to send emails so
> this should not be our bug (unless the API changed).
>
> Thanks
>
> --
> Martin Sivak
> SLA / oVirt
>
>
> On Mon, Nov 9, 2015 at 1:11 PM, Sandro Bonazzola <sbonazzo at redhat.com> wrote:
>>
>>
>> On Mon, Nov 9, 2015 at 11:44 AM, Stefano Danzi <s.danzi at hawai.it> wrote:
>>>
>>> Your trick work fine! Thanks!
>>>
>>> Now I see that emails sent from brocker has "corrupted" headers:
>>>
>>> At the ent of message we can see:
>>>
>>> Content-Type: text/plain; charset="us-ascii"
>>> MIME-Version: 1.0
>>> Content-Transfer-Encoding: 7bit
>>> Date: Mon, 09 Nov 2015 11:33:37 +0100
>>> Message-Id: <20151109103337.D9C7D1260001 at my.server.lan>
>>> From: mysender at server.lan
>>> To: undisclosed-recipients:;
>>>
>>> From: mysender at server.lan
>>> To: myreceiver at server.lan
>>> Subject: ovirt-hosted-engine state transition EngineUp-GlobalMaintenance
>>>
>>> The state machine changed state.
>>>
>>>
>>
>> Adding Roy and Martin, looks like a separate issue
>>
>>
>>
>>>
>>>
>>> From and To are repeated twice. This cause that email client show
>>> correctly the sender,
>>> an empty recipient and an empty subject.
>>>
>>> On message body I see everything after "To: undisclosed-recipients:;"
>>>
>>> Il 06/11/2015 20.01, Simone Tiraboschi ha scritto:
>>>
>>>
>>>
>>> On Thu, Nov 5, 2015 at 7:10 PM, Stefano Danzi <s.danzi at hawai.it> wrote:
>>>>
>>>>
>>>>
>>>>
>>>> the content is:
>>>>
>>>> [email]
>>>> smtp-server=localhost
>>>> smtp-port=25
>>>> destination-emails=root at localhost
>>>> source-email=root at localhost
>>>>
>>>> [notify]
>>>> state_transition=maintenance|start|stop|migrate|up|down
>>>>
>>>> and is the default. My conf was lost during upgrade.
>>>> If I restart ovirt-ha-broker the broker.conf is replaced with the default
>>>>
>>>> If I don't restart ovirt-ha-broker, the broker.conf is silently replaced
>>>> after a while.
>>>>
>>>> Looking here
>>>> http://lists.ovirt.org/pipermail/engine-commits/2015-June/022940.html
>>>> I understand that broker.conf is stored in another place and overwrite at
>>>> runtime.
>>>
>>>
>>> The broker.conf is now on the shared storage (as other hosted-engine
>>> related configuration files) so that in the future they'll be easily
>>> editable from the web UI.
>>>
>>> The issue here seams to be that the upgrade overwrite it with the default
>>> file before copying to the shared storage.
>>> I'm opening a bug against that.
>>>
>>> Let's try to fix in your instance (please substitute
>>> '192.168.1.115:_Virtual_ext35u36' with the mount point on your system):
>>>
>>> dir=`mktemp -d` && cd $dir
>>> systemctl stop ovirt-ha-broker
>>> sdUUID_line=$(grep sdUUID /etc/ovirt-hosted-engine/hosted-engine.conf)
>>> sdUUID=${sdUUID_line:7:36}
>>> conf_volume_UUID_line=$(grep conf_volume_UUID
>>> /etc/ovirt-hosted-engine/hosted-engine.conf)
>>> conf_volume_UUID=${conf_volume_UUID_line:17:36}
>>> conf_image_UUID_line=$(grep conf_image_UUID
>>> /etc/ovirt-hosted-engine/hosted-engine.conf)
>>> conf_image_UUID=${conf_image_UUID_line:16:36}
>>> dd
>>> if=/rhev/data-center/mnt/192.168.1.115:_Virtual_ext35u36/$sdUUID/images/$conf_image_UUID/$conf_volume_UUID
>>> 2>/dev/null| tar -xvf -
>>> cp /etc/ovirt-hosted-engine-ha/broker.conf.rpmsave broker.conf # or edit
>>> broker.conf as you need
>>> tar -cO * | dd
>>> of=/rhev/data-center/mnt/192.168.1.115:_Virtual_ext35u36/$sdUUID/images/$conf_image_UUID/$conf_volume_UUID
>>> systemctl start ovirt-ha-broker
>>>
>>>
>>>>
>>>>
>>>>
>>>>
>>>> Il 05/11/2015 18.44, Simone Tiraboschi ha scritto:
>>>>
>>>> Can you please paste here the content of
>>>> /var/lib/ovirt-hosted-engine-ha/broker.conf ?
>>>> eventually make it anonymous if you prefer
>>>>
>>>>
>>>>
>>>> On Thu, Nov 5, 2015 at 6:42 PM, Stefano Danzi <s.danzi at hawai.it> wrote:
>>>>>
>>>>> After upgrading from 3.5 to 3.6 Hosted engine notifications stop to
>>>>> work.
>>>>> I think that broker.conf was lost during upgrade.
>>>>>
>>>>> I found this: https://bugzilla.redhat.com/show_bug.cgi?id=1260757
>>>>> But I don't undertand how to change the configuration now.
>>>>> _______________________________________________
>>>>> Users mailing list
>>>>> Users at ovirt.org
>>>>> http://lists.ovirt.org/mailman/listinfo/users
>>>>
>>>>
>>>>
>>>>
>>>
>>>
>>>
>>> _______________________________________________
>>> Users mailing list
>>> Users at ovirt.org
>>> http://lists.ovirt.org/mailman/listinfo/users
>>>
>>
>>
>>
>> --
>> Sandro Bonazzola
>> Better technology. Faster innovation. Powered by community collaboration.
>> See how it works at redhat.com



More information about the Users mailing list