Blagador! – marvspace.com official Blog
26Jan/100

My cat is plotting to kill me!

Kitteh planning the attack when I got home

Kitteh planning the attack when I got home

Kitteh attacking as soon as I got seated!

Kitteh attacking as soon as I got seated!

Kitteh practicing her ninja skills to commence attack while we are asleep.

Kitteh practicing her ninja skills to commence attack while we are asleep.

And it maybe so...

Is your cat plotting to kill you?

13Jan/100

PKP: Aurora RoadTrip – Mobile Edition

The road to hell is paved with good intentions.

Ok, so you have four idiots who want a roadtrip, a Hyundai Getz (digs?), and two JPEG images of Nueva Ecija and Aurora maps as your guide. What do you get? A stressful but really enjoyable venture into the unknown.

The PKP team decided to go to Aurora province in Eastern Philippines for their first trip of the year. No one really knew how to get there, no reservations were made for the accommodation, and no one has a slight idea on what to expect on the trip. The only thing we knew is that we wanted to go to Aurora with Lily (the Getz).

After meeting somewhere in Quezon City, we started our adventure by going to the North Luzon Expressway and the SCTEX. We left the expressway at La Paz, Tarlac and then proceeded eastward towards Nueva Ecija. At lunchtime we arrived at Cabanatuan City and ate at one of the restaurants along the National Road. Frankly the meals they offered were not delicious.

Start your engines! Boss Erol driving the first stretch.

Start your engines! Boss Erol driving the first stretch.

Moving on, we were deliberating whether we will go to the Pantabangan Dam or not in northern Nueva Ecija, but in the end we decided not to go in order to save time and to ensure that we arrive at Aurora before nighttime. Since we are not going to the dam, we headed towards Palayan (the capital) to take the Bongabon route towards Aurora.

But as we drove our way through Nueva Ecija, we noticed that we are headed towards the town of Talavera! The path we are taking is opposite the path towards Palayan. But since Cabanatuan is already far behind, we decided to push through and proceed to the northern route towards Aurora, via Pantabangan town.

Lily parked at Pantabangan

Lily parked at Pantabangan

We stopped somewhere in Pantabangan, ate some local isaw, and then continued our journey. The dam area is visible but we decided not to go there because we may not have much time.

Ihaw at isaw sa Pantabangan

Ihaw at isaw sa Pantabangan

After hours of driving and after passing through a one way road above a dam, we finally reached Aurora province. It is already getting dark and the cool breeze is starting to chill us so after some picture taking, we continued on towards Baler, where we will spend the night.

The roads in Aurora near the border to the other provinces are really rough. They are not made of cement/asphalt but it looked like someone just dumped small rocks and clay and then they called it a road. Lily, the faithful and still reliable Getz had a hard time navigating through rough terrain and uphill slopes. Really, we should have brought a 4x4 vehicle. It will make things much easier.

We finally reached Aurora province!

We finally reached Aurora province!

At 7 pm, we are still driving in the rough road. The road passes through the Sierra Madre mountain range so it is full of zig-zag turns. At around 7:30 pm we finally arrived at the town of Maria Aurora, where we asked for directions on how to get to Baler. Luckily, from Maria Aurora, the road is already paved so the drive went smoothly.

After arriving at Baler, we refueled and then asked for directions on where we can spend the night. They pointed us to Bay's Inn resort, located just in front of the beach. Perfect. It was already dark so we just ate our dinner at the resort, drank 3 liters of Red Horse and then went to sleep. I was surprised that the food there is quite cheap compared to other resorts I have been to.

Hindi pa ako lasheng....

Hindi pa ako lasheng....

The next morning, the view of the beach is really tempting. There are many surfers who enjoyed the waves. That was the first time I saw the Pacific Ocean from a beachfront.

After eating our breakfast, we decided to try surfing. No one really knew how to do it, but the surfers looked like they were really enjoying themselves so why not give it a try? We rented two surfboards for 200 Php/hour each. Cheaper compared to the surf boards in Zambales. And the waves here are really nice too. Sweet.

Normally, you would want to hire an instructor if you still do not know how to surf. But we decided to do it the PKP way by doing it ourselves. In short, nag urag-uragunan lang.

The waves are really violent, and I mostly found myself being tossed under the water. I had a hard time positioning the board because the waves keep on coming and coming. If a wave crashed on you and you are still recovering another will surely come and hit you again. Luckily the water is quite shallow else I would have drowned then. A tiring but definitely fun experience.

