Finally a good day of sort.

slept in till 1400, nice considering the rest of the weekdays I have/will be getting up early :

Been toying around with Getopt::Long in Perl for a little ‘toy’ that I’ve had on the brain, worked on it a bit in my spare time. I’m used to working with tar, even gzip/bzip2 directly but occasionally have to work with zip/rar files and I find that I always need to look up the switches to use. So I was thinking about a script that would apply a uniform usage-style accross a varied set of such programs (tar inspired of course). I thought about using pax as a standard program, because for most stuff that I use I’ll generally leave it at TApe aRchives and skip the compression but I find generally speaking that using the pax utility is *annoying compared to the alternatives (when they work of course). KDE has an archiver program called Ark but I find it works poorly with /large/ archive files several hundred megs thick and there is no command line utility that I know of that has built in support for every format and runs both on NT and *Nix, the best I found in a short look require the Bourne Again Shell.

Enjoyed a few rounds on TG#1 with Jonsi and Rct Spawn. It’s good to get back into action again, I havn’t really played or trained much this week because of work. And I’m really looking forward to doing a training session on observation and marksmanship skills this weekend. I also managed to pop in to TG#3 and join Duke, Dallers, Chester, and the gang for a few before the DSL dropped out as usual.

I really wish I could tell Bellsouth to go suck an egg.

I think if I can find a day to do it and some time to print out the Gez Admin Mods command reference I might be able to setup a quick live op. I remember we have a hunt missing MI5 Programmer and a Russian Terrorist Cell on our Live Operations board that are still waiting for the green light. You know, the government should pay me for ideas lol, some of the live ops I concoct for our training are first rate !

For tonight, hmm on the basis of what hits me first. I need to get some stuff done that I told Gerard I’d take care of him on the documentation front. There’s the Perl script I’ve been toying with, and the age old issue of organizing my music collection +S

Every time I organize the damn thing I break my playlists, every time I update my playlists I usually spend more time either rebuilding them or s/search/replace/’in’g the entries instead of listing. What I really think would be best is if I just find or write a quick tag editor, use that to organize stuff. Then combine a script and a library to organize files according to the tags and regenerate my playlists when ever it is run.

I’m also thinking about switching to either MPlayer or VLC as a dedicated omni-purpose media player. The advantage of course being that they both run on any OS I’m likely to need them and can play darn near any thing ;-).

The only problem is I am used to Amaroks collection browser and playlist interface lol. I don’t really need much more then the basic features but aside from a handful (xmms/winamp, mplayer, vlc, amarok, kaffine) I’ve never really found a single Media Player that I am universally happy with but I suppose that is just the natural. One thing that I do like very much about MPlayer is there is a command line interface (very powerful one at that) and you can basically choose from any of several GUI Frontends, which I do really prefer to use for video operations but to be honest I’ve generally had better luck with VLC for DVD playback.

Hopefully work will get done before I loose concentration…

Egg on my face

Oh this is a shocker!

I noticed I had one of my quick bookmarks in konqueror that I never finished reading, some thing on command line arguments — a very poor name for a bookmark generally speaking.

So I opened it in another tab and parsed it at my usual rapid pace. Gradually I started lookinf around at other stuff on the site, intrigued by some of the other things I found, even things noted about the design of termcap/terminfo, fetchmail, gcc, etc and decisions involved with the problems the developers had to solve. About a half an hour and almost 3 chapters later and figuring it was probably some (good) book gifted to the WWW by a universities CS department I finally clicked the ‘home’ button and felt like popping myself in the head when I realized what I had been reading a mirror of:

The Art of Unix Programming

I remember I was reading it last year but I never had time to finish it. Hmm, I wonder where I left off? It is a very fine book but unfortunately not one I was able to inhale in my spare time :. I might be a strange person but when I find a good book, it usually makes a transition from eye to brain at a rate of 50-120 pages a day xD, time and energy permitting of course.

It’s a book I’d fully recommend for any one interested in problem solving or engineering’ish thinking.

Manually upgrading PC-BSD v1.4 to using FreeBSD 7 underneath

It can be done although I don’t actually recommend it lol, I did this solely for fun. Here is what I recored in the ~/fun-log file on my Samba server. A copy of my kernel configuration and a screen shot of the first GUI enabled boot is at the end of the post:

——————————————————————
Enabled SSH login to my test machine, since I don’t use the default port 22 for SSH I had to open ssh_config and sshd_config in /etc/ssh/ and uncomment the ‘Port’ line and change the port number.

A quick restart of the SSH Daemon from a root shell:

/etc/rc.d/sshd restart

I also disabled the firewall (pf) since I was in no mood to sort it out or port my laptops pf.config over.

and from my own shell

ssh Terry@xxx.xxx.xxx.xxx # s/xxx.xxx.xxx.xxx/server ip/g

I accepted the finger print and logged in, then ssh’d to this machine from that ssh connection doing like wise.

I’d recommend taking back ups of the system before proceeding, since this is a test machine I can skip it. I would suggest using either tar or dump in conjunction with a mounted recovery partition (or other storage device) or SSH if you have another system to use for storing the backups. Some people prefer Optical disks (cd/dvd) but I only use these for perm. backups.

rebooted with the FreeBSD 7.0-RELEASE install cd in the drive and chose the upgrade option from sysinstall. I chose to upgrade ‘custom’ and selected all sets except the profiled libraries and source code: every thing worked perfect except that X.Org failed to upgrade due to already installed packages, unexpected yes but no problem as I was not planning on using X until after KDE was upgraded.

Completed the upgrade and chose the ‘Fixit’ option in the main menu dropping to a shell on ttyv4 which I used to edit /etc/ttys and disable the start of X.Org on boot up.

Located the ttyv4 line that starts /PCBSD/bin/pdm on an xterm and change the ‘on’ to an ‘off’. Saved the file and gave a ‘reboot’.

I forgot that FreeBSD’s GENERIC kernels detect my hard drives wrong because the kernel uses the ATA_STATIC_ID option. I have a SATA drive for ad0 and with ATA_STATIC_ID in the kenrel config it detects ad0 as ad4, PC-BSD’s kernel builds have the ‘right’ option commented out to fix that so I had to manually select a root disk at boot:

