Author Topic: segmentation fault  (Read 1223 times)

jjmolina

  • Newbie
  • *
  • Posts: 2
segmentation fault
« on: September 05, 2017, 04:30:47 AM »
Hello,

I recently upgraded to version 2.9.0 (macOS 10.12.6) but Ovito stopped working. Now, I get a segmentation fault when trying to launch the program. I tried reverting to previous versions but the problem persists. I have attached the "Problem report for Ovito" generated by the system.

Any help would be greatly appreciated.

Alexander Stukowski

  • Administrator
  • Sr. Member
  • *****
  • Posts: 398
Re: segmentation fault
« Reply #1 on: September 05, 2017, 10:10:02 AM »
Hi,

i haven't seen this kind of program crash before. The segmentation faults occurs on application startup, inside a function of the Qt library, when OVITO tries to contact the update notification server at www.ovito.org. This part of the program has not been changed for a long time, so it's not surprising that the crash is independent of the OVITO version in use. On the other hand, it remains unclear why you observe this crash now, and never before.

The stack trace indicates that the crash happens in a function named PAC::PACClient::invokeClientCallback(). PAC stands for proxy auto-config. So perhaps you have recently set up the use of a proxy server in the network settings. The error might be related to this bug in the Qt library: https://bugreports.qt.io/browse/QTBUG-56747 But that is only a guess.

You should try this newer build of OVITO 2.9.0, which was compiled against a more recent version of the Qt library:

http://ovito.org/download/testing/ovito-2.9.0-macos-qt5.9.1.dmg

Perhaps it already fixes the issue. Let's keep our fingers crossed.

-Alex

jjmolina

  • Newbie
  • *
  • Posts: 2
Re: segmentation fault
« Reply #2 on: September 05, 2017, 01:24:10 PM »
Hi Alex,

Thank you for the tip! I'm not exactly sure what the problem was, but I deleted the /Library/Preferences/SystemConfiguration folder, rebooted and now Ovito is working again.

John

enriquemasa

  • Newbie
  • *
  • Posts: 6
Re: segmentation fault
« Reply #3 on: October 17, 2017, 05:51:45 PM »
Hi Alex,

I am experiencing the same problem with a new mac desktop with Sierra. I guess I'm going through a proxy but Ovito is working on a different machine with the same settings (as far as I know). I have tried the version you suggested in this post with no luck, and I don't have the folder jjmolina deleted.
Do you happen to have any suggestions? Is there any work around this?

Thanks,
Best,
Enrique

Alexander Stukowski

  • Administrator
  • Sr. Member
  • *****
  • Posts: 398
Re: segmentation fault
« Reply #4 on: October 17, 2017, 07:44:47 PM »
As a workaround, I think the following should work:

  • Open the file $HOME/Library/Preferences/org.ovito.Ovito.plist in a text editor.
  • Look for the line <key>updates.check_for_updates</key>. Change the following line from <true/> to <false/>.

This disables the update check on program startup and Ovito won't access the network anymore.

I keep my eyes open in the hope that the Qt developers will fix this problem soon. I don't think there is any way I can fix this myself in the Ovito code.

Update to the instructions above:
The updates.check_for_updates entry may not exist yet. In this case, simply add the two lines to the config file.
« Last Edit: October 17, 2017, 07:47:32 PM by Alexander Stukowski »

enriquemasa

  • Newbie
  • *
  • Posts: 6
Re: segmentation fault
« Reply #5 on: October 18, 2017, 04:35:55 PM »
Alex,

It seems like that file is not a text file as is now. It was created already but it seems to be a binary file. Should I try to edit it anyways?

Thanks,
Enrique

Alexander Stukowski

  • Administrator
  • Sr. Member
  • *****
  • Posts: 398
Re: segmentation fault
« Reply #6 on: October 18, 2017, 06:41:41 PM »
I am pretty sure it is a text file, despite its unusual filename extension. On macOS, .plist files are XML-based config files.

enriquemasa

  • Newbie
  • *
  • Posts: 6
Re: segmentation fault
« Reply #7 on: October 18, 2017, 07:07:18 PM »
I edited the file that now reads

<key>updates.check_for_updates</key>
<false/>

and try to run Ovito but again it gives me a segfault. Is there a log file that I can check in case is something more specific of this computer?

Thanks,
Enrique

Alexander Stukowski

  • Administrator
  • Sr. Member
  • *****
  • Posts: 398
Re: segmentation fault
« Reply #8 on: October 19, 2017, 07:11:59 PM »
This is surprising. Did you check if the program crash really is due to the same error as jjmolina reported above?

After the Ovito app crashes, a system dialog should appear. Click the "Report" button to see the error log. It should be similar to jjmolina's: 

Code: [Select]
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   org.qt-project.QtNetwork      0x000000010b5c4425 0x10b525000 + 652325
1   com.apple.CFNetwork            0x00007fffad35f5c4 PAC::PACClient::invokeClientCallback() + 102
2   com.apple.CoreFoundation      0x00007fffae0bd321 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17

If it's different, please post the error log here.

enriquemasa

  • Newbie
  • *
  • Posts: 6
Re: segmentation fault
« Reply #9 on: October 19, 2017, 09:09:34 PM »
Yeah, it is pretty similar I think:

