[BusyBox 0003894]: sysctl is not parsing vlans (contains "." symbol)

bugs at busybox.net bugs at busybox.net
Mon Oct 27 12:38:30 UTC 2008


The following issue has been CLOSED 
====================================================================== 
http://busybox.net/bugs/view.php?id=3894 
====================================================================== 
Reported By:                nuclearcat
Assigned To:                BusyBox
====================================================================== 
Project:                    BusyBox
Issue ID:                   3894
Category:                   Other
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     closed
Resolution:                 open
Fixed in Version:           
====================================================================== 
Date Submitted:             06-28-2008 10:01 PDT
Last Modified:              10-27-2008 05:38 PDT
====================================================================== 
Summary:                    sysctl is not parsing vlans (contains "." symbol)
Description: 
if i add vlan to system, sysctl -a will fail on vlan interfaces

Example
sysctl: error: 'net.ipv4.conf.eth0.100.mc_forwarding' is an unknown key
sysctl: error: 'net.ipv4.conf.eth0.100.accept_redirects' is an unknown
key
sysctl: error: 'net.ipv4.conf.eth0.100.secure_redirects' is an unknown
key
sysctl: error: 'net.ipv4.conf.eth0.100.shared_media' is an unknown key
sysctl: error: 'net.ipv4.conf.eth0.100.rp_filter' is an unknown key
sysctl: error: 'net.ipv4.conf.eth0.100.send_redirects' is an unknown key

defaulthost ~ # ls /proc/sys/net/ipv4/conf/
all       eth0.100  ifb1      ppp1      ppp12     ppp15     ppp18    
ppp20     ppp23     ppp26     ppp3      ppp6      ppp9
default   eth1      lo        ppp10     ppp13     ppp16     ppp19    
ppp21     ppp24     ppp27     ppp4      ppp7
eth0      ifb0      ppp0      ppp11     ppp14     ppp17     ppp2     
ppp22     ppp25     ppp28     ppp5      ppp8

====================================================================== 

---------------------------------------------------------------------- 
 vda - 10-15-08 02:10  
---------------------------------------------------------------------- 
cat, does net/ipv4/conf/eth0/mc_forwarding exist too
along with net/ipv4/conf/eth0.100/mc_forwarding?

How do you create vlans? Give exact sequence of commands so I can
reproduce

 

---------------------------------------------------------------------- 
 nuclearcat - 10-15-08 02:40  
---------------------------------------------------------------------- 
yes, they both exists, eth0.100 is separate interface (even logically
linked to eth0)

vlan name depends on options in vconfig, but by default it makes
INTERACE.NUMBER

You need 802.1q enabled in kernel
then
vconfig add eth0 32

it must be enough 

---------------------------------------------------------------------- 
 vda - 10-15-08 02:45  
---------------------------------------------------------------------- 
Please try updated sysctl.c (attached). 

---------------------------------------------------------------------- 
 nuclearcat - 10-15-08 03:12  
---------------------------------------------------------------------- 
Doesn't work. I made sure, it is new binary:
pc busybox-1.12.1 # grep "sysctl_dots_to_slashes" busybox_unstripped
Binary file busybox_unstripped matches

pc busybox-1.12.1 # ./busybox sysctl -a >>/dev/null
sysctl: error reading key 'net.ipv4.route.flush': Permission denied
sysctl: error: 'net.ipv4.neigh.eth0.1.mcast_solicit' is an unknown key
sysctl: error: 'net.ipv4.neigh.eth0.1.ucast_solicit' is an unknown key
sysctl: error: 'net.ipv4.neigh.eth0.1.app_solicit' is an unknown key
sysctl: error: 'net.ipv4.neigh.eth0.1.retrans_time' is an unknown key
sysctl: error: 'net.ipv4.neigh.eth0.1.base_reachable_time' is an unknown
key


I notice sysctl from procps doing like this:
net.ipv4.conf.eth0.disable_xfrm = 0
net.ipv4.conf.eth0.disable_policy = 0
net.ipv4.conf.eth0.force_igmp_version = 0
net.ipv4.conf.eth0.promote_secondaries = 0
net.ipv4.conf.eth0/1.forwarding = 1
net.ipv4.conf.eth0/1.mc_forwarding = 0
net.ipv4.conf.eth0/1.accept_redirects = 1
net.ipv4.conf.eth0/1.secure_redirects = 1
net.ipv4.conf.eth0/1.shared_media = 1 

---------------------------------------------------------------------- 
 vda - 10-15-08 06:51  
---------------------------------------------------------------------- 
Try this newer one 

---------------------------------------------------------------------- 
 nuclearcat - 10-15-08 06:59  
---------------------------------------------------------------------- 
Thanks, it works fine. Tested by reading and writing values. 

---------------------------------------------------------------------- 
 vda - 10-27-08 05:38  
---------------------------------------------------------------------- 
Recently fixed in svn 

Issue History 
Date Modified   Username       Field                    Change               
====================================================================== 
06-28-08 10:01  nuclearcat     New Issue                                    
06-28-08 10:01  nuclearcat     Status                   new => assigned     
06-28-08 10:01  nuclearcat     Assigned To               => BusyBox         
10-15-08 02:09  vda            Note Added: 0013584                          
10-15-08 02:10  vda            Note Edited: 0013584                         
10-15-08 02:40  nuclearcat     Note Added: 0013594                          
10-15-08 02:45  vda            File Added: sysctl.c                         
10-15-08 02:45  vda            Note Added: 0013604                          
10-15-08 03:12  nuclearcat     Note Added: 0013614                          
10-15-08 06:51  vda            Note Added: 0013624                          
10-15-08 06:51  vda            File Deleted: sysctl.c                       
10-15-08 06:51  vda            File Added: sysctl.c                         
10-15-08 06:59  nuclearcat     Note Added: 0013634                          
10-27-08 05:38  vda            Status                   assigned => closed  
10-27-08 05:38  vda            Note Added: 0014324                          
======================================================================




More information about the busybox-cvs mailing list