ufs:ad4s3

While I could easily fix this with changing the lines in /etc/fstab that would defeat the point of merging PC-BSD’s SMP Kernel configuration with FreeBSD’s GENERIC kernel. Which I could have done before rebooting any way.

I Inserted my install disk and ran /usr/sbin/sysinstall, using the ‘Configure’ option I chose to install the source code for every thing through the distribution sets. As far as I know you need the full system source to build a kernel.

I set PACKAGEROOT and did a pkg_add of lynx so I could view the installed version of the FreeBSD handbook without reading HTML source code. I like to have access to the handbook when building a kernel so that I can check if any new notes have been made in the section on the kernel configuration file. I also did a pkg_add of the mg editor, much smaller then vim but easier for me to work with then FreeBSDs /usr/bin/vi when I wish to view two files at once.

mkdir ~/kernel-config; cd ~/kernel-config
cp /PCBSD/conf/PCBSD-SMP.i386 ./
cp /usr/src/sys/i386/conf/GENERIC ./
pkg_add -r mg
...
vi ~/.mg # set a few options I like for emacs

Then I used MicroGNUEmacs (mg) to merge PCBSD-SMP.i386 into GENERIC saving it as mykernel with the ^x^w command, the basics of using mgh you can find in the man page; if you choose to use mg but don’t know emacs. In point of fact, I have not used emacs regularly to edit files in over 2 years!

touch ./mykernel; ln -s /root/kerne-config/mykernel /usr/src/sys/i386/conf/mykernel; mg ./mykernel
cd /usr/src
make buildkernel KERNCONF=mykernel

You know, I wish I remembered to use the -j 8 option to make… Because last time I did that on my Pentium D it only took ~45 minutes to compile a kernel on 6.1-RELEASE or so.

Build started at: Sun Mar 2 21:19:14 UTC 2008
Build finished at: Sun Mar 2 21:40:51 UTC 2008

And to top it off, when I got up to do a few chores when I got back the console ‘screen saver’ kicked in. Which just happened to be the PC-BSD splash screen that comes up when ever the system boots kicked in during my kernel compile. This appears to have been some thing I broke with the upgrade, unless there is a difference because my laptop uses a Beastie image for the console screen saver.

I’m standing here like WTF? Did I crash or are they joking. Sure enough the system was playing a mean joke on me haha. And I know the system shouldn’t go down during a buildkernel even with what I’ve been ‘doing’ to the system without some serious problems. Right now it looks like the NIC drivers are compiling so it shouldn’t take to much longer.

While I wait, I’ll start merging the configuration files in /etc with those in /etc/upgrade.

A quick look to see if there are any config files from PC-BSD with pcbsd mentioned in them:

find /etc/ -type f -exec grep -ni ‘pcbsd|pc-bsd’ ‘{}’ ;

Of course they are *never* so nice as to denote what files are explicitly changed from the base FreeBSD installs 8=). Used lynx to browse PC-BSD’s SVN Repository online, looking at the system overlay in the 1.4 branch. I don’t see any any thing here that should effect me seriously — if any one tries this after me, check PC-BSDs SVN -> pcbsd/branches/1.4/system-overlay/etc (some thing like that) and look at the commit messages, if you see some thing that might effect you. Carefully compare the relevant files in /etc/ and /etc/upgrade unless like me, there is nothing you can seriously break that you will ever want to fix later.

There are two ways of doing this part, manual and mergemaster. If you have never done a buildworld/installworld before read the manual page for mergemaster and run it in a more user friendly mode. I usually do this any way because I use mergemaster only a few times a year at the most.

Some switches to mergemaster you might want to look up are: -a, -i, -v, -U

If you are going manually, I suggest you move the files from /etc/upgrade to /etc/ but pay special attention to files such as group and rc.local -> You don’t want to be unable to login as any thing but root on your reboot now do you? Hehe.

mv /etc/upgrade /root/etc-upgrade
mergemaster -viU
...

I installed most files but merged several others, among them:

ssh_conf and sshd_conf I merged to keep my port settings

group I merged to keep the various groups PC-BSD has setup for HAL’d and friends as well as having my user in wheel, operator, and its own group 😉

login.conf because I use ‘blf’ for the pass word format rather then the default md5. At the end of my mergemaster’ing I was happy to see that mergemaster was already a step ahead of me and promped for the login.conf database to be rebuilt for fool proof safeties sake:

*** You installed a login.conf file, so make sure that you run
'/usr/bin/cap_mkdb /etc/login.conf'
to rebuild your login.conf database

Would you like to run it now? y or n [n] y
Running /usr/bin/cap_mkdb /etc/login.conf

Some files that I chose to delete, the extra rc scripts which may have broken one of the Intel Wifi drivers. Also I decided not to install the *new* printcap file -> which if I had installed would have overwritten any printer setup I have done on my test machine.

One nice advantage is I have PC-BSD’s kernel stored in /boot/kernel.prev from the FreeBSD upgrade proceedure and the GENERIC FreeBSD 7.0-RELEASE kernel in /boot/kernel.old after installing my newly compiled custom kernel.

For extra safety, I’ll archive these in roots home directory with more normal names in case I need them later:

tar -cf - /boot/kernel.old | bzip2 -9 > /root/kernel-FreeBSD7.0-RELEASE.g
eneric.tar.bz2
tar -cf - /boot/kernel.prev | bzip2 -9 > /root/kernel-PCBSD1.4.2.smp.tar.
bz

I don’t know how to get BSD tar to adjust the compression level for gzip/bzip2 (-z,-j), assuming there is a switch for it. So I redirected tar’s output to bzip2 directly to enable maximum compression.

Sadly, on reboot my system would lock up when ever the kernel tried to probe /dev/da3. No matter how many times I try to boot it, it locks up on this. I booted the Windows XP installation on the machine, rebooted into PC-BSD again and it boots perfectly — This is a *standing* issue with this test machine.