Process:               ovito [46194]
Path:                  /Applications/Ovito.app/Contents/MacOS/./ovito
Identifier:            org.ovito
Version:               2.9.0 (2.9.0)
Code Type:             X86-64 (Native)
Parent Process:        bash [36982]
Responsible:           ovito [46194]
User ID:               502

Date/Time:             2017-10-19 13:06:55.951 -0600
OS Version:            Mac OS X 10.12.6 (16G29)
Report Version:        12
Anonymous UUID:        6B2497DC-119D-BF7F-D92D-77FF1A87941A


Time Awake Since Boot: 250000 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       KERN_INVALID_ADDRESS at 0x0000000000000010
Exception Note:        EXC_CORPSE_NOTIFY

Termination Signal:    Segmentation fault: 11
Termination Reason:    Namespace SIGNAL, Code 0xb
Terminating Process:   exc handler


VM Regions Near 0x10:
-->
    __TEXT                 0000000103152000-0000000103156000 [   16K] r-x/rwx SM=COW  /Applications/Ovito.app/Contents/MacOS/ovito

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   org.qt-project.QtNetwork         0x00000001040b9425 0x10401a000 + 652325
1   com.apple.CFNetwork              0x00007fff986945c4 PAC::PACClient::invokeClientCallback() + 102
2   com.apple.CoreFoundation         0x00007fff993f33e1 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
3   com.apple.CoreFoundation         0x00007fff993d465c __CFRunLoopDoSources0 + 556
4   com.apple.CoreFoundation         0x00007fff993d3b46 __CFRunLoopRun + 934
5   com.apple.CoreFoundation         0x00007fff993d3544 CFRunLoopRunSpecific + 420
6   org.qt-project.QtNetwork         0x00000001040b8835 0x10401a000 + 649269
7   org.qt-project.QtNetwork         0x00000001040b9681 QNetworkProxyFactory::systemProxyForQuery(QNetworkProxyQuery const&) + 17
8   org.qt-project.QtNetwork         0x00000001040af383 0x10401a000 + 611203
9   org.qt-project.QtNetwork         0x00000001040b1442 QNetworkProxyFactory::proxyForQuery(QNetworkProxyQuery const&) + 50
10  org.qt-project.QtNetwork         0x000000010404948e 0x10401a000 + 193678
11  org.qt-project.QtNetwork         0x0000000104066889 0x10401a000 + 313481
12  org.qt-project.QtNetwork         0x000000010406b6f3 0x10401a000 + 333555
13  org.qt-project.QtNetwork         0x00000001040633ce 0x10401a000 + 299982
14  org.qt-project.QtNetwork         0x000000010406307b 0x10401a000 + 299131
15  org.qt-project.QtNetwork         0x0000000104047d98 QNetworkAccessManager::createRequest(QNetworkAccessManager::Operation, QNetworkRequest const&, QIODevice*) + 1656
16  org.qt-project.QtNetwork         0x00000001040461be QNetworkAccessManager::get(QNetworkRequest const&) + 30
17  libGui.dylib                     0x000000010316f40b Ovito::ModifyCommandPage::createAboutPanel() + 3467
18  libGui.dylib                     0x000000010316a50a Ovito::ModifyCommandPage::ModifyCommandPage(Ovito::MainWindow*, QWidget*) + 4138
19  libGui.dylib                     0x0000000103168940 Ovito::CommandPanel::CommandPanel(Ovito::MainWindow*, QWidget*) + 192
20  libGui.dylib                     0x0000000103162ffa Ovito::MainWindow::MainWindow() + 3738
21  libGui.dylib                     0x00000001031ef53b Ovito::GuiApplication::startupApplication() + 667
22  libCore.dylib                    0x00000001033c4ad4 Ovito::StandaloneApplication::initialize(int&, char**) + 2932
23  org.ovito                        0x0000000103155c2e main + 142
24  libdyld.dylib                    0x00007fffaef9e235 start + 1

Alexander Stukowski

  • Administrator
  • Sr. Member
  • *****
  • Posts: 398
Re: segmentation fault
« Reply #10 on: October 20, 2017, 09:09:58 AM »
The log certainly shows that my instructions for turning off the network access during program startup did not work for some reason. If you have access to another macOS computer with a working Ovito installation, you can test whether the changes to the .plist settings file take effect. The updates.check_for_updates key in the settings file controls the user option "Auto-refresh news page from web server" in the Ovito application settings dialog. So setting it to false should uncheck the corresponding check box and vice versa.

I uploaded a new dev build of Ovito (3.0.0-dev46) yesterday. The macOS binary is build against the latest version of the Qt library (5.9.2). If you have the time, please try if that makes any difference.

enriquemasa

  • Newbie
  • *
  • Posts: 6
Re: segmentation fault
« Reply #11 on: October 23, 2017, 04:54:33 PM »
This one worked!!!
Thanks a lot

Best,
Enrique

hruzayqa

  • Newbie
  • *
  • Posts: 1
Re: segmentation fault
« Reply #12 on: December 19, 2017, 03:23:26 AM »
Dear Alexander,

I have the same problem on MacOS High Sierra 10.13.1. I tried the dev build 3.0.0-dev46 but still have same problem. I also opened the org.ovito.Ovito.plist  file in a text editor but it only has 2 lines:

bplist00—_installation.idO≈∂Û£ÜkOw1˜xÏ¢+ç∑
0


Any help is appreciated!