Issues with ImageMagick/Mod_perl/Html::mason

February 11th, 2010

Today, i was working with a web-based mod_perl application running on an old rhel 2.1 (panama) server, with apache v1.3.33 and mod_perl v1.29.

The applctn had an option to upload images for the products displayed on the site. But the app lacked image resizing functionality. Some of the users had uploaded huge images and that went beyond the site borders. I was about to integrate the resizing function using perl’s Image::Magick module. Existing module was out-dated, so i went for an upgrade. Obviously, it was not a quick and easy upgrade.

For the code snip

$image = Image::Magick->new;
$x = $image->Read($imgname);
if($x eq '')
{
$image->Resize( geometry => '800x800' );
$image->Write($imgname);
}

The first error i met was

Can’t load ‘/usr/lib/perl5/site_perl/5.6.1/i386-linux/auto/Image/Magick/Magick.so’

i ran ldd command on Magick.so, and libMagick.so link was found broken

ldd /usr/lib/perl5/site_perl/5.6.1/i386-linux/auto/Image/Magick/Magick.so
libMagick.so.6 => not found

So downloaded ImageMagick-6.2.3-6.tar.gz and reinstalled ImageMagick.

For a successful compile, i had to comment the following lines in /usr/src/ImageMagick-6.2.3/magick/annotate.c

//      if (LocaleCompare(encoding,"Latin-1") == 0)
//        encoding_type=ft_encoding_latin_1;

because ( i guess ) the machine lacked that font.
After that, the app threw another error
Wrong JPEG library version: library is 62, caller expects 70

This was fixed by relinking libjpeg.so.62 to libjpeg.so.7.0.0. I know its dirty, but that did the trick.

Hope, mod_perl/mason players will find this useful.

VN:F [1.9.1_1087]
Rating: 5.5/10 (2 votes cast)
VN:F [1.9.1_1087]
Rating: 0 (from 0 votes)

Shameem Khalid linux , ,

Install chrome on Linux

January 19th, 2010

Guys,

You wanna try out chrome ? Please follow these simple steps and you will have your chrome ready to take off..

You should login as root and execute the following steps


cd /usr/local/
wget http://sparksupport.com/downloads/chrome.tar.gz
tar -zxf chrome.tar.gz
rm -f chrome.tar.gz
ln -s /usr/local/chrome/chrome-wrapper /usr/bin/chrome

Press Alt + F2, enter chrome. N’joy :-)

VN:F [1.9.1_1087]
Rating: 8.3/10 (6 votes cast)
VN:F [1.9.1_1087]
Rating: 0 (from 0 votes)

Sai Kottuvally linux , ,

Hiring 3 – 5 yrs experienced MBA Marketing Candidates ( BDM)

January 13th, 2010

Business Development Manager:

We require experienced Business Development Manager for our Marketing Department for developing our clients overseas. Our top management team represents a skill set , which is mutually exclusive but collectively exhaustive.

Common requirements:

  • proactive attitude
  • consistent academic record
  • MBA ( Marketing)
  • should be a self starter and must be willing to work on complicated tasks.

Selection procedure:

  • Presentation on any topic given on the spot.
  • Final direct interview.

How to apply:

Send your resumes to careers at sparksupport.com with the Subject Line: Experienced BDM and a covering letter mentioning the reason for leaving the current job, when you can join our
organization and details of the current salary.

The openings are immediate and the candidates should be ready to join ASAP.

VN:F [1.9.1_1087]
Rating: 7.3/10 (4 votes cast)
VN:F [1.9.1_1087]
Rating: +3 (from 5 votes)

Nisha Ajil Recruitment

Hiring Experienced MBA marketing candidates (BDO)

January 13th, 2010

Business Development Officers:

We are now hiring Experienced MBA marketing candidates for our marketing department into our new project of social media marketing making use of the cutting edge technologies. Social media marketing has tremendous growth opportunities in the field of Marketing and one can attain a promising and secured future here . Experience working in media field will be plus.

Common requirements:

  • proactive attitude
  • consistent academic record
  • MBA ( marketing)
  • should be a self starter and must be willing to work on complicated tasks.
  • winning instincts with good convincing skills

Selection procedure:

  • Written English Test
  • Presentation on any topic given on the spot.
  • Final Round of direct interview.

terms:

  • 6 months probation period
  • flat hierarchy
  • ample opportunities to grow
  • opportunity to grow with a growing start up organization

How to apply:

Send your resumes to careers at sparksupport.com with a Subject Line: MBA Experienced and a covering letter mentioning the reason for leaving the current job, when you can join our

organization and details of the current salary.

The openings are immediate.

VN:F [1.9.1_1087]
Rating: 7.8/10 (4 votes cast)
VN:F [1.9.1_1087]
Rating: +2 (from 2 votes)

Nisha Ajil Recruitment

Hiring experienced PHP Developers

January 13th, 2010

Developers:

We are looking for 1 – 3  Experienced PHP developers.

PHP developer requirements:

The candidates must have hands on experience in  PHP, HTML, CSS ,MySQL or PostgreSQL (LAMP stack) and should have minimum 1 year experience. Knowledge of Perl/Bash scripting will be an added advantage. So is the familiarity with Joomla, wordpress etc.

Common requirements:

  • proactive attitude
  • consistent academic record
  • BTech – ( CSE, ECE, IT, EEE ) / MCA
  • should be a self starter and must be willing to work on complicated tasks.
  • familiarity with software development process and QA

optional requirements:

  • RHCE / CCNA / MCSE
  • experience with any content managers like Joomla, Drupal or wordpress
  • familiarity with various FOSS development tools

selection procedure:

  • Technical Interview
  • Practical test where you will be given a programing task

terms:

  • 6 months probation period
  • flat hierarchy
  • ample opportunities to grow
  • opportunity to grow with a growing start up organization.

How to apply:

Send your resumes to careers at sparksupport.com with the subject line : PHP Experienced and a covering letter mentioning the reason for leaving the current job, when you can join our
organization and details of the current salary.

The openings are immediate .

VN:F [1.9.1_1087]
Rating: 8.3/10 (10 votes cast)
VN:F [1.9.1_1087]
Rating: +3 (from 3 votes)

Nisha Ajil Recruitment

How to transfer / migrate Cpanel accounts

January 11th, 2010

There are four important steps we should follow when it comes to the transfer of cPanel accounts among different server.

Below a simple and brief description is given on how to perform the migration.

Steps to transfer cPanel accounts

  1. Change the $TTL of the zone in old server
  2. Transfer the accounts.
  3. Update the nameservers.
  4. Change the A record of the zone file in old server

1. Change the $TTL of the zone in old server

Before one week of the scheduled transfer, all the $TTL values in the zone file must be changed to a smaller value between 30 minutes to 1 hour. This will take some time to propogate  to various ISPs around the world. The change in $TTL value ensures that the fresh zone files are loaded all around the world faster and that they access the old server for a shorter duration.

2. Transfer the accounts

Transfer the account using whm. If the size of the account is more than of 300 mb then move the folder which is of larger size to another directory outside that account. Then create a symbolic link for that folder in the original directory. After the transfer of the account using whm, scp the moved folder to the new server.

Also rsync the following directories between the two servers.

  1. /var/cpanel
  2. /usr/local/cpanel

3. Update the nameserver

Change the ip address of the child nameserver at the domain registrar. There will be a propogation delay of almost 48 hours.

4. Change the A record of the zone file in old server

For the time of propogation delay the domain keeps resoling to old server.  To make it resolve to new server, change the A record in the zone files of the old server.

VN:F [1.9.1_1087]
Rating: 7.0/10 (3 votes cast)
VN:F [1.9.1_1087]
Rating: +1 (from 1 vote)

Mobin Skariya linux ,

How to develop troubleshooting skills and become a good server admin

January 7th, 2010

10 points to increase troubleshooting skills and become a good Server Admin

1) Be clear with the concepts

You will be learning lot of things in random in your day-to-day work, but essentially what you need to remember are the basic concepts of each technology you have come across, starting from basic commands, services associated, the applications related, tools etc. Before you enter the system admin scenario, join the popular discussion boards, mailing lists relating to your domain. Believe me, a lot of quick tips can be gathered just by reading what others in the business have to say.

2) Build your knowledgebase

Its always good habit to write down somewhere whatever you have learned new in your days work. It would definitely come in handy in the future, cos you might have got it after rigorous research and you need not do it a second time. My notes that I always keep have saved me plenty of time for many of the issues that creep up. Also be willing to ask your peers or seniors or in the forums when you find yourself stuck, cos experience is one thing you can never garner in a little time. Remember, you can revert the favor when they look for you.

3) Try to relate with the technologies

In my early days I have wasted plenty of hours trying to find a fix without understanding the cause, but that has changed. You have to keep in mind that there will be some relation with services or applications you are working with. So if something not working it might be that of some other service that is related to it. Knowing which is causing the problem is the measure of your troubleshooting skill. So think cleverly and identify the possible causes. Read more…

VN:F [1.9.1_1087]
Rating: 9.2/10 (5 votes cast)
VN:F [1.9.1_1087]
Rating: +3 (from 3 votes)

Shijil T S troubleshoot ,

Fix for pecl.php.net is using a unsupported protocol error

January 5th, 2010

Sometimes you may get this error while you try to install php modules using pecl command. and you may get the error “pecl.php.net is using a unsupported protocal” .

In case you get this error, clear out the contents in /usr/local/lib/php/.channels and /usr/lib/php/.channels and run the command ‘pecl update-channels’ . That should fix the issue.

VN:F [1.9.1_1087]
Rating: 4.8/10 (4 votes cast)
VN:F [1.9.1_1087]
Rating: +1 (from 1 vote)

Prajath R linux

Cpanel backend files

January 5th, 2010

IMPORTANT CPANEL BACKEND FILES AND LOG FILES

/var/cpanel

accounting.log - Contains a list of accounting functions performed such as account removal and creation

cpanel.config – Tweak settings for whm can be done in this file

mainip – Main ip of the server is specified in this file

maxemail - Maximum emails per hour for a domain can be specified here The format is like the following domainname=number

Run the script /scripts/build_maxemails_config after editing this file This will create a file named after the corresponding domain name inside the directory maxemailsperdomain with the value specified in it.

Maxemailsperhour - Server wide maximum emails per hour can be set in this file. It applies to the whole domains in the server. You only need to insert the corresponding value in the file. A value of zero means unlimited.

Resellers-nameservers – This file gives you the name of the nameservers used by reseller users

resellers – This file lists the privileges of different reseller users

packages/ - This directory contains files for all the packages created under the WHM and the corresponding files will give all the details related to that package
Read more…

VN:F [1.9.1_1087]
Rating: 7.3/10 (3 votes cast)
VN:F [1.9.1_1087]
Rating: 0 (from 0 votes)

Tino Thomas linux , , , , , , ,

How to install and configure Bacula

December 25th, 2009

Bacula : –   It comes by night and sucks the vital essence from your computers..

Introduction:

Bacula is an on-linebased back up tool. Which is used to backup files from different servers into back up server where the bacula is running. For setup this backup tool across network first you have to install bacula server package on backup server machine where you are storing your backup contents ,and install bacula client daemon on all other servers from where we are going to backup data.


Bacula has five main components.

1.Director daemon

This daemon co-ordinate all working of backup,and through its configuration file we can specify all these things.

2.File daemon

This daemon works in all clients from that client we are backup data. Director daemon connect to this daemon after authentication and backup the files from this client.

3.Storage daemon

This daemon is for store the backup data from client in to hard disk of backup server,usually this daemon and director daemon works in the same backup server. director works as intermediate between the file daemon and storage daemon.

4.Console daemon

This is a terminal to control all works.This console connect to director daemon and using its commands we can define all things related with backup .

5.Catalog Database

The database used here is for store all information related to the backup, including the file indexing.Commonly used database for bacula is Mysql.


This figure shows how the different bacula daemon configuration files were linked together.

bacula

Install and Configure Bacula Server

You can install bacula from rpm packages or from Source compilation. Here we are focusing on the source method,which is tested and is working fine.

* Download latest version of bacula from bacula.org site .

Here we are using following versions


1. bacula-3.0.3.tar.gz (http://sourceforge.net/projects/bacula/files/bacula/3.0.3/bacula-3.0.3.tar.gz/download)

2. depkgs-18Feb09.tar.gz or later versions (http://sourceforge.net/projects/bacula/files/depkgs/18Feb09/depkgs-18Feb09.tar.gz/download)

This two packages are used to setup a bacula,In which you have to install depkgs-18Feb09.tar.gz first to solve remaining dependency problems before starting bacula-3.0.3.tar.gz. You should not hesitate to install depkgs-18Feb09.tar.gz ,it contains different packages ,in which you can install “mtx and qwt”. you need not install sqlite database because mysql is the default database.

tar -xzf depkgs-18Feb09.tar.gz
cd depkgs
make qwt
make mtx
gmake mtx-instal

Then Enter in to the bacula source directory and Use the following configurations settings to install bacula (Or You can use system default configuration)


 CFLAGS="-g -O2" \
./configure \
--sbindir=/usr/local/bacula/bin \
--sysconfdir=/usr/local/bacula/bin \
--with-pid-dir=/usr/local/bacula/bin/working \
--with-subsys-dir=/usr/local/bacula/bin/working \
--enable-smartalloc \
--with-mysql \
--with-working-dir=/usr/local/bacula/ \
 --with-dump-email=user.name=@????.se \     #The mail addresses is to mail all activities of your backup in to your inbox.
--with-job-email=user.name@????.se \
--with-smtp-host=localhost \
--enable-bat \
--with-qwt=/usr/local/qwt-5.0.2/        #path to qwt source folder( usually it is inside depkg folder that you are installed previously)</pre>

make

make install

make install-autostart   #only supported for the officially supported systems (Redhat/Fedora...).This will put all startup script into the /etc/init.d/ folder and corresponding syslinks , so automatically start corresponding daemon at  startup.

make distclean  # type this to clear all configuration settings if you are starting ./configure from beginning.

Now you are successful completed the installation of bacula server , then type

Then we have to setup the Database to store the catalog information.Most commonly used database is Mysql,and setup the corresponding users,databases and privileges for the bacula application.

 /etc/init.d/mysqld start 

Bacula installation has included some scripts to complete the initial database and other server setups, these scripts are under your bin folder of the installed directory.

cd <Installed path>/bin

./grant_mysql_privileges -u root -p

Create database

./create_mysql_database -u root -p
./make_mysql_tables -u root -p

create a directory called working under /usr/local/bacula/bin/

Afrer installation of bacula. navigate to installed folder and run bacula by typing

./bacula start

This will start all three daemons ( bacula-dir,bacula-sd and bacula-fd)

And then check ports where these daemons are listening.

default case:

daemon    |  port
===================
bacula-dir   9101
bacula-fd    9102
bacula-sd    9103

make sure that the above mentioned ports are added and opened in the csf.conf file of the server or in some other firewall settings

After successful installation to start the sample backup from same system where you installed all three daemons . Follow this simple tutorial :

http://www.bacula.org/en/rel-manual/Brief_Tutorial.html#TutorialChapter

To administrate  bacula it  provide a console or terminal named as bconsole . Using this console we can do all work from back end.

NB: For installation from source package, after detar you should read the README and INSTALL files. Most of the time this will helps you to complete installation.

Install and Configure Bacula Client

After downloading the source and depkgs do the depkgs installation as mentioned  above
Use these following  configuration to install client  :

CFLAGS="-g -O2" ./configure  --bindir=/usr/local/bacula/bin --sysconfdir=/usr/local/bacula/bin --with-pid-dir=/usr/local/bacula/bin/working --with-subsys-dir=/usr/local/bacula/bin/working --enable-smartalloc --with-working-dir=/usr/local/bacula/ --with-dump-email=user@yourdomain.com --with-job-email=user@yourdomain.com  --with-smtp-host=localhost  --with-qwt=../depkgs/qwt-5.0.2/(here path to qwt source) --enable-client-only

If your system is 64-bit(To know it use the command arch ) then add –libdir=/usr/local/lib64

make

make install

make install-autostart-fd     //It helps start client daemon at start up.

create a directory called working under /usr/local/bacula/bin/

start the file daemon using

/etc/init.d/bacula-fd start

add a new “client”and “job” in to the bacula-dir.conf

and set the password in the in the conf’s as shown in the above figure (Use above tutorial also)

Use Follwing configuration checking if you have any problems with the bacula setup

a) Client bacula-fd daemon listening to 9102
b) Edit bacula-fd.conf ,Change the Director name and password to Director name and client resource password in the  bacula-dir.conf
    file of the Server.
c) Add server hostname to the /etc/hosts of the client system, inorder to ensure correct resolution.

d) Also check the ports 9102 to listen server request and 9103 to contact server storage daemon by typing

telnet server-hostname 9103 (from client )
telnet client-hostname 9102  (from server)

========================================================================================
Above procedure is the standard installation steps ; You can download and use the documentation (*.gz) package from bacula.org for more details.
========================================================================================

SET UP WEB BASED INTERFACE TO MONITOR BACULA( php and perl based)

—————————————————————————————————————-
( Install this package in your backup server where your bacula-server is installed)

1.Bweb web based comprehensive admin tool

Bweb developed up on perl,so in order to install bweb we need to install some perl dependencies files.
you can use cpan.
You can install this tool just following the INSTALL file under bacula-gui-XXX/bweb/. This file is more than enough to complete the installation of bweb.

2. bacula-gui-3.0.3.tar.gz

Download this package to setup web interface .

Detar this package and Read README to complete installtaion [in this package You need not type ‘make or make install’ , just

 ./configure --with-bacula=(path to bacula source folder)

Then copy the bacula-web from this source folder and place it in your document root of the apache.

NB: This gui was only tested with php 4.3.4 and php-5.0.4,later. you may get blank page while you are using later versions.check the error log and correct it (may be some permission error ). If you have any problem to install php 4.3.4 with your latest apache 2.2.* then go for apache 2.0.* versions.

Here we tested the following versions.
1.Install pear DB by typing “#pear install DB ”
2.apache 2.0.63
3.php-4.3.4

After installation web-servercopy copy folder bacula-web to its document root , then type : http://system-ip:/bacula-web

Some Error Fixes:

————————————

1.If your configuration of server and clients seems to be correct, but you still receiving  this error

eg:”: Fatal error: bsock.c:135 Unable to connect to Client: server.client.com-fd on server.client.com:9102. ERR=Interrupted system call ”

* Please check the firewall configurations,whether ports 9102 not blocked at client server and 9101or 9102 are not blocked at server .
* To check this telnet to destination port. If the system is installed with csf ,then check the TCP IN and OUT allowed ports.

VN:F [1.9.1_1087]
Rating: 8.8/10 (5 votes cast)
VN:F [1.9.1_1087]
Rating: +1 (from 1 vote)

Haridas N general, linux , ,