Erol and Lily quality time

Erol and Lily quality time

At around lunchtime we checked out of the resort, and headed back home. Since we do not want to experience the rough road to Pantabangan, we headed towards the Bongabon route instead, hoping that the roads there are better.

Bridge somewhere in Aurora (Baler - Bongabon)

Bridge somewhere in Aurora (Baler - Bongabon)

We were wrong. For me, it was worse than the Pantabangan route. Not only is the road rough, but it is also very narrow, and the side that we are driving is the side where the cliff is! One wrong move and we will plunge in the forests below. Cool. The town of Bongabon is 77 kilometers away, not that far, but that is if you are not driving at 20kph.

WTF Dead End?

WTF Dead End?

After some rough experience in the road, we were greeted by a broken bridge! WTF, a dead end?

Crossing the wooden bridge of death

Crossing the wooden bridge of death

We asked a local who is passing by and he said that we can use the makeshift wooden bridge to cross the stream. Nice. We got out of the vehicle to make it lighter or else we risk breaking the wooden bridge.

Collapsed bridge en route to Bongabon

Collapsed bridge en route to Bongabon

I was wondering what the hell happened to this bridge. It looked like it was bombed or something. Which reminded me, there are numerous reports of the New People's Army operating at Aurora province.

Slow and steady

Slow and steady

The wooden bridge looked tough anyway, and Lily made it to the other side safe and sound.

One wrong move and the trip is over.

One wrong move and the trip is over.

If the bridge collapsed and we wrecked the car, I have no idea how we are going to go back home in Manila. This place is very remote and there are only a few trucks going through this road. My guess is the trucks are not passing through the wooden bridge but they cross the stream directly.

Toti the Explorer doing his job

Toti the Explorer doing his job

After we made it to the other side, we moved on. But since the road is really f***ed up, our navigator had to sometimes guide the car or else we risk being stuck in the mud or falling in the cliff.

The entire scenario

The entire scenario

It was already dark and we are still driving in the mountain pass. There were no electric posts guiding our way, but only the sound of insects and the rustling of leaves at night. There were a few houses then and there, and I was amazed at how they were living their lives in this remote area without electricity. We passed by a DENR checkpoint, they pointed their flashlight at us and let us pass. Maybe they were there to report any illegal logging activities happening in Aurora.

After about 5 hours of navigating the rough mountain pass, we finally arrived at Bongabon. From there, the road is paved again so going back to Cabanatuan did not pose much of a problem. Our navigator instructed our driver on how to drive in a provincial highway at night. Cool.

9 pm. We finally arrived at Cabanatuan City and had our dinner.

Dinner at Jolibee Cabanatuan City

Dinner at McDo Cabanatuan City

Throughout the trip Lily was really reliable even though there were several accidents, like hitting the bottom of the car at a parking lot, hitting it again in the rough road, driving while the hand brake is still on, and others. We were lucky we were not involved in a major accident while driving, especially since we are only using a small car.

It was already midnight when we arrived at Manila and got back home. My entire body is aching the next day and I had a fever after that, but all in all, the trip is really rewarding.

It is good to have an end to journey toward; but it is the journey that matters, in the end - Ernest Hemingway

Filed under: Travels, pkp No Comments
17Nov/094

PKP: Traveling in a Different Way

I really love to travel and explore new places. The more difficult the journey is, the more satisfying it is to finally reach the destination. It is only by seeing for ourselves what the "outside" world looks like that we gain a wider understanding of the "why"s and "how"s in our own lives.

In this post I will state my views on each of the items written by Paulo regarding his experiences in traveling.

*************************************************

By Paulo Coelho

When I was very young I discovered that, for me, a journey is the best way to learn. I still have this pilgrim’s soul to this day, and have decided to relate some of the lessons I have learned, in the hopes that they will be useful to other like-minded pilgrims.

Avoid museums.
This advice may seem absurd, but let us reflect a little together: if you are in a foreign city, isn’t it far more interesting to seek out the present, than the past? Usually, people feel obliged to go to museums, because ever since they were small they have been told that traveling is a search for this type of culture. Of course museums are important, but they require time and objectivity - you need to know what it is you want to see there, otherwise you will come away with the impression that you saw several things which are fundamental to your life, but cannot remember what they were.