Often FreeBSD will lock up during boot while probing my (internal) USB Card Reader when it gets to the memory stick slot and refuse to boot until I have booted another operating system on the machine. I have had this problem since FreeBSD 6.0-RELEASE, never tried any earlier ones.

Yes I hate this computer.

But otherwise my system however works bloody perfect 🙂

pcbsd# uname -ai
FreeBSD pcbsd 7.0-RELEASE FreeBSD 7.0-RELEASE #0: Sun Mar 2 16:27:13 EST 2008
root@pcbsd:/usr/obj/usr/src/sys/mykernel i386 TERRYP

Now to get X.Org and KDE back online, installed the ports tree from the FreeBSD 7.0-RELEASE CD-ROM, new enough for my needs. While that goes, lets back up a few things of interest:

tar -czf /root/old-ports.tgz /usr/local/etc /usr/local/share/{icons,config,config.kcfg,apps,applnk}
tar -cjf /root/linux-fc4.tar.bz2 /compat

These files are essentially our KDE icons and a few directories we might want to keep handy for later. Also I chose to backup the /compat directory that houses the linux files.

Now for the portupgrade business:

After telling the pkgdb what to do with it self, I checked the help and gave this a go after I got tired of the interactive:

pkgdb -fFi

The one thing I hate about dealing with portupgrade and friends on FreeBSD is the packages database — it’s a royal pain in the arse to deal with when you are not in the mood! After sorting out all of the crap that pkgdb had to shout at including the mother ****ing **** load of fonts mentioned in the sale dependencies I know I will __never__ do this again.

In fact, if I ever go back to maintaining a standard FreeBSD system for my workstation I’ll do this my way — use a list of programs needed, and do upgrades with out mucking with pkgdb and it’s friends lol -> less trouble I think to do it by hand the way my mind is thinking of it now hehe.

Now to fetch every thing needed before we start and prefer binary packages where possible to save on some compile time. -> Warning!!! Not my reccomendation, done here out of my lack of concern for breaking the test machine.

portupgrade -FDParR

Now to upgrade every thing preferring packages, go to splitsvile and read the log later.

portupgrade –batch -faPrR –results-file /root/portupgrade.log

Whether -a impiles -rR or not I don’t know, never really read the source code that much but I’m used to using all three switches at once for this. Portupgrade also crashed about 3 times during the installation, mostly from upgrading ruby and missing stuff in /tmp. It also fragged /var/db/pkg/pkgdb.db once or twice and shouted at /usr/ports/INDEX-7.db’s format. So I had to run the command several times taking about a day and a half to complete the entire operation as described here.

Now I remember why I don’t use portupgrade or mass software upgrades a lot on my stable machines.

I had to create a new xorg.conf so I did an

X -configure
X -config /root/xorg.conf.new

and it worked, a reboot and I was soon greated by KDE 3.5.8 running on X.Org 7.3 😉

I know I broke the PBReg program so I would expect most other custom programs that PC-BSD has needs a recompile from the source code. I also used as many packages as possible during the upgrade procedure to save time, not what I normally do on FreeBSD but it actually worked well enough. Tomorrow after work I’ll test out a few of the PC-BSD programs and the Firefox PBI I have installed on the test machine, and installing a PBI to see if any thing survived without a recompile needed. I also want to test the Linux ABI’s new abilities and see what happens when installing linux-flock binaries.

——————————————

Screen shot:

Free Image Hosting at www.ImageShack.us

Here is a copy of my kernel configuration:

# My PC-BSD v1.4.2 + FreeBSD 7.0-RELEASE kernel configuration

cpu I686_CPU
ident TERRYP

# To statically compile in device wiring instead of /boot/device.hints
#hints "GENERIC.hints" # Default places to look for devices.

makeoptions DEBUG=-g # Build kernel with gdb(1) debug symbols

#options SCHED_4BSD # 4BSD scheduler
options SCHED_ULE # ULE scheduler instead ;-)

# options from PC-BSD that I'll keep handy
options LIBICONV
options LIBMCHAIN
options CD9660_ICONV
options MSDOSFS_ICONV
options NTFS
options NTFS_ICONV
options UDF
options UDF_ICONV
options GEOM_UZIP
options DEVICE_POLLING
device iwi # intel wireless adapters
device ipw # intel wireless adapters

#### I want to use PF.
device pf
device pflog
device pfsync

options ALTQ
options ALTQ_CBQ
options ALTQ_RED
options ALTQ_RIO
options ALTQ_HFSC
options ALTQ_CDNR
options ALTQ_PRIQ
options ALTQ_NOPCC

# Memory card drivers I want to test:
device mmc
device mmcsd

# options in GENERIC
options INET # InterNETworking
options INET6 # IPv6 communications protocols
options SCTP # Stream Control Transmission Protocol
options FFS # Berkeley Fast Filesystem
options SOFTUPDATES # Enable FFS soft updates support
options UFS_ACL # Support for access control lists
options UFS_DIRHASH # Improve performance on big directories
options UFS_GJOURNAL # Enable gjournal-based UFS journaling
options MD_ROOT # MD is a potential root device
options NFSCLIENT # Network Filesystem Client
options NFSSERVER # Network Filesystem Server
options NFS_ROOT # NFS usable as /, requires NFSCLIENT
options MSDOSFS # MSDOS Filesystem
options CD9660 # ISO 9660 Filesystem
options PROCFS # Process filesystem (requires PSEUDOFS)
options PSEUDOFS # Pseudo-filesystem framework
options GEOM_PART_GPT # GUID Partition Tables.
options GEOM_LABEL # Provides labelization
options COMPAT_43TTY # BSD 4.3 TTY compat [KEEP THIS!]
options COMPAT_FREEBSD4 # Compatible with FreeBSD4
options COMPAT_FREEBSD5 # Compatible with FreeBSD5
options COMPAT_FREEBSD6 # Compatible with FreeBSD6
options SCSI_DELAY=5000 # Delay (in ms) before probing SCSI
options KTRACE # ktrace(1) support
options SYSVSHM # SYSV-style shared memory
options SYSVMSG # SYSV-style message queues
options SYSVSEM # SYSV-style semaphores
options _KPOSIX_PRIORITY_SCHEDULING # POSIX P1003_1B real-time extensions
options KBD_INSTALL_CDEV # install a CDEV entry in /dev
options ADAPTIVE_GIANT # Giant mutex is adaptive.
options STOP_NMI # Stop CPUS using NMI instead of IPI
options AUDIT # Security event auditing

