Tuesday, January 1, 2013

GDB and Breakpoints on x86

This is a short post summarizing my findings on how some key features of gdb work on the x86 platform. Initially I was under the impression that gdb relies exclusively on the hardware support provided by x86 processors, but it turned out that was not the case.

x86 debug registers

First some background on the x86 debug support. There are 8 debug registers available on the x86 architecture, named DR0 through DR7. The function of these registers is as follows:
  • DR0 - DR3: Hold upto 4 addresses that can be watched
  • DR4, DR5: Obsolete synonyms for DR6 and DR7
  • DR6: Status register
  • DR7: Control register
The registers DR0, DR1, DR2 and DR3 can be used to implement hardware assisted breakpoints. These are 64-bit registers and can be accessed using the regular MOV instructions. Upto 4 addresses can be loaded in these registers. The processor compares the contents of the address bus with each of these debug registers for every memory access. Note that this comparison occurs before any virtual address translation, and so the debug registers should contain virtual, i.e. untranslated addresses. The CPU may be performing any of these operations on the address:
  1. Fetching an instruction from the address
  2. Reading a piece of data from the address
  3. Writing a piece of data to the address
Control bits in the DR7 register determine which type of memory access needs to be watched. If there is an address match, and the memory access corresponds to one that needs to be watched as per DR7, then a debug exception is generated which eventually transfers control to the debugger. This feature can be used to implement watchpoints that are invaluable in hunting down memory corruption issues.

To implement user-defined breakpoints to stop at certain designated locations in a program, the processor should compare the contents of the eip register (the program counter) with each of the debug registers DR0 - DR3, and generate a debug exception if there is a match. The debugger can determine which debug condition has occurred (for e.g. which of the four addresses was matched) by examining the DR6 status register.

So much for the x86 debug registers. So why doesn't gdb normally use these registers for implementing user-defined breakpoints? One problem is that the debug registers can be accessed only in ring 0 in protected mode. In other words, they can be accessed only in kernel mode but not in user mode. What then is the alternative? Enter ptrace.

Ptrace

Ptrace is a very elegant and versatile system call provided by the Linux kernel that can be used to examine and control other processes. Debuggers such as gdb and system call tracing tools such as strace rely heavily on this system call to debug and monitor other programs.

#include <sys/ptrace.h>

long ptrace(enum __ptrace_request request, pid_t pid,
                   void *addr, void *data);

The first parameter to ptrace indicates the operation requested. Ptrace supports a number of monitoring and control operations, such as attaching and detaching from processes, examining and modifying data at specified addresses in the target process, examining and modifying the target process registers, stopping, resuming and killing the target process, and so on. The pid argument specifies the process id of the target process. The last two parameters, addr and data have significance specific to the requested operation.

Gdb can either start and control a program from the outset, or attach to an already running process. The main event notification mechanism in play is the wait system call. The debugger starts or attaches to the process and sits in a wait call. Whenever a signal is sent to the target process, the process is stopped and the wait returns to the debugger which may then examine and/or modify the process state. The debugger may then either continue the process or kill it. One exception to this event notification rule is the SIGKILL signal which kills the target process rather than simply stopping it.

Software assisted breakpoints

When the user requests a breakpoint at a specified address, gdb needs a way to gain control just before the target process executes the instruction at that address. The usual way to accomplish this is to leverage the x86 int 3 instruction. The int instruction raises a software interrupt to the processor which immediately transfers control to the registered interrupt handler in the interrupt descriptor table (IDT).

Why int 3 and not any other interrupt number? Intel has defined a special one byte opcode for the int 3 instruction (0xcc). Thus gdb can simply replace the byte at the breakpoint address with this opcode (using ptrace of course) and remember the original byte in the program. When control reaches that address in the program, the software interrupt gets generated as intended, the process is stopped and the debugger gets control. When the user has finished examining the process state and gives the command to continue the program, gdb substitutes the int 3 instruction with the original byte. Also the program counter eip register should be adjusted back by one byte so that the processor can continue with the original instruction at that address (remember the eip register always has the address of the next instruction to be executed). This register adjustment is again achieved using ptrace.

