Category Archives: Hosting

1-Click Install of Open Atrium on Dreamhost

Summary: If it was just one click I probably wouldn’t be writing about it ;) This is really for the ADD peeps and newbs out there, there’s nothing too challenging about this install.

Here’s a quick guide to starting an Open Atrium (Drupal-based “intranet in a box”) site if you happen to be a lucky Dreamhost customer. Dreamhost just added this feature today and it is pretty slick, but there’s still a couple bits of manual configuration.

Here’s what you’ll get:
screenshot of the dashboard of a fresh Open Atrium installation

How to Install Open Atrium on Dreamhost

  1. DH Panel: Go to Domains > Manage > Add New Domain / Subdomain, and create a spot to put your Open Atrium install. For example: oa.23rdworld.com. You can make your subdomain anything you want.
  2. DH Panel: Goodies > One-Click Installs > OpenAtrium. Select your new subdomain and leave option set to ‘Automatically create database’.
  3. You will receive an automated email from Dreamhost that will include an link to your new site and information about your database that you will need later. Save this info!
  4. Set file permissions. Access your server files (FTP or shell, etc) to your new site. Just as the actually quite helpful error message says:

    # Copy the ./sites/default/default.settings.php file to ./sites/default/settings.php.
    # Change file permissions so that it is writable by the web server. If you are unsure how to grant file permissions, please consult the on-line handbook

    For you newbs, an easy way to do this is to use an FTP client (like Filezilla) to access your new site.

    • Download /sites/default/default.settings.php
    • Rename default.settings.php settings.php
    • Upload settings.php to /sites/default/
    • Right-click settings.php and select file permissions (in Filezilla, will be similar in other FTP clients) and set it to 744 (server/owner can read-write)
  5. Go to your new site, for example: oa.23rdworld.com, this is where the prompts begin. Follow them.
  6. Open Atrium installation settings.php file permission errorYou will get an error message (at right) if you skipped the ‘Set file permissions’ step (above). That’s ok, you can just go back and do that now and then click ‘Try again’.
  7. Database settings: Fill in the database settings based on the email mentioned earlier. Make sure to open the ‘Advanced options’ menu group and enter the hostname (also provided in the email).
  8. The rest of the configuration settings should be pretty obvious.

Hope this was useful for someone, I’m curious to see/hear what folks are using their Open Atrium installs for. Obviously not an intranet…unless you made it private…there’s loads of ways to do that (if there’s interest I’ll expand). I’m using mine to organize house projects with my roommate and husband. What are you using Open Atrium for?

P.s. If anyone is looking to get a new Dreamhost account I have a $100 off invitation if you’re ready to commit to two years and there’s plenty of referral codes out there too, so find one before you sign up!

Installing Using Drupal book source on Dreamhost

USE THIS INFORMATION AT YOUR OWN RISK. Any information found on this website is offered only as informational and includes no warranty, guarantees or support. The author claims no authority on any subject whatsoever.

Using Drupal, 1st Edition by OReilly

Using Drupal, 1st Edition by O'Reilly

I just started reading the recently published book Using Drupal, 1st Edition, published by trusty ol’ O’Reilly and written by a bunch of Lullabots.

So far the book is great, but the instructions on setting up a dev environment aren’t exactly crystal clear for those completely new to Drupal. I thought I’d help out the next geek that bothers to GTS to find pitfalls before starting.

First review the preface section 2.7 ‘Downloading Drupal’. If you’ve never installed Drupal before, or any web application on a web server before, it’s a good idea to check out Lullabot Addison Berry’s very easy to follow video, Installing Drupal 6.

These instructions are specific to the context of a shared hosting account on Dreamhost, but may work for your environment as well. Be sure to review the book’s errata – the ‘confirmed errata’ will let you know about any code mistakes or problems with source discovered since the book was published. For troubleshooting help related to the books exercises and installation issues, review the Using Drupal book forum.

THESE INSTRUCTIONS MAY CAUSE YOUR DATAZ TO BE LOST. In addition to setting up things quickly, these steps include how to quickly delete all the stuff in your database, without bothersome ‘back up your data first’ steps. The idea is you are just creating a sandbox and nuking your install is no big deal.

