The Crucial Blog - Archive
March 31, 2008
1. Backup all the relevant wordpress files.
mv blog blog.bkp
2. Backup your MySQL database
mysqldump crucialu_blog > crucialu_blog.sql
3. Upgrade necessary plugins and once done, login to WordPress as admin and deactivate all plugins.
Dashboard ->> Plugins ->> Deactivate All Plugins
4. Download the latest wordpress.
5. Untar the file and rename it to /blog
mv wordpress blog
6. Copy the wp-config.php from the backup
cp -p blog.bkp/wp-config.php blog/
7. Take the URL http://www.crucial.com.au/blog/wp-admin/upgrade.php and Click on “Upgrade WordPress”
Click on “Continue” to complete the upgrade.
8. Copy the custom files /folder from backup to the new installation folder
cp -rpf blog.bkp/wp-content/* blog/wp-content/
9. Login to wordpress as admin and Activate the required plugins.
Dashboard ->> Plugins
After upgrade, if you are getting a blank screen while accessing the site, you might have forgotten to copy the themes and templates. Go to step 8 in that case.Tags: wordpress
Filed under: Uncategorized by — aaron @ 11:40 pm
March 31, 2008
If you are using the pvcreate command something like this:
And it gives an error like this:
Device /dev/sda4 not found (or ignored by filtering).
This can sometimes be resolved by rebooting the server (if the LVM partition was just created, and the server has not yet been rebooted).Tags: server-administration, servers
Filed under: Uncategorized by — aaron @ 6:38 pm
March 27, 2008
A number of clients have approached us asking how to get their Ruby on Rails application running on cPanel, so we wrote a tutorial to help alleviate some of doubt:
After starting the application, you can access it using the URL : http://domainname/app_name/public/
Each application will be using a port above 12000(>12000). The application will be automatically assigned a port when we are creating the application from cpanel.
Note : If we are creating the application under public_html directory, the application’s source code and configuration files can be viewed by anyone on the web. So, to avoid this you have two options:
You can create the application in the home directory (/home/username) and then use the rewrite option in cpanel(Cpanel >> Ruby On Rails >> Create A Rewrite). On the right hand side of each application, click the link “Create Rewrite” and save the required rewrite rule. For example: if you want to redirect the main domain to your rails application port, say http://domainname:12002, Select the main domain in “Domain & URL to be redirected to rails app” section and click save. Similarly, you can redirect a subdomain to the rails application by selecting the corresponding subdomains from the list(Domain & URL to be redirected to rails app). But before that you should create that particular subdomain in cPanel.
Each user can run 4 rails applications at a time.
Simple test application :
When you access the URL http://domainname:port, the default ruby welcome page will be displayed. If you want to see the application on the main page, set the corresponding route in the configuration file routes.rb.
For example: In the above test application example, to display the welcome page of our home controller, instead of rails welcome page, uncomment and change the following line in routes.rb (home/username/public_html/example/config/routes.rb).
Move the default rails welcome index file “/home/username/public_html/example/public/index.html” to another name(index.html.bak) or you can remove the file.
Creating a simple database application :
Rails strongly recommends the following:
Rails Environments :
Cpanel uses Mongrel webserver for rails applications.
Starting mongrel :
NOTE: Thanks to Anusha for this great article!Tags: cpanel, ruby-on-rails
Filed under: Uncategorized by — aaron @ 6:28 pm
March 25, 2008
Gallery Upgrade Error: Some files and or directories in your storage directory are not writeable by the webserver user
While upgrading gallery, you may come across with the following error while doing Step 2: System Checks
Even if you change the permissions / ownerships for g2data, you will get the same error.
This occurs when the versions.dat file is missing in the storage folder (g2data folder). You can create one by entering the following:
The second line is not significant. But you should enter the first line correctly. It must be the version of the g2 core module installed in the current gallery installation. You can get the version by executing this query in the MySQL database used by gallery.
The output will be something like this:
Once you create the versions.dat file, run the upgrade/index.php and run “System Checks”.Tags: gallery, security
Filed under: Uncategorized by — aaron @ 12:08 am
March 19, 2008
HyperVM: VM creation has failed. Reason: Could not download __path_program_ or no_template_and_could_not_download 
Tags: hypervm, server-administration, vds, virtual dedicated servers, xen
Filed under: Uncategorized by — aaron @ 10:12 pm
March 18, 2008
When you receive the following error:
This error can occur when installing via a USB CD-ROM drive, or if you have a USB hard drive. The solution to this is to unplug them, and install without using that device.Tags: freebsd, server-administration
Filed under: Uncategorized by — aaron @ 1:56 am
March 16, 2008
Sometimes, spamd child process for a particular user can cause high server load. This is a bug with spamassassin and is reported here:
To fix the issue, apply the patch mentioned in the bug.
Filed under: Uncategorized by — aaron @ 2:59 pm
March 13, 2008
If you are wanting to access 3Ware RAID cards (which are great btw!), either the 8006-2LP you can use the tw_cli utility, which you can download from the 3ware website. This is a great way to manage most aspects of the RAID card while your system is running, such as rebuilding an array, detecting failed drives, etc.
More info can be found here: https://twiki.cern.ch/twiki/bin/view/FIOgroup/Tw_cliTags: hardware, raid, system administration
Filed under: Uncategorized by — aaron @ 5:20 pm
March 13, 2008
MySQL error: supplied argument is not a valid MySQL result resource in /home/user/public_html/somepage.php
- mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/user/public_html/somepage.php
Most of the time, this happens because the database user doesn’t have enough permissions on the concerned database. When you check the permissions, even if shows all right, please grant the permissions once again. This should fix itNo tags for this post.
Filed under: Uncategorized by — aaron @ 1:35 am
March 13, 2008
Error: uninitialized constant Gem::GemRunner (NameError)
When: Installing Ruby on Rails gem on cPanel
1. Open the file
2. Simply add the line to that file
3. Save and exitTags: cpanel, ruby-on-rails, system administration
Filed under: Uncategorized by — aaron @ 1:34 am
xen joomla yum ssh windows 2008 server microsoft raid mail cpanel server-administration webmin apache php system administration ruby-on-rails gentoo vps networking exchange XenServer security cisco virtualization firewall hypervm subversion lxadmin wordpress ubuntu debian windows fantastico esxi fedora storage vmware windows server centos linux control panels virtual dedicated servers servers centos5 lxlabs vds
© Copyright 2003-2008
ABN 97 125 618 662