RubyMine 1.0.5: Remote debugging

One of the new features of RubyMine 1.0.5, released yesterday, is remote debugging support. Here’s a small guide for using this feature:

  1. Create new remote debug run configuration. Run Configuration Parameters
  2. Specify remote host and remote port to connect to. Ensure your firewall doesn’t block connections at given port.
  3. Specify Remote root folder and Local root folder options.These options will be used for sources mapping on remote and local machines. If root folders selected are incorrect, the debugger will connect but no breakpoints will be reached.
  4. Run rdebug-ide –port SELECTED_PORT — SCRIPT on the server side

We are ready to start.  Launch created remote debug run configuration and explore what’s happening on the remote machine!

-JetBrains RubyMine Team

This entry was posted in Feature and tagged . Bookmark the permalink.

8 Responses to RubyMine 1.0.5: Remote debugging

  1. Kevin Menard says:

    Is there an easy way to debug out of process rake tasks? I’d like to debug tests as they run through rake, since sometimes there’s different execution behavior than there is in RubyMine.

  2. Oleg Shpynov says:

    Hello Kevin,
    When you run rake task inside RubyMine it creates correspoding run configuration, so you should go to run configurations editor, save it and debug.
    Hope this helps

  3. Pingback: JetBrains RubyMine Blog » Blog Archive » RubyMine 1.1 RC

  4. Gary Taylor says:

    I tried this – but when I run the configuration, rdebug-ide exits and displays the following ‘Uncaught exception: no such file to load — $
    ‘. I am literally typing in the command shown by the IDE which is ‘rdebug-ide –port 1234 — $SCRIPT$’.

    Can anyone help with this please ?

    Many Thanks

    Gary

  5. Oleg Shpynov says:

    Hello Gary,
    Please replace $SCRIPT$ to path of the script you want to debug.

  6. Dave says:

    What about this error? Any thoughts?

    #1 – I don’t have rdebug-ide, just rdebug. No gems appear available
    #2 – when I execute this:

    $ rdebug –port 9000 — source_tree
    ruby: Is a directory – /home//source_tree (Errno::EISDIR)

    Thoughts?

  7. Oleg Shpynov says:

    Hi Dave,

    Rdebug-ide gem is required fom debugging within RubyMine.
    Please use for installation:
    gem install ruby-debug-ide

    The latest argument should be your script you want do debug remotely.

  8. yon says:

    Just a tip for anyone looking for it.
    If you can’t seem to be able to connect to the remote server (10 sec thingie)
    just add -host 0.0.0.0 to the command that will make the rdebug-ide listen to request from all machines.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>