unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: merlyn@stonehenge.com (Randal L. Schwartz)
Cc: emacs-devel@gnu.org
Subject: Re: Tramp Mode not working connecting to OpenSolaris
Date: Wed, 10 Mar 2010 21:20:05 +0100	[thread overview]
Message-ID: <87y6i0ornu.fsf@gmx.de> (raw)
In-Reply-To: <864okodryx.fsf@blue.stonehenge.com> (Randal L. Schwartz's message of "Wed, 10 Mar 2010 09:08:54 -0800")

merlyn@stonehenge.com (Randal L. Schwartz) writes:

> Michael> The following patch shall remove the right "exec":
>
> I did that (by hand) already, similar result.  Do you want the trace?

Nope, I believe you. It does not go this way. Please revert the previous
patch.

Let's assume, the default shell in OpenSolaris is buggy. It's not the
first time, Tramp is confronted by this. Consequently, we shall use
another shell like bash, instead of applying several workarounds for
those bugs. The appended patch does exactly this. Note that I couldn't
test it with a remote OpenSolaris machine ...

Before you test this, you must call "M-x tramp-cleanup-all-connections".
This flushes Tramp's caches, which is necessary.

--8<---------------cut here---------------start------------->8---
*** /tmp/ediff3714iRe	2010-03-10 21:07:27.054171338 +0100
--- /home/albinus/src/emacs/lisp/net/tramp.el	2010-03-10 21:06:13.924172486 +0100
***************
*** 6403,6414 ****
        (with-current-buffer (tramp-get-buffer vec)
  	(tramp-send-command vec "echo ~root" t)
  	(cond
! 	 ((string-match "^~root$" (buffer-string))
  	  (setq shell
  		(or (tramp-find-executable
! 		     vec "bash" (tramp-get-remote-path vec) t)
  		    (tramp-find-executable
! 		     vec "ksh" (tramp-get-remote-path vec) t)))
  	  (unless shell
  	    (tramp-error
  	     vec 'file-error
--- 6403,6417 ----
        (with-current-buffer (tramp-get-buffer vec)
  	(tramp-send-command vec "echo ~root" t)
  	(cond
! 	 ((or (string-match "^~root$" (buffer-string))
! 	      ;; The default shell (ksh93) of OpenSolaris is buggy.
! 	      (string-equal (tramp-get-connection-property vec "uname" "")
! 			    "SunOS 5.11"))
  	  (setq shell
  		(or (tramp-find-executable
! 		     vec "bash" (tramp-get-remote-path vec) t t)
  		    (tramp-find-executable
! 		     vec "ksh" (tramp-get-remote-path vec) t t)))
  	  (unless shell
  	    (tramp-error
  	     vec 'file-error
***************
*** 6851,6858 ****
    ;; On OpenSolaris, there is a bug when HISTFILE is changed in place
    ;; <http://bugs.opensolaris.org/view_bug.do?bug_id=6834184>.  We
    ;; apply the workaround.
!   (if (string-equal (tramp-get-connection-property vec "uname" "") "SunOS 5.11")
!       (tramp-send-command vec "unset HISTFILE" t))
  
    (let ((env (copy-sequence tramp-remote-process-environment))
  	unset item)
--- 6854,6861 ----
    ;; On OpenSolaris, there is a bug when HISTFILE is changed in place
    ;; <http://bugs.opensolaris.org/view_bug.do?bug_id=6834184>.  We
    ;; apply the workaround.
!   ;(if (string-equal (tramp-get-connection-property vec "uname" "") "SunOS 5.11")
!   ;(tramp-send-command vec "unset HISTFILE" t))
  
    (let ((env (copy-sequence tramp-remote-process-environment))
  	unset item)
--8<---------------cut here---------------end--------------->8---

Best regards, Michael.




  reply	other threads:[~2010-03-10 20:20 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-05 22:15 tramp mode not working on OSX with dev HEAD Randal L. Schwartz
2010-03-06  8:03 ` Michael Albinus
2010-03-07 22:39   ` Randal L. Schwartz
2010-03-08  8:00     ` Michael Albinus
2010-03-08 15:24       ` Randal L. Schwartz
2010-03-08 16:58         ` Michael Albinus
2010-03-08 17:03           ` Randal L. Schwartz
2010-03-08 17:19             ` Michael Albinus
2010-03-08 17:40               ` Tramp Mode not working connecting to OpenSolaris (was Re: tramp mode not working on OSX with dev HEAD) Randal L. Schwartz
2010-03-08 17:48                 ` Tramp Mode not working connecting to OpenSolaris Randal L. Schwartz
2010-03-08 18:11                   ` David Kastrup
2010-03-08 21:38                     ` Michael Albinus
2010-03-08 21:35                 ` Michael Albinus
2010-03-08 21:43                   ` Randal L. Schwartz
2010-03-09  6:34                     ` Michael Albinus
2010-03-09 15:49                       ` Randal L. Schwartz
2010-03-09 15:51                       ` Randal L. Schwartz
2010-03-10 17:04                         ` Michael Albinus
2010-03-10 17:08                           ` Randal L. Schwartz
2010-03-10 20:20                             ` Michael Albinus [this message]
2010-03-11 16:53                               ` Randal L. Schwartz
2010-03-11 17:53                                 ` Davis Herring
2010-03-11 17:58                                   ` Randal L. Schwartz
2010-03-11 19:37                                     ` Michael Albinus
2010-03-11 19:49                                       ` Randal L. Schwartz
2010-03-11 20:11                                         ` Michael Albinus
2010-03-11 21:21                                           ` Randal L. Schwartz
2010-03-12  5:38                                             ` Michael Albinus
2010-03-12 16:24                                               ` Chong Yidong
2010-03-13 19:34                                                 ` Michael Albinus
2010-03-13 19:56                                                   ` Stefan Monnier
2010-03-14 18:35                                               ` Randal L. Schwartz
2010-03-14 18:51                                                 ` Michael Albinus
2010-03-15  0:03                                                   ` Randal L. Schwartz
2010-03-09 21:26           ` tramp mode not working on OSX with dev HEAD Andreas Schwab

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.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=87y6i0ornu.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=emacs-devel@gnu.org \
    --cc=merlyn@stonehenge.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.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).