Bug 185781

Summary: ifup clashes with $WINDOW environment variable
Product: [Fedora] Fedora Reporter: cody koeninger <codykoeninger>
Component: initscriptsAssignee: Bill Nottingham <notting>
Status: CLOSED DUPLICATE QA Contact: Brock Organ <borgan>
Severity: medium Docs Contact:
Priority: medium    
Version: 4CC: mitr, rvokal
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-03-18 14:54:37 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description cody koeninger 2006-03-17 22:47:50 UTC
Description of problem:

This one's hilarious . . . the ifup scripts (eg.
/etc/sysconfig/network-scripts/ifup-eth ) contain lines like:

ip route replace default ${SRC} ${WINDOW:+window $WINDOW} dev ${REALDEVICE}

And guess what?  GNU screen sets the environment variable $WINDOW to
the number of the current window you're in, so if you're in a non-zero
screen window, the tcp window gets set to a small value, killing network
performance.

Version-Release number of selected component (if applicable):
at least fc 2 and 4

How reproducible:
run screen, add a window (^t c), switch to that window (^t 1).

# netstat -rn

Kernel IP routing table
Destination     Gateway         Genmask         Flags   MSS Window  irtt
Iface
0.0.0.0         192.168.38.1    0.0.0.0         UG        0 0          0

# ifup bond0:9

# netstat -rn
Kernel IP routing table
Destination     Gateway         Genmask         Flags   MSS Window  irtt
Iface
0.0.0.0         192.168.38.1    0.0.0.0         UG        0 1          0


lo and behold, the tcp window is jacked.  Here's why:
# echo $WINDOW
1  (or whatever the number of your GNU screen window is)


Expected results:

the network scripts should rely on something as likely to cause name clashes as
$WINDOW


Additional info:

Comment 1 Miloslav Trmač 2006-03-18 14:54:37 UTC
Thank you for the bug report. This particular bug has already been reported
into our bug tracking system, but please feel free to report any further
bugs you find.

*** This bug has been marked as a duplicate of 174336 ***