emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Neil Best <nbest@ci.uchicago.edu>
To: nicholas.dokos@hp.com, emacs-orgmode@gnu.org
Subject: Re: remote execution in heterogeneous environment
Date: Thu, 29 Nov 2012 16:07:30 -0600	[thread overview]
Message-ID: <CANVU8H35vc1bB5Nm3X+AiKM-HHg3DEHRCBoTQdj_6WVooKqSAA@mail.gmail.com> (raw)
In-Reply-To: <11047.1354217134@alphaville>

On Thu, Nov 29, 2012 at 1:25 PM, Nick Dokos <nicholas.dokos@hp.com> wrote:

>
>> But your earlier mail says that it is trying to create the temp file on the remote
>>
>> ,----
>> | > Tramp: Decoding region into remote file
>> | > /ssh:midway:/var/folders/2y/qrw3hhkx0dlb9sbl51mjy5wm0000gn/T/sh-510999vN...done
>> | > byte-code: Couldn't write region to
>> | > `/ssh:midway:/var/folders/2y/qrw3hhkx0dlb9sbl51mjy5wm0000gn/T/sh-510999vN'
>> `----
>>
>> Not sure what causes tramp to use /var/folders/2y for remote temp files
>> but that seems to be the main problem here.
>>
>
> If you evaluate
>
>    (tramp-compat-temporary-file-directory)
>
> on your local system, what do you get?
>

> tramp may be assuming that whatever temp directory you are using
> on your local system should work on the remote as well, an
> assumption that's not true in your case. You may have to provide
> your own function to get around this - or use /tmp just like the
> rest of the world.
>

It's exactly as you suspected, Nick.  That crazy /var/folders/...
value was apparently hard-coded in the value of
temporary-file-directory out of the box.  That must be something that
happens in Macports.  When I changed it to "/tmp" things appear to
work better:

#+BEGIN_SRC sh :dir /midway:~
echo "Executed by `whoami` on `hostname` in `pwd`"
#+END_SRC

#+RESULTS:
: Executed by nbest on lep in /Users/nbest

The temp file problem was preventing any results from appearing, but
now we see that the code is being executed locally, as suspected.
There is a work-around for this, however:  M-x ssh.

#+BEGIN_SRC sh :session *ssh-midway*
echo "Executed by `whoami` on `hostname` in `pwd`"
#+END_SRC

#+RESULTS:
: Executed by nbest on midway-login1 in /pwd/from/that/session

This opens up some possibilities but probably does not address the
shortcomings detailed in the thread that Nick points to.  The elisp
hacking going on there is over my head so I will play with this some
more and watch for updates.

  parent reply	other threads:[~2012-11-29 22:07 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-29 16:48 remote execution in heterogeneous environment Neil Best
2012-11-29 17:05 ` Nick Dokos
2012-11-29 17:16 ` Nick Dokos
2012-11-29 21:48   ` Neil Best
     [not found]   ` <CANVU8H2wkXN90W+C24t75TDVEctGLqYOYi-H7e86_a2OkFFO8Q@mail.gmail.com>
     [not found]     ` <11047.1354217134@alphaville>
2012-11-29 22:07       ` Neil Best [this message]
2012-11-30  7:37 ` Michael Albinus
2012-11-30 15:33   ` Nick Dokos
2012-11-30 17:12     ` Michael Albinus
2012-11-30 18:24       ` Nick Dokos
2012-11-30 19:13         ` Michael Albinus
2012-11-30 18:02   ` Neil Best
2012-11-30 19:22     ` Michael Albinus
2012-11-30 20:13       ` Neil Best
2012-12-01  9:49         ` Michael Albinus
     [not found] <6D36E0F9-01D1-4F95-9FAA-B2B2CA10E57E@gmail.com>
2012-12-18  7:56 ` Michael Albinus
2012-12-20 13:16   ` Michael Albinus
2012-12-20 16:39     ` Bastien
2012-12-20 16:59       ` Achim Gratz
2012-12-20 17:09         ` Nick Dokos
2012-12-20 17:15           ` Bastien
2012-12-20 17:12         ` Bastien
2012-12-20 20:25           ` Achim Gratz
2012-12-20 17:23         ` Michael Albinus
2012-12-20 17:30           ` Bastien
2012-12-21  8:24             ` Michael Albinus
2012-12-21  8:51               ` Bastien
2012-12-21 17:32               ` Nick Dokos
2012-12-21  1:21       ` George Jones
2012-12-21  8:27         ` Michael Albinus
2012-12-22 13:32           ` George
2012-12-22 13:36           ` George
2012-12-22 13:48             ` Michael Albinus
     [not found]               ` <CAOhM7yVOvrL0F8v1hAnxb4z0Mw0kTf6L6_uZk5o7T3W08geUeg@mail.gmail.com>
     [not found]                 ` <CAOhM7yXmD3OEhBt66Ts9YG+8s9LKhkw0-BT0grh734fH07p2pw@mail.gmail.com>
2012-12-23 14:10                   ` Michael Albinus
2012-12-23 15:14                     ` Bastien
2012-12-23 16:09                       ` Michael Albinus
2012-12-23 16:47                         ` Bastien
2012-12-23 17:53                           ` George Jones
2012-12-23 19:54                             ` Bastien
2012-12-23 21:37                               ` George Jones
2012-12-24 13:38                                 ` Michael Albinus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CANVU8H35vc1bB5Nm3X+AiKM-HHg3DEHRCBoTQdj_6WVooKqSAA@mail.gmail.com \
    --to=nbest@ci.uchicago.edu \
    --cc=emacs-orgmode@gnu.org \
    --cc=nicholas.dokos@hp.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).