Showing posts with label softwares. Show all posts
Showing posts with label softwares. Show all posts

Friday, March 7, 2008

Files, directories and database script comparison tool


There is one UI based tool available for Linux which can be used for Files, database script and directory comparison; its "Aqua Data Studio".
Download the Linux version from here.

It requires JDK/JRE 1.5 or above.

After downloading the tar file extract it some location and run the datastudio.sh file.

Friday, February 1, 2008

Solunas: The hotel management system

Solunas is a Hotel Booking Engine Software written in RoR.

There are 2 separate parts of the whole application.
a) Backend: Solunas server for the admin of the property.
Its features are:
Manage your Properties / Rooms,
Manage the very flexible price system - Minimum stay / weekday match / etc

b) Frontend:A component integrated on Joomla for the end users.
Its features are:
Show availability calendars
Cart function to add multiple bookings
Checkout

Installation( Applicable on Linux, tested on Fedora 7)
I am assuming your machine has MySQL, Apache, Ruby and Rails installed.

Download the solunas from sourceforge

Extract it some where like /home/sanjay

Create one blank database on mysql.

There is one sql file solunas.sql inside solunas/db folder, dump this file against the mysql database created for solunas.

Check your ruby version:

$ rails -v

Then change the environment.rb file (inside config folder)
RAILS_GEM_VERSION = '1.1.6'

Also change the database.yml file:
development:
adapter: mysql
database: solunas
username: db_user
password: db_pass
host: localhost

Start the webrick server.

$ cd /home/sanjay/solunas
$ ruby script/server

Point your browser at:
http://localhost:3000/
Login as user 'marc' and password 'isemann'
And start managing your hotel.
:)

Tuesday, November 27, 2007

A quick note on how to install Alfresco

1. Install (if not already there) jre/jdk1.5x (no jdk-1.4x)

2. Set JAVA_HOME environment variable
In the .bash_profile file of root add these line at the last
JAVA_HOME=/Path_Of_Jdk1.5
export JAVA_HOME

3. Create a dir 'alfresco' in /opt

$cd /opt
$ mkdir alfresco

4. Download this file 'alfresco-community-tomcat-2.0.0.tar.gz' from
sourceforge
http://sourceforge.net/project/showfiles.php?group_id=143373

5. Untar the tar file at /opt/alfresco
$ cd /opt/alfresco
$tar -xzf /Path/alfresco-community-tomcat-2.0.0.tar.gz

6. Create one mysql database
$ cd alfresco/extras/databases/mysql
$ mysql -u root -p < db_setup.sql

7. Remove 3 files (default for HSQL) from here

$ cd /opt/alfresco/tomcat/shared/classes/alfresco/extension

custom-db-and-data-context.xml
custom-db-connection.properties
custom-hibernate-dialect.properties

8. Start the tomcat server and run the alfresco
$cd /opt/alfresco
$ alfresco.sh start


9. Point browser at
http://localhost:8080/alfresco

10. Stop alfresco
$cd /opt/alfresco
$ alfresco.sh stop

Thursday, October 25, 2007

NetBeans IDE on Linux

The NetBeans IDE is a free, open-source Integrated Development Environment for software developers.
The NetBeans IDE provides developers with all the tools they need to create professional
cross-platform desktop, enterprise, web and mobile applications.

To install NetBeans IDE on Linux (Steps given here are performed on FC7):

It needs Java SDK-1.5.x so first install Java SDK-1.5.x and the JAVA_HOME in the environment variable in the .bash_profile file

# Download NetBeans IDE from here.

Downloaded file be like this: netbeans-x_x_x-linux.bin

# Make the file executable

$ chmod +x netbeans-x_x_x-linux.bin
Run this file
$ ./netbeans-x_x_x-linux.bin

It will open the Launcher, accept the License and click Next.
Select the Java version you want to use with the IDE, specify the path where you want to install the NetBeans IDE.

It will install all the files in the selected folder to run the NetBeans IDE cd to the bin directory and run the command:

$ ./netbeans

Thursday, September 27, 2007

RMagick installation on Fedoras

RMagick requires ImageMagick and ImageMagick-devel libraries.
Your distribution may include at least some of these libraries by default and probably provides pre-built packages for the others. If not, these are available as source code tarballs from http://www.imagemagick.org/pub/delegates/.

