dfbills.com blog

Spotlight became “sputter-heavy”

I was having problems with Spotlight on Leopard 10.5.1.  My computer was dog-slow and just plain unresponsive.  Spotlight search results were inconsistent and I was noticing that my drive was being re-indexed quite regularly (as evidenced by the spotlight menu item and the concealed progress bar).

My first troubleshooting step was to fire up Spotless to delete the indexes and allow them to rebuild.  Unfortunately, 24 hours later the indexing was still going.  My index kept stalling at around 127MB.

I used the following code to check it.

sudo du -h /.Spotlight-V100/

After watching it for about and hour, I decided to upgrade to a self-running version with Growl notifications.

while :
do
clear
sudo du -h /.Spotlight-V100/ | /usr/local/bin/growlnotify
echo “growled” & date “+%H:%M:%S%n”
sleep 90
done

Some searching revealed that quite a number of people had experienced this problem at the release of 10.5.1.  My standard tracing solution didn’t tell me too much.

lsof | grep mdworker

But, anther user explained how to use the dtrace system utility to examine the mdworker process.  On my system it was using 90-100% processor time.

sudo dtrace -n ‘syscall::open*:entry /execname == “mdworker” | execname == “mds”/ { printf("%Y %u %s %s",walltimestamp,pid,execname,copyinstr(arg0)); }’

This led me to examine the console and sure enough, the mdworker was crashing every 3 secs on a particular file and writing a crashlog.

Jan 30 23:55:07 Macintosh ReportCrash2692: Formulating crash report for process mds2686
Jan 30 23:55:07 Macintosh com.apple.launchd[1] (0x10c830.mdworker2687): Exited: Terminated
Jan 30 23:55:07 Macintosh com.apple.launchd[1] (0x10c9f0.mdworker2690): Exited: Terminated
Jan 30 23:55:07 Macintosh com.apple.launchd[1] (0x10cbb0.mdworker2691): Exited: Terminated
Jan 30 23:55:07 Macintosh com.apple.launchd[1] (com.apple.metadata.mds2686): Exited abnormally: Segmentation fault
Jan 30 23:55:07 Macintosh mds2695: (/.Spotlight-V100/Store-V1/Stores/9A285684-2061-4212-B186-56B95ACE8BD7)(Error) IndexCI in ContentIndexOpenBulk:No index
Jan 30 23:55:07 Macintosh ReportCrash2692: Saved crashreport to /Library/Logs/CrashReporter/mds_2007-11-12-235505_Macintosh.crash using uid: 0 gid: 0, euid: 0 egid: 0

After poking about for a while I settled on the same solution as many others- an OS reinstall.  Archive & Install worked fine and the entire process, including software updates, took about 90 minutes.

Fixed.

comment on this | posted in: Mac Tips Troubleshooting Unix

Activate QuickLook plugins without logout or reboot

To activate QuickLook plugins without a logout or reboot, simply reset QuickLook at the command line.

qlmanage -r

(1) comments | posted in: Mac Tips Unix

How to create an iPhone WebClip Bookmark Icon

A clever developer has posted instructions on how to create an iPhone WebClip icons for your own website: (via MacRumors)

The lowdown:

- Create a 57x57 PNG
- Name it “apple-touch-icon.png”
- Upload to the root level of your website

You can override Safari’s WebClip search behavior just like with favicons:

<link rel="apple-touch-icon" href="myicon.png"/>

As usual, detailed instructions for iPhone web development are posted in Apple’s iPhone Dev Center.

comment on this | posted in: iPhone Tips Webdev

MacOSX filesystem usage

To see realtime filesystem usage in MacOSX:

fs_usage

Also useful for checking what exactly an app is doing:

fs_usage -w -f filesys | grep AppName

comment on this | posted in: Mac Tips Troubleshooting Unix

MacOSX network connections and activity

To list all open network connections:

sudo lsof -i | grep LISTEN

comment on this | posted in: Mac Tips Unix

MacOSX system troubleshooting via kernel extensions

To find non-apple kernel extensions:

kextstat | grep -v apple

comment on this | posted in: Mac Tips Troubleshooting Unix

Refresh MacOSX DNS cache

To flush DNS cache

Tiger:

sudo lookupd -flushcache

Leopard:

dscacheutil -flushcache

comment on this | posted in: Mac Tips Unix Webdev

Limit iPhone radiation exposure + boost signal strength

Flipping through the iPhone manual, I happened upon this nugget of info.

“For optimal mobile device performance and to be sure that human exposure to RF energy does
not exceed the FCC guidelines, always follow these instructions and precautions: When on a
call using the built-in audio receiver in iPhone, hold iPhone with the 30-pin connector
pointed down toward your shoulder to increase separation from the antenna.”

Translation: Keep you hand off of the plastic antenna cover.

I wondered if anyone had measured changes in signal strength when “holding the iPhone properly” and sure enough Nate True posts “iPhone tip - want better EDGE speeds? Take your hand off the antenna”  He claims that he sees a 50% speed increase.  It seems a bit faster to me, but who knows.

comment on this | posted in: iPhone News Tips

Don’t believe the hype

If you can read this, my 6-week nightmare with Media Temple hosting is over.  Since switching, I had one problem after another…  from their entire service being down for almost 24 hours to extreme slowdowns.. can you say 30 sec php load times?  (9.4 secs for my homepage at the time of writing)

They pride themselves on friendly, knowledgeable tech support.  They were friendly, but certainly not knowledgeable.  I found them more interested in recapping the phone conversation that actually helping out.  I was given incorrect information, the classic run-around, told there was nothing I could do but wait – and frankly my patience ran out.  They gave me three free months of hosting, but honestly I don’t want it.

If you are thinking of hosting your website with Media Temple- don’t.

The list of shame:

- Less than 10 hours notice before 24 hours of downtime
- Performance 10x slower than my previous shared host
- Processing time overages with no warning (I guess should have been monitoring myself.  Although this is tough to do when there are no debug tools and the readout is more than an our behind realtime.)
- Lost email (But hey, my spam count was way down.)
- Snide & not helpful phone tech support (they’re geeks just like you, only less helpful)
- Who asks for text account passwords over the phone?
- All marketing and no muscle

comment on this | posted in: News Personal Tips

Leopard’s unix changes

I found this great technote and linked documentation on Apple’s site: “Mac OS X 10.5: Terminal command changes in Leopard.”  It all has to do with UNIX 03 conformance.

UNIX 03 Conformance Release Notes

General Command-Line Tool Differences

Now I know why this doesn’t work..

ps -auxww

The replacement would be:

ps -el

More notes as I have time to dive in.

comment on this | posted in: Mac Tips Troubleshooting Unix
« First  <  7 8 9 10 11 >