How exactly does gdb get control when the int 3 instruction is executed in the target process? Let us look at the Linux 2.6.29 kernel to understand this better. Looking at the entry_32.S file in the linux/arch/x86/kernel directory, we can find the handler for the int 3 software interrupt:

ENTRY(int3)
        RING0_INT_FRAME
        pushl $-1                       # mark this as an int
        CFI_ADJUST_CFA_OFFSET 4
        SAVE_ALL
        TRACE_IRQS_OFF
        xorl %edx,%edx          # zero error code
        movl %esp,%eax          # pt_regs pointer
        call do_int3
        jmp ret_from_exception
        CFI_ENDPROC
END(int3) 

We can see that the function do_int3 will get invoked whenever the int 3 software interrupt is raised. This function calls do_trap as follows:

do_trap(3, SIGTRAP, "int3", regs, error_code, NULL);

The do_trap function generates a SIGTRAP signal and delivers it to the target process. As mentioned earlier, whenever a signal is delivered to the target process being traced, the process is stopped and the monitoring program, i.e. gdb gets control via a return from wait. gdb can then use ptrace and figure out that the SIGTRAP signal was delivered to the process and then notify the user that a breakpoint was hit.

Wednesday, August 4, 2010

BMTC Bus Route Search Now More Powerful!

One of the main limitations of my bus route search website was the lack of information on indirect routes between any two locations. For example, if you wanted to go to ITPL from say Basavanagudi, you would not find any direct bus route available. So what would you do? Catch an auto? No way, what with the recent skyward hike in auto fares. A better solution would be to change one or two buses to reach your destination. Thus you could catch one bus to Richmond Circle, and then a connecting bus to ITPL. There could be other alternatives for the changeover point. Which among them is the best alternative?

Several people had requested for this feature as well. The result is now before you. Do browse to http://www.narasimhadatta.info/bmtc_query.html and check out for yourself.

There are several search methods you could use. These are:
  1. Direct Routes Only
  2. Minimum Number of Hops
  3. Maximum Bus Route Availability
  4. Via Terminal Bus Stations Only
  5. Shortest Distance

The Direct Routes Only option is exactly the same as the earlier simple search - it only shows the direct bus routes between any two locations. In case no direct route exists, you could try the other methods. There could be several criteria for selecting a multi-hop route plan. For instance, you might want to minimize the number of buses to change. Or you might want to travel only along those paths that have the highest bus frequency. If you travel by bus occasionally, you might want to change over to another bus only at terminal bus stations. Now you can get the information about any of these preferences.

In the Minimum Number of Hops method, upto five route plans are presented. These route plans have been arranged so as to minimize the total distance travelled. The Maximum Bus Route Availability method also computes upto five route plans. Here the travel time has been taken into consideration as a secondary parameter.

The Via Terminal Bus Stations Only method shows the direct routes between two locations if they are available. Otherwise the changeover points are restricted to only terminal stations. Here terminal station refers to any location where a bus route starts or terminates. Thus some locations such as Corporation which are normally not thought of as terminal stations would also figure in the search results.

The final search method is Shortest Distance. As the note on the website indicates, the route plan determined by this method may not be directly useful since it tends to generate too many hops. It is included for the sake of completeness only. This is based on approximate distances and is by no means accurate. This method could be used for other purposes also, for example to get direct paths while driving from one location to another.

Last but not least, the website has got a UI makeover what with my exercises with HTML and CSS. All the pages on the website validate as XHTML 1.0 Strict as mandated by the W3C consortium. There are some incompatibilities in the display between IE and Firefox, but that hopefully should get ironed out soon. Now you can also leave a comment which shows up directly on the website itself. Use that facility and let me know your comments and suggestions!

Saturday, April 10, 2010

BMTC Bus Routes in Bangalore

How often do you travel by BMTC buses in Bangalore? How many are too scared to even give it a try? And how many have tried and given up? There are several reasons why many Bangaloreans do not opt to travel by public transport. Some of them are:
(a) Buses are not reliable.
(b) Buses are not punctual.
(c) Buses are not fast and take circuitous routes to reach the destination.
(d) Oftentimes the bus stops are a kilometer or more away from the residence and/or place of work.
(e) Buses are old and rickety with poor suspension.
(f) Buses are over-crowded leaving little standing space, let alone seating.
(g) Buses do not stop at the stipulated bus stops.

