# Bug #496 (DRb slow)

**URL:** <https://www.ruby-forum.com/t/bug-496-drb-slow/147320>\
**Category:** Ruby\
**Created:** [August 31, 2008, 12:34am UTC](https://www.ruby-forum.com/t/bug-496-drb-slow/147320 "2008-08-31T00:34:13Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sithadmin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/858c86/32.png) [@sithadmin](https://www.ruby-forum.com/u/sithadmin)\
**Post date:** [August 31, 2008, 12:34am UTC](https://www.ruby-forum.com/t/bug-496-drb-slow/147320/1 "2008-08-31T00:34:13Z")

</div>

Since I don’t have access to Ruby-core, I’ll just post a couple  
observations here in the hope of giving someone a head start with this  
problem.

I have experienced the same problem as the original poster (Hongli L.)  
i.e. a 5 second lag at start up using DRb.start\_service() on Ubuntu 7 &  
8 so I did a simple test this afternoon.

> require ‘drb’  
> require ‘benchmark’
> 
> puts Benchmark.measure { DRb.start\_service() }

This consistently yielded this sort of result iteration after iteration:

0.000000 0.000000 0.000000 ( 5.020901)

This implies that the delay (5 seconds in my case) is occurring outside  
of Benchmark’s scope i.e. in an external service.

On a hunch, I turned off the Multicast DNS service discovery (AKA  
avahi-daemon)  
and re-ran the simple Benchmark.

The results are now consistently like so:

0.000000 0.000000 0.000000 ( 0.170901)

Apparently, avahi-daemon is somehow involved in the delay and review of  
it’s  
configuration show what seem to be stub files.

Upon further investigation, the Ubuntu systems that I have that were  
configured with Ubuntu-server (rather than Ubuntu-client) did not have  
avahi-daemon installed and/or running and these did not experience any  
start-up delay.

Briefly, DRb.start\_service() and ubuntu-client systems with the  
avahi-daemon appear to interact poorly. I suspect the default  
configuration of the avahi-daemon but don’t had the time (presently) to  
investigate further.

Regards all…
