netstat: sysctl: net.inet.tcp.stats: Cannot allocate memory

From: Vicky Shrestha (mail_at_vickysh.wlink.com.np)
Date: 05/26/05

  • Next message: Timofey V. Chernousov: "Re: best sollution (and also simple) to guarantee a bandwidth"
    To: freebsd-isp@freebsd.org
    Date: Thu, 26 May 2005 23:40:15 +0545
    
    

    Dear all,

    I am running FreeBSD 5.4-STABLE and I have a problem with netstat. I cannot
    see the tcp sockets stats using netstat -p tcp or netstat command. When using
    "netstat -s" command I get "netstat: sysctl: net.inet.tcp.stats: Cannot
    allocate memory"

    At first I thought it was a problem with netstat binary ,however even after
    copying binary from the other working server with same release of FreeBSD ,
    it didn't work.

    The only change I made was to built a new kernel with the following options:
    # IPSEC
    options IPSEC #IP security
    options IPSEC_ESP #IP security (crypto; define w/ IPSEC)

    #IPFW
    options IPFIREWALL
    options IPDIVERT

    I also do cvsup to sync the src and ports, I think the netstat binary and
    kernel is out of sync however, when I do make
    inside /usr/src/usr.bin/netstat/ it gives me the following errors:

    Warning: Object directory not changed from original /usr/src/usr.bin/netstat
    cc -O -pipe -DIPSEC -DINET6 -Wsystem-headers -Wall -Wno-format-y2k
    -Wno-uninitialized -c inet.c
    inet.c:54:29: netinet/ip_carp.h: No such file or directory
    inet.c: In function `tcp_stats':
    inet.c:467: error: structure has no member named `tcps_sack_sboverflow'
    inet.c:467: error: structure has no member named `tcps_sack_sboverflow'
    inet.c: In function `carp_stats':
    inet.c:536: error: storage size of 'carpstat' isn't known
    inet.c:536: error: storage size of 'zerostat' isn't known
    inet.c:537: error: invalid application of `sizeof' to incomplete type
    `carpstats'
    inet.c:536: warning: unused variable `carpstat'
    inet.c:536: warning: unused variable `zerostat'
    *** Error code 1

    Stop in /usr/src/usr.bin/netstat.

    How can I resolve this issue, help and pointers to the web will be
    appreciated.

    -- 
    With regards,
    Vicky Shrestha
    System Director
    WorldLink Communications
    Jawalakhel , Kathmandu, Nepal
    _______________________________________________
    freebsd-isp@freebsd.org mailing list
    http://lists.freebsd.org/mailman/listinfo/freebsd-isp
    To unsubscribe, send any mail to "freebsd-isp-unsubscribe@freebsd.org"
    

  • Next message: Timofey V. Chernousov: "Re: best sollution (and also simple) to guarantee a bandwidth"