Before traveling to another place, you must first study at least a part of what you will expect when you reach there. Part of the excitement in a journey is finally seeing face to face what you only saw previously in post cards, books, magazines, and other materials. But it is not good to focus only on famous tourist spots, but instead try to find and discover your own "tourist spot".

Frequent bars.
Unlike museums, this is where the life of the city can be found. Bars are not discotheques, but places where the people gather to have a drink, pass the time, and are always willing to chat. Buy a newspaper and observe the bustle of people coming and going. If someone speaks to you, strike up a conversation, however banal: one cannot judge the beauty of a path merely by looking at its entrance.

This depends on the culture and environment of the place that you are staying. Make sure you follow all of the community rules and policies so as not to get into trouble. The "bars" mentioned above does not necessarily mean the ones that only open at night, but rather the places where locals gather together and share their stories, probably near the market, a park, or a transportation station.

Be open and forward.
The best tourist guide is someone who lives there, knows everything, but doesn’t work at a travel agency. Go out into the street, choose someone you wish to speak to, and ask him or her for directions (where is such-and-such a cathedral? Where is the post office?) If this bears no fruit, try someone else - I guarantee that in the end you will find excellent company.

This is related to the previous item, where communication with the locals is a very rewarding experience. We had several experiences where strangers helped us find our way home, provided us with transportation, or let us eat lunch at their home when we had nowhere else to go. It is these types of interaction with the people that the journey becomes a rewarding and unforgettable experience (much more than the famous tourist spots).

Try and travel alone, or - if you are married - with your spouse.
It will be harder work, no one will be looking after you, but this is the only way of truly leaving your country. Group travel is just a disguised way of pretending to go abroad, where you speak your own language, obey the leader of the pack, and concern yourself more with the internal gossip of the group than with the place you are visiting.

Again it depends on the place you are going. Generally, safety is the top priority when you travel outside your "comfort zone". Although traveling alone really gives you the chance to discover your inner strengths, as much as possible, find a companion (unless you are prepared to make that journey your last).

Don’t compare.
Don’t compare anything - not prices, nor cleanliness, nor quality of life, nor means of transport, nothing! You are not traveling in order to prove you live better than others - your search, in fact, is to find out how others live, what they have to teach, how they view reality and the extraordinary things in life.

Observing how other people live their lives can be an eye-opener for you.

Understand that everyone understands you.
Even if you don’t speak the language, don’t be afraid: I have been in many places in which there was no way of communicating with words, and I always found support, guidance, important suggestions, even girlfriends. Some people think that if you travel alone, you will go out into the street and be lost forever. All you need is the hotel card in your pocket, and - should you find yourself in extreme circumstances - take a taxi and show it to the driver.

Yes, most people will understand you, but some will definitely take advantage of your situation for their own profit. If this is the case, make sure you have lots of extra cash to spend during unexpected expenses/situations.

Don’t buy much.
Spend your money on things which you won’t have to carry: good theater, restaurants, walks. Nowadays, with the global market and the Internet, you can have everything you want without having to pay for excess baggage.

Try to buy only small items that you can easily carry and make sure that you cannot buy it elsewhere! It is a bit frustrating to buy a "souvenir" item just to find that you can buy it at home from one of the souvenir shops. Do not take flora or fauna as souvenirs! Your memories with the place is the greatest souvenir you can have, so make sure you make good ones!

Don’t try and see the world in a month.
It is better to stay in one city for four or five days, that visit five cities in a week. A city is like a capricious woman, who needs time to be seduced and reveal herself completely.

In today's busy world, more often it is impossible to take it slow and savor the place. The farther the place or the more difficult it is to go to your destination, the longer your stay should be. No one wants to go to a faraway place only to get back home very tired and all of the good times spent in the journey gone because of it.

A journey is an adventure.
Henry Miller said that it is far more important to discover a church no one has heard of, than go to Rome and feel obliged to visit the Sistine Chapel, with two hundred thousand tourists shouting all around you. Go to the Sistine Chapel, but also get lost in the streets, wander down alleyways, feel free to look for something, without knowing what it is. I swear you will find it and that it will change your life.

The most important thing when you travel: find your own tourist spot!

30Oct/092

OH SHI- 03: Stop Trying To Fix People!

The purpose of the Overly Helpful Self Help Initiative (OH SHI) series is to help individuals discover their inner selves and spark a new sense of purpose in life. The articles posted here are not written by Marvs, and the author's name and contact will be indicated in the article.

