Posts in category misc

Chrome on CentOS 7

So my Google Chrome on my CentOS 7 box updated, and SELinux doesn't like it.

There's an official bug for it - https://bugzilla.redhat.com/show_bug.cgi?id=1251996 - but I don't know when that will propagate down.

Until then, here's what I did, with some plaintext showing what was happening:

$ sudo grep chrome /var/log/audit/audit.log | grep setcap | audit2allow
#============= chrome_sandbox_t ==============

#!!!! This avc is allowed in the current policy
allow chrome_sandbox_t self:process setcap;

$ sudo grep chrome /var/log/audit/audit.log | grep setcap |
audit2allow -M chrome.pol
******************** IMPORTANT ***********************
To make this policy package active, execute:

semodule -i chrome.pol.pp

$ cat chrome.pol.te

module chrome.pol 1.0;

require {
        type chrome_sandbox_t;
        class process setcap;
}

#============= chrome_sandbox_t ==============

#!!!! This avc is allowed in the current policy
allow chrome_sandbox_t self:process setcap;

$ sudo semodule -i chrome.pol.pp

Scripting konsole and tabs

At work I want to launch two programs in separate tabs in konsole from a script, so I whipped this one up:

#!/bin/bash

checkfile() {
  if [ ! -f $1 ]; then
    echo "could not find $1"
    exit 99
  else
    echo "OK"
  fi
}

# Check for App1 XML
echo -n "Checking for App 1 XML... "
XMLA=/domain/DM.xml
checkfile ${DEVROOT}/${XMLA}

# Check for App2 XML
echo -n "Checking for App 2 XML... "
hostname=$(hostname)
XMLB=/domain/DM_${hostname}.xml
checkfile ${DEVROOT}/${XMLB}

# Launch Konsole
echo -n "Launching konsole... "
K=$(dcopstart konsole-script)

[ -z "${K}" ] && exit 98
# Create second tab and resize
SDA=$(dcop $k konsole currentSession)
SDB=$(dcop $k konsole newSession)
dcop $K $SDA setSize 121x25

# Let bash login, etc.
sleep 1

# Rename the tabs
dcop $K $SDA renameSession "App 1"
dcop $K $SDB renameSession "App 2"

# Start services, letting user watch
echo -n "starting app1... "
dcop $K konsole activateSession $SDA
dcop $K $SDA sendSession "echo -ne '\033]0;DEV (${hostname})\007' && clear && starter $XMLA"
sleep 2
echo -n "starting app2... "
dcop $K konsole activateSession $SDB
dcop $K $SDB sendSession "echo -ne '\033]0;DEV (${hostname})\007' && clear && starter $XMLB"
echo done.

The funky echo commands will set the application title to "DEV (hostname)" while the tab title is set with renameSession.

PAR2 file mover

This is my first Ruby script… please feel free to contact me with feedback.

It will read a PAR2 parity file and move all the files in it to a subdirectory. The original thing I asked for:


I know you can currently download into subdirectories based on ID3 tags. I would love to be able to have downloads go into subdirectories based on the PAR2 file that "covers" them.

Example, all files downloaded overnite into a huge directory:

AAA.PAR2
AAA 01-16.mp3
AAA 02-16.mp3
...
AAA 16-16.mp3
AAA.nfo
AnnoyinglyNamedNothingLikeAAAButInThePARFileAnyway.nfo
BBB.PAR2
BBB 01-92.mp3
BBB 02-92.mp3
...
BBB 92-92.mp3
BBB.nfo
...
XXY.PAR2
XXY.mp3
XXY.txt

So I would want them moved into the subdirectories "AAA", "BBB", "XXY", etc. It wouldn't be perfect but it would be a great start for what I do to process my inbound stuff.

If not, how about dumping some log file I can parse in perl or ruby that gives me "AAA.LOG" which lists the files that went with AAA.PAR2 ?


