Yast in rootless NX nomachine session

Hi, I am having a similar problem to this one NoMachine NX - Support: Trouble Report

It has been reported that by launching an X client (e.g. xterm, xclock, gaim) in a rootless session from an NX Client installed on a 32bit architecture to an NX server installed on a 64bit architecture, the local X server prints the following error in the .xsession-errors file:

*warning: internal X error: BadDrawable (invalid Pixmap or Window parameter) *

  •     Request code: 14 X_GetGeometry *
    
  •     Request minor code: 0 *
    
  •     Resource ID: 0x0 *
    
  •     Error serial: 3258612 *
    

when I launch yast in a Nomachine NX session, yast opens but there are no icons, just an empty form, this happens too when I try to edit the smb.conf file with the sact tool, it opens kwrite with root permission, kwrite opens but there are no icons or content just an empty form, but if I open a root session, there is no problem, yast works just fine, It has nothing to do with the libcairo2 problem, I think it is a permissions problem

if I run yast with a command I get this output

X Error: BadAccess (attempt to access private resource denied) 10
extension: 129 (MIT-SHM)
Minor opcode:: 1 (X_ShmAttach)
resource id: 0x57
X Error: badShmSeg (invalid shared segment parameter) 128
Extension: 129 (MIT-SHM)
Minor opcode: 5 (X_ShmCreatePixmap)
resource id: 0x3800018
X Error: BadDrawable (invalid Pixmap or Window parameter) 9
Major opcode: 62 (X_copyArea)
resource id: 0x3800011

the list is long but repetitive from there

Thanks

Looks like this bug:
https://bugzilla.novell.com/show_bug.cgi?id=807781

It seems to be a bug in libqt4…
I think it is caused by the following change:

Thu Feb 21 09:56:04 UTC 2013 - mvyskocil@suse.com

- fix bnc#802634: information disclosure via QSharedMemory (CVE-2013-0254)
  * libqt4-CVE-2013-0254.patch

