Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 8 Jan 2012 00:32:25 +0100
From:      Polytropon <freebsd@edvax.de>
To:        <leeoliveshackelford@surewest.net>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Installing FreeBSD ver. 8.2
Message-ID:  <20120108003225.dc64798a.freebsd@edvax.de>
In-Reply-To: <20120107150555.BYL92929@ms5.mc.surewest.net>
References:  <20120107150555.BYL92929@ms5.mc.surewest.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat,  7 Jan 2012 15:05:55 -0800 (PST), leeoliveshackelford@surewest.net wrote:
> (1)  Does anyone know how to get FreeBSD to read the
> motherboard name?  This name, on an xw4400, starts with
> "HP" followed by a eleven digits, and is given in Windows
> XP as "Full Computer Name" on the "Computer Name" tab
> of the "System Properties" window.  Among other purposes,
> this name is used by Novell network operating system to
> distinguish hosts on a subnet.

The OS provides the output of dmesg and maybe the
output of pciconf -lv, as well as the sysctl value
dev.acpi.0.%desc which may contain the required
information. However, I'm sure there is a program
in the ports collection that can be used to obtain
that kind of information.

Try:

	dmesg | grep "HP"
	sysctl -a | grep "HP"
	pciconf -lv | less

and see if there's such a number mentioned. Maybe
you can also use acpidump to retrieve that information
from the ACPI datasets.



> (2)  I cannot get the "find" command to locate files
> that I believe were installed at the time of sysinstall. 
> If I understand the Handbook correctly, when one runs
> "find" from the "/" directory, it is supposed to inspect
> all directories and subdirectories of all partitions,
> which it is not doing.  What concept am I missing here?

It would be easier to answer if you could provide
the find command line you've been running. :-)

See "man find" for more information. Basically,
"find / -name <namespec> -type f" should be sufficient
to access all partitions currently mounted to search
for <namespec> specified regular files.



> (3)  I thought that I would obtain a better understanding
> of the file system by running "man heir."  This command
> runs fine under "sh."  When I switch to my preferred shell,
> which is "bash," I type, and receive echo on the screen,
> "man hei."  As soon as I depress "r," the entire previously
> entered command echos to the screen, starting where the
> "r" should have appeared.  In checking the bash manual, it
> says that this response is correct for "control-r."  I
> could not find "non-shift-r" to be called out as a command. 
> Am I doing something wrong?  Is this a hardware bug?  Is
> this a software bug?  Is there something that needs to be
> defined or undefined in a configuration file?  

No, bash's configuration files provided after install
should be fine.

However, I think you have a typo. The command you're
intending to run is "man hier" ("hierarchy"). I've
tested both csh and bash here, both allow the command
to be entered without any interruption. When I type
"man hei" followed by Ctrl+R, I get the following
output: "(reverse-i-search)`': man hei".



> (4)  Not having very good luck with the "find" command,
> I thought I would try to use the "locate" command. 
> To use this command, one must create a database. 
> On www.us-webmasters.com, I read that this database
> could be constructed by running the command
> "#usr/libexec/locate.updatedb." 

The required task is usually executed by the system's
"night job" at 3:00 once a week. The script that will
be run is /etc/periodic/weekly/310.locate which you
could run manually. It will deal with the correct
call of /usr/libexec/locate.updatedb (instead of
running it as root!).



> I entered "cd" to get to this directory,  I entered
> "ls -lt" to read the directory and to verify that it
> contained a file named "locate.updatedb," which it did. 
> But when I entered "locate.updatedb" at the command
> prompt, I received the response "command not found." 
> Why can the command shell not find the command when
> "ls" clearly indicates it to exist in the current
> directory? 

Because execution of programs will only be done from
directories that are listed in $PATH. Check the
output of "echo $PATH" and you'll see that /usr/libexec
is not on that list. Intendedly.

You need to explicitely call such programs with the
full pathname, or from within the directory by prefixing
it with ./, e. g. "./locate.updatedb". However, doing
that as user or as root is not the correct way to perform
the required action. Call the script from /etc/periodic
instead to issue the building of the database now.



> How do I, as a user, distinguish an executable binary
> file from a data file? 

This is done by file attributes. The "executable" bit
must be set. Shells that call the ls command have the
ability to use a color scheme and a suffix to show
this directly:

% ll /etc/rc.conf /etc/rc.local 
-rw-r--r--  1 root  wheel  1563 Aug 24 06:43 /etc/rc.conf
-rwxr-----  1 root  wheel   602 Dec 11  2009 /etc/rc.local*

The asterisk indicates an executable, as well as the "x"
in the attributes field at the beginning. Furthermore,
the filename "/etc/rc.local" appears in bright green
color.

For the C shell, use

	setenv LSCOLORS ExGxdxdxCxDxDxBxBxegeg

and for bash, use

	export LSCOLORS="ExGxdxdxCxDxDxBxBxegeg"

to configure the colors. See "man ls" for details.
Oh, and the "ll" from my example is "ls -laFG" which
also includes the suffix to indicate the type of
file (directory, executable, pipe and so on).



> FreeBSD does not seem to use file extension labels for
> this purpose.

No, why should anyone do that? It's dangerous! :-)



> (5)  What device driver must be installed for the sound
> board to be able to receive a m.i.d.i. over u.s.b. signal? 
> This signal would be generated by a musician's keyboard,
> and would control a music synthesizer application, to be
> installed.  I could find no mention of this topic in the
> Handbook.

I'm not familiar with "modern" USB hardware for that
purpose. My MIDI times are long over, sorry. :-)



> (6)  In the book "Absolute FreeBSD" by Urban and Tiemann,
> I found a two line command to cause the bash prompt to
> display the file path and current directory.  Unfortunately,
> the text is quite unclear as to the name of the file to
> which these line are to be added, or the directory in which
> this file is located.  I assume  that somewhere there must
> be login configuration files, bearing each user's name,
> that give his or her shell configuration instructions. 
> What are the names of such files, and where are they
> located?

I've put my prompt configuration for bash in ~/.-bashrc
locally to my user, and the setting for a standard UNIX
prompt is

	export PS1="\u@\h:\w\$ "

which I have in that file. You can find more suggestions
at http://www.gilesorr.com/bashprompt/prompts/ for customizing
your bash prompt.



-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120108003225.dc64798a.freebsd>