Return-Path: william@bourbon.usc.edu Delivery-Date: Thu Oct 30 11:32:52 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on merlot.usc.edu X-Spam-Level: X-Spam-Status: No, score=-2.4 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.3 Received: from bourbon.usc.edu (bourbon.usc.edu [128.125.9.75]) by merlot.usc.edu (8.14.1/8.14.1) with ESMTP id m9UIWqjV005909 for ; Thu, 30 Oct 2008 11:32:52 -0700 Received: from bourbon.usc.edu (localhost.localdomain [127.0.0.1]) by bourbon.usc.edu (8.14.2/8.14.1) with ESMTP id m9UIiTJt012538 for ; Thu, 30 Oct 2008 11:44:29 -0700 Message-Id: <200810301844.m9UIiTJt012538@bourbon.usc.edu> To: cs551@merlot.usc.edu Subject: Re: gethostbyname giving error Date: Thu, 30 Oct 2008 11:44:29 -0700 From: Bill Cheng Someone wrote: > Does a beacon node get its hostname from the startup configuration fle > or by gethostname()? A node first calls gethostname() and then compare it with what's in the startup configuration to determine if it is a beacon node. -- Bill Cheng // bill.cheng@usc.edu On Thu, Oct 30, 2008 at 8:53 AM, Bill Cheng wrote: > Someone wrote: > > > gethostbyname is returning null, saying Too many open files. Please help. > > If you write a small program with just a call to gethostbyname() > in it, I assume that works. Therefore, the problem is not > gethostbyname(). May be you have too many files/sockets opened. > Do you know how many files/sockets you have opened? > > In general, you need to know how much resources you are using. > -- > Bill Cheng // bill.cheng@usc.edu