<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
I usually use TeamViewer for remotely accessing my workstation from my laptop. I have a Mac laptop and a Centos 7 workstation and it works pretty well. I also used to use it with Windows systems. The advantage of TeamViewer is that one can access the whole
 desktop unlike X window forwarding. <br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> 3dem <3dem-bounces@ncmir.ucsd.edu> on behalf of Amar Dhananjai Parvate <aparvate@purdue.edu><br>
<b>Sent:</b> Sunday, February 3, 2019 1:35 PM<br>
<b>To:</b> Michael Elbaum; 3dem@ncmir.ucsd.edu<br>
<b>Subject:</b> Re: [3dem] visualization of data from a remote server</font>
<div> </div>
</div>
<style type="text/css" style="display:none">
<!--
p
        {margin-top:0;
        margin-bottom:0}
-->
</style>
<div dir="ltr">
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Dear All</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
I am very glad to know i am not the only one with remote log in GUI visualization problems and ... even better that ppl on this forum have some solutions. </div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Here is what i am trying to do and of course its not working... </div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
1) My workstation is a linux machine with Centos 7. I can access both single particle and tomography software through my home directory. </div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
2) I have a Windows 10 laptop where i have installed my institute recommended Putty and Xming client for remote login</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
3) While off campus, my VPN works fine, i can log in to my workstation, access home directory and run anything command line properly. </div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<b>4) Issue comes when anything GUI needs to be displayed. </b>I have followed several tutorials for Putty and Xming, tried loging in to the computer via IP or user@home.edu. Have tried several local hosts for X11 forwarding... and it doesnt seem to work. </div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
I have even tried to edit the ssh-config file. where the X11 forwarding is turned off by default.  </div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Basically if i try to open a .mrc file via say 3dmod, i see the file being read in the main window but the connection is refused while displaying the zap window. </div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Be glad if anyone can share any solutions on this regard...</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:EmojiFont,Calibri,Arial,Helvetica,sans-serif,"Apple Color Emoji","Segoe UI Emoji",NotoColorEmoji,"Segoe UI Symbol","Android Emoji",EmojiSymbols; font-size:12pt; color:rgb(0,0,0)">
P.S. - The Putty+X forwarding worked for my colleague who basically has the same laptop as mine, and we are in the same lab, trying to access the same set of imod GUIs.  <span>🤔</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div id="x_signature">
<div id="x_divtagdefaultwrapper" dir="ltr" style="font-size:12pt; color:#000000; background-color:#FFFFFF; font-family:Calibri,Arial,Helvetica,sans-serif">
<p style="margin-top:0px; margin-bottom:0px">Amar Parvate</p>
<p style="margin-top:0px; margin-bottom:0px">Purdue University<br>
</p>
<p style="margin-top:0px; margin-bottom:0px">Department of Biological Sciences</p>
<p style="margin-top:0px; margin-bottom:0px"><br>
</p>
</div>
</div>
<div id="x_appendonsend"></div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="x_divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> 3dem <3dem-bounces@ncmir.ucsd.edu> on behalf of Michael Elbaum <michael.elbaum@weizmann.ac.il><br>
<b>Sent:</b> Sunday, February 3, 2019 10:27 AM<br>
<b>To:</b> 3dem@ncmir.ucsd.edu<br>
<b>Subject:</b> [3dem] visualization of data from a remote server</font>
<div> </div>
</div>
<style type="text/css" id="owaParaStyle">
<!--
p
        {margin-top:0;
        margin-bottom:0}
-->
</style>
<div>
<div style="direction:ltr; font-family:Tahoma; color:#000000; font-size:10pt">
<div style="direction:ltr; font-family:Tahoma; color:#000000; font-size:10pt"><br>
Hi all,<br>
<br>
I'm normally using a powerful server for image processing, and then I look at the data by remote ssh with X forwarding. Recently I upgraded the linux OS on my laptop (to Ubuntu 18.04) and all sorts of programs stopped working this way, including 3dmod. It turned
 out to be a much broader problem having to do with OpenGL. Indirect rendering, which is what we need, is turned off by default in newer versions of X. I assume others have encountered such trouble as well. Since it took quite some digging to find a solution
 I'm posting it here.<br>
<br>
For those who boot into a command line interface with a black screen and start an X session manually, (e.g., startx -- :2) the fix is simple.
<br>
Edit the file /usr/bin/startx and change the line defaultclientargs="" to defaultclientargs="+iglx"<br>
+iglx allows indirect rendering by OpenGL applications.<br>
This is not relevant to most of us.<br>
<br>
For those who boot the computer and expect to see the graphical display right away it's a bit trickier. Ubuntu uses X or Wayland for the graphical interface, depending on the version. The solution I found is only for X, so we have to revert to that first. It's
 done in two steps, as root:<br>
1) In the file /etc/gdm3/custom.conf, uncomment (erase the hash) the line #WaylandEnable=false. (In Ubuntu it should be enough to start GNOME in Xorg, which is one of the login options.)<br>
2) Create a new file /usr/share/X11/xorg.conf.d/50-iglx.conf:<br>
Section "ServerFlags"  <br>
Option "AllowIndirectGLX" "on"  <br>
    Option "IndirectGLX" "on"  <br>
EndSection <br>
Reboot and it should work. at your own risk, of course...<br>
Other distributions might put these files in different places.<br>
<br>
Here are some useful resources:<br>
https://www.visitusers.org/index.php?title=Re-enabling_INdirect_glx_on_your_X_server<br>
https://lists.freedesktop.org/archives/xorg/2016-May/058072.html<br>
https://askubuntu.com/questions/745135/how-to-enable-indirect-glx-contexts-iglx-in-ubuntu-14-04-lts-with-nvidia-gfx/747088<br>
<br>
There seems to be a similar issue with XQuartz on the Mac, which is addressed by reverting to the last version that worked.<br>
<br>
There was another instruction to add in the file /usr/share/lightdm/lightdm.conf.d/50-xserver-command.conf<br>
[SeatDefaults]<br>
# Dump core<br>
xserver-command=X -core +iglx<br>
but this didn't work for me.<br>
<br>
As for Wayland, typing Xwayland -h shows that the options include +iglx, but I wasn't able to find a config file for passing it startup options.<br>
<br>
A longer term solution seems to be VirtualGL or TurboVNC. Does anyone have those working with 3dem visualization software?<br>
<br>
regards,<br>
Michael<br>
</div>
</div>
</div>
</div>
</body>
</html>