Welcome to Geeklog, Anonymous Thursday, March 28 2024 @ 08:41 pm EDT

Installing Geeklog

TABLE OF CONTENTS

New Installation Upgrading To New Version Common Problems
Glossary
  • path: A physical location on a server that describes where files and directories are. On Windows paths begin with the drive letter (c:/inetpub/wwwroot/), on *nix paths start at root (/) like (/var/www/)
  • url: Uniform Resource Locator, the address of a specific piece of information on the web (http://www.foo.com/)

PRE-INSTALLATION CHECKLIST (new installation)

Before installing Geeklog for the first time, please make sure you have or know the following:

  1. A web server running PHP 4.04 or higher
  2. A web server running MySQL, with access to a database or the ability to create a database
  3. The ability to create a new database in MySQL or access to an existing one
  4. A telnet or SSH connection to your web server (although FTP will work). This document will be written assuming you have command line access to your server, but we will note the major differences for FTP users.
  5. The ability to unpack a tarball (file ending in tar.gz)
  6. You know the difference between a path and a URL
  7. You know how to determine your system paths

    SPECIAL NOTE ABOUT PARSE ERRORS:

    Some users have reported that WinZip corrupts certain files in the Geeklog tarball during decompression which will cause errors during the installation process. You are strongly urged not to use WinZip. Try WinRAR if you must decompress the file locally, or better yet, unpack the file from your server (requires telnet/SSH access).

    Parse errors can also be caused by using a WYSIWYG editor on lib-common.php, e.g. Dreamweaver - you should use a "plain text editor".






INSTALLATION INSTRUCTIONS (new installation)

The installation process for 1.3.5 has changed. Please read this section COMPLETELY before beginning.

  1. Unpack the tarball *within* your web tree by running the following in your shell (this assumes you have ssh access and that you are working with the tarball on the designated server - this can be locally or hosted elsewhere):

    tar -zxvf geeklog-1.3.5sr1.tar.gz

    FTP, Windows Users: unpack the tarball on your local computer and upload the result to your designated server. Everything uploads as ASCII except the images.

  2. For *nix installations the following may be required:

    chown -R webuser:webuser /path/to/geeklog

    This guarantees that everything in that path belongs to you, typical settings are www:www or nobody:nobody and more often than not doesn't matter.

  3. For *nix installations cd into /path/to/geeklog and do the following:

    chmod -R 775 logs/
    chmod -R 775 public_html/backend/
    chmod -R 775 public_html/images/articles
    chmod -R 775 public_html/images/userphotos


    FTP Users: If you're doing the chmod via a FTP client, you must also apply the chmod to the files in logs/ and public_html/backend as well as the directories themselves. Most, if not all, ftp clients do not perform this command recursively. That means you need to set each file within each of these directories manually.

    SPECIAL NOTE:

    Not following step #3 correctly is the #1 reason why people receive errors when they first try to use Geeklog. Take your time and get it right. Also, some users have reported problems if the above permissions are not set to 777. Try 775 first and only be more permissive if you receive an error message.


  4. Create the database you want Geeklog to reside in. If you are not familiar with using MySQL, you are urged to get phpMyAdmin and use it to create a new database. If you have no idea what the previous two sentences mean, contact your sysadmin for help.

  5. Edit config.php with the appropriate settings for your server. For installation, this basically means "set your paths," as all other variables can be changed after a successful installation. The config.php file contains comments to help you out. Windows users, you should be able to use the Unix '/' in your paths without any problems. Otherwise, you will need to use the doubled Windows slashes '\\'.

    NOTE FOR RETURNING USERS OF GEEKLOG:

    Please note that the database settings are back in config.php. This is to make it so that you do not have to edit lib-database.php


  6. Edit lib-common.php and change the require_once() at the top to point to the location of your config.php file.

  7. Open your browser and navigate to http://yourgeeklogdomain/admin/install/install.php and follow the directions!

    SPECIAL NOTE:

    Some users may get the following error message during install:

    "1121: Column 'ug_grp_id' is used with UNIQUE or INDEX but is not defined as NOT NULL"

    This error is caused by having a slightly out of date version of MySQL. There are two easy ways to fix the problem:

    Solution #1 = Get your ISP to upgrade MySQL or do it yourself.

    Solution #2 = Edit the file sql/mysql_tableanddata.php and remove lines 176 and 375. They read:

    INDEX group_assignments_ug_grp_id(ug_grp_id),

    and

    INDEX stories_tid(tid),

    Make sure you remove the entire line, including the comma. Once those lines are removed, you need to drop all the tables that were created by the installation script and re-run the installation script.


  8. Once you see the success message, you are ready to go. You can now delete the admin/install directory (and all files within it). Please remember to change the default passwords on all administrator accounts right away.





PRE-UPGRADE CHECKLIST (upgrade)

WARNING:

Take extreme care to back up any files from your current Geeklog installation that have any custom code in them, especially lib-custom.php (where all custom code should reside). Be sure to back up any modified themes, images, and static pages from your current installation.

Also, please be sure to back up your database. We can't stress the importance of backing up your files and database enough.

YOU HAVE BEEN WARNED.






UPGRADE INSTRUCTIONS (upgrade)
  1. Upgrading is no different than a fresh installation except your database already exists and needs to be upgraded.
  1. Back up any files with custom code in them and back up your database.

    SPECIAL NOTE:

    Please pay special attention to the older config.php and lib-common.php files, these files contain database and path information you entered the last time you installed Geeklog and they MUST be copied over to the NEW config.php and lib-common.php files.


  2. You can choose to either rename or remove your current Geeklog directory. Although in the end you will be deleting the older install it's probably safer to keep the old copy around for a few days *just* in-case you forgot to transfer some files.

  3. Uncompress the new version and copy the result to the same path that your old installation had. For instance, if your old Geeklog was in /usr/home/www/geeklog/, then your new installation should also be in /usr/home/www/geeklog/.

  4. The next step depends on which version of Geeklog you are upgrading from.

    If you are upgrading from Geeklog 1.2 or earlier, change to /path/to/geeklog/sql/updates and apply all needed database updates. For example, if you are upgrading from Geeklog 1.1, you will need to apply 1.1_to_1.2.sql and 1.2_to_1.2.2.sql which will upgrade your database to Geeklog 1.2.5-1. I say 1.2.5-1 because there were no database changes from 1.2.2 to 1.2.5-1 (e.g. a 1.2.2 database is the same as a 1.2.5-1 database). If you are uncomfortable using the MySQL command line to do this, you can do it via phpMyAdmin as well.

    If you are upgrading from 1.2.5-1 or a more recent version, the second step of the installation script should have an option to convert your database to the current version.

  5. The rest of the upgrade process is identical to the install process. Once you successfully run the install script, you should be ready to go after restoring any files with custom code.




INSTALLATION PROBLEMS (common problems)

SPECIAL NOTE:

Before you go any further, please open config.php AND DOUBLE CHECK YOUR PATHS. Bad paths, or typos in the paths will cause all sorts of errors in Geeklog.



I get the following error message after step two of the install script:

"1121: Column 'ug_grp_id' is used with UNIQUE or INDEX but is not defined as NOT NULL"

Answer:

This error is caused by having a slightly out of date version of MySQL. There are two easy ways to fix the problem:

Solution #1 = Get your ISP to upgrade MySQL or do it yourself.
Solution #2 = Edit the file sql/mysql_tableanddata.php and remove lines 176 and 375. They read:

INDEX group_assignments_ug_grp_id(ug_grp_id),

and

INDEX stories_tid(tid),

Make sure you remove the entire line, including the comma. Once those lines are removed, you need to drop all the tables that were created by the installation script and re-run the installation script.



I can't get past the first page of the install script. It keeps reloading itself after I click the button.

Answer:

Geeklog needs the register_globals variable turned on in order to work. Since PHP 4.2.0, the default for register_globals is "off". To fix it, simply add the following line to your php.ini file:

register_globals=on

If you cannot find your php.ini file, ask your sysadmin.



During installation, I get the following errors:

"Parse error: parse error in ../../lib-common.php on line 2231 "

"Fatal error: Cannot instantiate non-existent class: template in ../../lib-common.php on line 335 "

Answer:

You have most likely used WinZip to decompress the Geeklog files. As noted at the top of this document, WinZip sometimes corrupts stuff and these errors are the results. You need to find a different way to decompress the tarball and get the files loaded onto your system







POST-INSTALL PROBLEMS (common problems)

Whenever I try to do anything on my site, I get a whole list of errors like:

Warning: fopen()...
Warning: fputs()...
Warning: fputs()...
Warning: fputs()...
Warning: fclose()...

Answer:

Make sure that the logs/ directory AND the files in it have permissions of at least 775. You may need to make the permissions 777 if 775 isn't working for you. For good measure, make sure the public_html/backend directory and the geeklog.rdf file have the same 775 or 777 permissions



Whenever someone tries to log in or out, the following error is produced:

Cannot add header information - headers already sent by (output started at /usr###/home//public_html/geeklog/config.php:589) in /usr###/home//public_html/geeklog/system/lib-sessions.php on line 133

Answer:

Make sure that the logs/ directory AND the files in it have permissions of at least 775. You may need to make the permissions 777 if 775 isn't working for you. For good measure, make sure the public_html/backend directory and the geeklog.rdf file have the same 775 or 777 permissions.




If you still have problems, please do one or more of the following:

1) Go to http://geeklog.sourceforge.net and check out the Support section. The Support section includes a FAQ and a search system.

2) Visit the mailing list archives at http://sourceforge.net/mail/?group_id=7371 . You can also subscribe to the mailing list and post your question to the Geeklog community

3) Try the chat room at irc.openprojects.net, channel #geeklog. Please have all your path information in config.php and lib-common.php readily available.

4) Try entering the text of the error message on Google. Chances are you will find someone else who had the same problem and fixed it. And sometimes searching for a specific error will cause Google to bring up broken pages that have the same error.



Extended version of this document created by Jason C. Levine,
layout by Simon Lord, reviewed by Dirk Haun and Jeffrey Schoolcraft.

Last Updated: Tuesday, September 10 2002 @ 03:09 pm EDT| Hits: 11,190 View Printable Version