Category Archives: Technology

SSH config for non-standard ports

This is the coolest thing I have seen in a while. I frequently spend time on remote hosts via SSH, some, if not most, of which run sshd on a port other than 22. This resulted in me adding “-p 1234″ to every single ssh command I executed.

Well, no more. Today I stumbled upon SSH config. Just edit your ~/.ssh/config file and add the following to get rid of all those -p’s:

Host myserver.com
    Port 1234
Do that for all your frequently visited hosts, and you will have saved your fingers a lot of typing.

Mouse gestures in Safari

Recently I switched from Opera to Safari, more precisely the Webkit nightlies. The main reason is the great 1Password password manager and form filler that takes care of all my logins and more so that I can be more secure on the web.

One of the main things I missed in Safari that I came to love in Opera are mouse gestures. I checked out the programs most often recommended, but they either didn’t work anymore or cost money now. Until I stumbled upon SafariGestures. It’s a SIMBL plugin (I use PlugSuite instead, either should work) and adds a menu item to your toolbar. From there you can set a plethora of preferences and customize it to your needs.

I actually prefer it over Opera’s mouse gestures; so far it’s been a good switch!

EDIT 4/2010: I have since switched to Chrome due to its speed and given up on mouse gestures. Safari with all the SIMBL plugins seemed just too slow.

DTrace with Entropy PHP on OSX Leopard

Similar to Xdebug, DTrace also didn’t want to work and failed with the same error, so I tried the same trick, and it worked.

Follow the instructions from Lee Packham’s blog but configure it as a 64-bit application:

  1. tar xzf dtrace-1.0.3fixtar.gz
  2. cd dtrace-1.0.3+fix
  3. phpize
  4. CFLAGS=’-arch x86_64′ ./configure –with-dtrace
  5. make
  6. make install

So far so good, the module is loaded. Now let’s see if Instruments will do its thing.

Xdebug on OSX Leopard with Entropy PHP5

Since I have been struggling with this for forever and finally found an answer, here’s an attempt to spread the wealth knowledge around.

Blog: Compiling & installing Xdebug for PHP 5.2.5 (Entropy.ch build) on OS X 10.5

Just to give the web crawlers some more info, the error message was:

PHP Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/php5/lib/php/extensions/no-debug-non-zts-20060613/xdebug.so’ – (null) in Unknown on line 0

The solution is to compile it manually as a 64-bit application like so:

CFLAGS=’-arch x86_64′ ./configure –enable-xdebug

Hope this helps someone out there.

JS error in IE7

Been battling with IE7 and a JS error I have been getting. We are using Modalbox for modal windows to display relogin information inside TYPO3 starting with version 4.3. In IE7 I have been getting the error “object doesn’t support this property or method” when loading content into the Modalbox.

After lots of trial and error I figured out that it didn’t like the name attribute on an input tag. Removing that, everything works fine now. Hope this will save someone a lot of trouble.

Christoph, who has high hopes in IE8 standards compliancy.

Postfix queue management

This is more a reminder for me than anything, but maybe someone else will benefit from this:

  • Print queue: postqueue -p
  • Delete all messages from the queue: postsuper -d ALL
  • Read a message: postcat -q <queue file id>
  • See what shape the queue is in: qshape

I am sure the man pages for each command will give you more info on what you can do with them.