Get rid of the U3 Launchpad on Your Sandisk Cruzer

May 27th, 2008

I love the Sandisk USB flash memory sticks. They are the best. The fact that they are made retractable and without the need for a cap of any kind makes them the best. Unfortunately, they bundle/format them with the annoying U3 Launchpad application for Windows which I have no use for. So, the first thing I do is remove it. Initially, I was doing low-level formats on the device on OS X, then Linux, but nothing worked unless you get this.

http://www.sandisk.com/Retail/Default.aspx?CatID=1415

Download the Launchpad Removal Tool and run it in Windows to nuke the U3 garbage. It gets rid of the CD emulation stuff, and the separate partition and just makes it a nice USB memory stick.

Denyhosts is your friend to stop ssh login attempts

May 23rd, 2008

Denyhosts

If you have a few linux servers that for whatever reason you have to leave open to ssh into on the standard port 22, denyhosts is a great way to get rid of the annoying daily logwatch email logs showing some losers somewhere have been spending all day doing a denial of service trying to brute-force attack their way in to ssh. Better ways are just to not even let ssh be accessible to non-legit IPs as well as disable ssh logins except for a couple of valid users, but in the case of mobile devices, locations, etc. you just sometimes need to have the ability to ssh into servers anywhere and other services might be dependent on the default port number, so changing it to get it out of the range of the script-kiddie or russian mafia is just not an option. It is one thing to have secure passwords, keys, etc. but just the fact they continue to bang on your servers can really rack-up bandwidth and annoyance.

Denyhosts is written in python and works with your logs to (based on your settings) inhibit attempts once thresholds you configure are met on login attempts. Really cool.

http://denyhosts.sourceforge.net

I have tested on ubuntu and centos and works great. The default configs are basically ready for centos/fedora/redhat out of the rpm or from source.

Moving Ubuntu Linux from PATA drive to SATA drive

May 20th, 2008

 Sata drivePata drive

I had mergy.org running on a very old laptop on a small ide 2.5″ drive. It was slow, but it was working. It got very tedious to work on though when anything went wrong and the webserver was really starting to get slow so I finally bit decided to move to newer hardware. But, the problem was that the drives on anything modern are serial ATA.

Here is what I did

1. Installed the same flavor and version of linux  on the new server and hard drive mimicing the partitions numbering on the old server. You could just get away with partitioning the drive in step 3 using one of the many RIPLinux bundled utils or fdisk, gparted, etc.

2. Took the drive out of the old laptop and put it in a usb external case and connected to the new server.

3. Booted on a RIPLinux CD - but any live CD would do really.

4. Blew away all files on the various partitions on the new server/drive

5. copied the files and directories over from the old drive with cp -prv

6. Changed the grub config in /boot to point to /dev/sda1 as opposed to /dev/hda1

7. Checked /etc/fstab to make sure mount points are OK

8. Edited the boot grub menu to make sure that point to the root directory

And it worked!

Recovery is Possible linux —> http://ftp.leg.uct.ac.za/pub/linux/rip/

Nice GUI LDAP Browser Application –> LUMA

April 18th, 2008

luma_browse

I have recently been doing a lot with LDAP and really needed a nice, flexible LDAP browser tool to run on Ubuntu Hardy.

Luma is great.  Very configurable and easy to work with. Has a plug-in architecture and just really slick from what else is out there now.

Check it out @

http://luma.sourceforge.net

Get Airport Extreme and WPA on an old TiBook or PowerBook

February 18th, 2008

Dynex Wireless G Notebook card

We have an old TiBook 800 that was sitting around after I moved the network from WEP to WPA encryption. The Airport card built-in the old Titanium Powerbook did not support WPA or higher encryption. So, I went looking on the net and found a lot of old information on cards that would work with OSX but most of those PC cards were no longer available and all the posts across the net were pretty old.

So, I went down to Besy Buy and got a couple to try hoping I would find one with a Broadcom chipset. Good news is that I did find one and OSX sees it natively as Airport Extreme. The card is a Dynex Wireless G Notebook card. It was $60 or so. The TiBook is running Tiger and is a great laptop outside of the networking limitation because of the orginal Airport card. I plugged in the card to the PowerBook and went the network control panel and it recognized it as a new Airport connection. I rebooted and it took over as the Airport Card.

More information on it @ http://www.dynexproducts.com

It is a great solution to give the older PowerBook a new life.

Ubuntu Wifi Management With WICD

February 2nd, 2008

Ubuntu Logo

Wifi

After running Ubuntu for quite a while now, most of the system is great and extremely functional. The real mess is with the lack of wireless management tools to handle multiple wireless networks. That is, until I have been working with WICD. WICD is the best manager I have used at it is great at storing keys, etc. This is really a must have for a desktop/laptop WIFI user. Installing it requires you remove the built-in ‘Network Manager’ that Gnome/Ubuntu installs, but you want to - trust me. It also handles toggling wired ethernet as well.

