Professional Web Applications Themes

Webrick slow when running on a stand-alone system - Ruby

I've developed a small app for a laptop using Webrick. It serves pages to a local browser. It works great when the laptop is connected to the internet. But when then laptop is running without an external network connection it runs very slowly, with long pauses before serving a page. I am guessing it is trying to do some kind of lookup and is timing out. Is there a way to disable that behavior. The problem is occuring on a Windows 98 box running Ruby 1.8.1 (with the included Webrick). Any ideas? -- -- Jim Weirich org http://onestepback.org ----------------------------------------------------------------- "Beware ...

  1. #1

    Default Webrick slow when running on a stand-alone system

    I've developed a small app for a laptop using Webrick. It serves pages to
    a local browser. It works great when the laptop is connected to the
    internet. But when then laptop is running without an external network
    connection it runs very slowly, with long pauses before serving a page. I
    am guessing it is trying to do some kind of lookup and is timing out. Is
    there a way to disable that behavior.

    The problem is occuring on a Windows 98 box running Ruby 1.8.1 (with the
    included Webrick).

    Any ideas?

    --
    -- Jim Weirich org http://onestepback.org
    -----------------------------------------------------------------
    "Beware of bugs in the above code; I have only proved it correct,
    not tried it." -- Donald Knuth (in a memo to Peter van Emde Boas)



    Jim Guest

  2. #2

    Default Re: Webrick slow when running on a stand-alone system




    Nathaniel Guest

  3. #3

    Default Re: Webrick slow when running on a stand-alone system

    On Sun, Feb 22, 2004 at 03:45:42PM +0900, Jim Weirich wrote: 

    My guess would be it's doing a reverse lookup for a PTR record
    based on ip address so it can log it by name. Just a guess,
    though, since I've not used webrick.



    -matt

    --
    matthew c. mead

    http://www.goof.com/~mmead/


    matthew Guest

  4. #4

    Default Re: Webrick slow when running on a stand-alone system

    On Feb 22, 2004, at 01:45, Jim Weirich wrote:
     

    Just a hunch... try this at the beginning of the program:

    Socket.do_not_reverse_lookup = true

    I've heard this mentioned as the solution to several previous WEBrick
    problems, and it seems like it might be related to yours.

    HTH,


    Nathaniel

    <:((><



    Nathaniel Guest

  5. #5

    Default Re: Webrick slow when running on a stand-alone system


    Nathaniel Talbott said:
     

    Good hunch. Unfortunately, it didn't seem to do anything.

    --
    -- Jim Weirich org http://onestepback.org
    -----------------------------------------------------------------
    "Beware of bugs in the above code; I have only proved it correct,
    not tried it." -- Donald Knuth (in a memo to Peter van Emde Boas)



    Jim Guest

  6. #6

    Default Re: Webrick slow when running on a stand-alone system

    Use 'localhost' ip address. It probably try to go out for dns lookup.

    "Jim Weirich" <org> wrote in message
    news:org... 


    Ruby Guest

Similar Threads

  1. running isa on windows2003 stand alone
    By amz050 in forum Windows Server
    Replies: 0
    Last Post: June 3rd, 07:39 AM
  2. Newb Questions: What does SMP stand for? How do I know if the system is utilizing both CPUs?
    By Michael Heiming in forum Linux Setup, Configuration & Administration
    Replies: 4
    Last Post: July 27th, 09:35 PM
  3. Samba running running slow...
    By Todd Cary in forum Linux Setup, Configuration & Administration
    Replies: 3
    Last Post: July 10th, 11:22 AM
  4. How to: Network XP system to system running 2000?
    By Trish in forum Windows Networking
    Replies: 0
    Last Post: July 2nd, 01:23 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139