I wonder if anyone can help? I need to put 1,500,000 IP entries into a table. My box is a P3-450 CPU, 1.5G of RAM, 6G IDE HD, 2NIC, Openbsd 3.4 with custom kernel running a bridge with PF. So far works great except when I tried to load a large list of IPs into a PF table.
So far I have managed to load 800,000 IPs into a table when I set nkmempages to 32768. 49152 & 65536 fails to boot with:
panic: uvm_km_suballoc: unable to allocate space in parent map
Stopped at Debugger+0x4: leave
RUN AT LEAST 'trace' AND 'ps' AND INCLUDE OUTPUT WHEN REPORTING THIS PANIC!
DO NOT EVEN BOTHER REPORTING THIS WITHOUT INCLUDING THAT INFORMATION!
ddb> trace
Debugger(10000000,0,d02d3f60,d01d5fcf,d02734a0) at Debugger+0x4
panic(d0240e80,ffffffff,0,41727,d02d1010) at panic+0x87
uvm_km_suballoc(d02734a0,d02d3f60,d02d3f64,10000000,2) at uvm_km_suballoc+0x5b
mbinit(d02d1010,2d1000,2d8000,0,0) at mbinit+0x32
main(0,0,0,0,0) at main+0x54
ddb> ps
PID PPID PGRP UID S FLAGS WAIT COMMAND
ddb>
pfctl -t spammers -Tr -f out1 1 table created. 800000 addresses added.
Loading 900,000 will fail with output: pfctl -t spammers -Tr -f out 1 table created. pfctl: Cannot allocate memory.
If don't increase nkmempages, I will get "pfctl: Cannot allocate memory." and sometimes "panic: malloc: out of space in kmem_map" when I tried to update the table.
Is there anything I can do, to allow me to put more entries into PF tables? 1,500,000 entries and beyond?
I still see lot of physical RAM free when loaded the 800,000 entries, about 1.2G free. Is there anyway to utilise those RAM to PF tables?
Please help.
Also please let me know if you require any data you want me to capture.
Thanks in advance!
Kent.
Enc. 1) panic when loading data: time pfctl -t spammers -Tr -f anotherdata 2) dmesg
panic: malloc: out of space in kmem_map
Stopped at Debugger+0x4: leave
RUN AT LEAST 'trace' AND 'ps' AND INCLUDE OUTPUT WHEN REPORTING THIS PANIC!
DO NOT EVEN BOTHER REPORTING THIS WITHOUT INCLUDING THAT INFORMATION!
ddb> trace
Debugger(15,15000,0,3fff,e91e2244) at Debugger+0x4
panic(d045bb20,d0546468,15000,0,15000) at panic+0x87
malloc(15000,62,0,e8d850a0,0) at malloc+0x29f
amap_extend(e927952c,2800000,e917dc38,e91c9c84) at amap_extend+0x17b
uvm_map(e917db98,e9284f24,2800000,0,0,0,0,1b0713) at uvm_map+0x31b
sys_obreak(e91c9c84,e9284f88,e9284f7c,d0268927,41029000) at sys_obreak+0x7d
syscall() at syscall+0x21d
--- syscall (number 17) ---
0x1c01e3d5:
ddb> ps
PID PPID PGRP UID S FLAGS WAIT COMMAND
* 7328 4207 7328 0 2 0x4006 pfctl
22173 31674 31674 0 3 0x44186 ttyin login_passwd
4207 2447 4207 0 3 0x4086 wait bash
2447 29311 2447 0 3 0x4086 pause csh
31674 1 31674 0 3 0x4086 netio login
17952 1 17952 0 3 0x4086 ttyin getty
32272 1 32272 0 3 0x4086 ttyin getty
29311 29798 29311 0 3 0x184 select sshd
28404 1 28404 0 3 0x84 select cron
29798 1 29798 0 3 0x84 select sshd
17850 1 17850 0 3 0x84 bpf pflogd
30914 17109 17109 73 3 0x184 select syslogd
17109 1 17109 0 3 0x84 netio syslogd
9 0 0 0 3 0x100204 usbtsk usbtask
8 0 0 0 3 0x100204 usbevt usb0
7 0 0 0 3 0x100204 crypto_wa crypto
6 0 0 0 3 0x100204 aiodoned aiodoned
5 0 0 0 3 0x100204 syncer update
4 0 0 0 3 0x100204 cleaner cleaner
3 0 0 0 3 0x100204 reaper reaper
2 0 0 0 3 0x100204 pgdaemon pagedaemon
1 0 1 0 3 0x4084 wait init
0 -1 0 0 3 0x80204 scheduler swapper
OpenBSD 3.4-stable (FW) #6: Fri Jan 9 18:46:51 GMT 2004
[EMAIL PROTECTED]:/usr/src/sys/arch/i386/compile/FW
cpu0: disabling processor serial number
cpu0: Intel Pentium III ("GenuineIntel" 686-class, 512KB L2 cache) 448 MHz
cpu0: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,MMX,FXSR,SIMD
real mem = 1610133504 (1572396K)
avail mem = 1491243008 (1456292K)
using 4278 buffers containing 80609280 bytes (78720K) of memory
mainbus0 (root)
bios0 at mainbus0: AT/286+(71) BIOS, date 03/26/01, BIOS32 rev. 0 @ 0xfd7e3
pcibios0 at bios0: rev. 2.1 @ 0xfd680/0x980
pcibios0: PCI IRQ Routing Table rev. 1.0 @ 0xfdf00/224 (12 entries)
pcibios0: PCI Interrupt Router at 000:18:0 ("Intel 82371FB PCI-ISA" rev 0x00)
pcibios0: PCI bus #2 is the last bus
bios0: ROM list: 0xc0000/0x8000 0xc8000/0x1800 0xc9800/0x1000
pci0 at mainbus0 bus 0: configuration mode 1 (no bios)
pchb0 at pci0 dev 0 function 0 "Intel 82440BX PCI-AGP" rev 0x00
ppb0 at pci0 dev 1 function 0 "Intel 82440BX AGP" rev 0x00
pci1 at ppb0 bus 1
ppb1 at pci1 dev 15 function 0 "DEC 21150-BC PCI-PCI" rev 0x06
pci2 at ppb1 bus 2
fxp0 at pci2 dev 4 function 0 "Intel 82557" rev 0x08: irq 5, address 00:02:b3:07:c2:b2
inphy0 at fxp0 phy 1: i82555 10/100 media interface, rev. 4
"Adaptec AIC-7896/7 U2" rev 0x00 at pci0 dev 12 function 0 not configured
"Adaptec AIC-7896/7 U2" rev 0x00 at pci0 dev 12 function 1 not configured
fxp1 at pci0 dev 14 function 0 "Intel 82557" rev 0x08: irq 10, address 00:d0:b7:a9:b4:72
inphy1 at fxp1 phy 1: i82555 10/100 media interface, rev. 4
pcib0 at pci0 dev 18 function 0 "Intel 82371AB PIIX4 ISA" rev 0x02
pciide0 at pci0 dev 18 function 1 "Intel 82371AB IDE" rev 0x01: DMA, channel 0 wired to compatibility, channel 1 wired to compatibility
wd0 at pciide0 channel 0 drive 0: <QUANTUM FIREBALL SE6.4A>
wd0: 16-sector PIO, LBA, 6149MB, 13328 cyl, 15 head, 63 sec, 12594960 sectors
wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2
drive at pciide0 channel 1 drive 0 not configured
pciide0: channel 1 disabled (no drives)
"Intel 82371AB USB" rev 0x01 at pci0 dev 18 function 2 not configured
"Intel 82371AB Power Mgmt" rev 0x02 at pci0 dev 18 function 3 not configured
vga1 at pci0 dev 20 function 0 "Cirrus Logic CL-GD5480" rev 0x23
wsdisplay0 at vga1: console (80x25, vt100 emulation)
wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
isa0 at pcib0
isadma0 at isa0
pckbc0 at isa0 port 0x60/5
pckbd0 at pckbc0 (kbd slot)
pckbc0: using irq 1 for kbd slot
wskbd0 at pckbd0: console keyboard, using wsdisplay0
pcppi0 at isa0 port 0x61
sysbeep0 at pcppi0
npx0 at isa0 port 0xf0/16: using exception 16
pccom0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
pccom0: console
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 4040 netmask 4460 ttymask 4462
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
-- Kent Ho, Senior Systems Engineer, Outblaze Ltd. www.outblaze.com Tel:+(852)25341218 Fax:+(852)28516779
