0

Okay so I'm very new at all of this so please forgive me if I don't provide enough information but feel free to ask for more.

I had to install ParaView from source on my linux system. ParaView requires Qt to be installed to be able to compile and install it. So I installed Qt on my linux system from source as well (version 4.8.6 to be precise). My ParaView is now installed but I can't seem to run it. The first time I tried I got the following output:

QWSSocket::connectToLocalFile could not connect:: Connection refused
QWSSocket::connectToLocalFile could not connect:: Connection refused
QWSSocket::connectToLocalFile could not connect:: Connection refused
QWSSocket::connectToLocalFile could not connect:: Connection refused
QWSSocket::connectToLocalFile could not connect:: Connection refused
QWSSocket::connectToLocalFile could not connect:: Connection refused
No Qt for Embedded Linux server appears to be running.
If you want to run this program as a server,
add the "-qws" command-line option.

When I ran it as sudo, I got the following output:

Qt for Embedded Linux data directory is not owned by user 0:  /tmp/qtembedded-0

I have no idea what this means or how to fix it, any help will be much appreciated.

Extra info: I installed ParaView version 4.4

my Qt dir is /usr/local/Trolltech/QtEmbedded-4.8.6/bin

my ParaView dir is /usr/local/bin

I couldn't find anything on google or on here and that's why I'm asking.

Murphy
  • 3,827
  • 4
  • 21
  • 35
Xentro
  • 35
  • 1
  • 7
  • No idea why you are doing all that, you do not need to compile ParaView to use it, nor do you need to compile Qt to compile ParaView, but in any case, you are using outdated software. ParaView 5.8.0 is out, Qt 5.14 is out. Update. – Mathieu Westphal May 27 '20 at 02:56

3 Answers3

0

If you want to run this program as a server, add the "-qws" command-line option.

You really need this; append it to the line where you call your binary. When trying to start it on a machine that runs X11 you'll need QVFb installed and running, too, plus support for it (graphics, mouse and keyboard) compiled into the Qt libs.

I strongly advise against starting with root privileges.

Murphy
  • 3,827
  • 4
  • 21
  • 35
  • I'm guessing you mean something like this: sudo paraview -qws When I try this, it gives the same output. – Xentro Feb 28 '16 at 13:50
  • No, I mean without `sudo`, just as you did at the first try. – Murphy Feb 28 '16 at 13:52
  • That gives me this output: `Qt for Embedded Linux data directory has incorrect permissions: /tmp/qtembedded-0 Aborted (core dumped)` – Xentro Feb 28 '16 at 13:53
  • Try to remove the dir, this time using `sudo`, to force it to be created with correct permissions; they've probably been messed up by your previous attempts. – Murphy Feb 28 '16 at 13:55
  • This returns `QScreenLinuxFb::connect: Permission denied Error opening framebuffer device /dev/fb0 ` a few times and then `Segmentation fault (core dumped) ` – Xentro Feb 28 '16 at 14:02
  • This is a different problem, concerning either the group membership of the user you start it with, or FB support in general. You may try it with `sudo` to check if root permissions solve it, but I strongly advise against running it as root by default; add the user to the correct group instead. See that link for possible solutions: https://forum.qt.io/topic/45598/solved-framebuffer-issue-while-running-the-qt-application – Murphy Feb 28 '16 at 14:06
  • changing permissions, removing the directory again and trying to run it again gave me [this](http://imgur.com/A5oTEse) EDIT: I got the same output with `sudo` before paraview -qws – Xentro Feb 28 '16 at 14:13
  • Oh, you're running the app on a desktop/X11 machine? You'll need [QVFb](http://doc.qt.io/qt-4.8/qvfb.html) installed and running in this case. Please open a new question if you've got problems with that, it's going out of scope here. – Murphy Feb 28 '16 at 14:17
  • Thanks a lot, so as far as I understand (which isn't very far) the program couldn't open because it was trying to write inside the framebuffer of my linux instead of the virtual one from Qt? I'm recompiling Qt to work with QVFb, will I need to reinstall my ParaView as well or just open the QVFb and then run the application like I tried before? – Xentro Feb 28 '16 at 14:40
  • It should work as soon as you add the QVFb support to the libs, if that's the only graphics output driver you included there, else an environment variable has to be set to select the driver to use. And don't forget to check for the appropriate input drivers (mouse and keyboard), too. The QWS serves as abstraction layer and will handle the I/O with the underlying system; you should read about it in the docs if you need to know the hairy details. – Murphy Feb 28 '16 at 14:46
0

It seems that you ran the application under the user, then killed it, switched to root and tried to run it again. You can just remove the temporary folder. rm -rf /tmp/qtembedded-0

  • Why do you think he started as a user and switched to root? Also, please edit your code to look like code. – Uberhumus May 26 '20 at 15:30
0

I just removed

rm -rf /tmp/qtembedded-0

and then restarted the framebuffer and it works for me.

Mistake: I changed the permission of /tmp/qtembedded-0 while framebuffer was running.

SayAz
  • 751
  • 1
  • 9
  • 16