which fixes this security issue: [Announce] [CVE-2013-0254] Qt Project Security Advisory: System V shared memory segments created world-writeable](http://lists.qt-project.org/pipermail/announce/2013-February/000023.html)

I have built libqt4-* packages without that patch:
Index of /repositories/home:/wolfi323:/branches:/KDE:/Qt

Please try them and report back whether they work for you!

Yes it worked!!, I enabled your repo and upgraded the following packages

libqt4
libqt4-qt3support
libqt4-sql
libqt4-sql-mysql
libqt4-sql-lite
libqt4-x11

these were the ones that have already been installed

Great! :slight_smile:

I added this information to the bug report.
I would suggest you to join in there…

I can now confirm too that it is only necessary to install the libqt4-x11package to fix the problem in openSUSE 12.3 64 bit

Hi, i know this is an old topic but im on openSUSE 13.2 and im a newbie to all this. How do I go about changing the non bugged version of libqt4-x11 so I can start yast using nomachine? Adding a 12.3 repository to 13.2 just strikes me as a bad idea, wont it downgrade all the other packages as well or…? My understanding of repositories/package management is pretty limited.

This would probably break your system, yes.
And YaST doesn’t use libqt4 at all in 13.2, it has been proted to Qt5 already, so installing a different libqt4-x11 won’t help in the slightest.

I have no idea whether Qt5 has the same problem, maybe you see a completely different issue?

Setting the environment variable QT_X11_NO_MITSHM=1 should workaround this issue as well, but I’m not sure whether this is still supported by Qt5.
But try to run YaST like this:

kdesu QT_X11_NO_MITSHM=1 /sbin/yast2

Does this help?

If not, please run “su -” in a terminal window, run “yast2” and post the output. This should at least tell whether your problem is the same as discussed in this thread.

Thanks for the reply, I tried the first suggestion (just type “kdesu QT_X11_NO_MITSHM=1 /sbin/yast2” into the terminal right?) a window popped up asking for root privileges but after that yast still didnt show up unfortunately.

This is the output from the terminal window when running “yast2” as su.

 max@maxserver:~> su -
Password: 
maxserver:~ # yast2
/sbin/yast2: line 440: 15042 Segmentation fault      $y2ccbin $Y2UI_ARGS "$@"
maxserver:~ # 



Yes. But as I said, I don’t know whether that variable has any effect with Qt5.

This is the output from the terminal window when running “yast2” as su.

 max@maxserver:~> su -
Password: 
maxserver:~ # yast2
/sbin/yast2: line 440: 15042 Segmentation fault      $y2ccbin $Y2UI_ARGS "$@"
maxserver:~ # 

This indicates that you have a completely different problem, not at all related to MITSHM as discussed in this thread.
Please post the last lines of /var/log/YaST2/y2log, and you should probably better open a new thread about your problem.
It does sound like this though:
https://bugzilla.opensuse.org/show_bug.cgi?id=903557

I see, heres the last lines of the log:

2015-01-02 15:31:01 <1> maxserver(15124) [liby2] genericfrontend.cc(main):575 Launched YaST2 component 'y2base' 'menu' 'ncurses'2015-01-02 15:31:01 <1> maxserver(15124) [ui-component] YUIComponentCreator.cc(createInternal):124 Creating UI component for ""
2015-01-02 15:31:01 <1> maxserver(15124) [liby2] genericfrontend.cc(main):764 YAST_IS_RUNNING is yes
2015-01-02 15:31:01 <1> maxserver(15124) [Ruby] yast/wfm.rb:181 Call client /usr/share/YaST2/clients/menu.rb
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YSettings.cc(setProgDir):60 Set progDir to "/usr/share/YaST2"
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YSettings.cc(setProgDir):61 progDir is now locked.
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YSettings.cc(setLocaleDir):146 Set localeDir to "/usr/share/YaST2/locale"
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YSettings.cc(setLocaleDir):147 localeDir is now locked.
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YPath.cc(YPath):49 Given filename: libyui-ncurses.so.6
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YSettings.cc(progDir):73 progDir: "/usr/share/YaST2"
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YPath.cc(YPath):65 Preferring subdir: /usr/share/YaST2
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YPath.cc(YPath):66 Subdir given with filename: 
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YPath.cc(YPath):67 Looking for: libyui-ncurses.so.6
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YPath.cc(lsDir):138 Looking in /usr/lib64/yui
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YPath.cc(YPath):118 Found libyui-ncurses.so.6 in /usr/lib64/yui
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YUI.cc(YUI):76 This is libyui 3.1.4
2015-01-02 15:31:01 <1> maxserver(15124) [ui] YUI.cc(YUI):77 Creating UI with threads
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] YNCursesUI.cc(YNCursesUI):63 Start YNCursesUI
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] YNCursesUI.cc(YNCursesUI):71 getenv LANG: en_GB.UTF-8 encoding: UTF-8
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] YNCursesUI.cc(YNCursesUI):77 setenv LC_CTYPE: en_GB.UTF-8 encoding: UTF-8
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCurses.cc(init):188 Launch NCurses...(ui-ncurses-2.46.6)
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCurses.cc(init):193 TERM=xterm
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCurses.cc(init):206 isatty(stdin)yes
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCurses.cc(init):214 mytty: /dev/pts/1
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCurses.cc(RedirectToLog):560 isatty(stderr)yes
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCurses.cc(RedirectToLog):569 isatty(stdout)yes
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCurses.cc(init):284 have color = 1
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCurses.cc(init):309 screen size 38 x 106
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCstyle.cc(NCstyle):315 Init xterm using color => 4 styles in xterm
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCurses.cc(SetTitle):476 Draw title called
2015-01-02 15:31:01 <1> maxserver(15124) [ncurses] NCurses.cc(init):321 NCurses ready
2015-01-02 15:31:01 <2> maxserver(15124) [ui-shortcuts] YShortcutManager.cc(checkShortcuts):85 Not enough widgets with valid shortcut characters - no check
2015-01-02 15:31:04 <1> maxserver(15124) [ui] YPushButton.cc(setRole):170 Guessing function key F1 for YPushButton "Help" at 0x7fe0fc004f40 from button role YHelpButton
2015-01-02 15:31:04 <3> maxserver(15124) [libycp] clients/menu.rb:214 Unknown option `defaultButton in PushButton widget
2015-01-02 15:31:04 &lt;1&gt; maxserver(15124) [ui] YPushButton.cc(setRole):170 Guessing function key F9 for YPushButton "Quit" at 0x7fe0fc005720 from button role YCancelButton
2015-01-02 15:31:05 &lt;1&gt; maxserver(15124) [ncurses] YNCursesUI.cc(~YNCursesUI):113 Stop YNCursesUI
2015-01-02 15:31:05 &lt;1&gt; maxserver(15124) [ncurses] NCurses.cc(~NCurses):145 Shutdown NCurses...
2015-01-02 15:31:05 &lt;1&gt; maxserver(15124) [ncurses] NCurses.cc(~NCurses):164 NCurses down
2015-01-02 15:31:05 &lt;1&gt; maxserver(15124) [liby2] genericfrontend.cc(main):778 Finished YaST2 component 'y2base'
2015-01-02 15:31:05 &lt;1&gt; maxserver(15124) [liby2] genericfrontend.cc(main):783 Exiting with client return value 'nil'
2015-01-02 15:31:06 &lt;1&gt; maxserver(15124) [Y2Ruby] binary/YRuby.cc(~YRuby):107 Shutting down ruby interpreter.
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [liby2] genericfrontend.cc(main):575 Launched YaST2 component 'y2base' 'menu' 'ncurses'
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui-component] YUIComponentCreator.cc(createInternal):124 Creating UI component for ""
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [liby2] genericfrontend.cc(main):764 YAST_IS_RUNNING is yes
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [Ruby] yast/wfm.rb:181 Call client /usr/share/YaST2/clients/menu.rb
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YSettings.cc(setProgDir):60 Set progDir to "/usr/share/YaST2"
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YSettings.cc(setProgDir):61 progDir is now locked.
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YSettings.cc(setLocaleDir):146 Set localeDir to "/usr/share/YaST2/locale"
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YSettings.cc(setLocaleDir):147 localeDir is now locked.
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YPath.cc(YPath):49 Given filename: libyui-ncurses.so.6
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YSettings.cc(progDir):73 progDir: "/usr/share/YaST2"
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YPath.cc(YPath):65 Preferring subdir: /usr/share/YaST2
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YPath.cc(YPath):66 Subdir given with filename: 
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YPath.cc(YPath):67 Looking for: libyui-ncurses.so.6
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YPath.cc(lsDir):138 Looking in /usr/lib64/yui
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YPath.cc(YPath):118 Found libyui-ncurses.so.6 in /usr/lib64/yui
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YUI.cc(YUI):76 This is libyui 3.1.4
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ui] YUI.cc(YUI):77 Creating UI with threads
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] YNCursesUI.cc(YNCursesUI):63 Start YNCursesUI
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] YNCursesUI.cc(YNCursesUI):71 getenv LANG: en_GB.UTF-8 encoding: UTF-8
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] YNCursesUI.cc(YNCursesUI):77 setenv LC_CTYPE: en_GB.UTF-8 encoding: UTF-8
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCurses.cc(init):188 Launch NCurses...(ui-ncurses-2.46.6)
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCurses.cc(init):193 TERM=xterm
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCurses.cc(init):206 isatty(stdin)yes
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCurses.cc(init):214 mytty: /dev/pts/1
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCurses.cc(RedirectToLog):560 isatty(stderr)yes
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCurses.cc(RedirectToLog):569 isatty(stdout)yes
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCurses.cc(init):284 have color = 1
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCurses.cc(init):309 screen size 38 x 106
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCstyle.cc(NCstyle):315 Init xterm using color =&gt; 4 styles in xterm
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCurses.cc(SetTitle):476 Draw title called
2015-01-02 15:31:08 &lt;1&gt; maxserver(15149) [ncurses] NCurses.cc(init):321 NCurses ready
2015-01-02 15:31:08 &lt;2&gt; maxserver(15149) [ui-shortcuts] YShortcutManager.cc(checkShortcuts):85 Not enough widgets with valid shortcut characters - no check
2015-01-02 15:31:10 &lt;1&gt; maxserver(15149) [ui] YPushButton.cc(setRole):170 Guessing function key F1 for YPushButton "Help" at 0x7f2580004f40 from button role YHelpButton
2015-01-02 15:31:10 &lt;3&gt; maxserver(15149) [libycp] clients/menu.rb:214 Unknown option `defaultButton in PushButton widget
2015-01-02 15:31:10 <1> maxserver(15149) [ui] YPushButton.cc(setRole):170 Guessing function key F9 for YPushButton "Quit" at 0x7f2580005720 from button role YCancelButton
2015-01-02 15:31:12 <1> maxserver(15149) [ncurses] YNCursesUI.cc(~YNCursesUI):113 Stop YNCursesUI
2015-01-02 15:31:12 <1> maxserver(15149) [ncurses] NCurses.cc(~NCurses):145 Shutdown NCurses...
2015-01-02 15:31:12 <1> maxserver(15149) [ncurses] NCurses.cc(~NCurses):164 NCurses down
2015-01-02 15:31:12 <1> maxserver(15149) [liby2] genericfrontend.cc(main):778 Finished YaST2 component 'y2base'
2015-01-02 15:31:12 <1> maxserver(15149) [liby2] genericfrontend.cc(main):783 Exiting with client return value 'nil'
2015-01-02 15:31:12 <1> maxserver(15149) [Y2Ruby] binary/YRuby.cc(~YRuby):107 Shutting down ruby interpreter.

