Blog

Sync your iPhone/iPod with two computers

For a very long time I’ve had my iPhone synched to my home computer. All my Apps, Music, Ringtones, Videos and Books were on my home computer. Than, I started managing new additions to my iTunes library on my work computer. I’ve added songs, playlists, albums and artists that represent my state of mind, mood and life better than before. And I realized that my iTunes library at work has more organized playlists, folders than one at home. What would be the easiest way to merge them together?

Well at first, I looked at home library, and copied all albums (I manager my iTunes folder myself as I file songs differently) to portable harddrive, brought it to work and add it in. Now, my work library had all my home playlists/albums and more. With 22GB of music, I’ve copied my whole folder /Users/username/Music/iTunes onto it and replaced the one I had on my home computer. Perfect, I thought, now all I do is add music on my work computer and then make sure I either bring that music to home computer later or copy the iTunes folder all over again, if changes are drastic.

Well, what I haven’t realized, and to my benefit it is a plus, by doing this, my iPhone now thinks that both libraries – one at home and another one at work – is the same thing. Great! I don’t have to worry when plugging iPhone to my work computer that all my music would be gone, I can update my iPhone either at work or at home and I can also keep managing my music in one library, copy it to another and don’t have to remember which computer I’ve synched my iPhone to.

Xerox 242 Printer under Snow Leopard

In the last couple of months we’ve acquired more iMacs and most of them came with Snow Leopard pre-installed and, being newer machines, will not take 10.5 system. Snow Leopard is great – quick, responsive but there are some challenges.

One of them was our Kerio Mail Server, which has been addressed in one of the Kerio updates. But most recent one, and more annoying is drivers for our Xerox 242 WorkCenter. Once drivers installed and user tries to print, it will give them error message saying that drivers might not be installed properly and require re-installation.

No matter how many times you try to reinstall, what user you install them as, or how many times you repair permissions on the drive, it seems not work properly.

Quick search on Apple Discussions leads to several similar problems with other printers’ drivers problems under Snow Leopard. Solution is repairing permissions, but not the usual way, actually, but using sudo

sudo chown -R root:admin /Library/Printers/

Just make sure you add your printer’s manufacturer folder after /Printers/

So Xerox will be:

sudo chown -R root:admin /Library/Printers/Xerox

Hope this helps as it did work for me.

OS X Server in VMWare – part 4

This will be forth article in the series of articles about Mac OS X Server 10.5 setup under VMWare.

I would leave FileMaker Server installation for another time. Right now I want to talk about following services on the server which will replace existing server. Here is the situation, just a reminder:

I have live server which hosts websites and FileMaker databases. It also runs AFP services for access to files internally and FTP service for external developers access to those files. Our registration websites are secure websites with proper CA signed certificates. This server, once virtualization project is complete, would become host server, which will not have any services running, well maybe AFP, and will have VMware hosting guest machines. One machine would be new server with registration websites and FileMaker databases with same FTP and AFP services running as well. My challenge is to swap services of current server with new virtual server with least impact, as those registration websites are live 365 days a year and updating every now and then.

So, I’ve setup bare 10.5.7 server, called it promorphius and it would become twin of prometheus, our existing server. Next steps would include:

Setup web server.

First I moved all files from prometheus web server folder to promorphius. I set up site under web service in Server Admin with exact same settings as existing, except for folder location, it’s on separate virtual drive. I then need to make sure that this site is secured and all HTTP requests are going to HTTPS.

As I already have signed certificate on prometheus, I would request Reissue of the certificate from our CA. Follow links provided by your provider to the step where they ask you for CSR (Certificate Signing Request). On that page you would have text field for the CSR. On the new server, I’ve created new certificate with same information as on existing server, but it becomes Self Signed. No worries, Save and select this certificate and click on little gear icon in Server Admin, choose “Generate Certificate Signing Request  (CSR)… ” and window with instruction would appear. Select image of certificate and drag it over text box on the CA’s website. It will be filled with some gibberish, that’s exactly what we need. Follow all neccesary remaining steps. Once you get your certificate select that text copy and select your Self Signed certificate from Server Admin and under little gear icon choose “Add Signed or Renewed Certificate from Certificate Authority…” paste the text in this area now. That’s it, your certificate is signed now!

Next in web server setup, we want to choose our newely signed certificate for our secure server. Under Web service, in Server Admin, choose Sites, select your site (remember, it suppose to use port 443) and under Security check box next to “Enable Secure Sockets Layer (SSL)” and select your signed certificate.

Now, we want to make sure that all requests to our HTTP forward to HTTPS. For that we would duplicate our web site, select port 80 instead of 443 and deselect SSL checkbox in security. We now need to do a little hack to setup these forwarding. Open Terminal, type in su type in root password, type in cd /private/etc/apache2/sites do ls to view your files, you will see some files like 0016_195.75.175.184_443_secure.example.com.conf type in pico 0002_10.1.1.11_443_secure.example.com.conf using your own file name. This will open basic text browser. Scroll down to area with:

RewriteEngine On
RewriteCond %{REQUEST_METHOD} ^TRACE
RewriteRule .* - [F]

Edit this section to include:

RewriteRule ^/(.*)$ https://secure.example.com/$1 [R]

And either delete or comment out existing lines.
So final would look like this:

RewriteEngine On
##RewriteCond %{REQUEST_METHOD} ^TRACE
##RewriteRule .* - [F]
RewriteRule ^/(.*)$ https://secure.example.com/$1 [R]

$1 would insure that if somebody types in http://secure.example.com/sub/page.php they would be redirected to same subpage but HTTPS.

Now it’s time to check our server. Since we don’t want to change DNS settings for our domain as it will take up to 24hrs to propogate, we would use exisiting settings and swap IP addresses of old-real and new-virtual servers (you mapped both external and internal interfaces of your hardware to VMware, right? Instructions) Test your site, and everything should stay the same.