# To make an SMP kernel, the next two lines are needed
options SMP # Symmetric MultiProcessor Kernel
device apic # I/O APIC

# CPU frequency control
device cpufreq

# Bus support.
device eisa
device pci

# Floppy drives
device fdc

# ATA and ATAPI devices
device ata
device atadisk # ATA disk drives
device ataraid # ATA RAID drives
device atapicd # ATAPI CDROM drives
device atapifd # ATAPI floppy drives
device atapist # ATAPI tape drives
#### XXX:
#### This option must be commented out for SATA drives to be
#### detected properly, e.g. ad0 not ad4 on boot up!
#options ATA_STATIC_ID # Static device numbering

# SCSI Controllers
device ahb # EISA AHA1742 family
device ahc # AHA2940 and onboard AIC7xxx devices
options AHC_REG_PRETTY_PRINT # Print register bitfields in debug
# output. Adds ~128k to driver.
device ahd # AHA39320/29320 and onboard AIC79xx devices
options AHD_REG_PRETTY_PRINT # Print register bitfields in debug
# output. Adds ~215k to driver.
device amd # AMD 53C974 (Tekram DC-390(T))
device hptiop # Highpoint RocketRaid 3xxx series
device isp # Qlogic family
#device ispfw # Firmware for QLogic HBAs- normally a module
device mpt # LSI-Logic MPT-Fusion
#device ncr # NCR/Symbios Logic
device sym # NCR/Symbios Logic (newer chipsets + those of `ncr')
device trm # Tekram DC395U/UW/F DC315U adapters

device adv # Advansys SCSI adapters
device adw # Advansys wide SCSI adapters
device aha # Adaptec 154x SCSI adapters
device aic # Adaptec 15[012]x SCSI adapters, AIC-6[23]60.
device bt # Buslogic/Mylex MultiMaster SCSI adapters

device ncv # NCR 53C500
device nsp # Workbit Ninja SCSI-3
device stg # TMC 18C30/18C50

# SCSI peripherals
device scbus # SCSI bus (required for SCSI)
device ch # SCSI media changers
device da # Direct Access (disks)
device sa # Sequential Access (tape etc)
device cd # CD
device pass # Passthrough device (direct SCSI access)
device ses # SCSI Environmental Services (and SAF-TE)

# RAID controllers interfaced to the SCSI subsystem
device amr # AMI MegaRAID
device arcmsr # Areca SATA II RAID
device asr # DPT SmartRAID V, VI and Adaptec SCSI RAID
device ciss # Compaq Smart RAID 5*
device dpt # DPT Smartcache III, IV - See NOTES for options
device hptmv # Highpoint RocketRAID 182x
device hptrr # Highpoint RocketRAID 17xx, 22xx, 23xx, 25xx
device iir # Intel Integrated RAID
device ips # IBM (Adaptec) ServeRAID
device mly # Mylex AcceleRAID/eXtremeRAID
device twa # 3ware 9000 series PATA/SATA RAID

# RAID controllers
device aac # Adaptec FSA RAID
device aacp # SCSI passthrough for aac (requires CAM)
device ida # Compaq Smart RAID
device mfi # LSI MegaRAID SAS
device mlx # Mylex DAC960 family
device pst # Promise Supertrak SX6000
device twe # 3ware ATA RAID

# atkbdc0 controls both the keyboard and the PS/2 mouse
device atkbdc # AT keyboard controller
device atkbd # AT keyboard
device psm # PS/2 mouse

device kbdmux # keyboard multiplexer

device vga # VGA video card driver

device splash # Splash screen and screen saver support

# syscons is the default console driver, resembling an SCO console
device sc

device agp # support several AGP chipsets

# Power management support (see NOTES for more options)
#device apm
# Add suspend/resume support for the i8254.
device pmtimer

# PCCARD (PCMCIA) support
# PCMCIA and cardbus bridge support
device cbb # cardbus (yenta) bridge
device pccard # PC Card (16-bit) bus
device cardbus # CardBus (32-bit) bus

# Serial (COM) ports
device sio # 8250, 16[45]50 based serial ports
device uart # Generic UART driver

# Parallel port
device ppc
device ppbus # Parallel port bus (required)
device lpt # Printer
device plip # TCP/IP over parallel
device ppi # Parallel port interface device
#device vpo # Requires scbus and da

# If you've got a "dumb" serial or parallel PCI card that is
# supported by the puc(4) glue driver, uncomment the following
# line to enable it (connects to sio, uart and/or ppc drivers):
#device puc

# PCI Ethernet NICs.
device de # DEC/Intel DC21x4x (``Tulip'')
device em # Intel PRO/1000 adapter Gigabit Ethernet Card
device ixgb # Intel PRO/10GbE Ethernet Card
device le # AMD Am7900 LANCE and Am79C9xx PCnet
device txp # 3Com 3cR990 (``Typhoon'')
device vx # 3Com 3c590, 3c595 (``Vortex'')

