GD Inst Generic
From giantdisc
General Installation Instructions for the GiantDisc Software
There are two possibilities where the GiantDisc server software can be installed. Either 1) in the home directory of an existing user (e.g. /home/music), or 2) anonymously (e.g. /opt/local/giantdisc). In the following instructions, installation option 1) will be assumed. Note that unless you are installing in a global directory such as /opt/local, none of the following steps require you to be logged in as root.
- Create a new user "music" and its home directory /home/music.
- Login as music and/or cd to the music home directory (if necessary).
- Copy the downloaded tarball GiantDisc_*.tar.gz to the music home directory (or somewhere else) and unpack it (tar -xvzf GiantDisc_*.tar.gz)
- cd to the unpacked directory GiantDisc_*. Execute the script Install.sh /home/music. It installs the server software in the directory /home/music, and creates directories 00, 01, 02, tmp, inbox, browse, PalmClient, bin and database and copies the server scripts, database files and the Palm client software into these directories. Previously installed versions are not overwritten but updated. Existing user data files or databases are not modified.
- Make sure you have the MySQL server installed and running. cd to ~music/database and create an empty database with the script make-db. The script will ask for your MySQL root password, press enter if you did not yet assign one.
- Create the database structure and initialize the genre, language, type and source tables by executing the script make-tables.
- Install the client software gd.prc and the file pnoJpegLib.prc on the Palm.
- Set the environment variable GIANTDISC_HOME to the installation directory (/home/music in our example) and make sure that PATH contains $GIANTDISC_HOME/bin. This can be done automatically with the commands cd path-to-installation-dir ; source gdsetenv.sh
- Establish Palm - Server communication. Start the server script gdd.pl as user music (use option --help to get a list of possible options). Make sure that gdd.pl is using the correct communication mode. The server options can also be specified in the configuration file ~music/.gdconfig. For the communication mode, you can choose between
- Either: Network TCP/IP - over WLan, Bluetooth, USB etc
- Make sure that a common TCP network connection is configured and can be established from the Palm to the server
- Start the server: gdd.pl --commmode 2
- Start the palm application, create a new connection of type TCP socket, enter the host name or IP address of your GiantDisc server and then connect.
- Or: Serial connection over comm port COM1
- Connect the Palm to the server with an RS-232 nullmodem cable (or use a normal cradle)
- Start the server: gdd.pl --commmode 1 --serialdevice /dev/ttyS0
- Start the palm application, create a new connection of type RS-232, choose the default baud rate 19200 and then connect.
- Either: Network TCP/IP - over WLan, Bluetooth, USB etc
- The Palm should then display the Search form, and the server should have printed some log data to the console ended by server listening...
- Before you can listen to music you have to record or check-in audio tracks. For information on this, see Importing Audio Tracks.
Upgrading the GiantDisc Software
If a previous version of GiantDisc is installed on your system, upgrading it is very simple.
- Copy the downloaded tarball GiantDisc_*.tar.gz to the music home directory (or somewhere else) and unpack it (tar -xvzf GiantDisc_*.tar.gz)
- cd to the unpacked directory GiantDisc_* and execute the script Install.sh. This copies the new or modified scripts and modules to the GiantDisc home directory ~music. User defined files are not modified.
- Important: Check the configuration file .gdconfig.newest-version for new or renamed options. The existing .gdconfig might have to be adapted manually.
- Re-start the server script gdd.pl.
- If the database structure has been extended, a warning appears that it should be upgraded by calling gdupdatedb.pl first. After updating the db, start gdd.pl again.
- Reload the client software to the Palm and start it. (In rare cases it might be necessary to delete the Palm client software in the Palm's memory manager to erase all local databases. This can be done without risk because the local databases are automatically reconstructed from the server's data when the client software is started on the Palm.)
Upgrading to Nightly Builds using Subversion
If you want to experiment with the latest and most exciting new additions to GiantDisc, you can easily upgrade an existing installation of GiantDisc to the latest version in the subversion repository. A word of warning: The code in the repository might not behave like you expect it and might require some hands-on configuration, with possibly very little documentation of new features available. In particular, you should not use this on your regular production system - at the very least you should always have a backup of your music files and your mysql database before playing around with the subversion code.
You can obtain a working copy of the latest development code (the "trunk") with the following commands (assuming the home directory of your installation is /home/music):
mkdir /home/music/svn/ cd /home/music/svn svn checkout https://giantdisc.svn.sourceforge.net/svnroot/giantdisc/trunk
The directory /home/music/svn/trunk will then contain all current code in various subdirectories, including various alternative clients (the whole trunk currently weighs in at about 25MB). If you only want to check out specific parts of the code, you could replace trunk in the above command by trunk/Server, trunk/PalmClient, trunk/Database or similar. You can browse the repository online at http://giantdisc.svn.sourceforge.net/viewvc/giantdisc/trunk/ to get an idea of the layout of the repository.
To use the new code on your server, it suffices in most cases to update the files in the directories bin and database, and to install the latest Palm client on your Palm device. This is easiest done by setting symbolic links to the trunk directories (again assuming your installation directory is /home/music):
rm -rf /home/music/bin ln -s /home/music/svn/trunk/Server /home/music/bin rm -rf /home/music/PalmClient ln -s /home/music/svn/trunk/PalmClient /home/music/PalmClient mv /home/music/database /home/music/database.old ln -s /home/music/svn/trunk/Database /home/music/database cp /home/music/database.old/*.txt /home/music/database rm -rf /home/music/database.old
You can then at any time upgrade to the latest version with:
cd /home/music/svn/trunk svn update
and use the following command to read short descriptions of the latest changes:
svn log | less
You should also have a look in trunk/misc/ChangeLog,in particular with respect to possible changes in trunk/misc/.gdconfig.Don't forget to restart the GiantDisc server process gdd.pl after an update, and to upload the latest version of PalmClient/gd.prc to your Palm pilot.
If you want to stay up-to-date on changes as they are commited to the svn repository, you should consider subscribing to the svn-commit mailinglist.
Please refer to the subversion documentation for more information on how to use the subversion client.
