From owner-freebsd-questions@FreeBSD.ORG Thu Mar 31 01:59:03 2005 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AF32416A4CE for ; Thu, 31 Mar 2005 01:59:03 +0000 (GMT) Received: from fusion.vilot.net (vilot.com [64.246.32.88]) by mx1.FreeBSD.org (Postfix) with ESMTP id 65A0A43D2D for ; Thu, 31 Mar 2005 01:59:03 +0000 (GMT) (envelope-from tom@vilot.com) Received: from vilot.com (c-24-8-184-241.client.comcast.net [24.8.184.241]) (authenticated bits=0) by fusion.vilot.net (8.13.1/8.12.9) with ESMTP id j2V1x2EQ022975; Wed, 30 Mar 2005 19:59:02 -0600 (CST) (envelope-from tom@vilot.com) Received: by vilot.com (sSMTP sendmail emulation); Wed, 30 Mar 2005 17:52:35 -0700 From: "Tom Vilot" Date: Wed, 30 Mar 2005 17:52:35 -0700 To: Abu Khaled Message-ID: <20050331005234.GB87058@vilot.com> References: <001101c53588$5f4503b0$6401a8c0@GRANT> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.1i Organization: 3Dimentia, Inc. Mailer: mutt for FreeBSD cc: Grant Peel cc: freebsd-questions@freebsd.org Subject: Re: Restart Networks X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 31 Mar 2005 01:59:04 -0000 > > On linux variants, you can run a command like: > > /etc/init.d/network restart > > that will restart network serverices ie, reinitialize ifconfig setup, reload > > IPs for a local NIC. > > > > Does anyone know if there is a similar command or command set in > > FreeBSD? You can also try just restarting the interface. On my laptop, for example, running FreeBSD 5.3, I re-start the ndis based network interface thusly: /etc/rc.d/ndis restart where that script is: ---------------------------------------------------------------------- #!/bin/sh # By Mario S. 2004 # PROVIDE: ndis # KEYWORD: FreeBSD . /etc/rc.subr name="ndis" start_precmd="" stop_precmd="" start_cmd="ndis_yastart" stop_cmd="ndis_yastop" ndis_yastart() { echo "Starting NDIS network driver: " sysctl dev.ndis.0.SSID="myssid" ifconfig ndis0 192.168.1.234 route add default 192.168.1.1 echo "Done" } ndis_yastop() { ifconfig ndis0 down kldunload if_ndis killall dhclient } load_rc_config $name run_rc_command "$1" ----------------------------------------------------------------------