Enough blab, let’s do this:

  • Create a subdomain for your dev environment like drupal.yourdomain.com
    • Dreamhost panel > Domains > Mandage Domains > Add New Domain / Sub-Domain
  • Create a new database (on a new or existing subdomain)
    • Goodies > Manage MySQL, scroll to the bottom where it says ‘Create a new MySQL database:’
    • Enter something in all the fields:database name must be unique system wide so get creative, create a new hostname like mysql.drupal.yourdomain.com, you can use your own username but I created a special username and password that I’ll also be using for the admin user in the Drupal install (note: dev enviro, not recc’d for production), you might want to put something to remind you what this is later in the comment field like “Sandbox for Using Drupal Book”.
    • Write down all that DB stuff so you can use it later.
    • Wait a while for new database host name and/or new subdomain to propagate.
  • Download the latest source from the book site.
    • Extract the zip somewhere you can find it, like your desktop.
  • Change the database connection string in using_drupal_source\drupal\sites\default\default.settings.php
    • Open default.settings.php with your favorite text editor
    • change connection string stored in $db_url (line 92 at TOW) from mysql://username:password@localhost/databasename to something like mysql://name:psswd@mysql.drupal.yourdomain.com/dbname
  • Copy default.settings.php in the same folder and call it settings.php
    • There should now be 2 files in the default folder
  • Save a backup copy of your default folder somewhere
    • I just copied the default folder and renamed it ‘_default’, or save somewhere on your hard drive, thumb drive, whatever…the point is, settings.php and default.settings.php that will soon live on your web server are going to change and you’re going to want these files again someday.
  • Upload the contents of using_drupal_source\drupal to the root of your new subdomain
  • chmod /sites/default to 777
    • On you web server (via your FTP client) navigate to /drupal/sites/default
    • If you’re using FileZilla, right click (ctrl+click for macs) the default folder and select file permissions, this will allow you to enter the numeric value 777 or just check read/write/execute for all roles
  • Open http://drupal.yourdomain.com

Installation profile options on successful install

Installation profile options on successful install

You’ll be prompted to select an ‘Installation Profile’. The book source code includes scripts to automatically install a site with assets and modules used in their examples for you. If you are just starting Chapter 2. where they send you off to the Appendix for installation instruction, chose the last option – the generic/basic Drupal install.

Here’s how to “start over” so you can use a different installation profile. These steps will cause you to lose any data you entered in Drupal – you will end up with a brand new install and a chance to chose a diferent installation profile:

  • Nuke all your database tables

    • Note I said ‘tables’, not the database.
    • Go to http://mysql.drupal.yourdomain.com (phpMyAdmin screen) and login
    • Select you Drupal database from the databases list at left (e.g. NOT information_schema)
    • Scroll to the bottom of tables listing page and select ‘Check All’, change the ‘With selected:’ drop down to ‘Drop’.
    • You will see a screen asking if you really want to execute this command. Click ‘Yes’.
  • CHMOD /sites/default to 777 again
    • On your web server, go to /sites/default
    • CHMOD default to 777 (again, because the previous install process modified the permissions) and be sure to check ‘recursive’ (or use -R on commandline) because there’s new files in there and we need to blow everything in the default folder away.
  • Delete everything in /sites/default
  • Put a clean copy of default.settings.php and settings.php in /sites/default
    • Remember that saved copy of default.settings.php and settings.php?
  • Go to http://drupal.yourdomain.com/install.php and start all over again :)

Bold moves in phpMyAdmin. Select all  drop.

Bold moves in phpMyAdmin. Select all > drop.

I hope that was helpful for someone. I remember all to well not even knowing what chmod was and trying to write perl scripts, ouch! As you might guess, with as much time as I spend documenting when I should be doing book exercises I don’t really have time to offer support, but please let me know if anything I’ve written here needs to be corrected or elaborated on. Have fun in Drupal land!

Don’t use Main Street Host for Web Hosting!

Someone just called me at work about “Main Street Host Dot Com”. Now, whether that’s mainstreethost.com or main-street-host.com or mainsthost.com, whatever. They telemarket, so they obviously can’t make money by offering good/fair service. Don’t use them. And as long as I’m on a rant about crappy web hosts, if you want to procrastinate whatever it is you’re doing and have a laugh read this account of Lunapages misguided insertion of link farms on their customers’ 404 pages. The comments become puerile and ranty. In fact, I haven’t seen such childish bantering since 1996 bbs flame wars.

