Blogging Tools: Wos Server – a useful tool in your armoury

Ages ago, I wrote about how you could put your applications on a stick. For the inveterate blogger, tinkerer, and under-the-hood kind of guy/girl, you can also put a blog on a stick with WordPress, and (almost) everything you need. The only caveat: the blog is not (nor should be) live for security reasons.

investorblogger - in a box

Look closely at the browser bar. This is InvestorBlogger on my stick! I’ve managed to import all the posts, plugins and themes. Now I can carry my blog, and work anywhere my computer and cruzer can take me!

Wos server is an installable application that you can put on your stick or anywhere. It includes a full version of apache for serving pages, PHP for parsing code, and MYSQL for your database. You can download and configure your own version of the server yourself at the website. There are a wide variety of apps that you can install, of course, bloggers can choose WordPress! But here’s a selection of other packages you could try!

  1. DBHcms
  2. Drupal
  3. Joomla
  4. MediaWiki
  5. Moodle
  6. OpenDB
  7. Textpattern
  8. WordPress

You can visit their site, or download my own customized version with themes, and plugins to get you started. The WordPress user is admin and the password is password.

Additional steps to setting up your blog on a stick or desktop.

  • Step 0: Copy your files/themes/plugins to your desktop and anything else you want to use in your install in the wp-content folder at your site…
  • Step 1: Download the file and unzip it on your desktop.
  • Step 2: Open the folder and find the file mowes.exe. Hit that and open it. Wait a few seconds.
  • Step 3: Your browser window will open. Look for the entry ‘wordpress’ and click on that link. (or type http://127.0.0.0/wordpress/ or http://localhost/wordpress/)
  • Step 4: You will see a mini-version of a blog… with themes and plugins.
  • Step 5: Customize your blog by copying the files/themes/plugins you use from your site to the same location in the wosserver (ie. wos server/www/wordpress directory).

Login details are on the folder in step 2. This is not a real blog, just a mini-blog. You can play with it all you want. Break it, too. Your real blog will be safe and carry on regardless. Some plugins may not work because they require additional features, or are not necessary at all (spam plugins, for example). If you want to import your database, you could do that, too. But you will need a plugin that allows you to import your db into the wosserver: wp-phpadmin plugin might work.

Have fun blogging, but don’t worry about borking your blog!

Update: I’ve had a weird issue with this software. If you download and expand the files to your desktop area, and run from there. It seems to work. Otherwise it won’t run properly if you put the files elsewhere. Apache seems to be  hurdle but I’m not sure about this. This is a pity: if you are like me, and you use your stick on a number of machines, the server may not run properly. Another possible workaround would be to set the drive for your USB stick to the same drive on all your machines. That might work. I’ll let you know.  The obvious solution: download the entire original file from the kind people at Wos.

Who put that spoke in my server? Or how to bring a server to its knees!

The last few months since getting my own private hosting have been quite challenging in a number of ways as I have had to adapt my handling of my sites to a number of new contingencies: including weird spikes in server activity. It’s been quite a learning experience, but I’m pretty sure I don’t want to go back to regular shared hosting! I love having my own server on Dreamhost…

——-
For more articles on running a business, making money, cutting debt, or creating your blog, subscribe to the RSS feed or email newsletter. There’s a lot more in the Random Walk to Wealth on InvestorBlogger dot com. Subscribe TODAY!
——-

This graph is taken from December 5th and shows four significant spikes in server traffic in the previous 24 hours, with the spike around 00:00 being the largest and also bringing the server down!

4-10am-5th-09h december

Dreamhost helpdesk have VERY helpful to me over the years, and patiently answered almost every query fully and in detail. The last few times though have been frustrating because the amount of activity has been quite high on occasion (without obvious justification either!), and they were suggesting that perhaps I should raise the allocation of resources (and the cost!) to cover the spikes! Now, I’d already tried this once or twice: having raised my basis from $15.00 to $20.00 to $30.00. While this did indeed improve my server responsiveness, I was still getting server outages every day about once or twice a day, and it just didn’t seem that my server traffic justified that!

What is a poor server to do?

Go on a bug hunt! It’s that simple. I decided to find out what was going on, and see if I couldn’t eliminate all the other possibililties before increasing the expense further…!

Step 1. Find the Crap…

I was amazed how much crap had built up on my servers over the three years I’ve been using Dreamhost hosting… It was actually quite shocking. And it took me days to clear. But first I took stock of the files and data that were on my server: html files, jpegs, mp3s (not many), php, applications, data, backups, gzips, etc… Once I determined which domains and subdomains were only serving files, I could eliminate those pretty easily. Then I went on a hunt for old PHP applications, principally old versions of WordPress, Galleries, etc..

Step 2. Three Choices: Choose NOW!

On finding an application, I was faced with three choices: upgrade the software to the current version; remove the software entirely; or password the entire directory. In most cases, I chose the second option to cut down on the security risk. On one or two occasions, I passworded entire subdomains (with .htaccess and .htpasswd files) as well to provide access to these applications only to the person concerned. In the cases of my primary websites, upgrading became mandatory. In rare occasions, I moved applications to the root directory as a stop gap measure.

From now on, though, I’m going to be much stricter on removing old applications because of the potential security problems that can be hidden by forgotten software.

Step 3. Deleting unnecessary plugins and themes

Since most of my blogs run versions of WordPress 2.2+ and I usually auto-install or auto-update the files (courtesy of Dreamhost’s great service), the process is quite quick and painless. Dreamhost have gotten it down to a fine art, such that upgrading involves backing up the Database, Turning off the plugins (one click), click update, and wait for confirmation. But each and every time I update Dreamhost creates a backup of the original files named domain.old, and throws in EVERY theme they can get their hands on with each install). This leads to a lot of stuff each time. So I usually now delete 95% of the themes, and maintain a lean installation with as few plugins as possible (and none spare). This helps make WP as responsive as possible.