Hm, I only see ncurses mentioned in there. The ncurses version doesn’t use Qt at all.
And I don’t even see any problem in there.
Did it work now or does not even the text mode version start?

Try to run “kdesu /sbin/yast2 --qt” or just “/sbin/yast2 --qt” after “su -”, and then post the last lines of the log again.

The text version has always worked thankfully, whoever thought that up was a genius lol!

This is what I get when I try the commands, the first command shows a password prompt like this:
http://i.imgur.com/ms3ecAU.png

I give it the password but then nothing happens:
http://i.imgur.com/NcJJQRh.png

The second command didnt work, it didnt like “–qt” for some reason.

max@maxserver:~> kdesu /sbin/yast2 --qt
max@maxserver:~> su - /sbin/yast2 --qt
su: unrecognized option '--qt'


Usage:
 su [options] -] <user> <argument>...]]


Change the effective user ID and group ID to that of <user>.
A mere - implies -l.  If <user> is not given, root is assumed.


Options:
 -m, -p, --preserve-environment  do not reset environment variables
 -g, --group <group>             specify the primary group
 -G, --supp-group <group>        specify a supplemental group


 -, -l, --login                  make the shell a login shell
 -c, --command <command>         pass a single command to the shell with -c
 --session-command <command>     pass a single command to the shell with -c
                                   and do not create a new session
 -f, --fast                      pass -f to the shell (for csh or tcsh)
 -s, --shell <shell>             run <shell> if /etc/shells allows it


 -h, --help     display this help and exit
 -V, --version  output version information and exit