I’ve had issues with error messages on my php pages:

Warning: session_start() [function.session-start]: Cannot send session cache limiter – headers already sent

The reason for that is session_start() function in php file. Make sure it is at the very first line of the file.

“Roam oversea” project

Two members of our team were heading oversees, Russia to be exact, for couple of weeks and it was my responsibility to come up with solution for cheaper roaming. One of them was on Telus with World Blackberry while other had personal Fido phone. Telus roams fine in Russia, but bills are outrageous. Telus charges near $5 per minute.

My challenges were:

  1. Find cost effective way to keep person with personal phone connected and eliminate need for reimbursement of personal expenses occurred on personal phone.
  2. Find cost effective way for person with Blackberry to stay connected while maintaining existing number.

The solution was… Read More

OS X Server in VMWare – part 3

This will be third article in the series of articles about Mac OS X Server 10.5 setup under VMWare.

Once we finished battling through updates on the OS X Server (install 10.5.6 by downloading Combo update from Apple.com first using VMware Fusion 2.0.4, then update to 10.5.7) we are ready to set up network interfaces.

My XServe is connected through 2 network cables to external world and internal network. One is public, external IP, other is internal IP.

Set up for my first server which will host registration websites, FileMaker Server and FTP/AFP access to it for developers, would include 1 public IP and 1 internal IP.

Let’s start.

First of al, I want to warn you that it is rather advanced setup to bridge two real network adapters to VM’s two virtual adapters. I hope it will work. I am referring to article on VMware community website.

First thing is download tokamak script from VMware community document by DaveP.

Make sure that all guest VMs are shutdown and VMware application is not running.

Follow instructions to install script. once script is installed, run configuration (remember to run it as root, easiest way to do it is to use su command):

./tokamak.sh --modify

This will take you through bunch of prompts, use as follows:

You have already setup networking.
Would you like to skip networking setup and keep your old settings as they are? (yes/no) [yes] n
Do you want networking for your virtual machines? (yes/no/help) [yes] y
Would you prefer to modify your existing networking configuration using the wizard or the editor? (wizard/editor/help) [wizard] e
The following virtual networks have been defined:
. vmnet1 is a host-only network on private subnet 192.168.170.0.
. vmnet8 is a NAT network on private subnet 192.168.64.0.
Do you wish to make any changes to the current virtual networks settings? (yes/no) [no] y
Which virtual network do you wish to configure? (0-99) 2
What type of virtual network do you wish to set vmnet2? (bridged,hostonly,nat,none) [none] b
Configuring a bridged network for vmnet2.
Your computer has multiple ethernet network interfaces available: en0, en1.
Which one do you want to bridge to vmnet2? [en0] en0
The following virtual networks have been defined:
. vmnet1 is a host-only network on private subnet 192.168.170.0.
. vmnet2 is bridged to en0
. vmnet8 is a NAT network on private subnet 192.168.64.0.
Do you wish to make additional changes to the current virtual networks settings? (yes/no) [yes] y
Which virtual network do you wish to configure? (0-99) 3
What type of virtual network do you wish to set vmnet3? (bridged,hostonly,nat,none) [none] b
Configuring a bridged network for vmnet3.
The following virtual networks have been defined:
. vmnet1 is a host-only network on private subnet 192.168.170.0.
. vmnet2 is bridged to en0
. vmnet3 is bridged to en1
. vmnet8 is a NAT network on private subnet 192.168.64.0.
Do you wish to make additional changes to the current virtual networks settings? (yes/no) [yes] n
VM@Work Tokamak 2.0.0: Display settings
The following virtual networks have been defined:
. vmnet1 is a host-only network on private subnet 192.168.170.0.
. vmnet2 is bridged to en0
. vmnet3 is bridged to en1
. vmnet8 is a NAT network on private subnet 192.168.64.0.
VM@Work Tokamak 2.0.0: Extended network scripting - Dave Parsons
Host-only/NAT networking on vmnet1 using 192.168.170.1/255.255.255.0 is running
DHCP server on vmnet1 is running
Bridged networking on vmnet2 using en0 is running
Bridged networking on vmnet3 using en1 is running
Host-only/NAT networking on vmnet8 using 192.168.64.1/255.255.255.0 is running
DHCP server on vmnet8 is running
NAT networking on vmnet8 is running

We are almost done.

Almost all of this is the same as document, with slight differences. We are linking XServe’s en0 interface to vmnet2 and en1 to vmnet3. One of them will be used for internal interface, one for external/public.

Next, as per document, open vmx file, I’ve modified it in BBedit, but use tool recommended on the same website. Now, here is where I wasted almost 2 hours trying to figure out why my VM does not see those interfaces.

See, this article and script have been tested on VMware Fusion 2.0.2 and I am using 2.0.4. Maybe it makes a difference, maybe not, but the bottom line is that my newly created interfaces were displaying fine in VMware (except for the message about custom configuration, which you can ignore), they are displaid as connected when VM is running, but Guest OS X Server does not see them.

I’ve searched every posting and forum on VMware community website and could not find anything. Unless I’ve noticed this string:

ethernet1.virtualDev = "e1000"

That string existed for each ethernet# created using VMware UI, but not for those custom added interfaces I’ve manually added to VMX file. By adding that string to those instructed in the article for each interface:

ethernet1.present = "TRUE"
ethernet1.connectionType = "custom"
ethernet1.vnet = "VMnet3"
ethernet1.virtualDev = "e1000"

to VMX file, Guest OS was loaded with two interfaces connected. I’ve assigned internal IP to one, and external IP to other. Next is installation of FileMaker Server (do not forget to take snapshot of the system)

Page 4 of 6« First...23456