The list goes on. While we can do little on certain matters such as punctuality and quality, we can contribute in several other ways. Using public transport makes a lot of environmental and economic sense. Assuming that an average bus can hold 40 people and an average car carries 2 persons, one can perceive that a bus can potentially replace 20 cars! It is not difficult to visualize the amount of toxic emissions that can be thus eliminated.

Economically too public transport scores over private ones. A daily pass for BMTC buses (excluding the air-conditioned buses) costs Rs. 32;  one can travel in any number of buses for 24 hours using this pass. A more comfortable journey can be had in the air-conditioned Volvo buses; a daily pass that includes air-conditioned buses also costs Rs. 75. If your office is 15 km away from your residence (which is not at all uncommon these days if you consider the far-flung Electronic City and ITPL corridors for example) and your car gives you a mileage of 10 km per litre in Bangalore's chaotic traffic, you would be burning 3 litres of fossil fuel daily. This translates to around 100 to 150 rupees per day. This is of course excluding the amount of stress involved in driving and parking private vehicles in busy areas. The stress can be avoided by travelling in autorickshaws (really?); however you will have to shell out almost double the amount, Rs. 210 for travelling 30 km.

This is not to discount the utility of private vehicles; in fact, owning a car has become a necessity rather than a luxury. However one can use the car judiciously and occasionally rather than for daily commuting.

One of the main barriers to using public transport is the lack of information on the availability of buses on any route. Most of the buses display the source and destination on their route boards in Kannada only. And that too is illegible many a time. This makes it difficult for outsiders and non-Kannadigas to know where a bus is heading. Not to speak of the challenge to our visual faculties in reading and deciphering the miniscule letters on a whizzing bus in a jiffy!

Even for people who can read Kannada well, there is not enough information to decide which bus to take for reaching a particular destination. The detailed stops are rarely mentioned on the route boards. Newer buses have scrolling LED displays which are better but not sufficient - the scrolling is too slow to read and get the complete picture before the bus rolls away. Another major issue arises when people travel to unfamiliar locations. It becomes very difficult to decide which bus to catch and which stop to get down at.

Having travelled in BMTC buses for over 15 years now, I thought of collecting information on bus route numbers and publishing it on the Web. Thus started the effort more than an year ago. The information was gathered from various sources, for example, the time table booklet published by BMTC, Bangalore city maps (the Eicher map is very good), Wikimapia, the BMTC web site, BTIS, and so on. It has been a painstaking but a very fulfilling exercise so far.

The result was the creation of a  new website to help  commuters search the BMTC  bus routes in Bangalore. You can browse to www.narasimhadatta.info/bmtc_query.html and check it out yourself!

I'm familiar with some places in Bangalore and not so familiar with others. So the information on some bus routes may be more refined than others. There is a feedback form at the bottom of the page that one can fill and submit for intimating any corrections and additions that need to be incorporated. Currently the site helps in searching direct bus routes only. Thus you will not be able to find the bus numbers between two locations for which no direct bus route exists. I'm working on a more advanced Bangalore Bus Route Planner that can compute and display multi-hop bus routes to reach any destination from any source. So stay tuned!

There are other websites on which one can search BMTC bus routes, but these are often outdated and lack sufficient detail. For instance the route search on the BMTC website has been defunct for several months now with no published deadline for activating it. Further most of these websites mention only a few bus stop names. The intermediate points need to be interpolated from the available information. Many times we may not know the exact name of the bus stop where we want to alight. To address this problem, I've attempted to incorporate popular landmarks and institutions in the search locations.

Please check out the website and let me know what you think of the idea and the website. I'll be specially interested in any constructive feedback to make the project better and more useful. And yes, spread the word around to your friends and relatives!

Saturday, October 17, 2009

Trip to North East India (Day 7)

Day 7
This was practically the last day of our north-east India tour. We wanted to visit some nearby places from Shillong and were recommended to go to Cherrapunji, the place with the heaviest rainfall in the world.