2009.03.09 Update Since this rather random little post continues to get a lot of traffic and comments, I thought I’d offer some useful links on SEO [via Lifehacker 2009.02.28]

2009.10.26 Update I have noticed that a lot of the relatively few pro-MSH and most of the name-calling rude comments are coming directly from mainstreethost.com IP addresses. I try to occasionally post their IPs publicly when I find this. Note however, it’s very easy to use a proxy server to fake your IP address so any comments could be by MSH employees and I would not be able to trace it. I am not saying they have zero happy customers, but I would caution that based on simple statistics so far, to use a healthy dose of skepticism while reading the following comments.

2011.08.03 Update Officially closing comments on this post. Some other blog will have to carry the torch as a place for the continually disgruntled customers and near-customers of Main Street Host to kvetch.

If you are looking for a web host recommendation, check out my post What Web Host Should I Use?. Though written in 2006, I still use and recommend Dreamhost (for shared hosting). Good luck!

How To Make Your MediaWiki Private

USE THIS INFORMATION AT YOUR OWN RISK. Any information found on this website is offered only as informational and includes no warranty, guarantees or support. The author claims no authority on any subject whatsoever.

I've been using an amalgamation of hacks to track all the information I want to be able to recall later: del.icio.us for bookmarks, gmail for contacts and random notes, private blog entries for some organized content, and tracks for tracking projects. Blech. It's just too much. My memory is too weak. What I really want is a comprehensive PIM (Personal Informatio Manager). And so I installed MediaWiki because that's what Wikipedia uses and that's what Dreamhost offers as a One-Click Install (e.g. the path of least resistance).

I thought I'd share with you all the the process of customizing the default install to create a private wiki. Following are the specifics to my install but this will probably be helpful to many with a different host or newer version.

  • Create a subdomain for your MediaWiki install, such as, wiki.yourdomain.com. Select PHP 5.x (not 4.4.2) and leave Extra Web Security.
  • Install MediaWiki. Dreamhost walks you through this and it's also covered at the Dreamhost Wiki so I'm not going to go into detail here. But be sure to move the newly generated LocalSettings.php to the parent directory, and delete the config directory with its content.
  • Chmod LocalSettings.php to 600
  • Create a backup copy of LocalSettings.php, rename it something like .BAK instead of .PHP or something. Put it back in your Wiki install directory right away so it's safe and available if you need it later.

Restrict Wiki Access

Before bothering to put up our own cute logo or other fun stuff like enabling image linking and using clean urls, we're going to lock down our install. I didn't find a lot for this particular intent on the official MediaWiki Docs or the Dreamhost Wiki, but I did find this old Meta Wiki Article

  • Prevent new user registrations. Add the following line to the bottom of LocalSettings.PHP:
    # This snippet prevents new registrations from anonymous users
    # (Sysops can still create user accounts)
    $wgGroupPermissions['*']['createaccount'] = false;
  • Make sure it's working by trying to create an account. You should receive an error message that says username not found, please create an account. To change the message login as yourself (you should have set up a Sysop login when you configured your wiki) and point your browser to wiki.yourdomain.com/index.php?title=MediaWiki:Nosuchuser&action=edit.
    I changed my message to:
    There is no user by the name "$1". This wiki is private and therefore closed to new accounts. Please contact Mahalie if you have any questions.
    I intentionally failed to provide contact information. If a user doesn't even know how to contact me, they really don't need an account on my private wiki!
  • Prevent anonymous users from reading by adding the following to LocalSettings.php: # Disable reading line, for anonymous (not-logged-in => * ) :
    $wgGroupPermissions['*']['read'] = false;

    # ... and enable anonymous to read the followings pages :
    $wgWhitelistRead = array( "Main Page", "Special:Userlogin", "-", "MediaWiki:Monobook.css" );

    # ... same in an other language (French, with one UTF-8 special characteres) :
    # $wgWhitelistRead = array( "Page Principale", "Special:Userlogin", utf8_encode('Aide en fran├žais'));
  • Verify setting by logging out of your wiki and attempting to browse. You should get a 'Login Required. You must login to view other pages.' when clicking on any local link and the page should redirect to the main page after a few seconds.
  • If you want to hide the side navigation if the user isn't logged in (because, perhaps you have private project names or something) edit includes/Skin.php and change the function buildSidebar(). Add these lines near the very top, after the globals.: global $wgUser; if (! $wgUser->isLoggedIn()) { return array(); } This will hide the navigation on sup-pages (not the default main page)