By Bo Sanchez

Note: This was sent to me by my sister via e-mail. I realized that complaining has been one of my biggest flaws, and that change should come from myself more than from others.

You know what our monstrous mistake is?
We try to fix the people in our life.
Oh, I see it everywhere.
Everywhere I go, I see people complain about the people in their life.
Wives complain about their husbands.
"Bo, please talk to my husband. He eats too much."
"Bo, can you help me? My husband watches too much TV."
One frustrated wife told me, "Bo, please advice my husband. He doesn't have a one romantic bone in his body. Last year, he gave me a bar of soap for Valentines Day. The brand? Mr. Clean."
But husbands complain about their wives too.
"Bo, please talk to my wife. She's gastadora."
"Bo, help me with my wife. My wife is always hysterical and historical. She remembers all my past mistakes, including date, time, and place."
One husband told me, "My wife is so talkative. If the universe paid 1 centavo for every word she said, I'll be the richest man in the world today."
Another man said, "My wife is always angry. When she's angry, she causes global warming and the melting of the ice caps in the North Pole."
Parents complain about their kids too.
"My kids are too messy."
"My kids can't focus on their studies."
One mother said, "My kids are so lazy. If given a chance, they'll ask someone to breathe for them."
And everywhere I go, I also hear many kids ask me to fix their parents.
"My parents are too strict."
"My parents are too corny."
"My parents are too kuripot."
One girl told me, "They allow me to swim only if I wear a long gown."
All over the world, people want to fix people.
Let me tell you why...

Are You Sick Of Comparasonities?
First of all, you want to fix people because you love them.
But sometimes, our motives aren't pure. Sometimes, we want to fix our loved ones because of shame. We're ashamed of what other people will say about our kids, our siblings, our spouses, and our parents.
Another reason of our "fixing other people" tendencies is we're afflicted with the disease called comparisonities.
Humans like to look to the other side of the fence to see if it's greener.
Someone told me that marriage is like going to a restaurant. After you ordered your dish, you learn what the other table ordered, and suddenly regret what you ordered.
Believe me, this urge to compare causes so much misery in marriages.
If you always compare your wife's body with Beyonce or Angel Locsin, she can't compete. Or if you compare your husband's salary with Manny Paquiao's earnings, he can't compete.
Many times, we compare our spouse to someone who doesn't exist. For example, we fantasize about Hollywood stars who aren't real. Because all their blemishes were removed by photoshop and a huge PR company.
Even the pretty officemate who seems so gorgeous on the outside may actually be your worst nightmare the moment you live with her.  You really don't fall in love with her. You fall in love with a projection of how you imagine her to be.
Even parents are guilty of this.

Motivate Your Kids In Other Ways
We have a tendency to compare our kids with other kids.
We even verbally share our comparisons in the hopes of motivating him.
I overheard one mother tell her little boy, "Junior, why can't you get good grades like your sister? She gets straight A's in all subjects. But you're highest grades are Recess and Lunch."
Parents compare their kids to their classmates, their cousins, and even to themselves when they were young. Their sermons begin with this famous line: "When I was young, I wasn't like you..."
Kids cannot flourish in an environment where they are being judged. Kids flourish in an environment of appreciation. They need to know that their parents accept them for their uniqueness.
Parents, stop comparing!
And there's also another disease that causes us to fix people.

The Virus of Criticalities
I've met people who have a strong critical spirit in them.
I pity them so much. Once afflicted, they become very miserable people.
These people think God created them to criticize others. All day long, they look for the faults of the people around them.
But behind this critical spirit towards others is really a critical spirit toward oneself. In fact, the critic pulls down others so that he can hide his own failures.
Let me now tell you what you should do.

Question: Do You Want Less Stress and More Joy?
Do you want less stress in your relationships?
Do you want less fights?
Do you want less wrinkles?
Do you want more joy?
My solution is really simple: Stop trying to fix others.
Big clarification: In my message today, I'm not talking about the big sins. Like marital abuse, alcoholism, adultery, and all the other major violations against the Ten Commandments. I'm also not talking about tolerating the sins of your kids. I'm not teaching you to say, "Wow son, you're very good in stealing. Perhaps you can be a Congressman one day." (I'll talk on "tough love" on the sixth instalment of this series, Relationship Reborn.)
Today, I'm talking about idiosyncrasies, eccentricities, personalities, and persuasions that make your loved one very unique.
If you're not going to fix people, what should you do?
Appreciate them.
I'll now explain a mystery.