8:30 AM
There is a water sports complex right next to the Orchid resort. Here various activities are organized such as speed boat ride, house boat and cruise. We decided to check it out early in the morning. It was a 15 minute walk down to the Umiam lake where the boats anchor. The boathouse was locked and the boatman had not yet come. So we sat by the lake for some time admiring its beauty. Here is a view of the lake.



The boatman arrived at 9:30 and we enquired about the rates. There were a couple of options available such as the speed boat that could accommodate four people, a slightly larger boat that could take around ten people and a bus that could house 30-35 people. There were only a few people and so hiring the bus was not feasible. We decided to go for the speed boat; it cost us Rs. 75 per head for a 5 minute ride. This would cover half the lake. It was also possible to hire the boat for 10 minutes which would cover the entire lake and for which Rs. 150 would be charged.

We had to put on life jackets before boarding the boat. The boatman struggled for some time to start the boat by yanking a lever several times. This reminded us of Bangalore autorickshaw drivers starting their autos. We enjoyed the boat ride which took us round the lake and gave many photo opportunities.



This is the speedboat in which we travelled and standing in front of it is our boatman:



10:00 AM
Returned to the hotel. We came back a little early since we expected to be out all day. We contacted the receptionist who called for the same taxi that had taken us to Shillong on the day before. Meanwhile we had breakfast in the dining hall awaiting the driver.

11:00 AM
The driver arrived at 11:00 AM and we had a brief talk about the places to be covered and the amount to be paid. We had to pay Rs. 1500 for the Cherrapunji trip, which was slightly higher than the Shillong tour since it involved an extra two and a half hour's drive.

12:15 PM
Our first stop was a view point at Mawkdok Valley on the way to Cherrapunji. It is a very deep valley with sloping sides dotted with waterfalls. The place is filled with such lush greenery that a pair of eyes is insufficient to take in all its splendour. It was simply breathtakingly awesome.



1:15 PM
Visit Nohkalikai Falls at Cherrapunji. The original name of Cherrapunji was Sohra and so most of the boards there mention Sohra instead of Cherrapunji. It was about an hour's drive through barren landscape before we reached the Nohkalikai Falls. This is reputed to be the fourth highest waterfall in the world. There was an entry fee of Rs. 5 per head and an additional Rs. 20 for a digital camera. The waterfall is visible at some distance from the viewpoint. Somebody told us that a newer viewpoint was under construction some distance away. We decided to explore it and found that we had to climb down around a hundred stone steps before reaching the new view point which was apparently still not completed. It was constantly drizzling and we had to watch our step while climbing down. There were no other tourists here probably because nobody knew of it or were not enthusiastic enough to climb so many steps. This is how the waterfall looks from the viewpoint.



Climbing the steps back up was more exhausting than going down!

2:15 PM
Visit Mawsmai Cave. This is a cave that is around 150 meters long. We had to pay an entrance fee of Rs. 10 per head plus Rs. 10 for the camera. The cave is filled with shallow water for most of the way and we had to remove our shoes and roll up our trousers to avoid getting wet. The wet surface makes the ground very slippery. There are several rocks along the path providing the stepping stones for making progress. The roof is very low at several spots and we had to walk with our head bent low. Stalactites and stalagmites hang from the roof lending it an authentic look. The rock formations are also very beautiful. The place is damp with water dripping down from the roof at several spots. The inside of the cave looks like this:



It took us around 10-15 minutes to cross the cave and come out at the other end. It resembled a subterranean obstacle race. Several excited teenagers went back into the cave for another round of exploration!

3:30 PM
We were famished by the time we finished our cave adventure and came out of the exit. There was a newly inaugurated small dhaba just outside the cave and we had a simple meal of chapattis there.

4:30 PM
Visit the Seven Sister Falls. There are seven different waterfalls here that can be seen from a distance. The seven north-eastern states (Assam, Arunachal Pradesh, Manipur, Nagaland, Tripura, Mizoram and Meghalaya) are also referred to as the seven sisters. The waterfalls are probably named after this analogy. It was quite cloudy and it was difficult to spot all the seven falls from the distance.