Of course, being a borderline OCD engineer, I didn't just solve the problem but also put together a full object-oriented infrastructure to parse and process PAR2 files. I've only handled one packet type defined in the PAR2 specifications, but put in place a Par2BasePacket with an interface that all the other packet types can be derived from.

Without further delay, see the attached code (sorry, my install doesn't support syntax highlighting of ruby and I don't have time now - but you can paste the code into this online highlighter).

Xilinx BIT files and the Linux/Unix/BSD "file" command

The attached file will ID a Xilinx BIT file and tell you when it was compiled, the original NCD file name, and most importantly the chip it is for. It doesn't give a speed grade, but it gives all the other stuff.

All credit goes to the FPGA FAQ Question 26.

To install on a machine that already has file installed (yours probably does) you need to find your magic file. I will present what I did on a Cygwin box as an example, season to taste:

  1. cd /usr/share/file/
  2. rm -rf magic.mgc
  3. cat /tmp/xilinx-magic >> magic
  4. file -C

The last command "compiles" the magic file into magic.mgc. To make sure it all worked, you can grep -i xilinx magic* and see a few spots.

Example output:

admaras@brisingamen ~/projects/ss/trunk/vhdl
$ file */*bit
BenADDA/benadda.bit:                Xilinx BIT file - from BenADDA.ncd - for 2v6000ff1152 - built 2007/ 6/27(13:19:26) - data length 0x23d014ff
BenADDAV4/benadda.bit:              Xilinx BIT file - from BenADDA.ncd - for 4vsx55ff1148 - built 2008/01/07(15:37:49) - data length 0x1f3928ff
BenADDAV4_Clock/mybenaddaclock.bit: Xilinx BIT file - from MyBenADDAClock.ncd -for 2v80cs144 - built 2008/01/11(14:18:37) - data length 0x1652cff
BenDATAV4/bendatadd.bit:            Xilinx BIT file - from BenDATADD.ncd - for 4vlx160ff1148 - built 2008/01/11(17:53:27) - data length 0x4cf4b0ff
BenNUEY/bennuey.bit:                Xilinx BIT file - from BenNUEY.ncd - for 2vp50ff1152 - built 2008/01/10(17:14:41) - data length 0x2447c4ff

This file has been submitted to the maintainer of the file command so some day may come with a default build.

Automated diffs in trac

Somebody on the mailing list for trac wanted to make a daily wiki page with the diffs for a build. He already had the scripts to do a nightly build, so I suggested this, and tried it and it worked:

echo {{{ > /tmp/tempo
echo '#!diff' >> /tmp/tempo
svn diff -r70:76 >> /tmp/tempo
echo }}} > /tmp/tempo
trac-admin /var/www/trac/personal wiki import TodaysDiff /tmp/tempo

Roll your own subversion

Under Cygwin…

Waiting for an official subversion 1.4 - but until then, I lost my command line svn because Tortoise SVN (awesome BTW) updated my working copy to the new format.

Abbreviated setup (I'm not telling you how to use tar, etc). It's also good idea to disable your virus scanner for a few minutes. Spawning processes under cygwin is painful to start with…

  1. Download both subversion and it's deps. Currently:
    http://subversion.tigris.org/downloads/subversion-deps-1.4.0.tar.bz2
    http://subversion.tigris.org/downloads/subversion-1.4.0.tar.bz2
    

These are from http://subversion.tigris.org/servlets/ProjectDocumentList?folderID=260&expandFolder=74

  1. Extract them both
  2. $ ./configure --prefix=/usr/local/svn14 --enable-all-static --disable-mod-activation
  3. make all
  4. make check

(You can usually just do "make check" but there seems to be a bug where it won't properly build the dependencies)

  1. make install
  2. add to .profile:
    alias svn14="/usr/local/svn14/bin/svn"
    

I have done this on two machines now. On both, some symlink stuff failed under one of the python checks. Oh well…

Make DVD Installer from CDs

Just stumbled on this online. Feel free to extrapolate:

  1. Create a Temp folder on harddrive. Name this folder "HL2_DVD" This will be the Label of our DVD.
  2. Copy all contents of CD1 to this Temp folder.
  3. From CD2 copy just two files! The "cab" file (hl2.CAB) and the "installer.dll" file to the main directory of the Temp folder.
  4. From CD3 copy the "hl23.CAB" file to the main directory of the Temp folder.
  5. From CD4 copy the "hl24.CAB" file to the main directory of the Temp folder.
  6. From CD5 copy the "hl25.CAB" file to the main directory of the Temp folder.
  7. Now download and install "Orca".
  8. Once Orca is installed go to the Temp folder and right click the file "hl2.msi" and from near the top of the menu choose "Edit with Orca".
  9. When opened you will see 2 window panes, go to the "Tables" one on the left and scroll down to Media"
    1. Click on "Media" this will show you the entries in the Right pane. There will be 6 columns.
    2. Change all the entries in the "VolumeLabel" column to HL2_DVD
    3. Then "Save" it. (You can also use a program called "Masai Editor" instead of "Orca")
  10. Now burn to a DVD using Nero using the Label HL2_DVD.

Tater Tot Casserole

http://tinyurl.com/awhjk

Ingredients: 1 32 oz bag tater tots
½ cup sour cream
½ cup butter
1 cup cheddar cheese
1 can cream of chicken soup
½ med onion (chopped)
1 cup corn flakes

Directions: Thaw tater tots and break up. Add ingredients one by one, mixing after each. Spread in buttered pan, best if let set overnight. Top with corn flakes that have been mixed with ½ cup melted butter. Cook at 350 for 50 mins.

My DIY Bike Rack

Shutting down VMWare clients

In /etc/services on CLIENT:

# Local services
shutdown 6666/tcp

In /etc/inetd.conf on CLIENT:

shutdown stream tcp nowait root /sbin/shutnow

In /sbin/shutnow of CLIENT: (you can prolly get rid of this and move this all into inetd.conf above, but I used to do other things too…)

#!/bin/bash
/sbin/shutdown -h now

On the CLIENT's iptables rules, I have:

0 0 DROP tcp -- eth1 * 0.0.0.0/0 0.0.0.0/0 tcp dpt:6666

So nobody can reach that port from eth1 (internet). The host will be hitting the port on eth2 which is the host-only virtual network.

Then on the HOST in /etc/init.d/kill_vms (new file):

#!/bin/sh
#
# chkconfig: 4 90 08
# description: Kills VMs on shutdown/reboot
/usr/bin/telnet 192.168.90.201 6666 < /dev/zero
PIDS=fake
while [ "foo$PIDS" != "foo" ]
do {
echo "Delaying shutdown... VMWare still on $PIDS"
sleep 10
PIDS=`pidof vmware-vmx`
};
done

So then on the server you install the "kill_vms" with chkconfig (fix the IP from 192.168.90.201 to your virtual client IP of course!).

It won't work the first time you reboot, sorry. If you 'touch' the file /var/lock/subsys/kill_vms (at least on my ancient RH based system) then it should. Also, it will hang forever if you don't have the virtual machine set to 'Close on shutdown' and I think maybe another option in VMWare about closing if all clients close.

More cpio tricks

Cleaning out my desk and came across these notes…

find /mnt/old_root -depth -print | cpio -odv | gzip -c -v -1 > /opt/bad_disk/old_root.cpio.gz

find -depth -print | cpio -odv > tempo.cpio
cpio -idvm < tempo.cpio

Neat trick:

tar cf - . | (cd /usr/local ; tar xvf - ) 

Bank routing numbers

Lazy Origami

How Old Are You?

http://www.onlineconversion.com/howold.htm

Today is my 10430th day. Yay.

Here's the PCI Spec I DID find...

Google Groups Link

              The PCI (Peripheral Component Interconnect) Bus

This file is not intended to be a thorough coverage of the PCI standard.
It is for informational purposes only, and is intended to give designers
and hobbyists an overview of the bus so that they might be able to design
their own PCI cards. Thus, I/O operations are explained in the most
detail, while memory operations, which will usually not be dealt with
by an I/O card, are only briefly explained. Hobbyists are also warned
that, due to the higher clock speeds involved, PCI cards are more
difficult to design than ISA cards or cards for other slower busses.
Many companies are now making PCI prototyping cards, and, for those
fortunate enough to have access to FPGA programmers, companies like
Xilinx are offering PCI compliant designs which you can use as a starting
point for your own projects.

For a copy of the full PCI standard, contact:

     PCI Special Interest Group (SIG)
     PO Box 14070
     Portland, OR 97214
     1-800-433-5177
     1-503-797-4207

     There is also a spec for CompactPCI, which uses the same timing
and signals, but uses a eurocard connector and format. This is not
presently covered in any detail within this document.


Pinout (5 volt and 3.3 volt boards)

 
               -12V     01      *TRST
                TCK             +12V
                GND             TMS
                TDO             TDI
                +5V             +5V
                +5V             *INTA
              *INTB             *INTC
              *INTD             +5V
            *PRSNT1             reserved
           reserved     10      +I/O V (+5 or +3.3) 
            *PRSNT2             reserved
                GND   Key3.3    GND
                GND   Key3.3    GND
           reserved             reserved
                GND             *RST
                CLK             +I/O V (+5 or +3.3)
                GND             *GNT
                REQ             GND
+I/O V (+5 or +3.3)     20      reserved
               AD31             AD30
               AD29             +3.3V
                GND             AD28
               AD27             AD26
               AD25             GND
              +3.3V             AD24
              C/BE3             IDSEL
               AD23             +3.3V     
                GND             AD22      
               AD21             AD20
               AD19     30      GND
              +3.3V             AD18  
               AD17             AD16
              C/BE2             +3.3V
                GND             *FRAME
              *IRDY             GND
              +3.3V             *TRDY
            *DEVSEL             GND
                GND             *STOP
              *LOCK             +3.3V
              *PERR     40      SDONE
              +3.3V             *SBO
              *SERR             GND
              +3.3V             PAR
              C/BE1             AD15
               AD14             +3.3V
                GND             AD13
               AD12             AD11
               AD10     49      AD9
                GND    Key5     GND
                GND    Key5     GND
                AD8     52      C/BE0
                AD7             +3.3V
              +3.3V             AD6
                AD5             AD4
                AD3             GND
                GND             AD2
+I/O V (+5 or +3.3)             +I/O V (+5 or +3.3) 
             *ACK64     60      *REQ64
                +5V             +5V
                +5V     62      +5V
             
             (64 Bit Bus Extension Only)
           reserved     63      GND      
                GND             C/BE7
              C/BE6             C/BE5
              C/BE4             +I/O V (+5 or +3.3)
                GND             PAR64
               AD63             AD62
               AD61             GND
+I/O V (+5 or +3.3)     70      AD60
               AD59             AD58
               AD57             GND
                GND             AD56
               AD55             AD54
               AD53             +I/O V (+5 or +3.3)
                GND             AD52
               AD51             AD50
               AD49             GND
+I/O V (+5 or +3.3)             AD48   
               AD47     80      AD46
               AD45             GND
                GND             AD44
               AD43             AD42
               AD41             +I/O V (+5 or +3.3)
                GND             AD40
               AD39             AD38
               AD37             GND
+I/O V (+5 or +3.3)             AD36   
               AD35             AD34
               AD33     90      GND
           reserved             reserved
           reserved             GND
                GND     94      reserved


* - Active Low


PCI slots are keyed so that a 3.3 volt card cannot be plugged into a 5
        volt slot, and a 5.5 volt card cannot be plugged into a 3 volt
        card. Dual voltage cards are possible.
Key3.3 - At this location, a key is present on 3.3 volt boards. On 5 volt
        boards, these pins are GND.
Key5 - At this location, a key is present on 5 volt boards. On 3.3 volt 
        boards, these pins are GND.

Signal Descriptions:

AD(x): Address/Data Lines.
CLK: Clock. 33 MHz maximum.
C/BE(x): Command, Byte Enable.
FRAME: Used to indicate whether the cycle is an address phase or
     or a data phase.
DEVSEL: Device Select.
IDSEL: Initialization Device Select
INT(x): Interrupt
IRDY: Initiator Ready
LOCK: Used to manage resource locks on the PCI bus.
REQ: Request. Requests a PCI transfer.
GNT: Grant. indicates that permission to use PCI is granted.
PAR: Parity. Used for AD0-31 and C/BE0-3.
PERR: Parity Error.
RST: Reset.
SBO: Snoop Backoff.
SDONE: Snoop Done.
SERR: System Error. Indicates an address parity error for special cycles
        or a system error.
STOP: Asserted by Target. Requests the master to stop the current transfer 
        cycle.
TCK: Test Clock
TDI: Test Data Input
TDO: Test Data Output
TMS: Test Mode Select
TRDY: Target Ready
TRST: Test Logic Reset


The PCI bus treats all transfers as a burst operation. Each cycle begins
with an address phase followed by one or more data phases. Data phases
may repeat indefinately, but are limited by a timer that defines the
maximum amount of time that the PCI device may control the bus. This
timer is set by the CPU as part of the configuration space. Each device
has its own timer (see the Latency Timer in the configuration space).

The same lines are used for address and data. The command lines are also
used for byte enable lines. This is done to reduce the overall number
of pins on the PCI connector.

The Command lines (C/BE3 to C/BE0) indicate the type of bus transfer during
the address phase.

C/BE    Command Type
0000    Interrupt Acknowledge
0001    Special Cycle
0010    I/O Read
0011    I/O Write
0100    reserved
0101    reserved
0110    Memory Read
0111    Memory Write
1000    reserved
1001    reserved
1010    Configuration Read
1011    Configuration Write
1100    Multiple Memory Read
1101    Dual Address Cycle
1110    Memory-Read Line
1111    Memory Write and Invalidate


The three basic types of transfers are I/O, Memory, and Configuration.


PCI timing diagrams:


            ___     ___     ___     ___     ___     ___    
CLK     ___|   |___|   |___|   |___|   |___|   |___|   |___

        _______                                   _________
FRAME          |_________________________________|

                ______  _______  ______  ______  ______
AD      -------<______><_______><______><______><______>---
                Address  Data1    Data2   Data3   Data4

                ______  _______________________________
C/BE    -------<______><_______________________________>---
                Command   Byte Enable Signals

         ____________                                   ___
IRDY                 |_________________________________|

         _____________                                  ___
TRDY                  |________________________________|

         ______________                                 ___
DEVSEL                 |_______________________________|


PCI transfer cycle, 4 data phases, no wait states.
Data is transferred on the rising edge of CLK.


                         [1]              [2]        [3]
            ___     ___     ___     ___     ___     ___     ___     ___
CLK     ___|   |___|   |___|   |___|   |___|   |___|   |___|   |___|   |__

        _______                                                  _________
FRAME          |________________________________________________|

                                   A               B               C
                ______           ______________  ______  _____________
AD      -------<______>---------<______________><______><_____________>---
                Address           Data1           Data2   Data3

                ______  ______________________________________________
C/BE    -------<______><______________________________________________>---
                Command   Byte Enable Signals

                                                         Wait
         ____________                                    _____         ___
IRDY                 |__________________________________|     |_______|

                        Wait            Wait
         ______________________         ______                         ___
TRDY                           |_______|      |_______________________|

         ______________                                                ___
DEVSEL                 |______________________________________________|


PCI transfer cycle, with wait states.
Data is transferred on the rising edge of CLK at points labled A, B, and C.



Bus Cycles:


Interrupt Acknowledge (0000)

        The interrupt controller automatically recognizes and reacts to
the INTA (interrupt acknowledge) command. In the data phase, it transfers
the interrupt vector to the AD lines.


Special Cycle (0001)

        AD15-AD0
        0x0000                  Processor Shutdown
        0x0001                  Processor Halt
        0x0002                  x86 Specific Code
        0x0003 to 0xFFFF        Reserved


I/O Read (0010) and I/O Write (0011)

        Input/Output device read or write operation. The AD lines contain
a byte address (AD0 and AD1 must be decoded).
PCI I/O ports may be 8 or 16 bits.
PCI allows 32 bits of address space. On IBM compatible machines, the
Intel CPU is limited to 16 bits of I/O space, which is further limited
by some ISA cards that may also be installed in the machine (many ISA
cards only decode the lower 10 bits of address space, and thus mirror
themselves throughout the 16 bit I/O space). This limit assumes that the
machine supports ISA or EISA slots in addition to PCI slots.
        The PCI configuration space may also be accessed through I/O
ports 0x0CF8 (Address) and 0x0CFC (Data). The address port must be
written first.


Memory Read (0110) and Memory Write (0111)

        A read or write to the system memory space. The AD lines contain
a doubleword address. AD0 and AD1 do not need to be decoded. The Byte
Enable lines (C/BE) indicate which bytes are valid.


Configuration Read (1010) and Configuration Write (1011)

        A read or write to the PCI device configuration space, which is
256 bytes in length. It is accessed in doubleword units.
AD0 and AD1 contain 0, AD2-7 contain the doubleword address, AD8-10
are used for selecting the addressed unit a the malfunction unit,
and the remaining AD lines are not used.

Address     Bit 32      16   15           0

00          Unit ID        | Manufacturer ID
04          Status         | Command
08          Class Code               | Revision
0C          BIST  | Header | Latency | CLS
10-24            Base Address Register
28          Reserved
2C          Reserved
30          Expansion ROM Base Address
34          Reserved
38          Reserved
3C          MaxLat|MnGNT   | INT-pin | INT-line
40-FF       available for PCI unit


Multiple Memory Read (1100)

This is an extension of the memory read bus cycle. It is used to read large
blocks of memory without caching, which is beneficial for long sequential
memory accesses.


Dual Address Cycle (1101)

        Two address cycles are necessary when a 64 bit address is used,
but only a 32 bit physical address exists. The least significant portion
of the address is placed on the AD lines first, followed by the most
significant 32 bits. The second address cycle also contains the command
for the type of transfer (I/O, Memory, etc). The PCI bus supports a 64 bit
I/O address space, although this is not available on Intel based PCs due
to limitations of the CPU.

Memory-Read Line (1110)

        This cycle is used to read in more than two 32 bit data blocks,
typically up to the end of a cache line. It is more effecient than
normal memory read bursts for a long series of sequential memory accesses.

Memory Write and Invalidate (1111)

        This indicates that a minimum of one cache line is to be transferred.
This allows main memory to be updated, saving a cache write-back cycle.


Bus Arbitration:

This section is under construction.

PCI Bios:

This section is under construction.

t


(C) Copyright 1996 by Mark Sokos. This file may be freely copied and
distributed, provided that no fee is charged.

This information is provided "as-is". While I try to insure that the
information is accurate, errors and typos may exist. Send corrections
and comments to [email protected]. The latest version of this file
may be found at http://www.gl.umbc.edu/~msokos1


References:

"Inside the PCI Local Bus" by Guy W. Kendall
Byte, February 1994  v 19 p. 177-180

"The Indispensible PC Hardware Book" by Hans-Peter Messmer
ISBN 0-201-8769-3

Makefile notes

Checking tabs:
cat -v -t -e makefile

Macro substitution:
SRCS = defs.c redraw.c calc.c
...
ls ${SRCS:.c=.o}
result: calc.o defs.o redraw.o
Second string can be nothing too to truncate

Suffix Rule: default begavior for a suffix:
.SUFFIXES : .o .c .s

.c.o :
$(CC) $(CFLAGS) -c $<
.s.o :
$(AS) $(ASFLAGS) -o $@ $<

$< is what triggered (only valid in suffixes)

Forcing rebuilds:
all :
make enter testex "CFLAGS=${CFLAGS}" "FRC=${FRC}"

enter : ${FRC}
make ${ENTER_OBJS} "CFLAGS=${CFLAGS}" "FRC=${FRC}"
${CC} -o $@ ${ENTER_OBJS} ${LIBRARIES}

testex : ${FRC}
make ${TESTEX_OBJS} "CFLAGS=${CFLAGS}" "FRC=${FRC}"
${CC} -o $@ ${TESTEX_OBJS} ${LIBRARIES}

force_rebuild:
[nothing here]

Then normal "make all" does normal. "make all FRC=force_rebuild" will do all

Debugging make files:
Try "make -d"

Misc notes:
A line starting with a hyphen ignores errors resulting from execution of that command

Macros:
$? = List of prereqs that have changed
$@ = Name of current target, except for libraries, which it is the lib name
$$@ = Name of current target if used AFER colon in dependency lines
$< = Name of current prereq only in suffix rules.
$* = The name (no suffix) of the current prereq that is newer. Only for suffixes.
$% = The name of the corresponding .o file when the current target is a library
Macro Mods: (not all makes support)
D = directory of any internal mac, ex: ${@D}
F = File portion of any internal except $?

Special Tagets:
.DEFAULT : Executed if make cannot find any descriptions or suffix rules to build.
.IGNORE : Ignore error codes, same as -i option.
.PRECIOUS : Files for this target are NOT removed if make is aborted.
.SILENT : Execute commands but do not echo, same as -s option.
.SUFFIXES : See above. 

Don't Plug a 10/100 Switch Into Your Phone!

Bad things happen.

I have a patch panel for structured wiring in my house. Took me a ½ hour to figure out why all my phones were dead - I had plugged the hub into the phone system! Oopsie!

Mom's Apple Pie Recipe

Mmm Mmm Good…

2 lb Cortlands
¾ cup sugar
¼ cup flour
1 tsp. cinnamon
dash nutmeg
2 tbsp butter/marg
lemon juice
Pillsbury 9" Pie Crust

Peel/Cut Apples. Generous amount of lemon juice after first and every few - coating to prevent oxidation.

Mix with sugar, flour, nutmeg, cinn. in bowl.

Pour into crust

Dot with butter (~pat each quarter and center)

Put on top crust, seal well, vent w/ knife

40 minutes at 450F (preheated) - Golden Brown, slight bubbling from vents

smtproutes.pl

Many (stupid) mail servers are now assuming all cable modem users are SPAMmers, so more and more are refusing to accept my mail. Here's a script that I run to regenerate QMail's 'smtproutes' whenever I need to add new ISPs… Start:

#!/usr/bin/perl

open OUTFILE, ">smtproutes";

$s = ":smtp.comcast.net\n"; # Replace with your ISP's outbound server

foreach (<DATA>) {
chomp;
next if /^\w*$/;
next if /#/;
print OUTFILE "$_$s.$_$s";
}

__DATA__
aol.com
pipeline.com
earthlink.net
comcast.net
ix.netcom.com
netcom.com
hut.fi
t-3.cc
earthengineering.com
usa.com
#CS is old compuserv, now AOL
cs.com
stanfordalumni.org
erasableinc.org
sbcglobal.net
hp.com
abs.net
juno.com
sourcenw.com
yahoogroups.com
msn.com

Using bBlog on your own server.

The installation program asks for your MySQL database name and password. I couldn't get the to work by myself, because I run my own so no admin just handed me the info. If you're in the same boat, here's all you need to do:

/usr/local/mysql/bin/mysql -p

Enter password: mypassword

mysql> CREATE database blog;
mysql> GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP,ALTER,INDEX
    -> ON blog.*
    -> TO blog@localhost
    -> IDENTIFIED BY 'myblogpassword';

Obviously, change the stuff in bold. Then in bBlog's setup use the user and database name of 'blog' with the password set above.

Unix commands you shouldn't do at 3 AM....

…well, ever.

rm -rf .*

rpm -qa | xargs rpm --erase

I've done them both and felt the pain. I did the first on a 2TB machine. In 1996, when 2TB was a lot more impressive.

Right click hanging horribly?

Other symptoms included moving any file to the trash, even with 'delete' button and no context menu used.

Re-enable PGPsdkService

This took me about 6 months to track down!!!

Data General UPS Pinout

The DG UPS pinout follows:

             Power
    Pin    Off    On    Signal
    ---    ---------    ------
     1      -     -
     2     +10   -10    Are we online? +10=false, -10=true
     3      -     -
     4      -     -
     5      -     -
     6      -     -
     7      -     -
     8     +-10  +10    Is the battery low? +10=false, -10=true
     9      -     -

nForce2 Driver Problems (Abit NV7-133R)

I have changed mobos "under" Windows many, MANY times… and THAT is the problem.

This install of Win98 has lasted since early 1999 - including… many, many registry hacks (which I am still putting back in now) mobos / procs:

  • Abit BH6, Celeron overclocked to 550
  • Abit BH6, Celeron overclocked to 850, then 950
  • Abit KG7-Lite, Athlon XP 1600+
  • died on Abit NV7-133R, Athlon XP 1600+

hard drives:

  • 20 GB on the mobo
  • Promise 66 RAID 2x20 + 1x40
  • Promise 66 RAID 2x40 + 1x80
  • Promise 100 RAID 2x40 + 1x80

video cards:

  • no-name PCI plus voodoo2
  • TNT2 (forgot which one, it was only a week)
  • voodoo3 3000
  • geforce3 ti 450 (gainward)

The list doesn't include 2 SCSI cards (ISA, then SCSI), the various CD-Burners (2), ZIP drive, scanners (3), cameras (2), mp3 player, X10 control hardware, and everything else that would bloat the hell out of the registry!

So it finally caught up with me, I am reinstalling Windows right now…

To answer all questions -

  • I will NOT go to XP as my home OS. Maybe in a VMWare window with

Linux watching it very VERY closely. I considered Win2K but found out a game I like ("Alice") doesn't work there… I have also had problems with Ghost on my laptop with Win2K…

  • The tape detection was crashing VCOMM because Windows was looking

for a parallel-port tape drive (my theory)

  • And the kicker, something that people NEED TO BE AWARE OF WITH

THIS MOTHERBOARD - installing the nForce drivers from the nVidia web page KILLED win98. I did an absolutely fresh install, ran it, BOOM no booting, total lockup. In safe mode, I went in and deleted the "new" not working PCI video - I assume the nForce installer pokes something in the registry to tell Windows that the video is there, but the 133R has it disabled, so Windows tries booting and just says "WTF?" - bootlog.txt showed it dying on video init.

Mis-ID'd Hard Drive

Problem: I have an 80GB Maxtor hooked up to the on-board IDE using a nice fancy 80 pin rounded cable. My problem is that when I cold boot, it ID's the hard drive as a "MAXTOR ROMULUS" and then says error with the drive. I hit ctrl-alt-del and it reboots, properly IDs, and boots fine. Any ideas? I have messed with the IDE delay, up to 3 seconds didn't fix it…

Solution: Turns out that drive didn't like to be the 'Slave' without a 'Master'. Never saw that before and I have had Master-less drives before…

UT Server on Laptop Problem

Don't remember how I figured it out… but I remember it took months. If your UT server is playing super crappy on a laptop under WinME (or WinXP), try running SETI@Home or distributed.net's RC5 cracker. It worked for me under both OSs.