What You Like And What You Don't Like
Maybe One And The Same Thing

I have mixed feelings about my cellphone.
My relationship with my phone is ambivalent.
I like it and I don't like it.
There are days when I think it's the greatest invention since peanut butter. And there are days when I want to fling it into the mouth of a volcano.
Here's what I noticed: The very features that I like are the very same features that I don't like. Absurd but true.
Why do I like my phone? I like the fact that I can call up the 954 people in my phone directory anytime. Useful when I have a flat tire, when I need a prayer, or when I'm on the rooftop because of Typhoon Ondoy.
Why do I not like my phone? I don't like the fact that these 954 people can call me up at anytime-even when I'm lying on a hammock in a tiny island far out in the Pacific Ocean.
Why do I like my phone? Because I can bring it everywhere I go.
Why do I not like my phone? Because I can bring it everywhere I go!
Question: Have you ever had the absurd experience of leaving your cellphone at home and having to make a U-turn to come back for it? Nuts, right? Cellphones are now like one of our kidneys. You can still survive if it gets lost, but it'll be risky.
I repeat: The very things that I like are the very same things that I don't like.
Funny, but this is also true with our relationships...

Why Did You Fall In Love?
Don't be shocked, but the very thing that made you crazy for a person will be the very same thing that will drive you crazy in the years to come.
I'm not kidding.
If you fell in love with your wife because she was bubbly and the life of the party, today, you want to zip her mouth so that there would be world peace.
If you fell in love with your husband because he was quiet, strong, and steady as a rock, today, you want to curse him for being so cold and unresponsive-like you're talking to a rock.
If you fell in love with your wife because of her stunning beauty, today, you find yourself pulling your hair in the car, waiting for her because she takes 3 hours just to dress up and put on her make-up.
Remember: Every strength has a weakness.
My friend Jon Escoto says that "a weakness is really a strength applied inappropriately." (As another friend loves to say, "You're right in the wrong way!") You can't have only one side of the coin. You have to have both.

Why My Wife Married Me
One day, I had a very serious talk with my wife.
"Sweetheart, I want you to be completely honest with me," I said to her. "Aside from the fact that I look like John Loyd and Piolo Pascual put together, what else made you marry me?"
After laughing out loud and rolling on the floor, she finally said, "Sorry Bo, your looks weren't the reason why I married you. I married you because you have such a big heart for God."
But I bet if you ask her today, "Marowe, what are the difficulties of being married to Bo?" she'll tell you, "Because Bo has such a big heart for God!"
She will explain to you, "Our schedule isn't normal. Our entire married life isn't normal. Bo runs 9 non-profit organizations. He's constantly stretched. He travels a lot." She's accepted that as her lot in life.
Here's something she's also accepted: When we have our weekly dates, she already expects it to be interrupted. Many times, a total stranger would approach me, cry on my shoulder, and ask for prayer.   In the middle of the busy mall, I hold an instant mini-healing rally-because the moment people see me praying for one person, people fall in line.
She's come to accept this reality as part of the set package called Bo Sanchez.
She's accepted the fact that when she married me, she also married the people I love-the flock I care for.
Why am I telling you all these?

Stop Trying To Fix People
To repeat my million-dollar point: If you want to have happy relationships, you'll have to stop trying to fix people and start appreciating them.
Jesus said, "Love your neighbor"; He didn't say, "Fix your neighbor."
Two reasons why you need to stop fixing people.
First, you can't.
Second, I've realized that people are like old houses. If one thing gets fixed, another thing gets broken.
Let me tell you what I mean by appreciate.