We were now very close to the Bangladesh border and our driver pointed out the Sylhet district of Bangladesh in the horizon.

5:00 PM
Visit the Eco Park. There was not much to see here. At the entrance was a small green-house with several plant species. There was a small stream flowing over which was a stone bridge.

6:00 PM
On the way back, one of the tyres of our taxi got punctured and we had to get it repaired in a mechanic shop. Finally we departed to Shillong. On the ride back, we got to witness the majestic sunset of Meghalaya, which literally means the Abode of Clouds. The sunset was visible for more than half an hour. Never before had we witnessed such a wonderful celestial spectacle. We thought that our journey all the way to the north-east was worth it and more after seeing that brilliant event. Words are insufficient to describe its magnificence. Here are some photographs of the Meghalaya sunset.









This later inspired me to pen a few lines of poetry:

Abode of Clouds, swathed in shrouds
Your beauty is but Nature's bounty!

On the azure plate
Who doth paint
A million hues
Is it Nature's ruse?

Words cannot express
All it does is impress!

8:30 PM
Arrive at the Orchid Resort. We had dinner soon after and retired for the night.

We were to later leave for Guwahati by taxi and thence take a flight back to Bangalore.

With this post, I will conclude the series of blogs on North-East India. It is my sincere hope that this will be useful to some enthusiastic traveler some day.

Saturday, October 10, 2009

Trip to North East India (Day 6)

Day 6
This day was Shillong. We had two days to spend there, the first day of which we decided to explore Shillong city and the second day to visit some nearby places.

But first a word about the resort where we stayed. The Umiam Orchid Lake Resort is owned and operated by the Meghalaya Tourism Department. It is situated around 15 km before Shillong in a place called Barapani. The hotel rent for a double room is of the order of Rs. 1500 per night. The double rooms are really huge and spacious with large French windows opening out into balconies. Our room had a wonderful view of Lake Umiam barely 50 meters outside. The lake is surrounded by beautiful and well maintained gardens which is a treat to watch. One can sit in the terrace and enjoy the view for hours. The whole place is very calm, placid and serene and is a perfect getaway for honeymooners and newly married couples. Here is a view from the balcony outside our room.



And here are a couple of views of the dining hall which boasts of a fireplace that is probably lit in the cold winters.






11:00 AM
Breakfast at Hotel Orchid. The food is nothing great but decent vegetarian food is available. We enquired at the reception about the local sight-seeing options available. Luckily the receptionist's cousin was a taxi driver who could also take us around the city. After talking for a few minutes over the phone, we agreed to pay some Rs. 1200 for a day's sight-seeing trip.

11:40 AM
The driver arrived at the hotel in his taxi, a black Maruti 800 and we started off on the tour. We would realize later that we would be with this same driver for three days on. Shillong is around half an hour from the resort on the highway where a constant stream of army and other trucks keep moving. On the way we stopped to have a glimpse of the Umiam lake. As we entered the city, we observed that the roads were narrow and the traffic was slow-moving at several junctions. Our driver informed us that traffic jams are common during the peak hours of the day.

12:00 PM
Visit Bishop Biden Falls. One can see two waterfalls at a distance from a small viewpoint. The falls are surrounded by lush greenery.



1:00 PM
Visit Shillong View Point. The view point is situated in the Indian Air Force Station premises and it is required to get a visitor's pass before entering. It took several minutes to fulfil this procedure as there were several tourist vehicles waiting to get in. Once inside the gate, a few minutes drive takes us to the view point. One can get a panoramic view of Shillong from this point.



Just behind the view point, some tribal women were making brisk business by dressing up ladies, gents and children alike in the Khasi traditional costume. It was a colourful picture to see the rich dresses, beads and crowns adorning the enthusiastic tourists. They would charge Rs. 50 for a few minutes of dressing and allowing snaps to be taken! Very nice business model indeed... There were also a few hawkers around selling clothes and other bric-a-brac.

2:00 PM
Arrive Elephant Falls. This is around half an hour's drive from the Shillong view point. Here the water falls in three steps forming three small waterfalls. The notice outside the falls explains the origin of the name Elephant Falls.



Here's how the three parts of the waterfall look like, one below another as the water gushes down its path.