# PCI Ethernet NICs that use the common MII bus controller code.
# NOTE: Be sure to keep the 'device miibus' line in order to use these NICs!
device miibus # MII bus support
device bce # Broadcom BCM5706/BCM5708 Gigabit Ethernet
device bfe # Broadcom BCM440x 10/100 Ethernet
device bge # Broadcom BCM570xx Gigabit Ethernet
device dc # DEC/Intel 21143 and various workalikes
device fxp # Intel EtherExpress PRO/100B (82557, 82558)
device lge # Level 1 LXT1001 gigabit Ethernet
device msk # Marvell/SysKonnect Yukon II Gigabit Ethernet
device nfe # nVidia nForce MCP on-board Ethernet
device nge # NatSemi DP83820 gigabit Ethernet
#device nve # nVidia nForce MCP on-board Ethernet Networking
device pcn # AMD Am79C97x PCI 10/100 (precedence over 'le')
device re # RealTek 8139C+/8169/8169S/8110S
device rl # RealTek 8129/8139
device sf # Adaptec AIC-6915 (``Starfire'')
device sis # Silicon Integrated Systems SiS 900/SiS 7016
device sk # SysKonnect SK-984x & SK-982x gigabit Ethernet
device ste # Sundance ST201 (D-Link DFE-550TX)
device stge # Sundance/Tamarack TC9021 gigabit Ethernet
device ti # Alteon Networks Tigon I/II gigabit Ethernet
device tl # Texas Instruments ThunderLAN
device tx # SMC EtherPower II (83c170 ``EPIC'')
device vge # VIA VT612x gigabit Ethernet
device vr # VIA Rhine, Rhine II
device wb # Winbond W89C840F
device xl # 3Com 3c90x (``Boomerang'', ``Cyclone'')

# ISA Ethernet NICs. pccard NICs included.
device cs # Crystal Semiconductor CS89x0 NIC
# 'device ed' requires 'device miibus'
device ed # NE[12]000, SMC Ultra, 3c503, DS8390 cards
device ex # Intel EtherExpress Pro/10 and Pro/10+
device ep # Etherlink III based cards
device fe # Fujitsu MB8696x based cards
device ie # EtherExpress 8/16, 3C507, StarLAN 10 etc.
device sn # SMC's 9000 series of Ethernet chips
device xe # Xircom pccard Ethernet

# Wireless NIC cards
device wlan # 802.11 support
device wlan_wep # 802.11 WEP support
device wlan_ccmp # 802.11 CCMP support
device wlan_tkip # 802.11 TKIP support
device wlan_amrr # AMRR transmit rate control algorithm
device wlan_scan_ap # 802.11 AP mode scanning
device wlan_scan_sta # 802.11 STA mode scanning
device an # Aironet 4500/4800 802.11 wireless NICs.
device ath # Atheros pci/cardbus NIC's
device ath_hal # Atheros HAL (Hardware Access Layer)
device ath_rate_sample # SampleRate tx rate control for ath
device awi # BayStack 660 and others
device ral # Ralink Technology RT2500 wireless NICs.
device wi # WaveLAN/Intersil/Symbol 802.11 wireless NICs.
#device wl # Older non 802.11 Wavelan wireless NIC.

# Pseudo devices.
device loop # Network loopback
device random # Entropy device
device ether # Ethernet support
device sl # Kernel SLIP
device ppp # Kernel PPP
device tun # Packet tunnel.
device pty # Pseudo-ttys (telnet etc)
device md # Memory "disks"
device gif # IPv6 and IPv4 tunneling
device faith # IPv6-to-IPv4 relaying (translation)
device firmware # firmware assist module

# The `bpf' device enables the Berkeley Packet Filter.
# Be aware of the administrative consequences of enabling this!
# Note that 'bpf' is required for DHCP.
device bpf # Berkeley packet filter

# USB support
device uhci # UHCI PCI->USB interface
device ohci # OHCI PCI->USB interface
device ehci # EHCI PCI->USB interface (USB 2.0)
device usb # USB Bus (required)
#device udbp # USB Double Bulk Pipe devices
device ugen # Generic
device uhid # "Human Interface Devices"
device ukbd # Keyboard
device ulpt # Printer
device umass # Disks/Mass storage - Requires scbus and da
device ums # Mouse
device ural # Ralink Technology RT2500USB wireless NICs
device rum # Ralink Technology RT2501USB wireless NICs
device urio # Diamond Rio 500 MP3 player
device uscanner # Scanners

# USB Ethernet, requires miibus
device aue # ADMtek USB Ethernet
device axe # ASIX Electronics USB Ethernet
device cdce # Generic USB over Ethernet
device cue # CATC USB Ethernet
device kue # Kawasaki LSI USB Ethernet
device rue # RealTek RTL8150 USB Ethernet

# FireWire support
device firewire # FireWire bus code
device sbp # SCSI over FireWire (Requires scbus and da)
device fwe # Ethernet over FireWire (non-standard!)
device fwip # IP over FireWire (RFC 2734,3146)
device dcons # Dumb console driver
device dcons_crom # Configuration ROM for dcons

I figure for today, I can probably work on updating my PC-BSD test machine to using FreeBSD 7, for updating the ports that will likely have to wait for later. With luck I can leave it running over night.

I want to spend some time working on the user-interface for NPM, I know what I want but I am not sure what value it will have. Essentially my idea is for the user to select from several implementations of the main window including the ability to use custom made modules for it.

I also want to implement an option by which each module is checked against a given list of checksums, if the module fails the checksum it won’t be allowed to load. With this method one could theroectically restrict any non-NPM supplied window layouts from being loaded but it’s probably a useless feature but one I’d like to tinker with just for the fun of it lol.

I also know if I don’t get a few things out of my head I’m going to pop.. Maybe coding will help :.

Whistling FreeBSD 7

Hehe, as a friend requested a screen shot of when I got FreeBSD 7 up:

[click to enlarge]
Free Image Hosting at www.ImageShack.us

Well actually it is about an hour and a half to two hours after but I dunno how to take a screen shot of FreeBSDs system console without image magic, then again I could’ve always used the camera… But no one wants to stare at the command prompt but me <_<.

FreeBSD 7.0 booted incredibly fast for my exptation, even off the install CD I think it out paced PC-BSD 1.4 (which uses FreeBSD 6.3-stuff). As always I set a few of the install options before hand, low output while installing packages, debugging console on etc. Normally when I setup a FreeBSD box I do a custom installation and exact maximum control over what goes in. For this, I just chose to use the canned X-Kern-Developer installation set which is essentially FreeBSD + Kernel Sources + Xorg which is what I wanted, I’m not expecting to need any sources other then the kernels.

For the optional packages I picked out a bare minimal to get me started, zsh for my user account -> I can use any of the standard shells easy enough but I ‘like’ the zsh hehe. Also portupgrade to ease any installation issues and a desktop environment, I chose to go the gnome2 meta-route.

