From owner-freebsd-questions@freebsd.org Thu May 10 19:42:03 2018 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F3C05FD4809 for ; Thu, 10 May 2018 19:42:02 +0000 (UTC) (envelope-from freebsd@t41t.com) Received: from dot.t41t.com (dot.t41t.com [159.203.61.223]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "digitalocean", Issuer "digitalocean" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 94A3E6B2E9 for ; Thu, 10 May 2018 19:42:02 +0000 (UTC) (envelope-from freebsd@t41t.com) Received: from dot.t41t.com (localhost [127.0.0.1]) by dot.t41t.com (8.15.2/8.15.2) with ESMTPS id w4AJedRH081780 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO) for ; Thu, 10 May 2018 19:40:40 GMT (envelope-from freebsd@t41t.com) Received: (from tait@localhost) by dot.t41t.com (8.15.2/8.15.2/Submit) id w4AJec7n081779 for freebsd-questions@freebsd.org; Thu, 10 May 2018 19:40:38 GMT (envelope-from freebsd@t41t.com) X-Authentication-Warning: dot.t41t.com: tait set sender to freebsd@t41t.com using -f Date: Thu, 10 May 2018 19:40:38 +0000 From: FBUser To: freebsd-questions@freebsd.org Subject: Re: ssh -X remote does not work due to problem with xauth Message-ID: <20180510194038.GE26824@dot.t41t.com> References: <587e3b37-c5c7-4af2-80e2-f7c040a4d221@unixarea.de> <7edbad31-8ac8-9c27-2536-9a9a37a579b6@kicp.uchicago.edu> <20180510150154.GA2699@c720-r314251> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180510150154.GA2699@c720-r314251> User-Agent: Mutt/1.9.1 (2017-09-22) X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 10 May 2018 19:42:03 -0000 Matthias Apitz said (on 2018/05/10): > I do thank for all replies, but have to say, that all ignored the provided > truss output (at least in all replies). Here it is again and shows that > there is a LOCAL problem; the LOCAL /usr/local/bin/xauth tries to > create the LOCAL file /tmp/ssh-adSkh4btDHWr/xauthfile (perhaps to move it over > the SSH channel to the remote end) and it fails doing this: To the contrary... > 2506: openat(AT_FDCWD,"/tmp/ssh-adSkh4btDHWr/xauthfile-c",O_WRONLY|O_CREAT|O_EXCL,0600) = 3 (0x3) A different file was created. > 2506: link("/tmp/ssh-adSkh4btDHWr/xauthfile-c","/tmp/ssh-adSkh4btDHWr/xauthfile-l") = 0 (0x0) A link to that file was successfully created. > 2506: access("/tmp/ssh-adSkh4btDHWr/xauthfile",F_OK) ERR#2 'No such file or directory' > 2506: open("/tmp/ssh-adSkh4btDHWr/xauthfile",O_RDONLY,0666) ERR#2 'No such file or directory' > 2506: access("/tmp/ssh-adSkh4btDHWr/xauthfile",F_OK) ERR#2 'No such file or directory' > 2506: write(2,"/usr/local/bin/xauth: file /tmp/ssh-adSkh4btDHWr/xauthfile does not exist\n",75) = 75 (0x4b) The file didn't exist, it couldn't be read, and it still didn't exist. Then log a complaint. Nothing ever tried to create the file in question. > 2506: access("/tmp/kde-guru/xauth-1001-_0",R_OK) = 0 (0x0) > 2506: open("/tmp/kde-guru/xauth-1001-_0",O_RDONLY,0666) = 4 (0x4) > 2506: write(2,"/usr/local/bin/xauth: (argv):1: ",33) = 33 (0x21) Some KDE-specific file was opened for read... > 2506: lstat("/tmp/ssh-adSkh4btDHWr/xauthfile-c",{ mode=-rw------- ,inode=24961,size=0,blksize=32768 }) = 0 (0x0) > 2506: unlink("/tmp/ssh-adSkh4btDHWr/xauthfile-c") = 0 (0x0) > 2506: lstat("/tmp/ssh-adSkh4btDHWr/xauthfile-l",{ mode=-rw------- ,inode=24961,size=0,blksize=32768 }) = 0 (0x0) > 2506: unlink("/tmp/ssh-adSkh4btDHWr/xauthfile-l") = 0 (0x0) > 2505: unlink("/tmp/ssh-adSkh4btDHWr/xauthfile") ERR#2 'No such file or directory' And after finding the KDE file, the files and links created earlier are discarded. If I were to try something, I'd suggest killing KDE, logging in from the console, and then seeing if you still have the same problem. (Or looking at xauth's source for what it's doing with KDE, and when /tmp/ssh-adSkh4btDHWr/xauthfile was supposed to have been opened with O_CREAT, and why it might not have been.)