Friday, November 25, 2011

Changing the email address on your Nike + iPod acount

These directions worked on a Mac running 10.5.8. I recently changed the email address on my Nike+ account. Getting to sync properly with iTunes again was a tad challenging. I basically followed the steps here but I did not reset my iPod. I lost a few runs because I didn't do things in the proper order.

1. Uncheck the automatically send workout data to in the Nike + iPod tab in iTunes and sync your iPod (in iTunes) without new workouts on your iPod.
2. Get a new workout recorded on your iPod. It can simply be walking around for 5 or 10 seconds.
3. Log in to Nike+ using Safari.
4. Connect your iPod with an unsynced run/walk
5. Recheck the automatically send workout data to in the Nike + iPod in iTunes and click Apply.

Your new Login ID is hopefully now showing in iTunes.

Thursday, November 24, 2011

Net10 monthly plans

I recently made a post to the Net10 Forums about their monthly plans. After submitting my post it mentioned that a moderator needed to approve my post. So clearly, Net10 does not want open discussion on their boards so I'm reposting my info here, where I moderate what I post :)

Beware the 750 minute 30 day plan

If all you do is make phone calls, the plan is fine. If you text, the plan is terrible. They don't tell you this up front, although they do kindly bury it in the terms and conditions, you will be charged 1 unit or minute per text message. We have an LG900G phone and were getting charged .25 units/text message. As we started to do more texting I thought moving to the 750 min/month plan would be ideal. It's my bad for not carefully reading the terms and conditions but Net10 should put that kind of info up front to it's perfectly clear. So for now I'll continue ripping through minutes until the minutes are used up and go back to another plan and supplement with airtime cards since it ultimately proves to be a better value for me.

Monday, November 21, 2011

Restore using pg_restore

We run daily dumps on our PostgreSQL databases. The command we use to dump the databases is:

pg_dump --blobs --compress=9 --format=c --verbose DBNAME --file=DUMPFILE.c

I recently had to restore one of the dumps to a different server and kept receiving the error:

ERROR: invalid byte sequence for encoding "UTF8": 0x93

I discovered that my original system had the database encoded as SQL_ASCII and the new system was encoding all new databases as UTF8. So I ran a create database with the proper encoding:


Then restored the file using pg_restore:

pg_restore --dbname=newdbname DUMPFILE.c

Monday, November 7, 2011

Argument list too long

I've run into this running rm * and du -hcs *. Solution is to pass the command via pipe and use xargs:

find . -name 'filename*' | xargs rm

Saturday, November 5, 2011

Slow data load speeds with Greenplum

Recently started loading data into a brand new Greenplum DCA. Data load speeds should be blazing fast right? Well, ours were very slow. It  was taking 50 seconds to load a 2.6GB csv file, pitifully slow. I finally figured out what error I had made. We were moving data from one GP system to another. That process involved dumping the schema out of the production system, dumping the data out of the production system, restoring the schema in the new contingency system, then restoring the data into the new contingency system. The problem was that when we restored the schema into the new system, we restored everything, including indexes. So as I was attempting to load the new data, the system was indexing it at the same time. After dropping indexes, that 2.6GB csv file loaded in about 8 seconds. That's more like it.