We had run out of batteries for our camera and had to buy them in a stall just outside Elephant Falls by paying a premium of Rs. 20! The vendors outrightly exploit the hapless tourists.

3:00 PM
From the Elephant Falls, we drove to the Shillong city center and had lunch at the City Dhaba, one of the fine eating places there.

4:15 PM
Arrive Ward Lake. This is a small lake in the city center with a nice garden around it and forms a good lung space for the people. A nominal entrance fee of Rs. 5 per head is charged. The day we went there a number of school children had come with their teachers probably on a picnic and so it was quite crowded. There is a small white bridge over the lake where one can stand and enjoy the view and feed the numerous fish abounding in the waters below. Several boats are anchored at one end of the bridge which can be taken on hire. We hired a pedal boat and took it for a spin around the lake.



The pedal boat is operated by pushing the pedals with the legs just like a bicycle; the harder one pedals the faster the boat goes. Pedalling in the opposite direction causes the boat to reverse direction. A steering rod is provided at the back - if the rod is pulled left, the boat turns right and vice versa. We spent a pleasant half an hour going around and spotted a duck-house on one of the banks of the lake. There are several stone seats scattered throughout the garden and we relaxed on them for a few minutes before moving on.

5:00 PM
Visit Golf Course. This is around ten minutes drive from the Ward Lake. Our driver informed us that this is a natural golf course.


5:15 PM
Visit Catholic Cathedral. It is a big blue Catholic church (Grotto Chapel) housing statues of Jesus and Mother Mary. We took a few photographs before departing.



5:45 PM
Visit Police Bazaar for shopping. This is the main shopping center of Shillong. Several roads lead away in different directions from the square. The city bus stand is located here from where buses ply to various north-eastern towns. The private taxi stand is also a stone's throw away from the bazaar. The bazaar is filled with numerous shops and shopping complexes mostly selling clothes, purses, bags and footwear. Shillong ladies have a very good dressing sense, the evidence of which is clearly seen there!

7:00 PM
Since it was getting dark, we did not get much time for shopping. Besides it would take around forty five minutes to get back to our resort. Hence we left a few minutes past six and reached the resort by 7 PM.

9:00 PM
After relaxing for some time in the hotel room, we went to the dining hall to have dinner. The hotel staff comes to each room to take the dinner order about an hour earlier. One can go to the dining hall at the appointed time and find the dinner waiting on a reserved table. Again the food was not that great but not too bad either. We took a short walk on the resort lawns post dinner before retiring for the night.

My next post will be the final one in this series where I'll describe our visit to Cherrapunji, the place with the reputation of the heaviest rainfall in the world.

Sunday, September 20, 2009

Trip to North East India (Day 5)

Day 5
This was a day full of travel. We had to reach Shillong from Gangtok.

5:30 AM
We had requested the hotel reception for a wake-up alarm at 5:30 AM. We were told that it takes nearly four hours to travel from Gangtok to New Jalpaiguri station. Our connecting train was scheduled at 11:00 AM and so we wanted to leave Gangtok well in time.
After quickly freshening up, we checked out of the hotel and hailed a shared taxi to NJP. The hotel receptionist provided a helper to carry our luggage to the boarding point which is around five minutes walk from the hotel. There were only two seats left in the Sumo-type of taxi and we had to pay Rs. 150 per head for the ride. The taxi departed from Gangtok at around 6:00 AM.

9:30 AM
The taxi ride was as usual very scenic with the River Teestha in the backdrop for more than half the journey.



The driver had to overtake many a lumbering truck on the narrow winding highway. As we approached NJP, people started getting off at their respective places. Initially we were a little apprehensive whether we could make it in time for the train. However to our pleasant surprise, the taxi reached NJP at 9:30 AM, half an hour before expected. We had breakfast at the IRCTC canteen in the station.

11:20 AM
We had nearly an hour to spare till our train arrived. We spent the time in the upper class waiting room on the railway platform. From the Statesman we learnt of the storm that had lashed West Bengal the day before and the widespread destruction it had caused. Providentially we had escaped the fury of the tempest by just 24 hours! There was some entertainment for us in the waiting room when an irate passenger took the railway staff to task over the ill-maintained toilets there. The Rajdhani express bound to Guwahati arrived on time and we boarded it at 11:00 AM. The train left NJP station by 11:20 AM.