You should check it out -> wicd.sourceforge.net

wicd screenshot

Ubuntu Gutsy and IBm ThinkPad T42 Xorg Configuration

January 27th, 2008

Ubuntu Logo

Thinkpad T42

Getting Ubuntu Gutsy running on an IBM ThinkPad T42 is easy, but the X Server can be a pain. Here is my config.

# xorg.conf (xorg X Window System server configuration file)
#
# This file was generated by dexconf, the Debian X Configuration tool, using
# values from the debconf database.
#
# Edit this file with caution, and see the xorg.conf manual page.
# (Type “man xorg.conf” at the shell prompt.)
#
# This file is automatically updated on xserver-xorg package upgrades *only*
# if it has not been modified since the last upgrade of the xserver-xorg
# package.
#
# If you have edited this file but would like it to be automatically updated
# again, run the following command:
# sudo dpkg-reconfigure -phigh xserver-xorg

Section “Files”
EndSection

Section “InputDevice”
Identifier “Generic Keyboard”
Driver “kbd”
Option “CoreKeyboard”
Option “XkbRules” “xorg”
Option “XkbModel” “pc105″
Option “XkbLayout” “us”
EndSection

Section “InputDevice”
Identifier “Configured Mouse”
Driver “mouse”
Option “CorePointer”
Option “Device” “/dev/input/mice”
Option “Protocol” “ImPS/2″
Option “ZAxisMapping” “4 5″
Option “Emulate3Buttons” “true”
EndSection

Section “InputDevice”
Identifier “Synaptics Touchpad”
Driver “synaptics”
Option “SendCoreEvents” “true”
Option “Device” “/dev/psaux”
Option “Protocol” “auto-dev”
Option “HorizEdgeScroll” “0″
EndSection

Section “InputDevice”
Driver “wacom”
Identifier “stylus”
Option “Device” “/dev/input/wacom”
Option “Type” “stylus”
Option “ForceDevice” “ISDV4″# Tablet PC ONLY
EndSection

Section “InputDevice”
Driver “wacom”
Identifier “eraser”
Option “Device” “/dev/input/wacom”
Option “Type” “eraser”
Option “ForceDevice” “ISDV4″# Tablet PC ONLY
EndSection

Section “InputDevice”
Driver “wacom”
Identifier “cursor”
Option “Device” “/dev/input/wacom”
Option “Type” “cursor”
Option “ForceDevice” “ISDV4″# Tablet PC ONLY
EndSection

Section “Device”
Identifier “ATI Technologies Inc RV350 [Mobility Radeon 9600 M10]”
Boardname “ati”
Busid “PCI:1:0:0″
Driver “ati”
Screen 0
Option “MergedFB” “off”
EndSection

Section “Monitor”
Identifier “Thinkpad T42 Display”
Modelname “Custom 1″
modeline “640×480@60″ 25.2 640 656 752 800 480 490 492 525 -vsync -hsync
modeline “800×600@56″ 36.0 800 824 896 1024 600 601 603 625 +hsync +vsync
modeline “800×600@60″ 40.0 800 840 968 1056 600 601 605 628 +hsync +vsync
modeline “1024×768@60″ 65.0 1024 1048 1184 1344 768 771 777 806 -vsync -hsync
modeline “1280×960@60″ 102.1 1280 1360 1496 1712 960 961 964 994 -hsync +vsync
modeline “1280×1024@60″ 108.0 1280 1328 1440 1688 1024 1025 1028 1066 +hsync +vsync
modeline “1400×1050@60″ 122.61 1400 1488 1640 1880 1050 1051 1054 1087 -hsync +vsync
Gamma 1.0
EndSection

Section “Screen”
Identifier “Default Screen”
Device “ATI Technologies Inc RV350 [Mobility Radeon 9600 M10]”
Monitor “Thinkpad T42 Display”
Defaultdepth 24
SubSection “Display”
Depth 24
Virtual 1400 1050
Modes “1400×1050@60″ “1280×1024@60″ “1280×960@60″ “1024×768@60″ “800×600@60″ “800×600@56″ “640×480@60″
EndSubSection
EndSection

Section “ServerLayout”
Identifier “Default Layout”
screen 0 “Default Screen” 0 0
Inputdevice “Generic Keyboard”
Inputdevice “Configured Mouse”

# Uncomment if you have a wacom tablet
# InputDevice “stylus” “SendCoreEvents”
# InputDevice “cursor” “SendCoreEvents”
# InputDevice “eraser” “SendCoreEvents”
Inputdevice “Synaptics Touchpad”
EndSection
Section “Module”
Load “v4l”
EndSection
Section “device” #
Identifier “device1″
Boardname “ati”
Busid “PCI:1:0:0″
Driver “ati”
Screen 1
Option “MergedFB” “off”
EndSection
Section “screen” #
Identifier “screen1″
Device “device1″
Defaultdepth 24
Monitor “monitor1″
EndSection
Section “monitor” #
Identifier “monitor1″
Gamma 1.0
EndSection
Section “ServerFlags”
EndSection

