I was executing a long Mathematica Notebook over night. The Mathematica instance is running on a Linux workstation (in a vnc server session to be precise). Now I cannot access this session anymore, which means that I likely loose the output data which was produced during the run. I can still login on the workstation as the same user and run Mathematica there. I know from the process list that Mathematica is still running, but I cannot access the GUI anymore. So, if there would be a remote control for Mathematica from command line or a second worksheet, which allows me to save the worksheet, I could prevent the data loss. I already tried to run a second instance of Mathematica but it seems that I cannot even see the Kernels there. Any ideas? It would save my day.
Export[...,"file.mx.gz"]
is your friend. Doesn't help you now, I know... $\endgroup$NotebookAutoSave
. $\endgroup$.mx
! It's not cross platform or cross-version. Never keep important data in.mx
. An cross-platform, cross-version alternative is toCompress
your expressions and write the resulting string into a file. I usezimport[filename_] := Uncompress@Import[filename, "String"]; zexport[filename_, data_] := Export[filename, Compress[data], "String"]
$\endgroup$NotebookAutoSave
feature? Is it stable? My experience with other software is that it may crash while saving, especially if the files are big. It can then leave the files in an inconsistent/partial state. $\endgroup$