Or you can install these using the yum command:

$yum install ImageMagick

$yum install ImageMagick-devel

RMagick also needs Windows TureType font, download the rpm from here:

http://www.zacharywhitley.com/linux/rpms/fedora/core/6/i386/msttcorefonts-2.0-1.noarch.rpm

Install this:
$ rpm -ivh msttcorefonts-2.0-1.noarch.rpm

Make a symbolic link the font dir to the place rmagick expects them:

ln -s /usr/share/fonts/msttcorefonts /usr/share/fonts/default/TrueType

Some applications based on RMagick also requires freeimage header files.
Download freeimage from here
http://freeimage.sourceforge.net/download.html
Unzip the file and cd to the freeimage dir and run following commands

# make
# make install

Now install RMagic using the gem

$ gem install RMagick --include-dependencies

Wednesday, August 8, 2007

installing and running memcached

memcached is a general-purpose distributed memory caching system.
It is often used to speed up dynamic database-driven websites by caching data and objects in memory to reduce the amount the database needs to be read.

memcached is dependent on libevent library, so firstly download the source files for Libevent
from http://www.monkey.org/~provos/libevent/

Install libevent:

$ tar -xvf libevent-1.3c.tar.gz
$ cd libevent-1.3c
$ ./configure
$ make
$ make install

In Fedora the library (libevent-1.3c.so.1.0.3) will be installed at
/usr/local/lib
Create a link or copy this file to standard libarary location (/lib) of Fedora
$ cd /lib
$ ln -s /usr/local/lib/libevent-1.3c.so.1.0.3 libevent-1.3c.so.1

Download the latest memcached from http://www.danga.com/memcached/download.bml


$ tar -xzf memcached-1.2.2.tar.gz
$ cd memcached-1.2.2
$ ./configure
$ make
$ make install

Running:
$ memcached -h
(Will display various options)

To run as a deoman
$ memcached -d -u apache
Will start as daemon with default options Port(p): 11211 and Max memory (m) to use: 64MB

Tuesday, July 17, 2007

Installing and running Nagios

Download latest & stable nagios from here. Select the tarball
Download
Also download the plugins

Here these steps have been performed on Fedora 2 and Fedora5 using the nagios-2.9 and nagios-plugin-1.4.9.

Add one user nagios and one group nagcmd
$adduser nagios
(There is no need of assigning password to this user as this user is not going to login to the
system)
$groupadd nagcmd

Add user nagios and web server user apache to this group
(To know who is the owner of web server
$grep "^User" /etc/httpd/conf/httpd.conf
)

$usermod -G nagcmd nagios
$usermod -G nagcmd apache

$cd /usr/local/
Create one dir to hold all the nagios files
$ mkdir nagios
Change ownership of this dir to nagios
$chown -R nagios:nagios nagios

Untar the downloaded nagios tar file
$tar -xzf nagios-x.x.tar.gz

It will create one dir nagios-x.x inside the /usr/local
$cd nagios-x.x/

Configure the nagios and install
$./configure --prefix=/usr/local/nagios --with-cgiurl=/nagios/cgi-bin --with-htmurl=/nagios --with-nagios-user=nagios --with-nagios-group=nagios --with-command-group=nagcmd
$make all
$make install
$make install-init
$make install-commandmode
$make install-config

Installing Plugins
$ cd /usr/local

Untar the downloaded nagios plugin
$tar -xzf nagios-plugins-1.x.x.tar.gz
$cd nagios-plugins-1.x.x/

Configure the nagios plugin, and install plugins
$./configure --prefix=/usr/local/nagios

$make
$make install

Plugins will be installed at
/usr/local/nagios/libexec

Setup The Web Interface

Configure Aliases and Directory Options For The Web Interface
Add these line (at last) in the httpd.conf file (at /etc/httpd/conf dir)

ScriptAlias /nagios/cgi-bin /usr/local/nagios/sbin



Options ExecCGI
AllowOverride None
Order allow,deny
Allow from all
AuthName "Nagios Access"
AuthType Basic
AuthUserFile /usr/local/nagios/etc/htpasswd.users
Require valid-user


Alias /nagios /usr/local/nagios/share


