From owner-freebsd-questions@FreeBSD.ORG Sun Apr 2 17:41:57 2006 Return-Path: X-Original-To: questions@freebsd.org 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 00FBA16A41F for ; Sun, 2 Apr 2006 17:41:57 +0000 (UTC) (envelope-from kdk@daleco.biz) Received: from ezekiel.daleco.biz (southernuniform.com [66.76.92.18]) by mx1.FreeBSD.org (Postfix) with ESMTP id EDC2343D4C for ; Sun, 2 Apr 2006 17:41:48 +0000 (GMT) (envelope-from kdk@daleco.biz) Received: from [192.168.2.2] ([69.27.149.254]) by ezekiel.daleco.biz (8.13.4/8.13.1) with ESMTP id k32HeV1V056392; Sun, 2 Apr 2006 12:40:52 -0500 (CDT) (envelope-from kdk@daleco.biz) Message-ID: <44300C85.20500@daleco.biz> Date: Sun, 02 Apr 2006 12:40:21 -0500 From: Kevin Kinsey User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.12) Gecko/20060127 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Norberto Meijome References: <5ceb5d550603230635l11871c9erea5ca2018635a585@mail.gmail.com> <20060326220541.2664b51e@localhost> In-Reply-To: <20060326220541.2664b51e@localhost> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: questions@freebsd.org, Wayne Subject: Re: Linux migration X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Apr 2006 17:41:57 -0000 Norberto Meijome wrote: >On Thu, 23 Mar 2006 14:47:54 +0000 >Wayne wrote: > > > >>Also another thing that I was thinking about since my original mail, >>things like chkconfig and commands like say 'service network >>restart'. Does such a thing like a "redhat layer" type project exist >>so that emgineers who must convert to freebsd have as much of the day >>to day commands available to them while retraining? >> >> > >RHE has its ways, fbsd has others. it's not that hard to carry over >really...you can make an simple cheatsheet for your engineeres. > > Or, see below. >IMHO, it's quite simple in Freebsd: > - if service is part of the base os, script is located in /etc/rc.d > - if service is something you have installed, it's located >in /usr/local/etc/rc.d > >Likewise, configuration for base services go in /etc, configuration for >ports goes in /usr/local/etc/ > >( If you can't tell what is part of the base OS or what is added...you >may have other issues at hand :) ) > >Since you don't have the SysV style scripts in BSD, what gets run >(base-system or added-from-ports) is defined in /etc/rc.conf (default >options for base services are in /etc/defaults/rc.conf . options for >services from ports are usually in the port documentation or the >startup script) > >Regardless of this, scripts in either /etc/rc.d or /usr/local/etc/rc.d/ >take the same params as RHE : start, stop, restart, status (+ custom >ones in some services/ports). > >so 'service network restart' = /etc/rc.d/netif restart > > Very good --- and, to ease transition: echo "alias 'service network restart' echo 'Did you mean /etc/rc.d/netif restart?' " >> ~/.cshrc Of course, two issues: shell globbing and the fact that they'll be expecting bash. Probably the former is of more consequence, as neither sh/bash nor csh/tcsh seem to want to accept spaces in commands. Bash is available in ports, so using it for wheel level accounts should be fine; the OP should be cautioned about replacing root's shell, though (Bad Idea(tm), AFAIK). Nonetheless, it might be a good idea to hack together some kind of reminder script for some of the RH commands; note, as a somewhat related example, how many FTPD's accept both "ls" and "dir" .... You could (and I have, before) alias "RHcommand" "FBSDequivalent", but that ends up not teaching anybody anything, and adds a layer of murk between the user and the OS; a layer that is not needed and detrimental for the most part. Shouldn't take any major corporate effort, and could be quite helpful. My $0.02, Kevin Kinsey -- My favorite sandwich is peanut butter, baloney, cheddar cheese, lettuce and mayonnaise on toasted bread with catsup on the side. -- Senator Hubert Humphrey