How to run multiple Chrome profiles for website testing

For many web developers is may be helpful to run multiple instances of Chrome to test multiple user types at the same time without having to constantly login and logout. Here are examples of how to do this by launching Chrome from the command line.

Ubuntu

chromium-browser --user-data-dir=/home/$USER/.config/chromium-profile-test

Mac OS X - Lion

/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --user-data-dir=/Users/$USER/Library/Application\ Support/Google/ChromeTest

There is much information about this here: http://www.google.com/support/accounts/bin/answer.py?answer=179236 but I found it easier to simple create a bash script to launch a separate testing profiles like so.

vim start_chromium_test_profile

 

Paste the following into the script file:
#!/bin/bash

chromium-browser --user-data-dir=/home/$USER/.config/chromium-profile-test
Make the script executable:
chmod +x start_chromium_test_profile
Run script:
./start_chromium_test_profile

Happy web developing!

Hi David thanks for this

Hi David thanks for this tip.

I notice that after you kill the new instance of Chrome you get:

Sep 17 19:46:57 Matthews-MacBook-Air.local Google Chrome Helper[781] : CGSLookupServerRootPort: Failed to look up the port for "com.apple.windowserver.active" (1100)
Sep 17 19:46:57 Matthews-MacBook-Air.local Google Chrome Helper[783] : CGSLookupServerRootPort: Failed to look up the port for "com.apple.windowserver.active" (1100)

in your terminal session. Any ideas why?

I'm not sure why you are

I'm not sure why you are getting the error. Is it causing any problems for you?