Copy Files To Your iPhone

Andy Ihnatko has a review of the Air Sharing iPhone app at the My Digital Life Podcast & Blog.

Of particular interest to me… Andy says:

“Music and video are both formats that the iPhone OS can simply view outside of the iPod app. If I just copy it into my Air Share, I can play it with just a tap. I often put whole albums on the iPhone, if I don’t yet know if I want to throw them into my big iTunes soup. That’s a particularly big plus when it’s a 700 meg movie file and I don’t know if I want to burn up that much space on my notebook’s little hard drive by actually importing it into iTunes.”

Only $4.99. Go read the review… good stuff.

Jawbone Charger Can Destroy Your Jawbone Headset

The original Jawbone headset by Aliph provides excellent noise reduction.

However, the unit has a design flaw; the charger fits too tight around the back of the unit. In fact, as I recently found out, it is SO tight that it can easily destroy the headset when removing it.

When I contacted Aliph customer service, they were cordial, but unwilling to help since I couldn’t find my receipt.

After some additional research, I found a video tutorial showing the best way to remove the charger. Apparently, this is known issue.

It’s really lame of Aliph to not stand behind their product. I definitely WILL NOT be buying my replacement headset from them.

Starting Ensim Pro For Linux SSL Tunnel [FAILED]

At work, I was unable to access my Ensim control panel (on RHEL4); the browser kept timing out. So I thought I’d restart it to see if that would fix it. I did the usual:

/etc/init.d/epld restart

And got this error

Stopping Ensim Pro For Linux Control Panel [ OK ] Stopping Ensim Pro For Linux SSL Tunnel [FAILED] Starting Ensim Pro For Linux Control Panel [ OK ] Starting Ensim Pro For Linux SSL Tunnel [FAILED]

I checked the log file and see this:

cat /usr/lib/ensim/frontend/httpd/logs/error_log

…No space left on device: mod_rewrite: could not create rewrite_log_lock

Problem Found

A quick google search told me it was a semaphore problem. So I ran the ipcs command to check my config:

ipcs -l

—— Semaphore Limits ——–
max number of arrays = 128
max semaphores per array = 250
max semaphores system wide = 32000
max ops per semop call = 32
semaphore max value = 32767

Then ran the ipcs command to see how many were semaphores were left:

service httpd stop
ipcs -s | grep apache | wc -l

It showed 110. Not 128, but maybe enough to cause problems. PLUS, it “should” be zero with apache stopped.

Solution

With apache and epld stopped, I ran this command

ipcs -s | grep apache | gawk ‘{ print $2 }’ | xargs -n 1 ipcrm sem

Then started apache/epld again. All is fine.

service httpd start
/etc/init.d/epld start

Your Linux Boot Disk Full?

While trying to run a YUM update on a CentOS server today, I got an error message about my /boot partition being full. I ran a df -h and sure enough, there was only 100k left. (My standard install uses 100MB for the boot partition.)

Here’s what I did to fix it.

rpm -q kernel

That returns a list of installed kernel updates. In my case I had more than 25…

kernel-2.6.9-22.EL
kernel-2.6.9-42.0.8.EL
kernel-2.6.9-42.0.8.plus.c4
kernel-2.6.9-42.0.10.plus.c4

kernel-2.6.9-67.plus.c4
kernel-2.6.9-67.0.1.EL
kernel-2.6.9-67.0.1.EL.plus.c4
kernel-2.6.9-67.0.4.plus.c4
kernel-2.6.9-67.0.7.plus.c4
kernel-2.6.9-67.0.15.plus.c4
kernel-2.6.9-67.0.20.EL

To remove some of the older ones, run:

yum remove kernel-2.6.9-42.0.10.plus.c4

or to get several at one time:

yum remove kernel-2.6.9-42.*

I recommend leaving a few of the older ones in case you need to revert one day.

Speed Up Mail.app

Mail.app seems to get slower and slower. Plus it crashes at least once a week. As I started looking around the web to find a solution I ran across this post from Tim Gaden at his blog: http://www.hawkwings.net/2007/03/01/a-faster-way-to-speed-up-mailapp/

He describes this solution:

Open Terminal, then run these three commands:

ls -lah ~/Library/Mail/Envelope\ Index
sqlite3 ~/Library/Mail/Envelope\ Index vacuum
ls -lah ~/Library/Mail/Envelope\ Index

I’ve just ran it myself and it only dropped the size of my index from 73MB to 60MB, but it DID speed up Mail considerably. I’ll have to wait and see if it helps the crashing.

Using Linux Tail to Trim Your Files

This tip is for my friend Scarb. For years I’ve used the Linux command “tail -f” for watching logs… but only recently did I discover its versatility for extracting parts of files.

Need to grab only the last 25 lines of a file?

tail -n 25 somefile.txt

How about the last 200000 bytes redirected to another file?

tail -c 200000 somefile.txt > newfile.txt