Foray into FreeBSD*


August 4, 2008

I made some changes. Blog post here.

March 16, 2007

I signed up for Dynamic DDS service a few days ago and finally set up the machine to run a website that can be accessed from the Web. Signing up for the service is easy and you can Alltheweb for companies that provide this.
Here's what you need to do it at home:

If you are behind a router that does NAT, log into the router and see what kind of settings it has for DDNS. Certain makes of routers may only support a particular service. You will also need to enable port forwarding through your router and tell the router that you are running HTTP on a machine located at 192.168.x.x and the port number that you specified in Apache. A lot of people use port 8080. Once your configure your router, run the script or application to tell your DDNS service your IP. Don't forget to restart Apache if you've made any changes. If everything works, you should be able to view your site by typing in http://name.hostnameyoupicked.org:8080. Your settings will vary. Also, have a friend check it from outside your home network just to make sure it's accessible. That's all there is to it.

February 25, 2006

The hard drive on this thing is being to click a little. So, I backed up everything on it and did an fsck. Everything checked out. So, I pulled the drive and wrapped in up and put in a box and put it outside. After a day or two I'll try it again.

> uptime
10:44AM up 148 days, 1:58, 1 user, load averages: 0.01, 0.08, 0.13

October 13, 2005

I installed Apache today; pkg_add -r apache. That's all there is to it. I used Absolute BSD as a guide and, as expected, it works fine. I want to tinker with Apache because I plan on hosting my web sites on my own equipment some day.

August 27, 2005

I finally set this up so I can read/write floppies.
Insert BLANK floppy into drive. Otherwise, you will lose data.
Create the directory: #mkdir floppy
Modify fstab; this is the line I inserted: /dev/fd0 /floppy ufs rw,noauto 0 0
Create the FFS filesystem: #disklabel -r -w /dev/fd0 fd1440
Then: #newfs /dev/fd0    This is the part that erases the diskette!
Now you should be able to mount/umount the floppy and read/write to it but only under BSD.

If you need to swap the floppy between BSD, Windows, and Linux machines, simply do this instead of #newfs /dev/fd0:
#newfs_msdos /dev/fd0
I tried it and was able to mount/umount the diskette under Linux and Windows. Oh yeah, change ufs in fstab to msdos.

July 24, 2005

I played around with IPFilter today. A good how-to can be found here:
http://www.freebsd-howto.com/HOWTO/IPFilter-HOWTO

July 11, 2005

The install I did yesterday did not install nmap; I don't think it was on Disk 1 and I did not burn Disk 2. So, I simply typed pkg_add -r nmap and nmap was downloaded and installed.

July 10, 2005

I installed FreeBSD 4.11 on a spare hard drive today. The prior install was only on a 1.6 GB drive so I found a 6.4 GB and installed 4.11. I also added some memory to this thing and now have 80 MB of RAM. So, I installed KDE in order to give myself a second desktop. It's a little slow but it is functional.

I learned something new today - setting the date. It's little different than in Linux. To set the time/date as 21:06:42 July 10, 2005 you type this at the prompt:

0507102106.42

It should be easy to tell the format from that example. Next up: building another custom kernel.

April 21, 2005

I haven't done too much with this lately. I had a good uptime going (94 days) but I shut it down voluntarily because I was going to be away. However, yesterday morning I must have had a crash of some sort. I awoke and the machine was off. It wasn't a power outage because nothing else in the house was affected. It took a few tries to reboot too. It wanted me to run fsck manually and I did. Finally, it rebooted ok. I don't know what happened. The hard drive is probably six years old so maybe it's beginning to fail. I'll let it run and see what happens. It doesn't have anything important on it but it makes me wonder if any of my other systems are going to go ka-blooey too.

December 16, 2004

I built my own kernel today. It's fairly straightforward. What I did was first copied the GENERIC kernel: cp GENERIC mykernel. The kernel should be in /sys/i386/conf. Then I edited mykernel. I commented out what I thought I didn't need. Once I did that the next step was to do a 'config mykernel.' I did a cd to the directory mykernel was in (../../compile/mykernel). Then I did 'make depend && make all install.' That's it. It took about 30 minutes to compile (133MHz machine). I rebooted and did a 'uname -v' and got this:

