KillFilter doesn't match due to dnsmasq upgrade

Bug #1179793 reported by Yufang Zhang
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
oslo-incubator
Fix Released
Undecided
Yufang Zhang

Bug Description

After upgrading dnsmasq on the compute nodes, nova-network make dnsmasq reload config file via KillFilter.

This problem is due to the readlink() implementation of python: when reading /proc/PID/exe, it doesn't stop at '\0', thus readlink() may return something like '/usr/sbin/dnsmasq\0\0\0\0324324242 (deleted)', while C's or Shell's readlink() return '/usr/sbin/dnsmasq' .

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to oslo-incubator (master)

Fix proposed to branch: master
Review: https://review.openstack.org/29053

Changed in oslo:
assignee: nobody → Yufang Zhang (yufang521247)
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to oslo-incubator (master)

Reviewed: https://review.openstack.org/29053
Committed: http://github.com/openstack/oslo-incubator/commit/ea78eecbd275fa7466e56d6eb0dc7a3c60f5b640
Submitter: Jenkins
Branch: master

commit ea78eecbd275fa7466e56d6eb0dc7a3c60f5b640
Author: Yufang Zhang <zhangyufang@360.cn>
Date: Tue May 14 14:58:19 2013 +0800

    Update KillFilter to stop at '\0' for readlink() function.

    Python's readlink() implementation doesn't stop at '\0' when reading
    file path. Thus after dnsmasq upgrade, it may return something like
    '/usr/sbin/dnsmasq\03453 (deleted)', while C's or Shell's readlink()
    return '/usr/sbin/dnsmasq'. This patch fixes this problem by cutting
    the readlink() results with '\0', so that KillFilter could get correct
    path.

    Bug 1179793

    Change-Id: I7354941e0508e019c8c9b63b87ad39f52ccb51ca

Changed in oslo:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in oslo:
milestone: none → havana-1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in oslo:
milestone: havana-1 → 2013.2
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.