But as you can see I was still getting server spikes, and my options were running out. Everything was eliminated in one way or another, and the server was still coming down. So what next?

Step 4. Is it time to ‘log’ out?

I compared the performance of my main blog with several other blogs by checking the error.logs (I had never checked these before) just to see what was going on. Surprisingly, I found the logs quite detailed (they’re in your FTP folder called ‘logs’… click through to your domain to find the logs and then look for the error logs. They were dated a couple of days back so I had to check through and this is what I saw:

errorlogs

That’s right, line after line of the same error: this read “(12)Cannot allocate memory: couldn’t spawn child process: /dh/cgi-system/php5.cgi” and “(12)Cannot allocate memory: couldn’t create child process: …” To make sure that I wasn’t just reading regular errors, I queried it on Google and got nothing, then I checked the logs of WordPress Sites that I had just started with no themes or plugins. Sure enough, everything looked fine. Then I remember something a Dreamhost engineer had said:

Just the other day, I was dealing with a fellow who had a wordpress blog who was almost instantly crashing his PS with a single hit, because he had some wonky wordpress plugin which was spawning hundreds of php.cgi processes. Jeff

Well, thanks, Jeff. That has proved to be the best advice I’ve received yet… So I’ve been testing different plugins to find out which one or ones have been causing the problems. The best way to do this is to simply turn off all the plugins to restore the neutral state and then turn them on singly and checking the error log to eliminate those that don’t create the problem. I think I have a culprit already, but I’m now double checking them to make sure that I don’t blame the wrong plugin. Think ‘sticky’…

While the testing goes on, please excuse me for having unstable features on my blog as I try to eliminate the problem. But as you know, this problem has been going on for months; and this represents my best hope to get to the root of the problem.

Have you had these problems? What happened? I am not particularly an expert, but I was surprised at how much I could figure out by myself!

Box.net: The whole world’s a widget away!

Vista has ’em, Opera has ’em, Mac has ’em, even Google has ’em! Now your blog can have ’em, too. It’s a widget, and Box.net Widget is offering a neat way to manage your downloads: you simply upload them to their server, then create a widget. Place the widget in a suitable place in your blog, a sidebar, or post, or in the theme itself. Voila! Your downloads are a click away. No more messing with FTP!

With music files, you simply click and they will play within their own little player. Images simply load! i haven’t tried movies yet! My files are too big to upload! Hosting of your files is upto 1GB for free, with unlimited bandwidth. That’s not a bad deal.


Get your own Box.net widget and share anywhere!

This post is sponsored by Box.net Widget.