Great Web Browser for Palm –> Opera Mini

January 16th, 2008

Opera Mini on Palm 700p

It is no iPhone/Safari, but it is much better than the tired Blazer browser that is stock on Palm-based Treos. If you have a Treo 700p, this is really a must to handle non-pda optimized content. I think with all the iPhone envy, it is getting even more play. You can do the zoomed-out view and then zoom into the specific parts of the page.

You can download here.

For Palm, you will also need IBM JVM for Palm. You can download here.

You will also need to set some settings for JVM in the IBM Java Preferences in the Palm Prefs

Set Memory Maximum: 4mb

Set Maximum Java Thread Stack Size: 32kb

I did this for the ‘Global Settings’ but you could do it just for Opera Mini but since it really is the only palm/java app I run it really was just the same.

Bonding Network Interfaces on RedHat Enterprise Linux 5 (RHEL 5)

January 2nd, 2008

Redhat Logo

RedHat’s Knowledgebase has no info on correctly bonding network interfaces on RHEL 5. They do have some old RHEL 3 information, but things have changed a little bit and they have failed to add the changes to another knowledgebase article. Here goes the quick way to get you going.

1. Get the hardware addresses of your network cards. These are usually eth0, eth1, etc. but the addresses may surprise you but they are usually eth0, eth1, eth2, etc.
2. Once you have your network addresses, you can get going. Stay out of the GUI network configuration tool RedHat provides because it has no idea what you are trying to do yet.

In ‘/etc/sysconfig/network-scripts’ create a new file for your bonded interface - for example, bond0. The file will be named

ifcfg-bond0

and put this in the file (replace the stuff in <> with the actual addresses you want and no <>)

DEVICE=bond0
BOOTPROTO=none
ONBOOT=yes
NETWORK=<WHATEVER YOUR NETWORK ADDR IS>
NETMASK=<YOUR NETMASK>
IPADDR=<IP ADDR YOU WANT THE BOND TO SERVE UP>
USERCTL=no
GATEWAY=<THE GATEWAY ROUTER IP>
TYPE=Ethernet
IPV6INIT=no
PEERDNS=yes

3. Then create a ifcfg file for each interface you want to be a part of the bond0. I have 2 for this bond. If there are existing files there, edit them or nuke them and recreate them. They were probably created with the GUI interface network config utility in RHEL. (For example purposes, I am using eth0 and eth1 as the 2 network interfaces we want to bond with bond0)

In ‘/etc/sysconfig/network-scripts’ you want;

a file for eth0

ifcfg-eth0

DEVICE=eth0
BOOTPROTO=none
ONBOOT=yes
MASTER=bond0
SLAVE=yes
USERCTL=yes

and a file for eth1

ifcfg-eth1

DEVICE=eth1
BOOTPROTO=none
ONBOOT=yes
MASTER=bond0
SLAVE=yes
USERCTL=yes

4. Then you have to add bond0 to be a recognized interface for the kernel. You can do this in modprobe.conf. RedHat still has references to /etc/modules.conf which doesn’t exist in RedHat 5 anymore.

So, modify ‘/etc/modprobe.conf’ and add the line

alias bond0 bonding

5. Then reboot the whole server. I know, you can restart the network (/etc/init.d/network restart) or restart the interface bond0 (/sbin/ifup bond0) and leave everything up, but if you are doing this, you probably have no one hitting the server across the network anyway and it would be good to make sure the bond kicks up on startup and plays nice.

Really surprised that RedHat has yet to incorporate this into the network config utility and they make you go down this road to handle it. There are other settings with ‘miimon’, etc. but this gets you into the ballpark. More information on linux bonding here.

I added this to the /etc/modprobe.conf to help with switch timing and delays we were seeing in transfer tests.

options bond0 miimon=100 mode=1

Take Tivo Content to iTunes and iPhone in OS X

December 29th, 2007

Tivo Logo TDM Screenshot

If you have a Series 2 Tivo, and have Tivo on the network it is very easy to get Tivo recorded shows to your iTunes and iPhone.

Using Tivo Decode Manager it is really a breeze. Basically, you want to record in ‘High Quality’ from Tivo then setup TDM to do the MP4 conversion. You will get a file that then can be imported into iTunes and be recognized as a TV Show or Movie. Of course, you need to know your Tivo IP and your Media Access Key, but this is a great solution to get high quality video off your Tivo in a very easy way. This is light years ahead of the way it used to have to be done. It has also been around for quite a while now and I have had tremendous success with it over the last year. It was shaky initially, but after the last TDM version, it has been solid.

Sample screenshot of TDM above.