6:30 PM
The train journey was uneventful and we traveled through the length of Assam. As we neared Guwahati, we had the first glimpse of the great River Brahmaputra from a railway overbridge. A fellow passenger pointed us to IIT Guwahati in the distance, several kilometres before the railway station. The scheduled time of arrival for the train was 6:30 PM and the train did keep up to its schedule. However just outside the station, there was a big signal which stalled the train for over forty five minutes. Hence it was nearly 7:15 PM by the time we could come out of the station.

7:45 PM
There are a couple of exits from the Guwahati station and we had a very harrowing time trying to figure out which way to go to catch a taxi to Shillong. Each of us had a heavy bag to carry and it was exhausting to run about from one end to another. Finally a police official directed us to the private taxi stand behind the station, but the worst was yet to come. We had to go to a place called Barapani where our hotel was situated about 15 kilometres before Shillong. There were touts all over the place who gave us misleading information about the mode of transport to take. At last one of them led us to a reluctant taxi driver who demanded some Rs. 1200 to take us to our destination. His claim was that he had to come back empty from Shillong which was not very credible. Besides we had heard that the usual fare was Rs. 300 per passenger. It was getting late and so we haggled with the driver to take us for Rs. 900. He agreed but he was waiting for more passengers to share the taxi with us.
Fortunately or unfortunately for us, there was an army man and his colleague who were also waiting to go to Shillong. They were also firmly bargaining with him over the amount to be paid. Finally after what seemed like eternity and heated arguments, they agreed to join us and the taxi left Guwahati at 7:45 PM.

10:30 PM
That taxi ride was one of the most difficult rides we ever had. The army chaps kept rebuking the driver continuously throughout the journey for demanding excess fare. We were in the dark as to whether it was sincere or whether they were in cahoots with the driver for some fiendish plan. The drive takes nearly three hours and the road was not very good for the first several kilometres of the stretch. Moreover it was pitch dark with few vehicles on the road for some distance. The driver was also driving a bit rashly. Finally we reached the Umiam Orchid Lake Resort in Barapani at around 10:30 PM. The army guy made us pay only Rs. 500 even though the driver kept insisting on getting Rs. 900. Altogether we were a bundle of nerves by the time we landed in our hotel room.

11:30 PM



We had pre-ordered dinner in the hotel over telephone. Cold parathas and a vegetable curry awaited us in the hotel room, and we consumed it before retiring for the night.

Sunday, September 6, 2009

Trip to North East India (Day 4)

Day 4
9:00 AM
Breakfast at Hotel Sagorika, Gangtok.

10:00 AM
Leave for the 10-points tour arranged from the hotel reception. Actually there are two different tours called the 7-points tour which includes Enchey Monastery, Ban Jhakri Falls, Tibetology Center, Ropeway, Flower Show, Handicrafts Emporium and Charten Stupa, and the 3-points tour which includes the Tashi View-point, Ganesh Tok and Hanuman Tok. Each of these tours could be completed in a few hours time. We were told that the Ropeway was under repair apparently after an unfortunate accident and hence we would not be able to go there. We opted for both the tours as a single day-long package for which we were charged around Rs. 1700. The vehicle that was provided for the tour was a Maruti Omni along with a driver-cum-guide. It was raining throughout the day but we did not allow that to dampen our spirits.

10:15 AM
Visit the Charten Stupa. Our driver seemed to have his own ideas about which places to take us to and was initially very uncooperative. After a phone call to the hotel, his behaviour was much better! After all, their main livelihood is derived from tourists like us and they cannot probably afford to lose hotel orders what with competition from several tour operators.
The Charten Stupa is a traditional Buddhist stupa along with a monastery. It has the usual rotating cylinders or the Dharma Chakras.

10:30 AM
Visit the Tibetology center. This is right next to the Charten Stupa in the same complex. We saw several paintings and idols of the Bodhisatthavas inside the center. They depict the life story of the Buddha. Photography is prohibited inside the center.

