Wednesday Nov 11, 2009

How To Install Acquia Drupal on OpenSolaris (it's easy!)

I just published a short how-to video showing how you can easily install Acquia Drupal on OpenSolaris.


Sun's ISV Engineering group has been working with Drupal for a couple of years now; I also use Acquia Drupal to develop and maintain this web site, which also hosts my personal blog.  The Drupal community is amazingly vibrant and growing by leaps and bounds, and Acquia has done a nice job of commercializing the Drupal open source content management software package.  Acquia Drupal is still free, but it has some nice additions that any Drupal user or developer would want.

Anyway, check out the video; it's about 8 minutes long and walks you through the steps to find the catalog of third party applications, then get Acquia Drupal and configure it on your OpenSolaris system.  It's easy, and it just works.

Oh and by the way: props to our Sun Learning Exchange web site and staff for making it so darned easy to publish content.  Nice job, folks!



Powered by ScribeFire.

Monday Oct 26, 2009

U.S. Government re-launches whitehouse.gov on Drupal

A big win for open source software happened this weekend, with the primary U.S. government web site being re-built using the Drupal open source content management system:

Also, Tim O'Reilly talked about it as well.

General Dynamics is the prime contractor for the project, with several Drupal shops being subs.

Nice job, Drupal people!


Powered by ScribeFire.

Wednesday Oct 14, 2009

Update: Drupal now available in OpenSolaris

Sun's ISV Engineering group has been working hard all spring and summer to get fistfuls of popular and important open source applications into the OpenSolaris "contrib" repository, a repo for third-party applications that can be assumed to have some level of sanity checking done on them.

Eric Reid in ISV Engineering has submitted three different releases of Drupal; today, the final release (Acquia Drupal) was approved and placed into /contrib.  These three applications are
  1. Drupal 5 (release 5.20)
  2. Drupal 6 (release 6.14)
  3. Acquia Drupal, created by the commercial enterprise backing Drupal: Acquia.com
It's nice and easy to try out any of these Drupal packages in OpenSolaris.  Want help?  Read this entry on drupal.org for complete yet succinct instructions.

(update)
I should also point out that when you install Drupal in OpenSolaris, the package management system will pull in the Sun WebStack components automatically, which is all free as you would expect.  It's the AMP stack components you know and love, but optimized by Sun for out-of-the-box performance improvement, plus a management console that lets you see what's going on with the components while you're running your Drupal web site.

(Okay, that may have sounded a bit like an advertisement, but we really did put a lot of engineering effort into optimizing the AMP components on Sun's systems and the new analytics thingy is pretty cool looking.)
(/update)

Meanwhile, this adds one of the premier open source content management systems to the stable of apps freely and easily available to you when you install OpenSolaris on your computer.  You can even choose from amongst the leaders in blog engines / content management systems / web site building tools: Drupal, Joomla!, WordPress are all available now.  Here is a list of packages published to the contrib repository.

Check 'em out!




Powered by ScribeFire.



Sunday Aug 09, 2009

Using ZFS Rollback and VirtualBox for Development

I came across this nice blog entry that shows how you can use ZFS's snapshot and rollback features along with VirtualBox to make it really easy (and safe) to try things out during development and not have to worry about losing track of exactly which changes you made when you want to go back to a clean state.

For me, this helps in creation of web sites.  I am using Drupal to create a web site, but there's a lot of exploratory development I'm doing and if I mess up something, I want to go back to a known-to-work state.  So, I create a VirtualBox image (OpenSolaris as my guest OS), then work with Drupal on that image.  The thing is, sometimes I make changes that affect the state of the operating system so I want to cleanly go back to a working state.  This blog entry shows me how to do exactly that.


Powered by ScribeFire.

Monday Apr 27, 2009

How to push a simple Drupal web site from test to production

As I'm learning how to use Drupal for creating and deploying web sites, I'm keeping track of it in blog entries.

The way I work: I do my development on a virtualized environment: I run OpenSolaris as a guest OS under VirtualBox; that way, I can easily blow away my development/test environment or send it to other machines running VirtualBox.  Then, I install the WebStack (PHP, Apache web server, MySQL), then I install Drupal using the instructions on the drupal.org web site.

Once I get my test Drupal site working, I follow these instructions to deploy to an actual production server.  It makes the develop-test-deploy cycle pretty easy, and I can develop and test pretty much anywhere.



Powered by ScribeFire.

Friday Mar 20, 2009

Notes on Setting up a Drupal automated test bot on OpenSolaris

On drupal.org, there is a topic about how to set up an automated test bot.  I'd like us at Sun to contribute to Drupal's automated test farm, so I'm trying to set up a computer running OpenSolaris to be a test server.  Here are notes I've taken based on the work I've done so far to get it working.


I got the test package here.  Unpacked it into /var/local, as per the instructions listed here.

- To get my test bot running on OpenSolaris, I have modified the following files in the directory tree:
First, I created a new profile, called it "opensolaris" (here it is).  Some parameters are different on OpenSolaris than on CentOS or Debian / Ubuntu; re-defined as appropriate for OpenSolaris.  (example: starting, stopping, and re-launching services like Apache.  Use the Service Management Framework (SMF) In OpenSolaris for easy start/stop/restart of services and automatically take care of other services which may need to be managed as dependencies.)

Next, tried to run the "testing_server_install.sh" script to see if everything just worked.  Nope.  Ran into several obstacles; here they are, with the fixes / workarounds to make things work.

Obstacle #1: cvs checkout with "-z6" option seemed to stall.  I think the check-out happened okay and cvs just isn't exiting, but I'm not sure.

Fix #1: added new variable to the profiles: CVS_COMPRESSION.  Then, modified the "install" shell script; whenever it used to say "$CVS -z6", substitute "$CVS $CVS_COMPRESSION".  Now in the platform-specific templates (in the profiles/ directory), look where "CVS" is defined.  Add a line before it, creating a new variable called "CVS_COMPRESSION" and on OpenSolaris, define it as empty (i.e., don't pass the "-z6" flag).  The cvs works fine without the "-z6" option.

Note to self: need to find out why -z6 didn't work.


Obstacle #2: tried running the script, it complained that it can't log into MySQL with root user & password.

Fix #2: I forgot to set up the DB with password.  Went into MySQL and did that.

Obstacle #3: APACHE_INIT didn't work as currently defined.  Needs to accommodate different ways of starting services; in particular, the OpenSolaris svcadm command syntax different from using init.d.

Fix #3: Modify the definition of $APACHE_INIT for OpenSolaris.  Also, modify the "install" script to just invoke "$APACHE_INIT" with no arguments (i.e., no "restart") since it'll now be part of the $APACHE_INIT variable itself.

Obstacle #4: during useradd, complains that usernames are too long. Red herring; it's a warning, not an error.

Fix #3: ignore it.  Ideally, either have OpenSolaris accept usernames longer than 8 characters (really, it doesn't do that?), or shorten the usernames for Drupal test package.

Obstacle #4: during useradd, the use of the "-m" flag caused useradd to fail.  Why does "-m" fail?  It's a conflict with trying to add directory in /home, which is automount-mapped to /export/home.  There's an OpenSolaris bug about this.

Fix #4: Specify a "-b" option to set the base directory to /export/home, i.e., "-b /export/home".  Added a variable to the profiles: "USERADDFLAGS", specified "-b /export/home" in the opensolaris profile.  Then, changed the "install" script to invoke $USERADD with $USERADDFLAGS.

Alternate Fix #4: disable automounting for the test apparatus.  I didn't try that.

Obstacle #5: PHP complains about not having valid timezone set.  Script continues fine, doesn't complain, but I'd like to get rid of the warning complaint message.  I'd rather not modify the php.ini file to set timezone, but setting TZ didn't work either.

Fix #5: Set /etc/php/5.2/php.ini line "date.timezone" to "US/Pacific"; that eliminates the warning complaint message.


After these fixes, the script ran to completion.  Next, launched the browser, tried to visit my virtual test site's virtual domain, which I called "www.opensolarisdrupaltest.com".

Obstacle #6: In my browser, went to http://localhost.  Nothing appeared.

Fix #6: Don't go there; go to http://www.opensolarisdrupaltest.com instead.  That's the virtual site used for the testing.

Obstacle #7: In my browser, went to http://www.opensolarisdrupaltest.com.  Nothing appeared.  Need to tell my system to resolve "www.opensolarisdrupaltest.com" to "127.0.0.1" (i.e., localhost).

Fix #7: added "www.opensolarisdrupaltest.com" to the end of the line in /etc/hosts that contains "127.0.0.1".  The entire line now looks like this:

127.0.0.1 vbox-testhost localhost loghost www.opensolarisdrupaltest.com

Obstacle #8: In my browser, went to http://www.opensolarisdrupaltest.com.  Apache told me it couldn't access this site; didn't have permissions to access the drupal subdir in /var/www, where the drupal instance is installed.  As it turns out; the install process creates a "vhosts.conf" file to tell Apache that we're creating a virtual host (www.opensolarisdrupaltest.com); the install process puts this in /var/apache2/2.2/vhosts.conf which is fine, but the default Apache install on OpenSolaris denies access to virtual directories. 


Fix #8: Reverse access policy for the virtual host.  Modify the "install" script, the section that begins and add the following two lines to that directive:

Order allow,deny
Allow from all

(note: no space around the comman separating allow and deny)


Next, restart the web server (go to the GNOME Applications menu and choose "Applications -> Developer Tools -> Web Stack Admin -> Start Apache2/MySQL Servers".

Now, browsing to http://www.opensolarisdrupaltest.com works; I see the DrupalTestBot page and can log into Drupal.

Note to self: was this the correct way to give permissions to Apache for the drupal directory root /var/www/drupal on the VirtualHost www.opensolarisdrupaltest.com?


Okay, so now it's all configured; so far, so good.  What next?

How can I try out my test bot to see if it's configured and working correctly?

How do I make my test bot part of the test server farm?

Powered by ScribeFire.



Thursday Mar 05, 2009

Notes from DrupalCon 2009, Day One

I'm in Washington DC for the DrupalCon 2009 conference.  Drupal, for those not familiar with the technology, is an open source content management system (CMS) built using the PHP programming language.  If that explanation doesn't help, think of it this way: lots of people use Drupal to build web sites.  I mean, lots of people.  For example, the Obama administration's recovery.gov web site is using Drupal.  And during the conference, I've talked to online newspaper sites and people who built web sites for the major music labels (e.g., Warner Music, Sony, others) and they use Drupal to build their web sites.  The popularity and growth of Drupal is astounding.  You can feel it at the convention center here.

I'm here to learn more about the Drupal community: I intend to learn more about the big problems the community wants to address, their main customer pain points, the technical and non-technical problems they face, how the community works...and ultimately, how Sun can play an important role in the Drupal community.

Sun has a table at DrupalCon, and we're getting a lot more people stopping by the table to talk to us than in previous conferences I've been at.  It's a great opportunity for us to learn what people want, and how (or whether) we can help.  Lots of people use MySQL, and they pretty much all seem to be aware that Sun purchased MySQL.  I was a bit surprised at how many people use VirtualBox, but not everybody knew that It's a Sun product.  (so we're telling them, and hearing how they use VBox).  General feedback I hear from visitors is that they are glad to see Sun showing support for the Drupal community and for open source in general.  I wouldn't say people are rushing to our table, but generally when we ask them questions, they happily stay and talk with us about what they're doing.

Here is what I'm learning so far about why Drupal is so successful: it is simple to extend, by design.  (built in PHP, you can get up-to-speed on how Drupal is built pretty quickly and the barriers to you contributing something new are reasonably low)  You don't have to contribute code to the core part of Drupal; you can create your own "module" to add new features, or you can contribute themes to help others' web sites look cool.  These are lower-risk ways of including the maximum number of people to add to Drupal, and they do.  Drupal really wants a lot of people to contribute, and they make it pretty easy to do it.

Also, Drupal is simple to get running; you can have a simple web site running in less than an hour, and you don't have to be a database administrator or a developer to do it.

There is a commercial entity formed by Drupal's founder, Dries Buytaert.  That commercial entity, called Acquia, contributes a lot to Drupal but they take steps not to try to assert too much control over Drupal.  In fact, of all the committers to the Drupal core, only one works at Acquia (Dries).

Time and time again I have heard from Drupal fans that they see Dries spending a lot of time and energy to make the community open and welcoming; getting people to contribute appears to be a cornerstone of Drupal's direction.  I've talked to a lot of people building web sites and asked them why they're at DrupalCon; many of them say they're looking for people to hire, and they use Drupal because it's easy to find developers who already know Drupal.  It's your classic developer play: Drupal succeeds in part because they have a larger developer base than competing open source CMSs like Joomla! or Wordpress.  I like this aspect because it shows the payoff of spending enormous energy in opening your community; the payoff is a huge ecosystem of features and add-ons, and an army of Drupal-trained workforce that makes it easy for customers to get somebody to build their websites in Drupal for a good price.

I installed Drupal on my OpenSolaris distro, running inside VBox on my MacBook Pro.  It took about 20 minutes from start to finish, including the time to download the software, unpack it, read the instructions, activate the WebStack components (MySQL, Apache), and configure the database for Drupal to get going.  If I were to do it again, it would take me about 10 minutes to get Drupal going, maybe 5.

Two main themes I'm hearing about what's important to work on for Drupal: simplicity, and performance.  Simplicity seems to be the much bigger issue, because Drupal is trying to expand its community by an order of magnitude.  They made it easy for PHP developers to contribute and build web sites, but they want to attract people who don't want to learn PHP.  Maybe these people know a little HTML, maybe a little CSS, but not PHP.  Drupal has to make things even simpler to create web sites with interesting content.  Anything to make it easier to install, configure, and run Drupal with a usable set of modules is a huge benefit to the Drupal community.

Performance seems to be not quiet as important, but still plenty worth talking about.  For smaller sites that don't get a lot of concurrent users hitting their web sites, performance of Drupal and the underlying software stack on a single server is plenty fine.  But when the web site starts to grow its audience, performance issues start to come into play, and I think there's a lot that Sun can do if we can show that we understand how to optimize performance on the whole software and hardware stack, from Drupal on down to the server.  I believe we can do that, and more: Sun has some interesting technology to make snapshots and test environments quick, easy, and reliable to do (ZFS comes into play here).  And we have a great tool for observing performance of Drupal sites live, in deployment (DTrace).  These are not for everybody -- I hear a lot of people saying they don't want to spend their time learning how to do detailed performance tuning, they'd rather spend their time getting web sites live -- but I think that people who see these tools at our BOF on Friday will see how these tools can be a real help.

One nice thing they're doing at the conference is the use of Twitter as a public address system: follow the twitter user "drupalcon" and you get updates about where lunch is being served, parties happening after hours, reporting on status of wi-fi downtime (mostly wireless access has been great, but when it goes down, the DrupalCon people tweet about it right away and ask people to tweet back saying where they find dead spots).  When slides get posted to web sites, it's announced on twitter.  Same with videos of the talks.  Somebody lost a phone; drupalcon tweeted a lost-and-found message.  It's a great use of Twitter.

I'll leave this entry with a quote from the opening keynote.  It was attributed to Clay Shirky, to represent the approach of the Drupal community: "Replace planning with coordination".  Simple example: going to lunch as a group.  Before cell phones, if you want to go to lunch as a group you have to talk about it before-hand and plan where you're going to go, because communication is complicated in a group.  With web-enabled cell phones, you can call, text, or tweet your mates in real time, coordinating what you're doing right then.  Interesting approach; I'd say it's a good summary of the open source way of doing things that I've seen in my own career working with open source.

More soon; the conference is a firehose, and I'm having a blast drinking from it.


Powered by ScribeFire.



About

The views expressed on this blog are my own and do not necessarily reflect the views of Oracle. What more do you need to know, really?

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today