From owner-freebsd-hackers@FreeBSD.ORG Fri Jun 13 13:22:54 2003 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D95B537B404 for ; Fri, 13 Jun 2003 13:22:54 -0700 (PDT) Received: from mail.econolodgetulsa.com (mail.econolodgetulsa.com [198.78.66.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 37EE943F93 for ; Fri, 13 Jun 2003 13:22:52 -0700 (PDT) (envelope-from user@mail.econolodgetulsa.com) Received: from mail (mail [198.78.66.163])h5DKMqnW003003 for ; Fri, 13 Jun 2003 13:22:52 -0700 (PDT) (envelope-from user@mail.econolodgetulsa.com) Date: Fri, 13 Jun 2003 13:22:52 -0700 (PDT) From: Josh Brooks To: freebsd-hackers@freebsd.org Message-ID: <20030613131940.J87307-100000@mail.econolodgetulsa.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Subject: How do I see open sockets count (kern.ipc.maxsockets, but status) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 13 Jun 2003 20:22:55 -0000 Hello, When I run out of files, I can see how many files are actually open by looking at the kern.openfiles sysctl. This makes it easy to see if I am hitting my limit or not. However, I am experiencing "No buffer space available" errors, and since I am not running out of mbufs: netstat -m 1728/2496/34816 mbufs in use (current/peak/max): 1714 mbufs allocated to data 14 mbufs allocated to packet headers 677/1430/8704 mbuf clusters in use (current/peak/max) 3484 Kbytes allocated to network (13% of mb_map in use) 0 requests for memory denied 0 requests for memory delayed 0 calls to protocol drain routines My natural choice is to increase: kern.ipc.maxsockets: 16424 But before I do that, I want to see how many I am currently using. So, whereas with open files I would simply check the kern.openfiles sysctl, how do I check how many sockets I currently have open ? Thanks you.