FreeBSD 4.7-RELEASE #0: Thu Dec 16 17:00:29 EST 2004 root@belterra.abc123xyz.***:/usr/src/sys/compile/mykernel.

Much thanks from Chapter 4 (Kernel Games) of Absolute BSD.

October 2, 2004

I installed naim today. I downloaded naim 0.11.6.7. It works.

September 11, 2004

I installed Lynx today. First I mounted the cdrom: mount -t cd9660 /dev/acd0c /cdrom
Then: cd /cdrom/packages
     did ls and cd to /packages/www
     then pkg_add lynx-2.8.4.1c.tgz
Lynx works.

August 25, 2004

I removed KDE today by doing pkg_delete -f kde\*. I don't need it.

August 24, 2004

Today I installed Ircii, a command-line IRC client. It's easy to install if you follow the directions. I connected without a problem to the server and channel that I frequent. I was using KSirc under TWM but X would crash sometimes; probably because I let it run all the time. So I figured with this machine it's better to use a text-based IRC client.

July 21, 2004

As stated earlier, this machine will be a server but I installed KDE on it anyway. I typed the obligatory 'startx' and TWM started up. From there I typed 'startkde' and KDE started. KDE would not start from either 'startkde' or 'kde' from a command prompt, unless TWM was already running. No biggie though; this machine isn't meant for X. KDE is soooo slow and just using KMail was painful enough. But, KDE worked fine but with a 133 MHz and 32 MB RAM it isn't practical.

I also ordered the hub, cables, and keyboard I need to make this machine work on its own without me having to disconnect something from one of the other four working PC's.

July 17, 2004

I decided to give FreeBSD a try on an IBM 300 GL that has a 133 MHz processor and 32 MB of RAM. As with when I first started with Linux, I just jumped in and gave it a go. I also have a copy of Absolute BSD by Michael Lucas for reference.

FreeBSD 4.7-Release

The FreeBSD installer is fairly basic and actually easy to use if you read the directions at each step. When it comes to partitioning the disk you can simply select auto defaults and it's done; real easy. After that, I chose a standard install and just selected X User package, options 8 and 9. Now, this machine is going to be a server but I selected and X package anyway just so I can expose myself to a basic install. The install took about 15 minutes. Then I followed the clear instructions and configured the network card, some services like NFS, the "daemon" screensaver, X (via xf86config), and selected the KDE desktop. The integrated video card is a Cirrus Logic GD5446 1MB card which apparently can use the 'vga' or 'cirrus' driver. I choose the latter. That's pretty much the install in a nutshell.

Problems (With Solutions!)

The first problem was with the mouse pointer. During the xf86config routine I selected PS/2 and then /dev/sysmouse. But, once I did a 'startx' the pointer was stuck in the upper right-hand corner of the screen. So, I did some searching and this is what I did:
1. In /etc/rc.conf: I added moused_type="auto" and moused_port="/dev/psm0". Auto instead of PS/2.
2. Then in /etc/X11/XF86Config under the mouse section I made sure that "auto" and "/dev/sysmouse" were there. I don't know why it's "/dev/sysmouse" in XF86Config and "/dev/psm0" in rc.conf but that's what worked.

The next problem was setting up the NFS client. Setting up the NFS server was as simple as following the directions but the client was a little different. I have a Linux machine running Apache HTTP and an NFS server. So, I wanted to mount it. In /etc/fstab I entered:
server:/dir mnt/nfs nfs soft 0 0. Ok, simple enough but it wouldn't mount. FreeBSD is different from Linux here so I had to do this:
1. # nfsiod -n 4
2. # mount server:/dir /mnt
It's a little different from Linux but easy enough once you know what to do.

Another problem I encountered was when doing "locate filename" this error was returned: locate: database too small: /var/db/locate.database. I did some quick searching and found the answer. First, I deleted locate.database (under /var/db/). Then I did ./locate.updatedb which is located in /usr/libexec. Works fine now.

I successfully installed Webmin on this machine too. Again, easy enough with no problems. I'll post more as I get deeper into it. The next step is Apache HTTP.


*Those of you who have done a Netcraft "What's that Site Running" lookup knows that this site is hosted on a FreeBSD machine. I chose my host because I could choose the operating system my site is hosted on.

Home

Last updated August 4, 2008

freebsd