<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>JW Network Consulting &#187; FreeBSD</title>
	<atom:link href="http://www.jwnetworkconsulting.com/category/freebsd/feed" rel="self" type="application/rss+xml" />
	<link>http://www.jwnetworkconsulting.com</link>
	<description>Watching the network so you don't have to.</description>
	<lastBuildDate>Mon, 15 Feb 2010 05:57:04 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Using &#8217;script&#8217; to record your session</title>
		<link>http://www.jwnetworkconsulting.com/freebsd/using-script-to-record-your-session</link>
		<comments>http://www.jwnetworkconsulting.com/freebsd/using-script-to-record-your-session#comments</comments>
		<pubDate>Sun, 01 Feb 2009 19:47:27 +0000</pubDate>
		<dc:creator>Jason</dc:creator>
				<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[documentation]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[unix]]></category>

		<guid isPermaLink="false">http://www.jwnetworkconsulting.com/?p=151</guid>
		<description><![CDATA[This is something that I ran across recently and that I probably should have known about before.  I was doing some testing for an upcoming upgrade and was getting annoyed because I didn&#8217;t have a good way to go review the results.  I knew there had to be something out there for this though, so [...]]]></description>
			<content:encoded><![CDATA[<p>This is something that I ran across recently and that I probably should have known about before.  I was doing some testing for an upcoming upgrade and was getting annoyed because I didn&#8217;t have a good way to go review the results.  I knew there had to be something out there for this though, so I did some digging.</p>
<p>Turns out that UNIX/Linux has a command named &#8217;script&#8217; which takes care of this for you.  I did a quick check and found that it&#8217;s part of the install on FreeBSD, Mac OS X and Ubuntu Linux.  It&#8217;s probably on nearly any *nix, but those are just the ones that I checked.  Running it is real hard.</p>
<div class="code panel" style="border-width: 1px;">
<div class="codeContent panelContent">
(jwood@Yardley.local)~<br />
(0 12:33:54 504) -> script foo.txt<br />
Script started, output file is foo.txt<br />
(jwood@Yardley.local)~<br />
(0 12:33:58 501) -> exit</p>
<p>Script done, output file is foo.txt<br />
(jwood@Yardley.local)~<br />
(0 12:34:01 505) ->
</p></div>
</div>
<p>The output is all logged into the file foo.txt.  So that&#8217;s neat and all, but what if I sudo to root?</p>
<div class="code panel" style="border-width: 1px;">
<div class="codeContent panelContent">
(jwood@Yardley.local)~<br />
(0 12:35:49 511) -> script foo.txt<br />
Script started, output file is foo.txt<br />
(jwood@Yardley.local)~<br />
(0 12:35:52 501) -> sudo -H -s<br />
Password:<br />
bash-3.2# cd temp/<br />
bash-3.2# ls<br />
.bash_profile           py-eve-test.py          zork<br />
.bashrc                 rubygems-1.1.0          zorki.hqx<br />
nagios-3.0.6            rubygems-1.1.0.tgz<br />
bash-3.2# cd ..<br />
bash-3.2# exit<br />
(jwood@Yardley.local)~<br />
(0 12:36:09 502) -> exit</p>
<p>Script done, output file is foo.txt<br />
(jwood@Yardley.local)~<br />
(0 12:36:12 512) ->
</p></div>
</div>
<p>Now, I to see what was recorded, I cat foo.txt.</p>
<div class="code panel" style="border-width: 1px;">
<div class="codeContent panelContent">
(jwood@Yardley.local)~<br />
(0 12:36:57 513) -> cat foo.txt<br />
Script started on Sun Feb  1 12:35:52 2009<br />
(jwood@Yardley.local)~<br />
(0 12:35:52 501) -> sudo -H -s<br />
Password:<br />
bash-3.2# cd temp/<br />
bash-3.2# ls<br />
.bash_profile           py-eve-test.py          zork<br />
.bashrc                 rubygems-1.1.0          zorki.hqx<br />
nagios-3.0.6            rubygems-1.1.0.tgz<br />
bash-3.2# cd ..<br />
bash-3.2# exit<br />
(jwood@Yardley.local)~<br />
(0 12:36:09 502) -> exit</p>
<p>Script done on Sun Feb  1 12:36:12 2009<br />
(jwood@Yardley.local)~<br />
(0 12:37:00 514) ->
</p></div>
</div>
<p>Perfect!  It recorded everything I did.  Or is it perfect?  In my case, not exactly.  You may notice that I have a fancy command prompt.  It&#8217;s got pretty colors and everything.  It seems that complicates things a bit.  When I open the file with vi, the problem becomes more apparent.</p>
<div class="code panel" style="border-width: 1px;">
<div class="codeContent panelContent">
(0 12:36:57 513) -> cat foo.txt<br />
Script started on Sun Feb  1 12:35:52 2009<br />
^[[0;31m(^[[1;32mjwood^[[1;37m@^[[1;32mYardley.local^[[0;31m)^[[1;34m~<br />
^[[0;31m(^[[0;31m0 ^[[0;36m12:35:52 ^[[0;32m501^[[0;31m) ^[[1;34m->^[[0m sudo -H -s<br />
Password:<br />
bash-3.2# cd temp/<br />
bash-3.2# ls<br />
.bash_profile           py-eve-test.py          zork<br />
.bashrc                 rubygems-1.1.0          zorki.hqx<br />
nagios-3.0.6            rubygems-1.1.0.tgz<br />
bash-3.2# cd ..<br />
bash-3.2# exit<br />
^[[0;31m(^[[1;32mjwood^[[1;37m@^[[1;32mYardley.local^[[0;31m)^[[1;34m~<br />
^[[0;31m(^[[0;31m0 ^[[0;36m12:36:09 ^[[0;32m502^[[0;31m) ^[[1;34m->^[[0m exit</p>
<p>Script done on Sun Feb  1 12:36:12 2009
</p></div>
</div>
<p>Notice that after I sudo to root, the command prompt is simplified and the text file suddenly becomes more legible.  All the stuff that I have going on in my bashrc file makes reading the text file a bit more complicated.  Obviously simplifying my command prompt will make this go away.  </p>
<p>Any how, its a pretty cool way to document what you are doing and what happened when while you were doing it.  Definitely something I will be using a lot more when I&#8217;m writing documentation</p>

<!-- start wp-tags-to-technorati 1.01 -->

<p class='technorati-tags'>Technorati Tags: <a class='technorati-link' href='http://technorati.com/tag/documentation' rel='tag' target='_self'>documentation</a>, <a class='technorati-link' href='http://technorati.com/tag/FreeBSD' rel='tag' target='_self'>FreeBSD</a>, <a class='technorati-link' href='http://technorati.com/tag/script' rel='tag' target='_self'>script</a>, <a class='technorati-link' href='http://technorati.com/tag/unix' rel='tag' target='_self'>unix</a></p>

<!-- end wp-tags-to-technorati -->
]]></content:encoded>
			<wfw:commentRss>http://www.jwnetworkconsulting.com/freebsd/using-script-to-record-your-session/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>FreeBSD 7.0 Build</title>
		<link>http://www.jwnetworkconsulting.com/consulting/freebsd-70-build</link>
		<comments>http://www.jwnetworkconsulting.com/consulting/freebsd-70-build#comments</comments>
		<pubDate>Mon, 13 Oct 2008 02:43:07 +0000</pubDate>
		<dc:creator>Jason</dc:creator>
				<category><![CDATA[Consulting]]></category>
		<category><![CDATA[FreeBSD]]></category>

		<guid isPermaLink="false">http://sysadmins.dyndns.org/?p=101</guid>
		<description><![CDATA[Introduction
This document contains basic instructions on building a system using FreeBSD 7.0.   				This covers security standards, configuration options, networking configuration, etc. 				The information used in this example probably doesn&#8217;t match your environment or hardware 				exactly.  Verify your network, hardware and other internal system build standards before 				using the information contained here.  [...]]]></description>
			<content:encoded><![CDATA[<h3>Introduction</h3>
<p>This document contains basic instructions on building a system using FreeBSD 7.0.   				This covers security standards, configuration options, networking configuration, etc. 				The information used in this example probably doesn&#8217;t match your environment or hardware 				exactly.  Verify your network, hardware and other internal system build standards before 				using the information contained here.  <strong>Use this document at your own risk.</strong></p>
<p>This document assumes technical knowledge of FreeBSD, especially in regards to kernel  				configuration (which is highly dependant on server hardware, application usage, and  				expected functionality.)</p>
<h3>Before You Begin</h3>
<p>Make sure that you have the following items completed and available for the installation:</p>
<ol>
<li>FreeBSD 7.0-RELEASE disc</li>
<li>Hardware has been updated with the correct configuration for its type  						(see hardware preparation documentation specific for the platform and model.)</li>
<li>Obtained server name and IP addresses</li>
</ol>
<h3>Operating System Installation</h3>
<ol>
<li>Boot from FreeBSD 7.0-RELEASE  installation media.  Accept the Boot Loader default when it is loaded.</li>
<li>Country Selection &#8211; United States</li>
<li>Choose &#8220;Custom&#8221; under the Main Installation Screen
<ol type="a">
<li>Select &#8220;Partition&#8221;
<ol type="i">
<li>Select free space and choose &#8220;A&#8221; to use the entire disk.  You will need to allocate disk differently 								    if you have particular storage requirements, such as direct attached storage.</li>
<li>Set the partition as bootable with &#8220;S&#8221;</li>
<li>Select &#8220;Q&#8221; to finish</li>
</ol>
</li>
</ol>
</li>
<li>When prompted on the Boot Manager Screen, select &#8220;Standard&#8221;</li>
<li>Select &#8220;Label&#8221; to begin assigning and labeling disk slices
<ol type="a">
<li>The following is an example.  I tend to make /var, /home and /opt separate slices so that if something fills that 							volume up, it doesn&#8217;t cause problems with the rest of the system.  Customize this as you need to.</li>
<li>As an example, use the following partition scheme:
<ul>
<li>swap &#8211; 512 MB</li>
<li>/ &#8211; 1024 MB</li>
<li>/usr &#8211; 8192 MB  (This can be more if needed, but I use 8192MB as a minimum)</li>
<li>/var &#8211; 1024 MB  (Running a large MySQL database will require an increase here)</li>
<li>/tmp &#8211; 512 MB</li>
<li>/home &#8211; 4096 MB</li>
<li>/opt &#8211; What ever is left.  I generally push large databases, applications or other data here so it doesn&#8217;t  								interfere with normal system operations.</li>
</ul>
</li>
<li>Hit &#8220;Q&#8221; to finish</li>
</ol>
</li>
<li>Choose &#8220;Distributions&#8221; under the Main Installation Screen
<ol type="a">
<li>Select only the following distributions:
<ul>
<li>Minimal</li>
<li>Custom</li>
<li>base</li>
<li>kernels</li>
<li>dict</li>
<li>doc</li>
<li>info</li>
<li>man</li>
<li>catman</li>
<li>proflibs</li>
<li>src &#8211; ALL</li>
<li>ports</li>
<li>local</li>
</ul>
</li>
<li>Back out to the Main Installation Screen</li>
</ol>
</li>
<li>Select &#8220;Media&#8221;
<ol>
<li>Choose &#8220;CD-ROM&#8221;</li>
</ol>
</li>
<li>Select &#8220;Commit&#8221; to finalize these settings
<ol type="a">
<li>Verify the settings by choosing &#8220;Yes&#8221;</li>
<li>The operating system will now be installed from CD-ROM</li>
</ol>
</li>
<li>After installation, when prompted to set last options, choose &#8220;Yes&#8221;
<ol type="a">
<li>Set root password</li>
<li>Set the time zone.  I use the Pacific time zone in the US as an example here.
<ol type="i">
<li>Select &#8220;No&#8221; when asked to set the clock to UTC</li>
<li>Select America &#8211; North and South</li>
<li>United States</li>
<li>Pacific Time &#8211; Confirm abbreviation of the time zone</li>
</ol>
</li>
</ol>
</li>
<li>Configure &#8220;Networking&#8221;
<ol type="a">
<li>Enable sshd</li>
<li>Select &#8220;Interfaces&#8221;
<ol type="i">
<li>Select interface you wish to configure</li>
<li>Do not enable Ipv6 (unless you need it)</li>
<li>Do not enable DHCP (unless you need it)</li>
<li>Enter hostname</li>
<li>Enter domain name</li>
<li>Enter Gateway &#8211; Appropriate gateway for the network you are on</li>
<li>Enter DNS server(s)</li>
<li>Enter IP address and subnet mask</li>
<li>Select Yes to bring up the interface</li>
<li>Exit back up out of Interfaces</li>
</ol>
</li>
<li>Configure &#8220;Startup&#8221;
<ol type="i">
<li>Unselect &#8220;quotas&#8221;</li>
</ol>
</li>
</ol>
</li>
<li>Select &#8220;Exit&#8221; twice, followed by &#8220;Exit Install&#8221;, then &#8220;Yes&#8221;</li>
<li>The server will be automatically rebooted, finishing the installation</li>
</ol>
<h3>Operating System Configuration</h3>
<ol>
<li>Log into the server as root</li>
<li>vi /etc/rc.conf and ensure the following options are set:
<ul>
<li>check_quotas=&#8221;NO&#8221;</li>
<li>defaultrouter=&#8221;x.x.x.x&#8221;</li>
<li>hostname=&#8221;hostname&#8221;</li>
<li>ifconfig_=&#8221;x.x.x.x netmask x.x.x.x&#8221;</li>
<li>xntpd_enable=&#8221;YES&#8221;</li>
<li>xntpd_program=&#8221;ntpd&#8221;</li>
<li>xntpd_flags=&#8221;-c /etc/ntpd.conf -p /var/run/ntpd.pid&#8221;</li>
</ul>
</li>
<p>Note:	Instances of &#8220;x.x.x.x&#8221; should be replaced with the proper IP address or network mask</p>
<li>vi /etc/resolv.conf and ensure the following lines are set:
<ul>
<li>domain	domain.com</li>
<li>nameserver	x.x.x.x</li>
<li>nameserver	x.x.x.x</li>
<li>search	search.com domains.com</li>
</ul>
</li>
<li>Configure NTP
<ol type="a">
<li>ntpdate local.time.server</li>
<li>vi /etc/ntpd.conf, erase all contents (if any) and insert the following:
<ul>
<li>server server 0.north-america.pool.ntp.org</li>
<li>server server 1.north-america.pool.ntp.org</li>
<li>server server 2.north-america.pool.ntp.org</li>
<li>driftfile /etc/ntpd/drift</li>
<li>multicastclient</li>
<li>broadcastdelay  0.008</li>
<li>restrict X.X.X.X mask X.X.X.X nomodify notrap</li>
</ul>
</li>
</ol>
</li>
<li>Configure the message of the day (MOTD) to something appropriate</li>
<li>run &#8220;chpass&#8221;
<ol type="a">
<li>Change &#8220;Charlie &amp;&#8221; to read &#8220;HOSTNAME &amp;&#8221;</li>
</ol>
</li>
<li>Disable unneeded terminals
<ol type="a">
<li>vi /etc/ttys</li>
<li>Comment out (or delete) everything in the Virtual Terminal section  							except the following ttyvs:
<ul>
<li>ttyv0</li>
<li>ttyv1</li>
<li>ttyv2</li>
</ul>
</li>
<li>Save and quit vi</li>
<li>killall -HUP init</li>
</ol>
</li>
<li>Install basic packages
<ol type="a">
<li>pkg_add -r bash</li>
<li>Install cvsup-without-gui</li>
<li>pkg_add -r sudo</li>
<li>pkg_add -r portupgrade</li>
</ol>
</li>
<li>Configure cvsUp
<ol type="i">
<li>vi /etc/cvsupfile and enter the following:
<ul>
<li>*default	tag=RELENGE_6_3</li>
<li>*default	host=cvsup12.freebsd.org</li>
<li>*default	prefix=/usr</li>
<li>*default	base=/var/db</li>
<li>*default	release=cvs delete use-rel-suffix compress</li>
<li>src-all</li>
<li>ports-all</li>
<li>docs-all</li>
</ul>
</li>
<li>Save and quit</li>
</ol>
</li>
<li>Run CVSup
<ol type="i">
<li>/usr/local/bin/cvsup /etc/cvsupfile</li>
<li>This will take a fair amount of time; leave the install  						and go do something else for awhile</li>
</ol>
</li>
<li>Update your world
<ol type="a">
<li>cd /usr/src</li>
<li>Check to see if the obj subdirectory exists; remove it  						(and all of its contents) if it does</li>
<li>make buildworld</li>
<li>This will take even longer than the cvsup; find something better to do  						then watch the pretty text scrolling by</li>
<li>cp /usr/src/sys/i386/conf/SMP /usr/src/sys/i386/conf/MYCUSTOMKERNEL</li>
<li>If you want to be able to connect to shares on Windows systems, edit MYCUSTOMKERNEL  						and add the following options:
<ul>
<li>options SMBFS</li>
<li>options LIBMCHAIN</li>
<li>options LIBICONV</li>
<li>options NETSMB</li>
<li>options NETSMBCRYPTO</li>
</ul>
</li>
<li>cd /usr/src &#8211; (just to make sure we are still in the right place)</li>
<li>make buildkernel KERNCONF= MYCUSTOMKERNEL</li>
<li>This will also take a while, but not nearly as long as buildworld.   						Once it finishes compiling, we next type</li>
<li>make installkernel KERNCONF= MYCUSTOMKERNEL</li>
<li>make installworld</li>
<li>Once this completes it is time to reboot into our newly updated OS.</li>
<li>init 6</li>
<li>Once the box comes back online, log in as root again and merge our config files</li>
<li>mergemaster</li>
<li>This will install new files and walk you through the process of merging changes  						into existing files.  My general rule of thumb is to install all files that I  						have not modified</li>
</ol>
</li>
<li>run portsnap and upgrade packages as needed with portupgrade.</li>
<li>Configure portupgrade and verify that all ports are up to date:
<ol type="a">
<li>portsdb -Uu</li>
<li>portversion</li>
</ol>
</li>
<li>Configure users
<ol type="a">
<li>adduser &#8211; follow the prompts</li>
<li>visudo
<ul>
<li>Add the user create a user alias and add your new user to the 								alias.</li>
<li>copy the line for root privileges, paste below and change to your 									user alias</li>
</ul>
</li>
</ol>
</li>
<li>Configure aliases
<ol type="a">
<li>vi /etc/aliases and change
<ul>
<li>root:	sysadmin@somedomain.com</li>
</ul>
</li>
<li>Write and quit</li>
<li>newaliases</li>
</ol>
</li>
<li>init 6	; manually cycle server power</li>
<li>Make sure everything starts up properly on boot</li>
<li>Done</li>
</ol>

<!-- start wp-tags-to-technorati 1.01 -->

<!-- end wp-tags-to-technorati -->
]]></content:encoded>
			<wfw:commentRss>http://www.jwnetworkconsulting.com/consulting/freebsd-70-build/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>FreeBSD 6.3 Build</title>
		<link>http://www.jwnetworkconsulting.com/consulting/freebsd-63-build</link>
		<comments>http://www.jwnetworkconsulting.com/consulting/freebsd-63-build#comments</comments>
		<pubDate>Mon, 13 Oct 2008 01:55:04 +0000</pubDate>
		<dc:creator>Jason</dc:creator>
				<category><![CDATA[Consulting]]></category>
		<category><![CDATA[FreeBSD]]></category>

		<guid isPermaLink="false">http://sysadmins.dyndns.org/?p=96</guid>
		<description><![CDATA[Introduction
This document contains basic instructions on building a system using FreeBSD 6.3.   				This covers security standards, configuration options, networking configuration, etc. 				The information used in this example probably doesn&#8217;t match your environment or hardware 				exactly.  Verify your network, hardware and other internal system build standards before 				using the information contained here.  [...]]]></description>
			<content:encoded><![CDATA[<h3>Introduction</h3>
<p>This document contains basic instructions on building a system using FreeBSD 6.3.   				This covers security standards, configuration options, networking configuration, etc. 				The information used in this example probably doesn&#8217;t match your environment or hardware 				exactly.  Verify your network, hardware and other internal system build standards before 				using the information contained here.  <strong>Use this document at your own risk.</strong></p>
<p>This document assumes technical knowledge of FreeBSD, especially in regards to kernel  				configuration (which is highly dependant on server hardware, application usage, and  				expected functionality.)</p>
<h3>Before You Begin</h3>
<p>Make sure that you have the following items completed and available for the installation:</p>
<ol>
<li>FreeBSD 6.3-RELEASE disc</li>
<li>Hardware has been updated with the correct configuration for its type  						(see hardware preparation documentation specific for the platform and model.)</li>
<li>Obtained server name and IP addresses</li>
</ol>
<h3>Operating System Installation</h3>
<ol>
<li>Boot from FreeBSD 6.3-RELEASE  installation media.  Ignore Boot Loader when it is loaded.</li>
<li>Country Selection &#8211; United States</li>
<li>Choose &#8220;Custom&#8221; under the Main Installation Screen
<ol type="a">
<li>Select &#8220;Partition&#8221;
<ol type="i">
<li>Select free space and choose &#8220;A&#8221; to use the entire disk</li>
<li>Set the partition as bootable with &#8220;S&#8221;</li>
<li>Select &#8220;Q&#8221; to finish</li>
</ol>
</li>
</ol>
</li>
<li>When prompted on the Boot Manager Screen, select &#8220;Standard&#8221;</li>
<li>Select &#8220;Label&#8221; to begin assigning and labeling disk slices
<ol type="a">
<li>Use the following partition scheme:
<ul>
<li>swap &#8211; 512 MB</li>
<li>/ &#8211; 1024 MB</li>
<li>/usr &#8211; 8192 MB  (This can be more if needed, but I use 8192MB as a minimum)</li>
<li>/var &#8211; 1024 MB  (Running a large MySQL database will require an increase here)</li>
<li>/tmp &#8211; 512 MB</li>
<li>/home &#8211; 4096 MB</li>
<li>/opt &#8211; What ever is left.</li>
</ul>
</li>
<li>Hit &#8220;Q&#8221; to finish</li>
</ol>
</li>
<li>Choose &#8220;Distributions&#8221; under the Main Installation Screen
<ol type="a">
<li>Select only the following distributions:
<ul>
<li>Minimal</li>
<li>Custom</li>
<li>base</li>
<li>kernels</li>
<li>dict</li>
<li>doc</li>
<li>man</li>
<li>catman</li>
<li>proflibs</li>
<li>src &#8211; ALL</li>
<li>ports</li>
<li>local</li>
</ul>
</li>
<li>Back out to the Main Installation Screen</li>
</ol>
</li>
<li>Select &#8220;Media&#8221;
<ol>
<li>Choose &#8220;CD-ROM&#8221;</li>
</ol>
</li>
<li>Select &#8220;Commit&#8221; to finalize these settings
<ol type="a">
<li>Verify the settings by choosing &#8220;Yes&#8221;</li>
<li>The operating system will now be installed from CD-ROM</li>
</ol>
</li>
<li>After installation, when prompted to set last options, choose &#8220;Yes&#8221;
<ol type="a">
<li>Set root password</li>
<li>Set the time zone.  I use the Pacific time zone in the US as an example here.
<ol type="i">
<li>Select &#8220;No&#8221; when asked to set the clock to UTC</li>
<li>Select America &#8211; North and South</li>
<li>United States</li>
<li>Pacific Time &#8211; Confirm abbreviation of the time zone</li>
</ol>
</li>
</ol>
</li>
<li>Configure &#8220;Networking&#8221;
<ol type="a">
<li>Enable ssh, leave the rest at defaults</li>
<li>Select &#8220;Interfaces&#8221;
<ol type="i">
<li>Select interface you wish to configure</li>
<li>Do not enable Ipv6 (unless you need it)</li>
<li>Do not enable DHCP (unless you need it)</li>
<li>Enter hostname</li>
<li>Enter domain name</li>
<li>Enter Gateway &#8211; Appropriate gateway for the network you are on</li>
<li>Enter DNS server(s)</li>
<li>Enter IP address and subnet mask</li>
<li>Select Yes to bring up the interface</li>
<li>Exit back up out of Interfaces</li>
</ol>
</li>
<li>Configure &#8220;Startup&#8221;
<ol type="i">
<li>Unselect &#8220;quotas&#8221;</li>
</ol>
</li>
</ol>
</li>
<li>Select &#8220;Exit&#8221; twice, followed by &#8220;Exit Install&#8221;, then &#8220;Yes&#8221;</li>
<li>The server will be automatically rebooted, finishing the installation</li>
</ol>
<h3>Operating System Configuration</h3>
<ol>
<li>On startup the server will prompt you to type in random junk to provide  					a seed value for the SSH keys.  Just pound on the keyboard until you get bored.</li>
<li>Log into the server as root</li>
<li>vi /etc/rc.conf and ensure the following options are set:
<ul>
<li>check_quotas=&#8221;NO&#8221;</li>
<li>defaultrouter=&#8221;x.x.x.x&#8221;</li>
<li>hostname=&#8221;hostname&#8221;</li>
<li>ifconfig_=&#8221;x.x.x.x netmask x.x.x.x&#8221;</li>
<li>xntpd_enable=&#8221;YES&#8221;</li>
<li>xntpd_program=&#8221;ntpd&#8221;</li>
<li>xntpd_flags=&#8221;-c /etc/ntpd.conf -p /var/run/ntpd.pid&#8221;</li>
</ul>
</li>
<p>Note:	Instances of &#8220;x.x.x.x&#8221; should be replaced with the proper IP address or network mask</p>
<li>vi /etc/resolv.conf and ensure the following lines are set:
<ul>
<li>domain	domain.com</li>
<li>nameserver	x.x.x.x</li>
<li>nameserver	x.x.x.x</li>
<li>search	search.com domains.com</li>
</ul>
</li>
<li>Configure the message of the day (MOTD) to something appropriate</li>
<li>run &#8220;chpass&#8221;
<ol type="a">
<li>Change &#8220;Charlie &amp;&#8221; to read &#8220;HOSTNAME &amp;&#8221;</li>
</ol>
</li>
<li>Disable unneeded terminals
<ol type="a">
<li>vi /etc/ttys</li>
<li>Comment out (or delete) everything in the Virtual Terminal section  							except the following ttyvs:
<ul>
<li>ttyv0</li>
<li>ttyv1</li>
<li>ttyv2</li>
</ul>
</li>
<li>Save and quit vi</li>
<li>killall -HUP init</li>
</ol>
</li>
<li>Install bash
<ol type="a">
<li>pkg_add -r bash</li>
</ol>
</li>
<li>Install cvsup-without-gui
<ol type="a">
<li>pkg_add -r cvsup-without-guiv</li>
<li>vi /etc/cvsupfile and enter the following:
<ul>
<li>*default	tag=RELENG_6_3</li>
<li>*default	host=cvsup12.freebsd.org</li>
<li>*default	prefix=/usr</li>
<li>*default	base=/var/db</li>
<li>*default	release=cvs delete use-rel-suffix compress</li>
<li>src-all</li>
<li>ports-all</li>
<li>docs-all</li>
</ul>
</li>
<li>Save and quit</li>
<li>Run CVSup
<ol type="i">
<li>/usr/local/bin/cvsup /etc/cvsupfile</li>
<li>This will take a fair amount of time; leave the install  									and go do something else for awhile</li>
</ol>
</li>
</ol>
</li>
<li>Update your world
<ol type="a">
<li>cd /usr/src</li>
<li>Check to see if the obj subdirectory exists; remove it  							(and all of its contents) if it does</li>
<li>make buildworld</li>
<li>This will take even longer than the cvsup; find something better to do  							then watch the pretty text scrolling by</li>
<li>cp /usr/src/sys/i386/conf/SMP /usr/src/sys/i386/conf/MYCUSTOMKERNEL</li>
<li>If you want to be able to connect to shares on Windows systems, edit MYCUSTOMKERNEL  						and add the following options:
<ul>
<li># Compile in SMBFS support</li>
<li>options SMBFS</li>
<li>options LIBMCHAIN</li>
<li>options LIBICONV</li>
<li>options NETSMB</li>
<li>options NETSMBCRYPTO</li>
</ul>
</li>
<li>cd /usr/src &#8211; (just to make sure we are still in the right place)</li>
<li>make buildkernel KERNCONF= MYCUSTOMKERNEL</li>
<li>This will also take a while, but not nearly as long as buildworld.   							Once it finishes compiling, we next type</li>
<li>make installkernel KERNCONF= MYCUSTOMKERNEL</li>
<li>make installworld</li>
<li>Once this completes it is time to reboot into our newly updated OS.</li>
<li>init 6</li>
<li>Once the box comes back online, log in as root again and merge our config files</li>
<li>mergemaster</li>
<li>This will install new files and walk you through the process of merging changes  							into existing files.  My general rule of thumb is to install all files that I  							have not modified</li>
</ol>
</li>
<li>Install basic packages
<ol type="a">
<li>pkg_add -r sudo</li>
<li>pkg_add -r portupgrade</li>
<li>pkg_add -r portsnap</li>
</ol>
</li>
<li>run portsnap and upgrade packages as needed with portupgrade.</li>
<li>visudo and verify that privileges are set correctly.</li>
<li>Configure portupgrade and verify that all ports are up to date:
<ol type="a">
<li>portsdb -Uu</li>
<li>portversion</li>
</ol>
</li>
<li>Configure NTP
<ol type="a">
<li>ntpdate local.time.server</li>
<li>vi /etc/ntpd.conf, erase all contents (if any) and insert the following:
<ul>
<li>server local.time.server</li>
<li>driftfile /etc/ntp/drift</li>
<li>multicastclient</li>
<li>broadcastdelay  0.008</li>
<li>restrict X.X.X.X mask X.X.X.X nomodify notrap</li>
</ul>
</li>
</ol>
</li>
<li>Configure aliases
<ol type="a">
<li>vi /etc/aliases and change
<ul>
<li>root:	sysadmin@somedomain.com</li>
</ul>
</li>
<li>Write and quit</li>
<li>newaliases</li>
</ol>
</li>
<li>init 6	; manually cycle server power</li>
<li>Make sure everything starts up properly on boot</li>
<li>Done</li>
</ol>

<!-- start wp-tags-to-technorati 1.01 -->

<!-- end wp-tags-to-technorati -->
]]></content:encoded>
			<wfw:commentRss>http://www.jwnetworkconsulting.com/consulting/freebsd-63-build/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