Two Levels Of Acceptance
The first level of acceptance is tolerance.
The second level is appreciation.
Let me tell you a story.
Jean came up to me one day and said, "Bo, can I share something with you? My story might help women you talk to."
Jean said that her husband is addicted to watching basketball. She told me that it drove her insane. "Brother Bo, there was a time when his passion for watching basketball made me so angry. I would nag him, I would throw pots and pans in his direction, I would hide the TV remote control-just so he can't watch."
She told him, "I think basketball has become your god. And the churches you attend are NBA, PBA, PBL, NCAA, and UAAP. All you talk about is basketball." And her husband would answer back, "Foul yan."
"But after a couple of years," Jean said, "I just gave up. I realized that nothing was going to happen. That he will never change."
That was the day when Jean began to tolerate her husband's passion for basketball. Whenever she saw him sitting in front of the TV watching a game, she felt less irritation in her heart.
But one day, Jean had a bigger epiphany.
That fateful morning, Jean's best friend called her up crying hysterically on the phone. Through many tears, she said that she discovered her husband was having an affair. After an hour of trying to comfort her, Jean's friend said, "I wish my husband was like your husband, Jean-so faithful to you."
That one sentence was like a slap on her face.
She woke up.
Jean realized she was blind to the great blessing that her husband was to her.
Because she was so focused on his basketball addiction, she never appreciated how faithful her husband was to her.
She also began to count the many ways he was a wonderful husband: He was hard-working, he loved the kids, he went with her to her prayer meetings, and he was sweet in his own manly, clumsy way.
Today, she sometimes joins him watching basketball.
She still doesn't appreciate the game. She told her husband once, "Why don't they just give one ball to each team?" But she enjoys being with her wonderful husband now.
That day, Jean moved from tolerance to appreciation.
And that was the day her marriage became very happy.

Are You A Judge Or A Painter?
What I'm sharing with you is so earth-shaking, I should be charging you a million for divulging this secret to you.
Believe me, if you apply this secret into your life, you will change your entire life-radically. You'll have less stress. You'll have less fights. You'll have more peace.   You'll be more joyful. You'll feel and look younger by ten years.
It was Dr. James Dobson who said that before you get married, you should have both eyes wide open. But after the marriage ceremony, close one eye.
What does he mean? Before you get married, you should be very careful in evaluating your future spouse. Check everything. Values. Background. Preferences. Reactions. Beliefs. Examine everything!
But when you get married, stop evaluating. Stop critiquing.
It's now time to stop fixing the other person and start appreciating the entire person in his totality.
Remove the robes of the courtroom judge. Instead, put on the robes of a painter capturing the beauty of a scene. An artist simply accepts what is and nurtures a gratitude for what is there.
When you accept the other person and become grateful for him, a great miracle happens: The person learns to accept himself too and thus bring healing of his Heart Wound. Changes begin to take place spontaneously.
You can never fix anyone.
Because fixing is an inside job. Never forced from the outside.
Yes, you should inspire. You should guide. You should teach. But you cannot force.
At the end of the day, the only thing you can do is to love the person by creating space for the other person to fix himself.

Your Assignment
One of the ways to show gratitude is to simply to say it.
Here's your assignment for this session: Go to 1, 2, or 3 people in your life and thank them for the blessing that they are to you.
Be specific. Write them a letter of gratitude.
Thank your wife for the small things she does for you.
Thank your husband for going to work everyday.
Thank your mother for the way she serves you.
Thank your child for being a wonderful child.
The next time a loved one presses your clothes, or takes out the trash, or fixes the car, or takes care of the baby, appreciate them in your heart and in your words.
I promise: Gratitude will be like oil in the engine of your relationship.
Your relationship will function in a whole new level.

Final Story:
"I Love The Perfection Of Your Imperfections."
Let me end with one of my favorite stories.
One day, a wife came to her husband with a magazine in her hand, "Darling, this article is wonderful. It describes a little activity that we can both do to improve our marriage. Can we do it together?"
"Sure," her husband said.
"It says here that for one day, each of us will separately write a list of what areas we want the other to change. Little annoyances, little irritations, etc. And then tomorrow, we share this list to each other. Deal?"
"Deal!" the husband smiled.
That day, the man sat on the living room with paper and hand. The wife went to the bedroom and did the same thing.
The next day, over breakfast, the wife said, "Game? Can I start first?"
"Yes," the husband said.
The wife pulled out three pages. Single spaced. Font 8. It was a long list. She began to read her list. "Darling, I don't like it when you do this..." On and on, she read the little ways her husbands annoyed her.
The man felt a sting in his heart. The wife noticed this and asked, "Do you want me to continue?"
"I can handle it. Go on," the man said.
So the wife continued to read.
Finally, the woman said, "Okay, it's your turn."
The husband pulled out his piece of paper and said, "Yesterday, I asked the question what are the changes I want in you. But hard as I tried to think, I couldn't think of one thing." He then showed to her the empty piece of paper in his hand. "Because to me, you're perfect in your imperfections.   I've accepted who you are-strengths and weaknesses. And I love the whole package. I love the mix. You are a wonderful person and I love you so much."
The wife began to sob, rolled up her three pages in her hand, and beat her husband on the head, "Bwiset ka!" And hugged him tight for a very long time.
May your dreams come true,