For more details see su(1).
max@maxserver:~> 




Strangely enough there are no new entries in the log at all:

http://i.imgur.com/yLbDmM3.png

Yes, it’s nice to be able to still use YaST in text mode as well…

The second command didnt work, it didnt like “–qt” for some reason.

max@maxserver:~> kdesu /sbin/yast2 --qt
max@maxserver:~> su - /sbin/yast2 --qt
su: unrecognized option '--qt'
...

You have to press Return after “su -” and then run “/sbin/yast2 --qt”.

Strangely enough there are no new entries in the log at all:

http://i.imgur.com/yLbDmM3.png

Hm. Then yast apparently does not even try to start…
Try the second command again to see whether this produces something in the log. If not, then YaST seems to crash before it even opens the log, which I would find extremely strange.

Just to be sure, please also post your repo list and the installed YaST UI packages:

zypper lr -d
rpm -qa libyui*

Still no change in the log:
http://i.imgur.com/X1BRj4l.png

I closed the log when I ran the command just in case that would affect it being changed. Dunno if I mentioned but yast does work as long as its not done via nomachine, if I plug in a screen and open it that way its fine.

maxserver:~ # zypper lr -d# | Alias                     | Name                               | Enabled | Refresh | Priority | Type   | URI                                                             | Service
--+---------------------------+------------------------------------+---------+---------+----------+--------+-----------------------------------------------------------------+--------
1 | openSUSE-13.2-0           | openSUSE-13.2-0                    | No      | No      |   99     | yast2  | hd:///?device=/dev/disk/by-id/scsi-1Flash.Drive.....2.00-part2  |        
2 | repo-debug                | openSUSE-13.2-Debug                | No      | Yes     |   99     | NONE   | http://download.opensuse.org/debug/distribution/13.2/repo/oss/  |        
3 | repo-debug-update         | openSUSE-13.2-Update-Debug         | No      | Yes     |   99     | NONE   | http://download.opensuse.org/debug/update/13.2/                 |        
4 | repo-debug-update-non-oss | openSUSE-13.2-Update-Debug-Non-Oss | No      | Yes     |   99     | NONE   | http://download.opensuse.org/debug/update/13.2-non-oss/         |        
5 | repo-non-oss              | openSUSE-13.2-Non-Oss              | Yes     | Yes     |   99     | yast2  | http://download.opensuse.org/distribution/13.2/repo/non-oss/    |        
6 | repo-oss                  | openSUSE-13.2-Oss                  | Yes     | Yes     |   99     | yast2  | http://download.opensuse.org/distribution/13.2/repo/oss/        |        
7 | repo-source               | openSUSE-13.2-Source               | No      | Yes     |   99     | NONE   | http://download.opensuse.org/source/distribution/13.2/repo/oss/ |        
8 | repo-update               | openSUSE-13.2-Update               | Yes     | Yes     |   99     | rpm-md | http://download.opensuse.org/update/13.2/                       |        
9 | repo-update-non-oss       | openSUSE-13.2-Update-Non-Oss       | Yes     | Yes     |   99     | rpm-md | http://download.opensuse.org/update/13.2-non-oss/               |        
maxserver:~ # rpm -qa libyui*
libyui6-3.1.4-1.8.x86_64
libyui-qt-graph6-2.44.2-2.1.10.x86_64
libyui-ncurses-pkg6-2.46.1-2.1.9.x86_64
libyui-qt-pkg6-2.44.7-1.8.x86_64
libyui-ncurses6-2.46.6-2.1.9.x86_64
libyui-qt6-2.46.13-2.1.9.x86_64
maxserver:~ #