Friday, January 27, 2006

Gentoo - dcfldd

dcfldd

A fancier version of the basic "dd" command. The big advantage that I wanted was:

- Status information (useful when wiping large hard drives)

Here's my wipe command.

# dcfldd if=/dev/urandom of=/dev/sda conv=notrunc bs=128k

If you're in more of a hurry, try:

# dcfldd if=/dev/zero of=/dev/sda conv=notrunc bs=128k

Some slower CPUs can't generate PRNG numbers (/dev/urandom) fast enough to keep up with the disk wipe process. If you're using "atop" you'll notice that the system is spending 100% of the time in the "sys" (and dcfldd is using up 100% CPU). In addition, the hard drive lights will not be constantly lit. Plus the "DSK" line for the drive being wiped will not be busy 100% of the time in "atop".

Friday, January 13, 2006

PostgreSQL - dumping a single table

$ pg_dump -Fp -U postgres --table=TABLENAME DATABASENAME > TABLENAME.sql

$ pg_dump -Fp -U postgres --table=TABLENAME DATABASENAME | gzip -c > TABLENAME.sql.gz

Useful for dumping out individual tables from a particular database in plain-text (SQL) format.

Thursday, January 12, 2006

Dual-core dual-opteron system pricing

I've been using a dual-Opteron (twin 246s) system as my main workhorse machine for a while now. It still works well, but the Tyan Tiger K8W pipes all memory accesses from the one CPU through the other CPU, which makes it slower then it could be. Plus the K8W doesn't support the newer dual-core Opterons (at least not according to Tyan's CPU chart).

The newer Tiger K8WE (S2877ANRF) has a different memory configuration along with an NVIDIA chipset (instead of the AMD chipset). It's also a PCIe motherboard, so there would be some upgrade potential. Looks like it's available for around $275 to $375.

However, the Opteron 265 (dual-core, 1.8Ghz, 2x1MB L2 cache) is around $720 each. The Opteron 270 (2.0Ghz) is $900-$1000. The Opteron 275 (2.2Ghz) is $1100 and the Opteron 280 (2.4Ghz) is $1350. Just a *little* pricey. In comparison, the Opteron 246 chips (2.0Ghz, single-core) are only $225.

Memory chips are $120 each (Corsair CM72SD1024RLP, PC3200).

Eh, I think I'll wait until the Opteron 270s drop below $500 each. The chips are still too far up the price curve for my tastes.