2010
07.09

OK, so I know these cell phone companies think they’re doing everyone a favor by setting up their own custom software loads and wallpaper and crap, but come on…

Basically, if you go to Telus and buy a Pearl 9100, they will helpfully install your SIM card in it and make sure you can make calls and surf the web and all that jazz, then they hand it to you and away you go. They will not ask you what you intend to do with it – like say, use it WITH A BLACKBERRY SERVER. So you take your new phone home, install the latest version of BlackBerry Professional on your Exchange server, create your account, set your activation password, pick up your Pearl and hunt (and hunt, and Google) for the Enterprise Activation icon.

Stop looking, it’s not there. But don’t worry.

Hopefully since you just brought the phone home, there’s not much on it. Go into “Options” -> “Security Options” and choose “Security Wipe”. Check off “Emails, Contacts, etc.” and “User Installed Applications”, enter the word “blackberry” in the field provided, and click on the “Wipe” button.

Let the phone reboot, and when it turns on and asks if you want to connect to the network, say “No”. Whip through the setup wizard and get to the home screen. You will find that the Telus wallpaper is there and the standard welcome message is in your Inbox, but you won’t find all of their custom crap. You will also find Enterprise Activation under “Options” -> “Advanced Options”. Enter your email address and activation password and tell the phone to activate. It will ask you to connect to the network. Say “Yes” now, and the activation should succeed if your server is working properly.

Oh, and before you tell me that you have to have an Enterprise (BES) plan from Telus in order for the icon to show up, or for BES to work, don’t bother. The new version of BES (5.0.1 at the moment) doesn’t require a BES data plan, and the removal of the Enterprise Activation program on the phone is just asinine.

At some point the Telus network may push their crapware down to my phone again, and hopefully it doesn’t break the already activated enterprise setup that I have going on. If it does, there will be another post. Trust me.

2010
06.16

My Linux background centers around RedHat and Centos. I have been using yum for a long time and I am very comfortable with it. One of the greatest frustrations I have with ubuntu is having difficulty finding the packages I need easily from the command line.

I realize there are a bunch of “apt-*” how to articles/blog posts out there but all of the ones I have read did not provide me with the required golden nugget which is, “I need file X, what package contains this file?” Specifically I needed mkimage to complete my boot image for a 1BeagleBoard and I did not know what package I needed to install to get it. The required command is apt-file, which is not installed by default on 10.04, so let’s go through some more basic commands first.

It’s probably a good idea to always start package management by running ‘apt-get update’ which fetches latest software list and version numbers

apt-get install –> installs packages and resolves dependencies
apt-get remove –> remove a package, leaves configuration files intact
apt-get purge –> remove package and configuration files

OK, so now we can install apt-file (sudo apt-get apt-file), once the package is installed, apt-file update must be run.

apt-file update –> updates file cache, takes a while

When the update has completed, we can search using apt-file search . Let’s look at my example above, what package do I need to install to get mkimage


don@S10:~$ apt-file search mkimage
cvsgraph: /usr/share/doc/cvsgraph/examples/mkimage.php3
grub-efi-amd64: /usr/bin/grub-mkimage
grub-efi-amd64: /usr/share/man/man1/grub-mkimage.1.gz
grub-efi-ia32: /usr/bin/grub-mkimage
grub-efi-ia32: /usr/share/man/man1/grub-mkimage.1.gz
grub-pc: /usr/bin/grub-mkimage
grub-pc: /usr/share/man/man1/grub-mkimage.1.gz
jigit: /usr/bin/jigit-mkimage
jigit: /usr/share/man/man1/jigit-mkimage.1.gz
lupin-support: /usr/share/lupin-support/grub-mkimage
opennebula: /usr/lib/one/tm_commands/nfs/tm_mkimage.sh
opennebula: /usr/lib/one/tm_commands/ssh/tm_mkimage.sh
opennebula: /usr/share/doc/opennebula/examples/tm/tm_mkimage.sh
python-freevo: /usr/share/pyshared/freevo/helpers/mkimagemrss.py
uboot-mkimage: /usr/bin/mkimage
uboot-mkimage: /usr/share/doc/uboot-mkimage/changelog.gz
uboot-mkimage: /usr/share/doc/uboot-mkimage/copyright
don@S10:~$

The output is quite verbose and some interpretation is required. In my case the required package is uboot-mkimage. This was fairly easy to identify since uboot is the grub equivalent on the 1BeageBoard.

In my personal quest to learn about apt-* I came across a a few more useful commands which I will summarize here:

