MATLAB permission error in Linux Ubuntu 18.04

22 visualizzazioni (ultimi 30 giorni)
I've installed MATLAB in Ubuntu 18.04.
When I open MATLAB it gives me a warning that the desktop configuration was not saved succesfully. When I try to use any command in the command window, it gives me an exception.
The desktop configuration was not saved successfully
>> clear
An error was encountered while saving the command history
java.io.FileNotFoundException: /home/shihab/.matlab/R2019a/History.xml (Permission denied)
at java.io.RandomAccessFile.open0(Native Method)
at java.io.RandomAccessFile.open(RandomAccessFile.java:316)
at java.io.RandomAccessFile.<init>(RandomAccessFile.java:243)
at com.mathworks.mde.cmdhist.AltHistoryCollection$CommandSaver.run(AltHistoryCollection.java:1214)
at java.lang.Thread.run(Thread.java:748)
Any help would be appreciated.
I tried two commands, but they didn't help
sudo chmod -R 777 /usr/local/MATLAB/R2019a/
sudo chown -R $LOGNAME: /usr/local/MATLAB/R2019a
But neither of them worked. If I use MATLAB with from a root terminal, I don't get any errors.
  2 Commenti
Walter Roberson
Walter Roberson il 14 Ago 2019
/home/shihab/.matlab/R2019a/History.xml is the file that is having the problem. You should be granting permission for that file specifically or for /home/shihab/.matlab/R2019a directory.
Mohd Shihabuddin Khan
Mohd Shihabuddin Khan il 14 Ago 2019
Thanks a lot Walter. It worked. Now that I look at it, it was so obvious. Thanks for helping out. :)

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Startup and Shutdown in Help Center e File Exchange

Prodotti

Community Treasure Hunt

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

Start Hunting!

Translated by