Bug 857917 - Piranha TCP/UDP timeout new fields doesn't work
Piranha TCP/UDP timeout new fields doesn't work
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: piranha (Show other bugs)
6.3
x86_64 Linux
unspecified Severity high
: rc
: ---
Assigned To: Ryan O'Hara
Cluster QE
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-09-17 09:28 EDT by benjamin.girard
Modified: 2013-02-21 04:07 EST (History)
3 users (show)

See Also:
Fixed In Version: piranha-0.8.6-1.el6
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-02-21 04:07:57 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Only set timeouts when specified via HTTP GET method. (1.09 KB, patch)
2012-09-17 15:49 EDT, Ryan O'Hara
no flags Details | Diff
Only set timeout values when specified in HTTP GET method. (1.09 KB, patch)
2012-09-17 16:18 EDT, Ryan O'Hara
no flags Details | Diff

  None (edit)
Description benjamin.girard 2012-09-17 09:28:54 EDT
Description of problem: The new option field "TCP/UDP timeout" doesn't work


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

How reproducible:
When I set this options and I accept, the file lvs.conf isn't modified.
If I come back onto the piranha GUI the fields are blank. 

Steps to Reproduce:
1.Connect to piranha GUI
2.Set TCP timeout
3.Accept the modification
4.logout the gui
5 come back to the gui
6. fields blank

Actual results:
No effects on the timeout

Expected results:
Change the timeout.
Use "ipvsadm -lnc" to see the timeout

Additional info:
Comment 2 Ryan O'Hara 2012-09-17 11:53:29 EDT

(In reply to comment #0)
> Description of problem: The new option field "TCP/UDP timeout" doesn't work
> 
> 
> Version-Release number of selected component (if applicable):
> piranha-0.8.5-19
> 
> How reproducible:
> When I set this options and I accept, the file lvs.conf isn't modified.
> If I come back onto the piranha GUI the fields are blank. 
> 
> Steps to Reproduce:
> 1.Connect to piranha GUI
> 2.Set TCP timeout
> 3.Accept the modification
> 4.logout the gui
> 5 come back to the gui
> 6. fields blank

I've confirmed this bug exists. It appears that a timeout value is written to lvs.cf when the 'ACCEPT' button is clicked, but it is erased if you logout/login.

> Actual results:
> No effects on the timeout
> 
> Expected results:
> Change the timeout.
> Use "ipvsadm -lnc" to see the timeout

You should check the timeout values by using 'ipvsadm --list --timeout'.
Comment 4 Ryan O'Hara 2012-09-17 15:49:28 EDT
Created attachment 613764 [details]
Only set timeouts when specified via HTTP GET method.

This patch fixes the problem where timeout values (TCP timeout, TCP FIN timeout, and UDP timeout) will be lost if you reload the general setting page. The root of the problem is that the page will always get the timeout values via the HTTP GET method. The result is that the timeout value can and will be lost when you revisit the general settings page. This fix checks to see the timeout values are specified in the URL (GET method) and if so they are used. Else the values in the config file (if any) are used.
Comment 5 Ryan O'Hara 2012-09-17 15:54:05 EDT
(In reply to comment #4)
> Created attachment 613764 [details]
> Only set timeouts when specified via HTTP GET method.
> 
> This patch fixes the problem where timeout values (TCP timeout, TCP FIN
> timeout, and UDP timeout) will be lost if you reload the general setting
> page. The root of the problem is that the page will always get the timeout
> values via the HTTP GET method. The result is that the timeout value can and
> will be lost when you revisit the general settings page. This fix checks to
> see the timeout values are specified in the URL (GET method) and if so they
> are used. Else the values in the config file (if any) are used.

Sorry, this should read 'global settings' not 'general settings'.
Comment 6 Ryan O'Hara 2012-09-17 15:59:35 EDT
This bug can be tested by the following procedure:

1. Start piranha-gui

% servcie piranha-gui start

2. Open piranha gui in browser (default port 3636).
3. Go to 'Global Settings' and fill in a value for 'TCP timeout', click accept.
4. Click 'Control/Monitoring' tab to navigate away from 'Global Settings'.
5. Click 'Global Settings' tab.

The timeout value that was entered in step #3 should be gone. You can also use 'grep tcp_timeout /etc/sysconfig/ha/lvs.cf' after each step to see that the value is actually written to the file until you revisit the 'Global Settings' page (step #5).

With the patch, perform the same steps as described above. The timeout value should still be set when you revisit the 'Global Settings' page in setp #5.
Comment 7 Ryan O'Hara 2012-09-17 16:18:14 EDT
Created attachment 613770 [details]
Only set timeout values when specified in HTTP GET method.

Fix typo in previous patch.
Comment 11 errata-xmlrpc 2013-02-21 04:07:57 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.

http://rhn.redhat.com/errata/RHBA-2013-0351.html

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