Bug 987335 - [supervdsm] supervdsm crashes when parsing misformed ip rule
[supervdsm] supervdsm crashes when parsing misformed ip rule
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: vdsm (Show other bugs)
x86_64 Unspecified
unspecified Severity high
: ---
: 3.3.0
Assigned To: Assaf Muller
Martin Pavlik
: Regression
Depends On:
  Show dependency treegraph
Reported: 2013-07-23 05:36 EDT by Elad
Modified: 2016-02-10 14:48 EST (History)
11 users (show)

See Also:
Fixed In Version: is8
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2014-01-21 11:29:24 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: Network
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
amuller: needinfo-

Attachments (Terms of Use)
logs (2.52 MB, application/x-gzip)
2013-07-23 05:36 EDT, Elad
no flags Details

External Trackers
Tracker ID Priority Status Summary Last Updated
oVirt gerrit 17425 None None None Never

  None (edit)
Description Elad 2013-07-23 05:36:10 EDT
Created attachment 777263 [details]

Description of problem:
supervdsm cannot handle with wrong ip rule, it crashes. We think that 

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce: 
1. have a block pool with 2 hosts and 2 data domains on different storage servers
2. run a vm on each host
3. block connectivity from HSM host to the non-master storage domain with iptables
4. maintenance SPM, wait for the other host to take SPM
5. retrieve connectivity between SPM to non-master SD

Actual results:
supervdsm crashes because a misformed ip rule:

MainThread::ERROR::2013-07-22 15:04:07,942::supervdsmServer::403::SuperVdsm.Server::(main) Could not start Super Vdsm
Traceback (most recent call last):
  File "/usr/share/vdsm/supervdsmServer.py", line 391, in main
  File "/usr/share/vdsm/sourceRouteThread.py", line 60, in subscribeToInotifyLoop
    SOURCE_ROUTES_FOLDER + '/' + filePath)
  File "/usr/share/vdsm/sourceRouteThread.py", line 36, in process_IN_CLOSE_WRITE_filePath
  File "/usr/share/vdsm/sourceRoute.py", line 171, in remove
    rules = self._getRules(self.device)
  File "/usr/share/vdsm/sourceRoute.py", line 150, in _getRules
    allRules = [Rule.fromText(entry) for entry in ruleList()]
  File "/usr/lib64/python2.6/site-packages/vdsm/ipwrapper.py", line 147, in fromText
    raise ValueError('The length of a textual representation of a '
ValueError: The length of a textual representation of a rule must be odd

Expected results:
supervdsm should continue to run 

Additional info:
Comment 2 Elad 2013-07-23 06:26:25 EDT
Please do not refer to 'We think that' in the description.
Comment 3 Assaf Muller 2013-07-23 11:03:32 EDT
I added a patch to VDSM that properly logs these types of errors.

I installed VDSM from master on the two hosts you gave me Elad. When you reproduce the error please upload the new logs here.
Comment 5 Dan Kenigsberg 2013-07-26 15:32:30 EDT
Assaf, I'm convinced. It is interesting which rule has caused this bug, but we should not die on finding a manually-concocted routing rule.
Comment 6 Martin Pavlik 2013-08-05 07:55:30 EDT
verified on IS8, supervdsm survives reproducer from BZ
Comment 7 Charlie 2013-11-27 19:30:14 EST
This bug is currently attached to errata RHBA-2013:15291. If this change is not to be documented in the text for this errata please either remove it from the errata, set the requires_doc_text flag to 
minus (-), or leave a "Doc Text" value of "--no tech note required" if you do not have permission to alter the flag.

Otherwise to aid in the development of relevant and accurate release documentation, please fill out the "Doc Text" field above with these four (4) pieces of information:

* Cause: What actions or circumstances cause this bug to present.
* Consequence: What happens when the bug presents.
* Fix: What was done to fix the bug.
* Result: What now happens when the actions or circumstances above occur. (NB: this is not the same as 'the bug doesn't present anymore')

Once filled out, please set the "Doc Type" field to the appropriate value for the type of change made and submit your edits to the bug.

For further details on the Cause, Consequence, Fix, Result format please refer to:


Thanks in advance.
Comment 8 errata-xmlrpc 2014-01-21 11:29:24 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.