Vinzenz Feenstra has posted comments on this change.
Change subject: agent: Send non-blocking uninstalled notification without python
......................................................................
Patch Set 1: (3 inline comments)
....................................................
File ovirt-guest-agent.spec
Line 127: /bin/systemctl stop ovirt-guest-agent.service > /dev/null 2>&1
Line 128:
Line 129: # Send an "uninstalled" notification to vdsm.
Line 130: VIRTIO=`grep "^device" %{_sysconfdir}/ovirt-guest-agent.conf |
awk '{ print $3; }'`
Line 131: if [ -w $VIRTIO ]
There is no logging done at all. I don't know any rpm which does logging...
Line 132: then
Line 133: # Non blocking uninstalled notification
Line 134: echo -e '{"__name__": "uninstalled"}\n' | dd of=$VIRTIO \
Line 135: oflag=nonblock status=noxfer conv=nocreat 1>& /dev/null
|| :
Line 130: VIRTIO=`grep "^device" %{_sysconfdir}/ovirt-guest-agent.conf |
awk '{ print $3; }'`
Line 131: if [ -w $VIRTIO ]
Line 132: then
Line 133: # Non blocking uninstalled notification
Line 134: echo -e '{"__name__": "uninstalled"}\n' | dd of=$VIRTIO \
This is an RPM spec file written specifically for Fedora/RHEL flavoured systems
... What other Linux?
conv=nocreat should simply not create a new file if the interface might maybe
exist
Line 135: oflag=nonblock status=noxfer conv=nocreat 1>& /dev/null
|| :
Line 136: fi
Line 137: fi
Line 138:
Line 131: if [ -w $VIRTIO ]
Line 132: then
Line 133: # Non blocking uninstalled notification
Line 134: echo -e '{"__name__": "uninstalled"}\n' | dd of=$VIRTIO \
Line 135: oflag=nonblock status=noxfer conv=nocreat 1>& /dev/null
|| :
if the previous statement fails it will ignore it and not make the rpm
uninstallation fail because preun failed.
Line 136: fi
Line 137: fi
Line 138:
Line 139: %postun common
--
To view, visit http://gerrit.ovirt.org/13612
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I8b2f84d56377ba4ba42ee206966b7b68deae7fc9
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-guest-agent
Gerrit-Branch: master
Gerrit-Owner: Vinzenz Feenstra <[email protected]>
Gerrit-Reviewer: Michal Skrivanek <[email protected]>
Gerrit-Reviewer: Vinzenz Feenstra <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches