Sunday, August 5, 2007

perl: warning: Setting locale failed.

I was getting this error

perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = "en_US:en_GB:en",
LC_ALL = (unset),
LANG = "en_US"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").


and I did not know what to do.
Yahoo'd and found this link "http://www.linuxquestions.org/questions/showthread.php?t=574006"

needed to create this file "/etc/environment" in my debian etch. I do not know, why this file was not present. I had just bootstrapped and installed debian as dom1 in my xen installation.

within the file you needed this

LANGUAGE = en_US
LC_ALL = en_US
LANG = en_US
LC_TYPE = en_US


Note : besides, I tried to have this dpkg-reconfigure locale.. which ran but still gave the errors. dpkg-reconfigure localeconf, said I did not have the package, when trying to isntall, it said this package does not exist.

So still do not know the details, but I am rid of the issue..

Wednesday, July 25, 2007

Working with ZOOP (Installing and configuring and a simple Hello World

Zoop Installation

1) Download the Zoop Library and unzip into the PHP folder
2) Download the Zoop Pear Library and unzip into the PHP/zoop-ver/ folder
3) Edit the php.ini file..
session.save_path = "E:\tmp"
include_path=".;E:\Program Files\PHP\pear;E:\Program Files\PHP\zoop-1.3b1;E:\Program Files\PHP\zoop-1.3b1\lib\pear"

4) Download the zoop-skeleton and copy it inside you htdocs web (root) folder.

Configuring the Zoop

1)

Friday, July 20, 2007

This Insert comes in Handy..

In Gentoo, the my.cnf, has a default setting of binding the local interface to 127.0.0.1, hence from outside we are unable to connect to the server at port 3306.

Always remember, that before we check all the permissions inside the mysql db, we should check the connection from outside ie. 'telnet romote-address 3306' If this connects and still you get error in connection, then there is an authentication problem..

Check the host table..
if not insert this..
insert into host (Host,Db,Select_priv,Insert_priv,Update_priv,Delete_priv,Create_priv,Drop_priv,Grant_priv,References_priv,Index_priv,Alter_priv,Create_tmp_table_priv,Lock_tables_priv) values ('%','db_name','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y');

% denotes all hosts.. You can mention an IP address to restrict connection from a certain IP address.


PEAR Installation on Windows..

Firstly get PHP installed on your machine.
next go to http://pear.php.net/go-pear, save this page as go-pear.php.

Assuming your PHP was installed nicely, and you had selected to configure the Env Variables, while Installing PHP, go to command prompt.. ie 'cmd'.
F:>php go-pear.php

Progress herewith by selecting the exact path of your PHP installation and continue henceforth.

How To Install Struts4PHP

Now, that Pear installed do the following things..

1) F:>pear channel-discover pear.struts4php.org
2) F:>pear install struts4php/struts4php
Although the above #2 command did not work on my machine..
I had to force install, it said some comflict with lang package ..
2) F:>pear --force install struts4php/struts4php

Thats all..

Now unto understanding the struts4php...

Friday, June 29, 2007

You never know

You Never know
how And When
The Existence Will Start
Using You For Its Purpose

You Never Know
How And When
You Will Be Filled With
Abundance
And You Will Start Raining
Quenching The Thirst of Many

You Never Know
How And When
You Will Be Full Of
Fruits And Shade
And Travelers Will Take
Shelter And Food From You



You Never Know
How And When
You Will Be Full With
Love And Light
And You Will Start Spreading
The Fragrance of Beauty To Everyone


You Never Know
How And When
The Death Will Come
And Make You Deathless
And Life Will Start
Flowing Out Of You
You Never Know
How & When....Really !


~Sri Sri

Drupal mysql database creation and assigning priviledges

Archived herein so that I can refer to this, whicle createg databases and assigning privileges.

First, you must create a new database for your Drupal site (here, 'databasename' is the name of the new database):

mysqladmin -u username -p create databasename

MySQL will prompt for the 'username' database password and then create the initial database files. Next you must login and set the access database rights:

mysql -u username -p

Again, you will be asked for the 'username' database password. At the MySQL prompt, enter following command:

GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES ON databasename.* TO 'username'@'localhost' IDENTIFIED BY 'password';

where

'databasename' is the name of your database 'username' is the username of your MySQL account 'password' is the password required for that username

Note: Unless your database user has all of the privileges listed above, you will not be able to run Drupal.

If successful, MySQL will reply with:

Query OK, 0 rows affected

To activate the new permissions, enter the following command:

FLUSH PRIVILEGES;

Tuesday, June 26, 2007

I do not believe in God

Archived, here, since its just so beautiful, copied from the author's discussion at orkut here, his profile is here..
I went to a barbershop to have his hair cut .

As the barber began to work, I began to have a good conversation.
We talked about so many things and various subjects. When we
eventually touched on the subject of God, the barber said:

"I don't believe that God exists."

"Why do you say that?" I asked .

Barber :

"Well, you just have to go out in the street to realize that God doesn't exist. Tell me, if God
exists, would there be so many sick people?

Would there be abandoned children?

If God existed, there would be neither suffering nor pain.

I can't imagine a loving God who would allow all of these things."

I thought for a moment, but didn't respond because I
didn't want to start an argument.

The barber finished his job and I left the shop.

Just after I left the barbershop, I saw a man in the street with
long, stringy, dirty hair and an untrimmed beard. He looked dirty and
unkempt.

I turned back and entered the barber shop again and said
to the barber: "You know what? Barbers do not exist."

"How can you say that?" asked the surprised barber.

"I am here, and I am a barber. And I just worked on you!"

"No!" I exclaimed. "Barbers don't exist because
if they did, there would be no people with dirty long hair
and untrimmed beards, like that man outside."

"Ah, but barbers DO exist! That's what happens when people do not come
to me."

"Exactly!" I affirmed . "That's the point! God, too, DOES
exist! That's what happens when people do not go to Him and don't look
to Him for help. That's! why there's so much pain and suffering in the
world."


The meaning to look to GOD is not to go to the temple or just rituals. Surrender yourself to GOD, kill your ego completely.
God is within U !


In Service with love
Ritesh Sharma

Monday, June 25, 2007

Tata Indicom are Fraudsters

After reading the full blog (here and here), I can only feel sorry that I opted for Tata indicom prepaid. My experience is as bad as any of you, when after using the phone for 2 months it died.

I brought it at the Tata true value (fraudsters) shop, and they told me, that I should take it to the Haier service station some 25 Kms away. I bowed to there insists and went there. They took my mobile away for repair asking me to come after 1 week. so long I am having to bear with no mobile. So after 1 week, like a donkey I go, and they give me a replacement certificate, and ask me to collect the new phone from tata true value (fraudsters) shop.

Like a donkey I go to there showroom, sit there for 1 hr for my turn to come. and then the kid, smartly dressed in jeans and yellow t-shirt, bull shits me, that all such replacements happen at nodal office, Ultadanga. which is another 25 Km from there.

After, requesting and feeling like a donkey, I again endure the long journey, to nodal office, and I meet, with Rikta Roy (033-65551181), and she informs me of the way a replacement is made. it goes like this...

"Once you get the Replacement Certificate you have two ways, either, you can deposit the handset at the True Value (fradusters) shop, and after a week you can get a refund, or, you can ask for a replacement, and if they have the same handset available, then they will replace you after 1 week."

I asked, what if they do not have the handset in stock,
she replied, " Then after a week, you can get another headset, provided you are willing to pay the difference."

And she added " We at nodal office, do not replace the thing, you go to the true value (fraudsters shop, and tell them this is the process."

amazed, I was at my wits end of controlling the bhadrolok (gentleman) dying to kill her. anyway, I came back to the true value (fraudsters) office, and told them the process, and they asked me to come next day and it will be solved.

I went back happy, think at last tomorrow will be the day. The next day, my company sent me off to Coimbatore, and I came back 6 days later. yet I remembered the meeting and went ASAP. The lady kept me waiting. then finaly when my turnm came, she asked me to wait, as she was calling the godown people. wait wait wait all she said and 3 hrs passed. I started fuming, and she told me to come after 4 days, that is the time it will take for the headset to come from the godown. I got angry shouted at my lungs limit, and it fell on deaf years and the kids just made a dissapearing act.

so, I went through another 2 of such torments and finally recieved the money of the headset after exactly 37 days.
Now, I will never ever take an Indicom Connection.

Also, I will tell, you, however, cheap the tataindicom may seem to you, stay away from it. They are fraudsters. They supply the worst handsets on earth.

Incase any of you are planning to sue the company, count me in. I can give you good length of materials.

regards