The install went very fast as usual and the whole time was basically spent installing X and associated crap. It did however bomb out on LibIDL not being found on disk 2 fragging the gnome install so it would seem and barfing at the ruby package on the disk set. I think this is rather /strange/ for having downloaded all 3 ISO’s to avoid things like that… But hey, I don’t mind. Usually when I install FreeBSD I only take off the CD-ROM’s what I’ll need to get the machine connected to the internet, usually nothing as far as whats in ports goes.

However despite the lack of a desktop and portupgrade utility I booted into an other wise fully functional system. Mounted my existing install on /mnt and merged my network config into the FreeBSD 7.0-RELEASE one and copied over the xorg.conf file, volia we have working internet and X.Org ! No need to even load kernel modules, although sound didn’t work because I never added the line to /boot/loader.conf for it: no problem on a test install. Whether or not sysinstall has gained the ability to handle WPA Encryption over the years I didn’t bother because setting up my well supported PCMCIA card is a breeze as long as you can use a text editor.

I then set the gdm_enable variable in /etc/rc.conf then I had to change the site to fetch packages from because ftp.FreeBSD.org was still shouting about to many connected users so I set PACKAGEROOT to ftp://ftp13.us.FreeBSD.org/ in roots .login file, logged in & out and proceeded to pkg_add portupgrade and gnome2.

That took about an hour !!!! A little toying with pkg_info and wc, and I would say that gnome depends on about 365+ things… Glad I got a working X.Org install off the CD-ROM… It took ****for freaking ever**** to download all of the packages for gnome but one console command and a single line added to the config file and it just /works/ out of the box after a reboot, although of course I already had the xorg.conf file hehe.

I’m a KDE user by taste not a Gnome one but I decided to install Gnome and while I don’t care much for Gnome I am glad to see that aside from the long wait that installing and setting up Gnome on FreeBSD is as painless as it gets thanks to the hard work of those maintaining the port. Now, customizing Gnome to do your evil bidding is some times problematic hehe. I only like two things about Gnome, that it looks nice (usually) and that it gets well the **** out of your way.

If that is worth the horrendous inefficient user interface they have for file open/save dialogs I dunno… But KDE is the best in that regard that I’ve ever seen.

There was just one small problem, since the FreeBSD 7.0-RELEASE install was going into a partition previously housing a linux distro I was testing a few months ago, it also took with it the GRUB configuration as was planned. So I had my GAG install CD ready before I started with FreeBSD because I knew I was going to be removing the boot loader I was using for PC-BSD (GRUB).

The problem, 2 OSes setup for booting in GAG but only the first would boot (FreeBSD 7). I even used the install disk to overwrite GAG with BSDs normal boot manager but no luck, it wouldn’t boot ad0s2a ! When ever I chose to boot off the second partition in GAG it would boot off the first, FreeBSDs boot manager would just beep at the second partition.

There is always more then one way to screw with a boot procedure, man I love thinking ^_^. Loaded up my trusty never wanta leave home without it Knoppix Linux LiveCD and used QTParted to unmark ad0s1a (FreeBSD 7) as active and to make extra sure I did the same to ad0s2a (PC-BSD 1.4) and set ad0s2a active again before commiting my changes.

Reboot and reinstall of GAG, PC-BSD boots fine and so does FreeBSD !

I know you’re only supposed to have one partition marked active and GOD and IBM only know what could happen if more then one ended up set active :. I figured that either GAG had to be goofing it up or there was some thing slagged. Sure enough QTParted told me both partitions were marked active..

I ain’t gonna ask how, not even if it is possible, so long as nothing explodes and my laptop works fully I am a happy spider hehe.

In my personal opinion, aside from my booting mixup I think any one able to read & understand English (I’ve never tried installing in another language) could get a working desktop in less then 2 hours if they sought after the suitable level of knowledge to configure there systems internet connection, for most wired users that is a cake walk during the install. And to setup an X.Org config file which is not a very hard task, when the proper values work that is lol.

PC-BSD on the other hand, 30-45 minutes time spent installing (mostly installing the files while you relax) and you have a fully functional KDE Desktop. That’s why I have PC-BSD on my laptop, because other wise I would have to install KDE manually… in which case I would probably skip it and just install amarok and friends 😉

With the increased performance in FreeBSD 7, I can’t wait to see PC-BSD 2.0 when they finally switch over. It should sure as heck boot faster for them then Ubuntu on a first date 😉

One thing I personally find weird, when I do have a problem 90% of the time if it makes sense I can figure out the problem eventually. The other 10% of the time, what makes sense doesn’t work 8=) so the only solution is to ‘fsck with it a bit.

Downloading FreeBSD 7.0-RELEASE and hoping my internet connection doesn’t fuck up on me…. freaking phones !!!

I’d like to tell bellsouth where they can stick there equipment…

Currently running 334MB of 509MB (rounded) and going at 270~340KB/Sec and still going full steam a head downloading i386 Disc #1.

I’m shocked really, the main download server already popped past the max connection limit when I went to browse the files.

Seeing the situation I started looking to see which US mirror was the fastest, several seemed to be KiA when I started pinging to find the best response time. Oddly enough ftp13.us.FreeBSD.org had the best response and by a vast majority !!!

Oh baby is this gonna be a goooooooooood release xD. I started with FreeBSDs 6.0-RELEASE and look forward to seeing the things coming out of current hehe. There’s also a driver for 7.0 that I want to test out some time soon, I might have to wait awhile… I know my desktop did a kernel compile of 6.1-Release in like ~45 minutes but my laptop is not quite as powerful….

Haha, this reminds me of when my file server ran FreeBSD. Chugging away on that little 500Mhz Pentium III it used to take like 6 to 8 hours to recompile the entire operating system but always rock solid.

Even if I was sound asleep by the end <_<

FreeBSD 7 draws near!

I think the word is euphoria hehe.

FreeBSD 7.0 is nearing it’s release with many many improvements, if I was in the business of having huge SMP servers doing lots of databases and network intensive stuff I’d probably have testing going on for months in advance..