11:45 AM
Arrive Rumtek Monastery. This place was not included in the original itinerary, but since it is a large and famous monastery in Gangtok, we requested our driver to take us there at some extra charge. It is nearly an hour's drive from the city and it was raining heavily throughout the drive. All along the way, we could see many rivulets and small waterfalls rushing past from the surrounding rocks, making the drive a spectacular experience.
Tourist vehicles have to be parked outside a big gate, and visitors have to walk around half a kilometre on a steeply ascending road. Here's how the monastery looks from the outside:
There are security guards at the entrance who check visitors before allowing them to pass. There are beautiful murals such as this one painted on the walls next to the main door:
Taking photographs is strictly prohibited inside the monastery as the notice board proclaimed:
So we had to be content with taking a few snaps outside the main hall. Just behind the monastery is the Karma Shri Nalanda Institute which is a residential school for the Buddhist monks. Next we visited the Golden Stupa nearby which houses a stupa made of pure gold and the image of the Buddha. A security guard is stationed here too and photography is not allowed.

1:15 PM
It was afternoon by the time we completed seeing the Rumtek Monastery and we were feeling quite hungry. Luckily we found a small restaurant in the same complex and had a reasonably good lunch.

2:15 PM
We returned to our taxi and proceeded to the Ban Jhakri Falls. It was still raining but the drive was again very enjoyable due to the excellent natural beauty of the place.
The Ban Jhakri falls is part of an energy park that was inaugurated in 2008. It has a very nice man-made waterfall where one can see water falling with great force from a height. In fact, it is possible to go upto touching distance of the falls and feel the spray hitting you from the roaring waters. A signboard nearby declared that the water was not fit for drinking. There is a small bridge across the water from where one can get a good view of the falls and the water below speeding past boulders making miniature falls along its course.

There are some interesting models and sculptures of the Jhakri tribal people at several locations around the waterfalls. These depict some of the tribal practices such as the healing ritual of sick people.
4:30 PM
Arrive at the Sikkim Handicrafts Sales Emporium. This is sponsored and maintained by the Sikkim Handloom and Handicrafts Development Corporation. Here a variety of local handicrafts such as clothes, hats, bags, soft toys and mementoes are available for display and sale. The prices are somewhat on the higher side and we spent only a few minutes browsing and making a couple of purchases.
4:40 PM
Arrive Flower Show. It was late by this time and so we did not have much time to enjoy the flower exhibition. We had a quick look at the well maintained garden. A little farther on, there is a green house chamber containing various plants but we did not go inside.
4:50 PM
Arrive Enchey Monastery. This was closed by the time we arrived there, but this is how it looks from the outside:
On the way out, we could espy several Buddhist monks around the monastery and some of them gave us a nice pose:
5:15 PM
Arrive Ganesh Tok. Our driver informed us that the word 'tok' means height. Ganesh Tok is a Ganesh temple located atop a hillock. We had to climb several steps that took us to the shrine. There is a big idol of Lord Ganapati to which a priest offers regular pujas. Photography is not permitted inside the shrine. However there is a viewpoint just outside from where one can watch a panoramic view of Gangtok.
We were also scheduled to visit the Hanuman Tok, a temple dedicated to Lord Hanuman but we could not do so since it was quite far from Ganesh Tok.
5:50 PM
Back to the hotel
6:30 PM
After having freshened up a bit, we left for the market. The city of Gangtok is arranged in layers: a few roads and buildings at one level, and then quaint narrow flights of stairs leading up to the next level. It is almost like  a huge multi-storied building where it is easy to get lost if one has not carefully noted some landmarks. We were directed to the market on M G Road, one of the main roads of Gangtok that is well maintained. The road is cobbled but was very slippery due to the incessant rainfall. Vehicular traffic is not allowed on the road and there are seats at regular intervals on the pavement where one can relax and drink in the sights and sounds of the place. A bust of Gandhiji adorns the middle of the road.
It was Tuesday the day we went there and it was the weekly holiday for the local markets. However the shops on M G Road remain open till around 8:30 PM. After shopping for an hour or so, we returned to our hotel for dinner and rest.