On Thu, May 12, 2005 at 04:01:03PM -0600, Whyzzi wrote:
> I've got two files, hostname.vlan2 and ifconfig.vlan2, both contain
> basically the same information:
> 
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
> # cat /etc/hostname.vlan2
> inet 10.117.254.2 255.255.255.248 NONE vlan 2 vlandev fxp0
> # cat /etc/ifconfig.vlan2
> inet 10.117.254.2 255.255.255.248 vlan 2 vlandev fxp0
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
> 
> When I boot, the netmask of vlan2 is /29, which is what I expect
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
> vlan2: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1496
>         lladdr 00:d0:b7:5a:d1:ec
>         vlan: 2 parent interface: fxp0
>         inet6 fe80::2d0:b7ff:fe5a:d1ec%vlan2 prefixlen 64 scopeid 0x8
>         inet 10.117.254.2 netmask 0xfffffff8 broadcast 10.117.254.7
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
> 
> but when I destroy vlan2 and recreate it
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
> # ifconfig vlan2 destroy
> # ifconfig vlan2 create
> # ifconfig vlan2 `cat /etc/ifconfig.vlan2`
> # cat /etc/ifconfig.vlan2
> inet 10.117.254.2 255.255.255.248 vlan 2 vlandev fxp0
                   ^^^
                   netmask is missing.

correct is "inet 10.117.254.2 netmask 255.255.255.248 vlan 2 vlandev fxp0"

> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
> 
> I get /8 netmask, which is not correct
> It interprets the subnet mask as broadcast address. 
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
> # ifconfig vlan2
> vlan2: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1496
>         lladdr 00:d0:b7:5a:d1:ec
>         vlan: 2 parent interface: fxp0
>         inet6 fe80::2d0:b7ff:fe5a:d1ec%vlan2 prefixlen 64 scopeid 0x9
>         inet 10.117.254.2 netmask 0xff000000 broadcast 255.255.255.248
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
> 
> What syntax can I use to correct this? I am using a recent snapshot.
> 
> thank you very much!
> Peter Verhagen
> 
> # dmesg       
> OpenBSD 3.7-current (GENERIC) #110: Mon May  2 20:07:58 MDT 2005
>     [EMAIL PROTECTED]:/usr/src/sys/arch/i386/compile/GENERIC
> cpu0: Intel Pentium III ("GenuineIntel" 686-class) 864 MHz
> cpu0: 
> FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,MM
> X,FXSR,SSE          
> real mem  = 333946880 (326120K)                               
> avail mem = 297398272 (290428K)                               
> using 4102 buffers containing 16801792 bytes (16408K) of memory
> mainbus0 (root)               
> bios0 at mainbus0: AT/286+(19) BIOS, date 08/25/00, BIOS32 rev. 0 @
> 0xe7300
> apm0 at bios0: Power Management spec V1.2
> apm0: AC on, battery charge unknown                                   
> pcibios0 at bios0: rev 2.1 @ 0xe7300/0x8d00
> pcibios0: PCI IRQ Routing Table rev 1.0 @ 0xf6260/208 (11 entries)
> pcibios0: PCI Interrupt Router at 000:31:0 ("Intel 82801BA LPC" rev
> 0x00)
> pcibios0: PCI bus #1 is the last bus                                    
> bios0: ROM list: 0xc0000/0xa000 0xca000/0x1000 0xcb000/0x1000
> cpu0 at mainbus0                
> pci0 at mainbus0 bus 0: configuration mode 1 (no bios)
> pchb0 at pci0 dev 0 function 0 "Intel 82815 Hub" rev 0x02: rng active,
> 8Kb/sec
> vga1 at pci0 dev 2 function 0 "Intel 82815 Graphics" rev 0x02:
> aperture at 0x440
> 00000, size 0x4000000                     
> wsdisplay0 at vga1: console (80x25, vt100 emulation)
> wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
> ppb0 at pci0 dev 30 function 0 "Intel 82801BA AGP" rev 0x01
> pci1 at ppb0 bus 1                  
> fxp0 at pci1 dev 4 function 0 "Intel 82557" rev 0x08, i82559: irq 5,
> address
> d0:b7:5a:d1:ec              
> inphy0 at fxp0 phy 1: i82555 10/100 PHY, rev. 4
> fxp1 at pci1 dev 8 function 0 "Intel 82562" rev 0x01: irq 10, address
> 00:02:a5:5
> 2:f9:13       
> inphy1 at fxp1 phy 1: i82562EM 10/100 PHY, rev. 0
> fxp2 at pci1 dev 9 function 0 "Intel 82557" rev 0x08, i82559: irq 11,
> address 00
> :d0:b7:4f:a9:10               
> inphy2 at fxp2 phy 1: i82555 10/100 PHY, rev. 4
> ichpcib0 at pci0 dev 31 function 0 "Intel 82801BA LPC" rev 0x01
> pciide0 at pci0 dev 31 function 1 "Intel 82801BA IDE" rev 0x01: DMA,
> channel 0 w
> ired to compatibility, channel 1 wired to compatibility
> wd0 at pciide0 channel 0 drive 0: <WDC AC24300L>
> wd0: 16-sector PIO, LBA, 4112MB, 8421840 sectors
> wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2
> atapiscsi0 at pciide0 channel 1 drive 1                                       
> scsibus0 at atapiscsi0: 2 targets                                 
> cd0 at scsibus0 targ 0 lun 0: <COMPAQ, CD-ROM LTN485, KQA4> SCSI0
> 5/cdrom remova
> ble   
> cd0(pciide0:1:1): using PIO mode 4, DMA mode 2
> uhci0 at pci0 dev 31 function 4 "Intel 82801BA USB" rev 0x01: irq 10
> usb0 at uhci0: USB revision 1.0                               
> uhub0 at usb0             
> uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
> uhub0: 2 ports with 2 removable, self powered
> auich0 at pci0 dev 31 function 5 "Intel 82801BA AC97" rev 0x01: irq 5,
> ICH2 AC97
> ac97: codec id 0x41445360 (Analog Devices AD1885)
> ac97: codec features headphone, Analog Devices Phat Stereo
> audio0 at auich0                
> isa0 at ichpcib0
> isadma0 at isa0
> pckbc0 at isa0 port 0x60/5
> pckbd0 at pckbc0 (kbd slot)
> pckbc0: using irq 1 for kbd slot
> wskbd0 at pckbd0 (mux 1 ignored for console): console keyboard, using 
> wsdisplay0
> pcppi0 at isa0 port 0x61
> midi0 at pcppi0: <PC speaker>
> sysbeep0 at pcppi0
> lpt0 at isa0 port 0x378/4 irq 7
> npx0 at isa0 port 0xf0/16: using exception 16
> pccom0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
> pccom1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo
> fdc0 at isa0 port 0x3f0/6 irq 6 drq 2
> fd0 at fdc0 drive 0: 1.44MB 80 cyl, 2 head, 18 sec
> biomask f745 netmask ff65 ttymask ffe7
> pctr: 686-class user-level performance counters enabled
> mtrr: Pentium Pro MTRR support
> dkcsum: wd0 matched BIOS disk 80
> root on wd0a
> rootdev=0x0 rrootdev=0x300 rawdev=0x302
> vlan2: initialized with non-standard mtu 1496 (parent fxp0)
> vlan2: initialized with non-standard mtu 1496 (parent fxp0)
> 

-- 
:wq Claudio

Reply via email to