Options None
AllowOverride None
Order allow,deny
Allow from all
AuthName "Nagios Access"
AuthType Basic
AuthUserFile /usr/local/nagios/etc/htpasswd.users
Require valid-user


Restart the webserver
$ /etc/init.d/httpd restart

Configure Web Authentication
$htpasswd -c /usr/local/nagios/etc/htpasswd.users nagiosadmin

(Enter the password)

Rename the config sample file
Nagios creates sample configurtion files at /usr/local/nagios/etc
Rename these files
$cd /usr/local/nagios/etc
$mv nagios.cfg-sample nagios.cfg
...and so on

Start nagios
$/etc/init.d/nagios start

After changing any config file check the main nagios.config
$ /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg

It will display any syntax error in any config file with file name and line number, rectify the errors and reload the nagios.

$/etc/init.d/nagios reload

Point your browser at:

http://localhost/nagios

It will ask for apache authentication, supply the user: nagiosadmin and password

Friday, June 29, 2007

add svn repository

1. add one svn user and group

$ useradd svn -c "SVN Owner" -s /bin/false
(-c comment, -s shell , here no shell access)

2. If we want more than one repository then add group for each one.

$ groupadd reposgp
$ usermod -G reposgp svn
(Add this group to svn user/group)

3. Create a Subversion repository

We are creating it at /var ; svn will be the folder containing all repos
$ install -v -m 0755 -o svn -g svn -d /var/svn
$ svnadmin create --fs-type fsfs /var/svn/repos

(Here 'repos' will be our repos)

Now we can import some files/dir to the repos

$ svn import -m "Initial import." /path/to/source/tree
file:///var/svn/repos


Now change owner and group information on the repository, and add
an unprivileged user to the svn and reposgp groups:

$ chown -R svn:odotgp /var/svn/repos
$ chmod -R g+w /var/svn/repos
$ chmod g+s /var/svn/repos/db
$ usermod -G svn,repsogp sanjay

(here sanjay is already a user in the system)

We can verify the existing groups of user with the commands

$ groups sanjay

Thursday, June 14, 2007

Setting a Crontab

Syntax:

* * * * * command

# Use the hash sign to prefix a comment
# +---------------- minute (0 - 59)
# | +------------- hour (0 - 23)
# | | +---------- day of month (1 - 31)
# | | | +------- month (1 - 12)
# | | | | +---- day of week (0 - 7) (Sunday=0 or 7)
# | | | | |
# * * * * * command to be executed


Crontab Example
_______

A line in crontab file like below removes the tmp files from /home/someuser/tmp each day at 6:30 PM.

30 18 * * * rm /home/someuser/tmp/*

Changing the parameter values as below will cause this command to run at different time schedule below :

min hour day/month month day/week Execution time
30 0 1 1,6,12 * -- 00:30 Hrs on 1st of Jan, June & Dec.

:

0 20 * 10 1-5 --8.00 PM every weekday (Mon-Fri) only in Oct.

:

0 0 1,10,15 * * -- midnight on 1st ,10th & 15th of month

:

5,10 0 10 * 1 -- At 12.05,12.10 every Monday & on 10th of every month
:

By default cron jobs sends a email to the user account executing the cronjob. If this is not needed put the following command At the end of the cron job line .

>/dev/null 2>&1

Wednesday, May 16, 2007

bugzilla installation on Fedora

Download latest stable Bugzilla from here
Untar the package at /var/www/html folder
$ tar -xzf bubzilla.x.x.tar.gz

Bugzilla's installation process is based on a script called checksetup.pl. The first thing it checks is whether you have appropriate versions of all the required Perl modules. The aim of this section is to pass this check. When it passes, proceed to Section 2.2.

To check you have the required modules, run:

bash# ./checksetup.pl --check-modules

checksetup.pl will print out a list of the required and optional Perl modules, together with the versions (if any) installed on your machine. The list of required modules is reasonably long; however, you may already have several of them installed

$ perl -MCPAN -e 'install ""'

Create one database in mysql with user/passord

Change the localcongif file of bugzilla (db related)

Run the
./checksetup.pl

Change the apache httpd.conf file add

AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
AllowOverride Limit


Restart the webserver
Point browser at
http://localhost/bugzilla

Whats new in Ajuby 0.5