Hi Leo,
the error message below occurs when the user (say, I)
uses Maxima like
> HOME=SPECIAL_DIR maxima
while it all works when just using
> maxima
So there are no different users involved, and also no ssh
(and it occurs like that on all my different machines).
To be more specific: Being in the maxima installation
directory bin (local installation), it first all works
as expected:
bin> ./rmaxima
;;; Loading #P"/home/csoliver/SAT-Algorithmen/OKplatform/ExternalSources/Installations/Ecl/9.4.1/lib/ecl-9.4.1/defsystem.fas"
;;; Loading #P"/home/csoliver/SAT-Algorithmen/OKplatform/ExternalSources/Installations/Ecl/9.4.1/lib/ecl-9.4.1/cmp.fas"
;;; Loading #P"/home/csoliver/SAT-Algorithmen/OKplatform/ExternalSources/Installations/Ecl/9.4.1/lib/ecl-9.4.1/sysfun.lsp"
Maxima 5.18.1 http://maxima.sourceforge.net
Using Lisp ECL 9.4.1
Distributed under the GNU Public License. See the file COPYING.
Dedicated to the memory of William Schelter.
The function bug_report() provides bug reporting information.
(%i1) plot2d(sin(x),[x,-5,5])$
however now let's redefine HOME to this directory:
Everything else seems to work, but not gnuplot:
bin> HOME=$(pwd) ./rmaxima
;;; Loading #P"/home/csoliver/SAT-Algorithmen/OKplatform/ExternalSources/Installations/Ecl/9.4.1/lib/ecl-9.4.1/defsystem.fas"
;;; Loading #P"/home/csoliver/SAT-Algorithmen/OKplatform/ExternalSources/Installations/Ecl/9.4.1/lib/ecl-9.4.1/cmp.fas"
;;; Loading #P"/home/csoliver/SAT-Algorithmen/OKplatform/ExternalSources/Installations/Ecl/9.4.1/lib/ecl-9.4.1/sysfun.lsp"
Maxima 5.18.1 http://maxima.sourceforge.net
Using Lisp ECL 9.4.1
Distributed under the GNU Public License. See the file COPYING.
Dedicated to the memory of William Schelter.
The function bug_report() provides bug reporting information.
(%i1) plot2d(sin(x),[x,-5,5])$
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified
gnuplot: unable to open display ':0'
gnuplot: X11 aborted.
(%i2) Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified
gnuplot: unable to open display ':0'
gnuplot: X11 aborted.
-----------------------------------------
Just to mention, using "maxima" instead of "rmaxima" doesn't change anything.
Could it then be that somehow gnuplot or whatever is involved
determines the user through his home directory?
Oliver
On Mon, Jun 01, 2009 at 05:03:27PM +0100, Leo Butler wrote:
>
>
> On Mon, 1 Jun 2009, Oliver Kullmann wrote:
>
> < Hi,
> <
> < since in my research platform Maxima needs to run locally,
> < without intrusion of the user space, I needed to do something
> < w.r.t. the .maxima directory, and fortunately redefining the
> < environment variable HOME when calling Maxima does the job!
> <
> < Alas, now I found out that gnuplot (version 4.2.4 or 4.2.5,
> < but apparently this doesn't matter) doesn't work anymore:
> <
> < (%i1) plot2d(sin(x),[x,-5,5])$
> < Xlib: connection to ":0.0" refused by server
> < Xlib: No protocol specified
> < gnuplot: unable to open display ':0'
> < gnuplot: X11 aborted.
>
> Oliver,
> This error message tells you that gnuplot is attempting to open display
> :0, but your xserver is refusing it permission. I suspect that you are
> running maxima in a terminal as a user other than the owner of the
> display.
>
> If you are running maxima as user B, while user A owns the display, then
> user A can enable B's access to the display via
>
> A$ xhost +local:B
>
> (possibly 'localhost', see the man page for xhost; 'A$' is the shell
> prompt for A).
>
> If you are running maxima on a remote machine via ssh, then you need to
> forward the xserver's port. This is done by adding the option '-X', e.g.
>
> ssh user at some.machine.org -X
>
> will open an ssh session for user on some.machine.org and the X
> connection will be forwarded from the remote some.machine.org
> to the local machine.
>
>
> Leo
>
> --
> The University of Edinburgh is a charitable body, registered in
> Scotland, with registration number SC005336.