Bo Sanchez

18Oct/094

How to Setup a Rails application in cPanel

Setting up a Rails application should be painless, but there are times when some hosting restrictions make deployment a real pain in the ass. I would like to share with you some tips that hopefully will help you get over some of the obstacles in deploying a Rails application using cPanel.

Currently my hosting provider does not provide shell access to my account. As we all know, shell access can spell the difference between a good dream and a nightmare deployment.

As a note, all of this was done using cPanel 11.24.5-RELEASE.

Step 1: Create your application in your local machine or from any source

Its as simple as running rails my_app, then populating the code with whatever you want it to be.

Step 2: Check the Rails gems in cPanel

Make sure that the Rails version on cPanel is the same as the version used in your application:

  1. Login to your cPanel administration panel. e.g. http://myapp.com/cpanel
  2. Enter your username and password
  3. Under Software and Services, click RubyGems
System-installed Ruby Gems

System-installed Ruby Gems

cPanel is using the latest available Rails gems. If your application is created using an earlier Rails version, you will need to "vendor" the older version of Rails (as described later in the post).

Step 3: Create the Rails application directory using cPanel

  1. Login to your cPanel administration panel. e.g. http://myapp.com/cpanel
  2. Enter your username and password
  3. Under Software and Services, click Ruby on Rails
    rails_dep1
  4. Enter your application name under App Name
  5. Check Load on Boot (I haven't tested this yet, but some sources say that this is not working, but check it anyway)
  6. The Application Path will be automatically updated using your application name. Take note that your Rails application is now residing under /home/<user>/etc and not in /home/<user>/public_html. This was probably due to security reasons to make your code inaccessible to prying eyes.
  7. Set the Environment to production mode
  8. Create! cPanel will automatically generate all the necessary files and folders needed by your application

Step 4: Vendor your ruby gems

Vendoring gems means putting the gems used by your application in the vendor/gems directory. This will ensure that your application will still run smoothly even if the system-installed gems in the server is changed. To properly do this, follow these steps:

  1. In your local machine, make sure the gem you will vendor is currently installed. If not, run
    gem install <gem name>
  2. Put the proper config.gem in config/environment.rb for each gem you will use
  3. Unpack the gems to be used  in  into the vendor/gems directory using this command:
    rake gems:unpack
  4. Check each unpacked gem if it contains a .specification file.

Example: Vendoring the sqlite3 gem

In my case, the sqlite3 gem is not included in the system-installed gems. Since I will be using sqlite3 and not mySQL as my database, I need to vendor it.

  1. In your local machine, install the sqlite3 gem (if it is not installed yet)
    gem install sqlite3-ruby
  2. Uncomment the config for the sqlite3 gem in config/environment.rb
    config.gem "sqlite3-ruby", :lib => "sqlite3"
  3. Run rake gems:unpack

Step 5: Populate your application with your code

Its now time to upload your code into cPanel. There are many ways to do this, but what I did was to upload my code using FTP and then moving the uploaded code into the main application under /home/<user>/etc/rails_apps/myapp

You will need to upload the following folders: app, vendor, db, config, lib, and public

Warning!
If your application uses Rails plugins, the vendor directory may contain thousands of files, making uploading it very slow. To solve this, I highly recommend archiving/compressing the directory first. Use gzip to compress the archived file. Do not use other types of compression (e.g. zip, rar) since they are not recognized by the cPanel Extract command!

To archive and compress a directory (for example, the vendor directory):
tar -cf vendor.tar <path of folder>/vendor
gzip vendor.tar

After compressing, upload the *.tar.gz file into cPanel. When the upload is finished, go to the cPanel File Manager. Navigate to the folder where you uploaded the file, check the *.tar.gz file and then press the Extract button on the top menu. Enter the directory where you want it to be extracted, and then press Extract. A window showing the files being extracted must be displayed. If the only thing you see is a loading bar saying that the file is being extracted, then the compression type you used is not recognized by cPanel.

After extracting the file, copy/move its contents to the main application directory in /home/<user>/etc/rails_apps/myapp

Step 6: Run your application!

It is now time to test your application. cPanel provides a simple method of stopping or starting your Rails application. Just go to Software and Services, click Ruby on Rails and click either the Run or Stop buttons to start or stop the mongrel processes. There are some things to remember though!

  1. Make sure you deleted/renamed the default Rails index page located at:
    /home/<user>/etc/rails_apps/<myapp>/public/index.html
  2. Check the log files if your application refuses to run. The log files are located at:
    /home/<user>/etc/rails_apps/<myapp>/log/mongrel.log
    /home/<user>/etc/rails_apps/<myapp>/log/production.log
  3. Do not delete the mongrel process id (pid) file! This file is needed by cPanel to determine which processes to stop when you need to stop your Rails application. I accidentally deleted this one time, and because of it I was unable to restart my application and I needed to contact the system administrator to manually kill the mongrel process (since I do not have shell access). This file is located at (why do they put it there...):
    /home/<user>/etc/rails_apps/<myapp>/log/mongrel.pid

Step 7: Create a Rewrite

Your Rails application is now running at a different port than your main URL. For example, the Rails application running in marvspace is at http://marvspace.com:12001. What you want is to make your main URL to point to this specific port. To do this, you need to create a Rewrite in your site public_html/.htaccess file to redirect all requests from your main URL to your Rails application running at a different port.

Fortunately, cPanel provides a very easy way to create a Rewrite. All you need to do is go to Software and Services, click Ruby on Rails and click Create a Rewrite beside the application name. If you check your .htaccess file, you will see these lines:

RewriteEngine on
Options All -Indexes
RewriteCond %{HTTP_HOST} ^marvspace.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.marvspace.com$
RewriteRule ^/?$ "http\:\/\/127\.0\.0\.1\:12001%{REQUEST_URI}" [P,QSA,L]

To put it into plain words, these lines mean: "If a request starting with marvspace.com or www.marvspace.com is accessed, that request is to be handled by the application running at port 12001."

Step 8: Got Errors?

Sometimes your Rails app refuses to run even if you already checked the above things. I will share to you some of the problems I encountered and how to solve them.

Error: My Rails app wont start and the production logs do not show anything.
Solution: Restart your application in development mode. View the development.log file to see the actual cause of error.

Error: no such file to load -- sqlite3
Solution: The sqlite3 gem is not installed in the system. Follow the example at Step 4 to install the sqlite3 gem

Error: libsqlite3.so: cannot open shared object file: No such file or directory
Solution: The system does not have the shared object file required by sqlite3. To solve this, you need to put the  libsqlite3.so file directly into your filesystem.

  1. Download the libsqlite3.so file here.
  2. Put this file into any accessible directory. In my case I put it in /home/<user>/bin
  3. Edit the sqlite3 gem to include the uploaded libsqlite3.so file.
    In /vendor/gems/sqlite3-ruby-1.2.4/lib/sqlite3/driver/dl/api.rb
module SQLite3 ; module Driver; module DL;
  module API
    extend ::DL::Importable
    library_name = case RUBY_PLATFORM.downcase
      when /darwin/
        "libsqlite3.dylib"
      when /linux/, /freebsd|netbsd|openbsd|dragonfly/, /solaris/
        "/home/<user>/bin/libsqlite3.so"
      when /win32/
        "sqlite3.dll"

Restart your application for your changes to take effect.

Error: My Rails application started but there are no images or the stylesheet is not loaded.
Solution: The Rewrite generated by cPanel is faulty. To fix this, you need to edit this file and update the Rewrite rule:
/home/<user>/public_html/.htaccess

Open the .htaccess in your text editor and change
RewriteRule ^/?$

to
RewriteRule ^.*$

Error: I edited my .htaccess file and now my files and folders under public_html are now inaccessible via URL
Solution: Since the updated Rewrite basically says that all requests be redirected to the Rails application, the URLs your other non-Rails directories are now being routed to the Rails application, causing an error. To circumvent this, either edit again the .htaccess file to exclude certain requests or use subdomains.

Ano Na Naman To?

You are in marvspace.com, the official website of Marvs. This is the official blog.

Justitia!

OPLAN: Retribution

May Pasok ba Bukas?

February 2010
S M T W T F S
« Jan    
 123456
78910111213
14151617181920
21222324252627
28  

Inactivity Meter

Categories

Commercial Muna

Kala mo naman sikat ka na…

Meta

Live Traffic Feed