apt-get upgrade -u –> get a list of what can be upgraded (run apt-get update first)
apt-get upgrade –> install available upgraded packages
dpkg-query -l “search_string” –> query package database (of installed packages)
dpkg-query -l –> list all installed packages
dpkg -i <*.deb> –> manually install a package, use this with care and make sure the package is trusted
deborphan –> with no arguements lists orphaned packages, must be installed, apt-get remove can then be used to remove orphans manually, use care with this!

Ii can now say that I can do all my required package management with apt-* as well as i can with yum which make using ubuntu somewhat less irritating.

————————
1 The Beagleboard is an embedded ARM platform that can run many flavours of Linux, I run Debian Lenny on mine (http://beagleboard.org/)

2010
05.17

That title might be longer than this post, but if you’re running into problems with zone transfers that don’t appear to happen, check to make sure you are putting your zone files in /var/cache/bind.

Read More >>

2010
03.11

So, as these things go, I spent 2 days looking at my OpenVPN config files and bridging setup before finding the solution to my problem was elsewhere.

A little background: I created a new OpenVPN VM using the Debian Squeeze net install CD, configured it to match what was already working on a physical Windows XP box, but only had limited success. I was able to connect to the VPN, ping the OpenVPN server on the network, but couldn’t connect to anything else. Trying to ping another server from the VPN client, and running tcpdump on that other server showed that it was receiving ICMP requests and replying, but they were not making it back to the VPN client. I tried a hundred different ways of creating the bridge on the OpenVPN server, but nothing worked. Finally, good old Google found the answer. The ESXi virtual switch drops promiscous packets by default. To fix it, open the vSphere Client, click on the ESXi host on the left side, click on the “Configuration” tab on the right, click “Networking” in the Hardware box, click on “Properties…” at the top-right of your “Virtual Switch: vSwitch#” graphic. Now on the “Tools” tab of this popup window, select the “vSwitch” and click the “Edit…” button. In this popup, click on the “Security” tab and change “Promiscuous Mode” from “Reject” to “Accept”. Click “OK” then “Close” and you should be all set.

Read More >>

2010
03.11

echo "# Disable IPv6" >> /etc/sysctl.conf
echo "net.ipv6.conf.all.disable_ipv6 = 1" >> /etc/sysctl.conf
echo "#" >> /etc/sysctl.conf
reboot

Oh yeah, and if exim freaks out,
vi /etc/exim4/update-exim4.conf.conf
and change dc_local_interfaces so it reads
dc_local_interfaces='127.0.0.1'

2010
03.03

Snapshots are available with VMware Workstation, VMware Fusion, VMware Server and ESX/ESXi.

Windows has a feature called system restore.  The idea behind System Restore is to revert to a point in history in case something goes wrong – i.e.: patch Tuesday. It’s an undo feature for your Windows OS. There is overhead for this undo feature, especially on the IO front which is generally acceptable for a dedicated desktop but not ideal for VMs.

One can approximate the function of System Restore with snapshots. Snapshots should be used only when modifying a VM, i.e. patch Tuesday, new software, etc… The idea is “I know I’m making a change so I snapshot the VM”, I execute the change, and test. Once testing reveals no issues and everything works as expected, the snapshot is removed.  (Of course this is now a manual process instead of an auto magic one so it’s a compromise)

Snapshots should not be persistent! They should only have a life of a few hours to a few days.  It is important to remove the snapshots since it creates a delta VMDK file and can grow quite large.  Also, if one creates many snapshots this can affect performance of the guest.

Personally I usually snapshot when the guest is powered down – this gives me the cleanest possible snapshot and I can revert to it with confidence.   It also means the snapshot is created instantly since the file system does not need to be quiesced.  Additionally, it is important to remember your VMware hypervisor can quiesce the file system (so long as VMware tools installed) but not necessarily the applications running in Windows.  i.e.:  SQL cannot be snapshotted reliably.

It is also very important to remember Snapshots are not backups in anyway shape or form. For “backup” purposes the entire VM package should be copied and compressed and stored on a medium other that the host running the VM.  i.e.:  I store my VM archives on my DIY NAS.

Disabling System Restore in XP: Right-Click My Computer and select properties and click the system restore tab, Select “Turn off System Restore” and click OK.
Disabling System Restore in Windows 7: Right-Click My Computer and select properties, click the System Protection link, Click the Configure Button and select “Turn off system Protection”, OK, OK

In conclusion, one can use snapshots in lieu of system restore to gain some performance in the Windows guest but it’s a compromise since the taking and deleting of snapshots is a manual process.