p.s. WebWorkerDaily just published 15 Productive Uses for a Wiki in case you're wondering why someone would want to do this!

Update: Check out a new tutorial on Lifehacker, Customize Mediawiki Into Your Ultimate Collaborative Website - it's not a PIM implementation but it offers some good information on quickly re-skinning and mods to consider.

Web Host offering .htaccess URL Rewrite

[Do you] have recommendations for a good economical place which offers hosting for apache? I need to be able to have support for url rewriting using .htaccess file

For Linux / Apache web hosting I always recommend Dreamhost, and they always provide whatever specific thing people seem to be requesting…in this case .htaccess url rewriting.

Here’s my review of Dreamhost:
http://www.mahalie.com/notebook/2005/06/10/my-web-host-reccommendation/

Here’s the answer to the inevitable “what about xyz webhost for only $3/month!”:
http://23rdworld.com/2006/03/06/what-web-host-should-i-use/

Here’s their support wiki page for Mod Rewrite:
http://wiki.dreamhost.com/index.php/Mod_rewrite

If you go with them I’d appreciate a referral (mahalie), but you
should go with them regardless, they’re great!

What Web Host Should I Use?

If I had a dollar for every time someone asked me what webhost to use, I wouldn’t have to work anymore. Well, maybe not, but I could definately buy one sweet pair of designer shoes! That’s why I’ve been documenting my answers, so I don’t have to write it anymore.

I always recommend Dreamhost.com right off the bat because I have personal, verifiable positive experience with them which has only increased in favor over time and which is supported by thousands of adulations by other customer of Dreamhost’s, freely accessibly via a Google search for “dreamhost“.

I have written about this on my personal blog, and recently someone asked me “but what about this ultra cheap host”. Well, here’s my review, and for future folks seeking reviews of their potential hosts…please just follow the advice herein and substitue “1and1″ with your webhost under consideration.

In short, if you’re going cheap as possible, their plans are better:

https://www.b-one.net/

http://dhost.info/

Registration is cheap, hosting is cheap, it depends on your needs. Because your needs are small (probably) for [the website] it might be fine.

For the price, it’s great…but here’s where they get you, entry packages are basically crippled and do not provide standard items such as Server Side Includes until the $10/mo (for instance, you want your navigation to be imported from one location on every page so navigation changes only have to be made in one file, not every page on your site), no statistics (on basic), no form builder and likely no ability to run scripts (for feedback/mail form, newsletter signup, etc) till $10/mo though you do get their pre-canned CGI form. Databases are where they really get you – SQL only included on $10/mo and up – only one database allowed on $10/mo and 2 on $20 per month with a truly measly 200mb limit. Although if you go with Linux hosting, you do start off with 10 mySQL databases on their base plan, but with a 100mb limit.

Again, if you’re just going to have a couple of static html pages then this could be a good deal for you. It’s definitely geared towards web design beginners and the prices are quite cheap. But if you guys decide you want to install some kind of calendar system or blog software, all of these things will require SQL (or mySQL) and you’ll quickly grow out of this plan and into the $20/mo and up. I didn’t see streaming media anywhere – I doubt it’s included and would quickly push you into traffic overages (extra charges) – so streaming music and vids would be out.

And of course, the ultimate test is a Google search the host, in this case, “1and1“.
It returned one oddly vague yet glowing review and then long threads of rants about them.
Also, I find their myriad incarnations of 1and1.com, 1and1.org, 1and1.co.uk, 1and1.fr, etc. a likely case of trying to push bad reviews on other sites down in search ranking (a direct domain name match nearly always gets ranking priveledge).

If a host is both cheap and good, trust me, a quick search will turn up pages and pages of raves from customers on blogs and message boards. People love finding cheap hosting that works. In fact, an interesting way to find a good webhost is a good search for “love my web host“. The many fine folks in the WordPress community have provided a small list of recommended hosts as well, even if you aren’t using WordPress (blogging software), I’d bet these hosts are pretty darn good in general.

1and1.com has a well-designed and enticing site, I’ll give them that…but you know the saying, if it seems too good…