Being a single spider, well I’ve yet to test it xD

So far FreeBSD 7 is looking like it is the best software update to hit my radar since Vim gained spell checking support in it’s own 7.x release 😉

Blessed number seven hehe !

I’ve already nearly blown out the walls and then my ears setting the radio ^_^ Celebration time ! Hooyah !

Creating Firefox searchplugins for any site – including Qt !

You know, Firefox and friends have a nice search system but there are so many websites that just don’t have a canned search plugin you can install like the Wikipedia and Google ones. Because I use Qt and Python for most work on Neo Ports Manager I tend to RTFM a lot and one of the things I truly love about using KDE’s Konqueror webbrowser is I can go to the address bar and

qt3: someclass

and it will take me there, in fact I have it setup in Flock at the moment to use qt3, qt4 e.t.c as keywords to take me to the index. The thing is, I would like to search, after all there is a bloody search bar !

I tried looking online on how to make one but didn’t find any thing helpful, I think the stuff was written for Firefox 1.x so to heck with it. I opened profile and looked for where the search scripts were located. My laptop and desktop use Flock as the default web browser but the only difference this should make here is that my profile is stored in ~/.flock instead of ~/.mozila/*

The searchplugins are in your user profile, for me with flock it is:

/home/Terry/.flock/browser/t247gnll.default/searchplugin

On Windows the profile goes in your %UserProfile%Application Data in a folder such as mozillafirefoxprofile-name or flockbrowserprofilename depending on the browser you are using. Don’t have a Mac so dunno where it goes on there but thats why there is a FAQ online 😉

In here are several XML files,

Terry@dixie$ ls                                                            7:25
dictcc.xml gmail.xml qt3.xml youtube.xml
dictionarycom.xml photobucket.xml weathercom.xml
Terry@dixie$ 7:26

Each one is a search plugin in the search bar in the top right of my browser, qt3.xml is a file of my own creation.

If you are like me, when you are surfing the fine web you occasionally look at the URL’s of the web pages you visit, since I spend alot of time looking around at the Qt documentation I know that the documentation for each class is stored as ClassName.html in a specific folder on trolltechs web servers. This means if you can find out how your favorite website stores it’s files you can create a search plugin for nearly any website on the world wide web !!!!

I opened the dictcc.xml file to see how it is done, so simple it is easy as pie. And unlike Operas easy way of doing it in the GUI, we can set an ICON to use in the search bar 🙂

Qt class docs are in http://doc.trolltech.com/major-version.minor-version/classname.html so we want the text we type in the search bar to be replace the classname part of the URL with out search text, we do that with a little string interpolation.



Qt Toolkit
Qt3 - Search all classes
UTF-8
data:image/x-icon;base64,
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAACQkWg2AAABtUlEQVQokY2Rv0sbYRjHv+97d1zu
8gtzwauGGmgjXU+hpaVCMlUMDnZox4IS/AvcCg4Obv4HLZk6dNLFJJ3SQoYkpSTQVUMj8Vf10KaX
O+Jd7u2QkHha0O/4PJ8Pz/PwkE8/XuB+cWwGBv6eNIAri7nuLeG4Yde/WidNGwxqXNBS0uRjod+S
QxQAGa7EXOSz7Uquw9jIJwRP5+V0JkzpoDKakM+2y7sdUSJzS4HEjAiC/Vq3tGNUCyaAxdVwH6PD
TSq5jiiRzKaSfBOIJYSwwkVjfGZT8cn0+xfzcM/2CPVvFmN4uRRQ4wIA49LNruufty7OWr25137G
UC+aHuH0lw0goYlD+qzljKncwyfC9IwI4PTA8QiDE6/Rnuq1DI5W40Lj59VevTs+xetHTmSCo5Sc
HzrZdX161gdAneI9E7SURAhKO0bkAfd2bWxlQ1neUKIxXj/ulXc7hEBLyR5h4pHwbMHftdiH9/p5
yzEu3b8Xvf72AHwBGowMyNHjXBf5j3+qBfPG46QgNdvu87Q/nQl5hH6O9u1a0frdtAGMx3ktKYei
XGnbePUuyPHkP8KdoXcj3vwDRIGtlNEJQYAAAAAASUVORK5CYII=





I saw that icons were encoded in Base64 much like with E-Mail attachments by looking at the dictcc.xml file so I wanted to include an icon for my qt3.xml search plug.

So I went to trolltechs website, downloaded their logo, opened it in kolourpaint and resize/scale’ed it down to 16×16. I then searched for a base64 encoder/decoder that could handle more then plain text, because opening an image file in a text editor to copy/paste is a pain in the neck. I consider this fair-use of the logo, if Trolltech doesn’t they can write me a search plugin ^_^.

I copy and pasted the encoded form of the icon into the file as you can see above and volia we have a search plugin muhauahauha ! Then saved the file, restarted flock, wrote “QLineEdit” in the search bar without qoutes and clicked the ‘Qt Toolkit’ entry and flock opened a new tab with the QLineEdit class documentation for Qt3.3 ;-).

In a few minutes I will make a Qt4 one and change the ShortNames accordingly. With a little attention to detail this means a search plugin can be created by most any user for most any website. In fact with a little work I could probably set it up so I could search the [SAS] or PC-BSD forums this way, either through the search functions ability to look for topics posted or by thread #’s to go straight to a thread (which would not be fun to have to search by!).

I wonder if with a little poking around at the Open Search and XML specifications if I could have the searchTerms passed on to a perl script to do a a few tricks and pass it back in… I should look at that option some day hehe.

I love it when people make it so you can plug into an application without having to compile crap !

Windows will make you bald

Today I had to set my Sister (in-law) with an e-mail account and access to it via my moms Desktop. So of course the obvious question is either she needs her own user account (in windows) plus the e-mail account or ma’s outlook would have to be setup to deal with the multi-login.

So I created the new user account for her, gave her an icon for outlook express next to the recycle bin and internet explorer (v6.x) on the desktop, set a wall paper and user pic (she loves Betty Boop).

Trying to find the docs on Bellsouth/AT&T’s website for creating a new e-mail account was not exactly as quick as I hoped but still easy as pie. I used my PC for that and RvS crashed in the process lol.

On Ma’s PC while logged in as the new user account for set up. I got a pop up from the windows security center just to tell me info I already knew. The Dell Support Center came up too, which we haven’t seen come up in many a year now ! Internet Explorer came up 404 on the pre-set home page (dellnet or some thing) and outlook express gave an error about the computer having no internet connection. Told it to go fsck itself and moved on and arranged for a pop-up less user log in.

Either AOL must have/had an in with Microsoft or a nice hackling plugin because outlook was set to launch AOL Instant Messenger on start up! And a general option for it too, like what the heck man. Now M$N or some thing from Microsoft I could understand but not AIM rofl. Although that PC’s got the good AOL client for AIM, the install is like 3 years old so it’s a version before AOL bloated the thing out. Which is really why I took to using all in one messengers like Kopete.

So I had to get that disabled, change the user picks, change the user names to match blah blah. Norton 360’s added toolbar in IE6 is not exactly welcome by my family — note to self, under no condition allow users to use IE as a default browser if I’m ever tasked with admining windows machines. And ban all Nortan and Mccfee products on machines with less then 768MB of Memory. In point of fact, make sure they pay extra for the psychiatrist bill for working with Windows.

So kicking about with Windows XP, Dell, Outlook Express, and AOL it was no problem to set up. But oh boy oh boy will you never find me using Windows for more then “Gaming” and similar reasons while Microsoft and other companies still are in power.

I’m a Unix man by nature and have a militaristic mind set. I value clear concise no shit assessments and not being nagged by pointless and flashy programs popping up taking several seconds to display only to tell me what I already know or worse try to sell me some thing 8=)

Windows, wouldn’t touch it with a 10 foot long cattle prod if I had a choice… Still it’s the only decent platform for playing *real* video games on. Experience has shown the consoles are, uhh I’ll zip my trap before some googler flames me <_< hehe.

This reminds me of why I do not want to buy Microsoft VISA, why my laptop and file server run Open Source unix based operating systems, and why I use few programs that are known to “annoy” me. I want to get work done, I know how to read the fine manual, and software that bitches at the user should be fed through a hex editor, operating systems included 🙂

FreeBSD, now that is a sensible design… it won’t nag you ever ten minutes or so.

With similar hardware specs between my laptop and ma’s desktop, the only other principal difference being I have a Sempron Mobile (AMD budget model laptop CPU) and hae has an early Pentium 4 (when 2Ghz was new and costly). My laptop running FreeBSD runs faster then her Desktop running Windows XP SP2 + NAV and now Norton 360 – even while running KDE on the laptop. Programs like Norton remind me why I’ve heard jokes about system admins automatically having a users quota reduced for trying to run heavy programs on time sharing systems hehe.

RIP nVidia GeForce 6200, PoS@256mb

Well, to make a long story shorter..

Whent to join TG#1 to kill some stress but it was full, supper was soon so I switched to TG#3 instead and went to join Duke for a round.

Before the round started I had to getup and do some thing and ma moved my chair out so she could get to the printer so I had to wait. By the time I got to sit back down my computer had already had the monitor blip and the PC restart — from running SWAT4:TSS to showing the BIOS start screen… if there was any error message before that I didn’t get a chance to see it.

On each restart that followed the monitor was all funky and kept blipping on and off as if the signal wasn’t working.

Instantly my brains thinking monitor, monitor cable, graphics card, fans, and motherboard for possible problems. Hooked up the monitor I got from the Library for a few bucks, same effect. Opened the case, blew the crap out of it with a can of air. Yanked all of the PCI family cards out, Audigy 4, TV Tuner, GeForce 6200 e.t.c and gave them a go. Cut my finger trying to get the graphics card out of it’s PCI-Ex16 slot, freaking plastic lever was to buried to see which way it angled.

Unscrewed the main (looked 90mm) fan from the case but the power connector was to short to pull it clean for cleaning… Couldn’t get that unplugged so I pulled out the (E)IDE cable connecting the DVD-ROM’s and one of the 512MB RAM DIMMs and still couldn’t get the flib’n thing out.. So I ended up cleaning it with a paper towel half over the PSU, half over the mother board : Needless to say I didn’t even want to mess with the issue of getting to the CPU.

Managed to get that screwed back in and then I had to pull the main power off the motherboard to get the RAM slot back in (the slots are right under the worst tangle of power cabling!). The inside of the PC was dusty but not that bad, most of it was just on the fan blades and the front side vents (veeerrrryyyy bad) but still cleaner then Ma’s Dell and that things been running forever without a cleaning, like once in 7+ years.

Booted her back up and still no luck although the main fan was running a heck of a lot better the temp was still normalD. I noticed though that my motherboard had a port for a monitor on it with a cover. I remember there was a note taped on it when I first set up the computer < 2 years ago.
Interestingly while the monitor was displaying screwy when plugged intot he Geforce 6200, maybe even some kind of pixel array during the computers startup. It was perfectly fine when in the BIOS setup, maybe because it would have to be used at a really low level dunno. Set the BIOS Video configuration from AUTO to Integrated, restarted and changed ports.

Using the onboard 128MB Intel GMA it works… RVS works fine to but RvS will work with just about any thing made after the stone age if it supports the right features.. With how over-optimized RvS is you could probably run it on a Cuisinart without trouble : SWAT4:TSS on the other hand is quite sensitive to ATI/nVidia drivers and essentially resulted in an impossible to kill application.

All of the other computers here use AGP so Ic an’t even test the card or a different card in the slot, so I hope it’s the GeForce 6200 and not part of the Motherboard..

So it looks like I have to either give up on S4 or buy a new Gfx card.. I know I’ve often thought about upgrading if finances allowed but this does not make me happy. Data failure is cheap, use backups but when the hardware goes nuts what do you do?

Upgrade to GeForce 8400GS and it’s fixed… Guess it was the GeForce 6200 going bad :