MATLAB Answers

Why is MATLAB unable to run the MATLABWindow application on Linux?

조회 수: 685(최근 30일)
Why is MATLAB unable to run the MATLABWindow application on Linux, with the following warning?
>> simulink
Warning: MATLABWindow application failed to launch. Unable to launch the MATLABWindow application

채택된 답변

MathWorks Support Team
편집: MathWorks Support Team 28 Aug 2018
NOTE: In the instructions below we use the phrase "_set aside_ somelibrary.so" a couple of times, this does not mean only moving somelibrary.so itself, it means moving all files which start with somelibrary.so, so for example also somelibrary.so.1, somelibrary.so.1.0, etc. Scroll down to the bottom of this answer to see example Linux shell commands which use the * wildcard with which you can easily move all those files starting with a particular name.
Due to some library compatibility issues, MATLAB may not be able to launch MATLABWindow on your particular distribution/version of Linux. Here are some steps to detect and work around the incompatibility.
In MATLAB:
>> cd(matlabroot)
>> ! bin/glnxa64/MATLABWindow
----------------
1)
If you see:
bin/glnxa64/MATLABWindow: error while loading shared libraries: libgconf-2.so.4: cannot open shared object file: No such file or directory
Then you should:
This is a known Ubuntu issue. As root:
# apt-get install libgconf-2-4
----------------
2)
If you see:
bin/glnxa64/MATLABWindow: symbol lookup error: _somelibrary_: undefined symbol: g_log_structured
or
bin/glnxa64/MATLABWindow: symbol lookup error: _somelibrary_: undefined symbol: g_log_structured_standard
Then you should:
Set aside MATLAB’s copy of the libglib-2.0.so library, located in <matlabroot>/cefclient/sys/os/glnxa64.
See instructions below.
----------------
3)
If you see:
bin/glnxa64/MATLABWindow: symbol lookup error: _somelibrary_: undefined symbol: FT_Get_Var_Blend_Coordinates
or
bin/glnxa64/MATLABWindow: symbol lookup error: _somelibrary_: undefined symbol: FT_Done_MM_Var
Then you should:
Set aside MATLAB’s copy of the libfreetype.so.6 library, located in <matlabroot>/bin/glnxa64.
See instructions below.
----------------
4)
If you see:
bin/glnxa64/MATLABWindow: path to/libstdc++.so.6: version `CXXABI_1.3.9' not found (required by _somelibrary_)
Then you should:
Set aside MATLAB’s copy of the libstdc++.so.6 library, located in <matlabroot>/sys/os/glnxa64
See instructions below
----------------
5)
If you see:
A mini-browser window appears showing www.mathworks.com
Then you should:
Close the mini-browser. MATLABWindows is working.
----------------
To set aside MATLAB’s copy of the libstdc++.so.6 library (for example), please navigate to MATLAB R2017b installation location in your system and remove the “libstdc++.so.6” library file shipped with MATLAB R2017b, so that MATLAB will use the system version of that library:
<matlabroot>/sys/os/glnxa64
Note: Here <matlabroot> is the location in your system where MATLAB R2017b is installed.
Eg: ‘/usr/local/MATLAB/R2017B’.
Following are the commands to execute in linux shell to perform the above mentioned operation: (You may need root privilege)
# cd /usr/local/MATLAB/R2017b (or wherever you may have installed MATLAB)
# cd cefclient/sys/os/glnxa64 (or whichever directory is indicated in above table)
# mkdir exclude
# mv libglib-2.0.so* exclude/ (or whichever library is indicated in above table)

  댓글 수: 27

표시 이전 댓글 수: 24
Greg
Greg 23 Sep 2020
Walter, my apologies - I attributed my specific situation to the comments posts from Jasper Vinkenvleugel and John Bollinger. They had the same library conflict I do, so I mistakenly assumed it was also occuring during install. For me, it is indeed happening within the install script provided for Linux distributions.
The update edit paragraph in my previous comment is the current behavior on my RHEL 8.2 system. Amusingly enough, shortly after that post, I tried running the silent install per installer_input.txt. It appears to have work beautifully (but I haven't tried to run any code to see if there are additional downstream issues).
Antonio Francino
Antonio Francino 17 Nov 2020
I run Pop!_OS 20.10
The error msg when trying MATLABWindow was not listed:
"bin/glnxa64/MATLABWindow: error while loading shared libraries: libgcrypt.so.11: cannot open shared object file: No such file or directory "
What library should be set aside ?
These are all the libraries in (matlabroot)/sys/os/glnxa64 :
libgcc_s.so.1.bak libirc.so libgfortran.so.3 libquadmath.so.0.0.0 libgfortran.so.3.0.0 libquadmath.so.0.bak libifcore.so.5 libstdc++.so.6.0.17 libifport.so.5 libstdc++.so.6.bak libimf.so
libsvml.so libintlc.so.5 README.libstdc++
Any fix ?

댓글을 달려면 로그인하십시오.

추가 답변(8개)

Ion Lazar
Ion Lazar 23 Apr 2018
This worked for me, thank you.

  댓글 수: 0

댓글을 달려면 로그인하십시오.


Jeff Mandel
Jeff Mandel 10 Oct 2020
The problem is that MATLABWindow uses the Chromium browser. If you are trying to use this on a headless server (in my case Ubuntu Server 18.04), none of the libraries have been installed. The simple solution is to install Chromium:
sudo apt-get install chromium-browser
I can now install things like MATLAB-Drive on my server through my X-server.

  댓글 수: 0

댓글을 달려면 로그인하십시오.


József Mózer
József Mózer 8 Jan 2021
I had an error that was not documented on support pages at all, but was very similar to this one. It propped up after I solved issue number 2 in this thread when attempting to launch Simulink.
This solution worked for me on R2019b, but since the issue is consistent it should work with all recent MATLAB releases as well as all Linux distributions. As it turns out, there has been a problem with the Add-on Manager of MATLAB for a while now, causing these issues. Here's the solution in case you don't want to read the details. Also it is uncessary to redirect the symlinks as described on the Wiki, it is enough to exclude them from the matlabroot folder so MATLAB will use system-defaults.
Here's the process, run commands as root when prompted:
cd /usr/local/MATLAB/R2019b/cefclient/sys/so/glnxa64 # default location for this
mkdir exclude
Now enter the commands to remove the symlinks causing the errors.
mv libgio-2.0.so* exclude
mv libglib-2.0.so* exclude
mv libgmodule-2.0.so* exclude
mv libgobject-2.0.so* exclude
mv libgthread-2.0.so* exclude
Your problem should be solved. This shouldn't break anything either, since more up-to-date system defaults exist for these libs. You should also make a README file, so you know what you did and why in case you need to come back a year later or something.
I would also like to state, that I am severely disappointed in MATLAB and Mathworks. Providing a .zip file for installation on systems with very well made package management is dumb and annoying. Shipping an expensive piece of commercial software on an operating system claiming it works, while it needs workarounds is straight up outrageous.

  댓글 수: 1

Matthew Mione
Matthew Mione 12 Jan 2021
This solved the issue for me--I had done something similar to this fix earlier when trying to get Simulink working after an installation of MATLAB on Ubuntu 20.04. It broke again, and this fixed the issue,

댓글을 달려면 로그인하십시오.


aleper
aleper 8 Mar 2018
I am facing a similar problem, but with a different library.
This is my error code when I am trying to start SIMULINK:
Warning: MATLABWindow application failed to launch. Unable to launch the MATLABWindow application
> In sltemplate.ui.StartPage/showWithFallback
In sltemplate.ui.StartPage.show
and after running:
>> cd(matlabroot)
>> ! bin/glnxa64/MATLABWindow
i get:
bin/glnxa64/MATLABWindow: symbol lookup error: /usr/lib/libharfbuzz.so.0: undefined symbol: FT_Done_MM_Var
Thank you in advance!

  댓글 수: 2

Tim Hilt
Tim Hilt 9 Mar 2018
Exactly the same thing as with user above is happening for me. Same Matlab- and Command-Output! Any help or recommendation will be greatly appreciated, since there seems to be no other Post regarding this particular Issue.
bb
bb 24 Mar 2018
Hi,
link seems to solve this problem.
Best regards

댓글을 달려면 로그인하십시오.


Hariprasad
Hariprasad 11 Apr 2018
I tried
>> ! bin/glnxa64/MATLABWindow
and I got error
-bash: bin/glnxa64/MATLABWindow: No such file or directory
What is wrong here? I'm running Matlab R2018a on Centos 6.9 on EC2 instance

  댓글 수: 2

Winston Yu
Winston Yu 17 Aug 2018
don't skip the first command: cd(matlabroot)

댓글을 달려면 로그인하십시오.


Tech Support
Tech Support 13 Apr 2018
편집: MathWorks Support Team 1 Feb 2021
Hi,
If you are still experiencing this issue, please contact MathWorks support:
-Justin

  댓글 수: 1

Rogier Delporte
Rogier Delporte 13 Mar 2019
I'm still experiencing a similar issue (where I cannot enter any text into textboxes to e.g. log in or use the add-on explorer) and I got none of the errors above. All the output I got while trying to log in after executing the command
!./MATLABWindow -url=http://mathworks.com --disable-gpu
was:
GLib-GIO-[1;32mMessage[0m: [34m10:42:41.753[0m: Using the 'memory' GSettings backend. Your settings will not be saved or shared with other applications.
[0313/104241.758859:ERROR:nss_util.cc(802)] After loading Root Certs, loaded==false: NSS error code: -8018
[0313/104241.814138:INFO:client_handler.cpp(150)] OnBeforeResourceLoad http://mathworks.com/
[0313/104242.122176:INFO:client_handler.cpp(150)] OnBeforeResourceLoad http://www.mathworks.com/
[0313/104242.156209:INFO:client_handler.cpp(150)] OnBeforeResourceLoad https://www.mathworks.com/
[0313/104242.224884:INFO:client_handler.cpp(162)] OnResourceResponse https://www.mathworks.com/
[0313/104242.229007:INFO:client_handler.cpp(481)] OnLoadStart
A Parser-blocking, cross site (i.e. different eTLD+1) script, https://assets.adobedtm.com/d0cc0600946eb3957f703b9fe43c3590597a8c2c/mbox-contents-95c6a4d9c82a8d20476522984666120b54192e9b.js, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.
A Parser-blocking, cross site (i.e. different eTLD+1) script, https://assets.adobedtm.com/d0cc0600946eb3957f703b9fe43c3590597a8c2c/mbox-contents-95c6a4d9c82a8d20476522984666120b54192e9b.js, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.
[0313/104242.468139:ERROR:render_process_host_impl.cc(2113)] Request for unknown Channel-associated interface: device::mojom::ScreenOrientationListener
A Parser-blocking, cross site (i.e. different eTLD+1) script, https://assets.adobedtm.com/d0cc0600946eb3957f703b9fe43c3590597a8c2c/scripts/satellite-5672ffbd64746d5bd3002853.js, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.
A Parser-blocking, cross site (i.e. different eTLD+1) script, https://assets.adobedtm.com/d0cc0600946eb3957f703b9fe43c3590597a8c2c/scripts/satellite-5672ffbd64746d5bd3002853.js, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.
[0313/104243.369665:INFO:client_handler.cpp(512)] OnLoadEnd:SETTING FOUCS
[0313/104243.560145:INFO:client_handler.cpp(512)] OnLoadEnd:SETTING FOUCS
[0313/104244.973149:INFO:client_handler.cpp(512)] OnLoadEnd:SETTING FOUCS
[0313/104244.973767:INFO:client_handler.cpp(512)] OnLoadEnd:SETTING FOUCS
[0313/104244.973937:INFO:client_handler.cpp(505)] OnLoadEnd
[0313/104244.973954:INFO:client_handler.cpp(512)] OnLoadEnd:SETTING FOUCS
[0313/104245.640779:INFO:client_handler.cpp(150)] OnBeforeResourceLoad https://nl.mathworks.com/?requestedDomain=
[0313/104245.678161:INFO:client_handler.cpp(162)] OnResourceResponse https://nl.mathworks.com/?requestedDomain=
[0313/104245.685755:INFO:client_handler.cpp(481)] OnLoadStart
A Parser-blocking, cross site (i.e. different eTLD+1) script, https://assets.adobedtm.com/d0cc0600946eb3957f703b9fe43c3590597a8c2c/mbox-contents-95c6a4d9c82a8d20476522984666120b54192e9b.js, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.
A Parser-blocking, cross site (i.e. different eTLD+1) script, https://assets.adobedtm.com/d0cc0600946eb3957f703b9fe43c3590597a8c2c/mbox-contents-95c6a4d9c82a8d20476522984666120b54192e9b.js, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.
A Parser-blocking, cross site (i.e. different eTLD+1) script, https://assets.adobedtm.com/d0cc0600946eb3957f703b9fe43c3590597a8c2c/scripts/satellite-5672ffbd64746d5bd3002853.js, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.
A Parser-blocking, cross site (i.e. different eTLD+1) script, https://assets.adobedtm.com/d0cc0600946eb3957f703b9fe43c3590597a8c2c/scripts/satellite-5672ffbd64746d5bd3002853.js, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.
[0313/104246.205072:INFO:client_handler.cpp(512)] OnLoadEnd:SETTING FOUCS
[0313/104246.641569:INFO:client_handler.cpp(505)] OnLoadEnd
[0313/104246.641625:INFO:client_handler.cpp(512)] OnLoadEnd:SETTING FOUCS
It's pretty annoying.
I'm running on Ubuntu 18.10, kernel 4.18.0-16-generic, MATLAB version 9.5.0.944444 (R2018b).

댓글을 달려면 로그인하십시오.


Jorge Martinez
Jorge Martinez 30 Aug 2019
Hi there,
I would like to refer you to the MATLAB page on the Arch Linux Wiki.
https://wiki.archlinux.org/index.php/MATLAB
Even when you do not use Arch as your Linux distribution this page contains very detailed instructions on how to get MATLAB to work under Linux, from installation to configuration and troubleshooting.
I found there the answer to the problem I had (the same problem aleper mentioned on starting SIMULINK).

  댓글 수: 1

houssam deboucha
houssam deboucha 19 May 2020
i could fix this problem of matlab due to some library new on linux while matlab use old version so just you can go to the path /usr/local/MATLAB/R2017b/bin/glnxa64 then rename the libfreetype.so.6.11.1 to libfreetype.so.11.1.old that's all

댓글을 달려면 로그인하십시오.


Júlio César Chaves
Júlio César Chaves 20 Jun 2020
Install a java virtual machine.
sudo install dnf
sudo dnf install java-1.8.0-openjdk ant -y

  댓글 수: 0

댓글을 달려면 로그인하십시오.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by