Backup for LMMS project

Having trouble with LMMS? Ask about it here.
Hello,

I'm now working with a huge project in LMMS for months. It consider about 180 tracks (most of it are lector tracks but there are also some VST tracks and presets from which I made unique sounds). Yesterday I almost had a heart attack when my laptop freezes and after reboot there was an error that make in unable to launch the system. Finally I resovled this problem and everything is fine, but this provoked me to think about backup my project. For about two weeks ago I exported my presets, VST track etc. I also have all the lector tracks on other disk. I also made a copy of my project (nmpz file). But... what will happen when I will try to open my project on other machine? I have npmz file, I have exported presets and instrument and lector tracks. But will it launch as LMMS project on other machine? I'm thinking the most about the paths to lector tracks etc. On other machine paths will differ, there will be maybe other directories. Is it not like that if i change directories of my files then LMMS could not find the files then? Does it mean that i cannot work with my project on othe machine?

How to make a real backup of my project, so I can sleep well even when my laptop (hard disk) will be crashed?
markam wrote:
Mon Nov 23, 2020 6:37 pm
But... what will happen when I will try to open my project on other machine? I have npmz file, I have exported presets and instrument and lector tracks. But will it launch as LMMS project on other machine? I'm thinking the most about the paths to lector tracks etc. On other machine paths will differ, there will be maybe other directories. Is it not like that if i change directories of my files then LMMS could not find the files then? Does it mean that i cannot work with my project on othe machine?
I was able to open my project on 2 different machines when I bought another PC, without the samples and VST's getting lost, and everything is smooth as butter.

There are some situations that LMMS will or will not load external stuff.

Project file:
1. Save as .mmp, not .mmpz. mmpz is not recoverable during crash.

Samples:
2. You should place ALL your external samples to the LMMS working directory "samples" folder (lmms/samples) for example, "C:/Users/MyName/lmms/samples". When you use a different PC, it should be loading the 3rd party samples again, regardless if the lmms/samples folder is placed in C: or D: drive. Do not put the samples outside of lmms/samples, LMMS will forget them after 6 months or so.

The VST part.
3. LMMS saves the chunk data of the VST, so if you reload the project, the parameters (what knob values, settings, etc.) are not lost. But, in order to retrieve it, the location of your VST in your new versus older machine, should be EXACTLY the same as the new. If the VST is located in C:/Program Files/Steinberg/example_plugin.dll in your old machine, the VST in your newer computer should be also placed in C:/Program Files/Steinberg/example_example.plugin.dll.

Mods, is this suitable for Support forums instead?
vortexsupernova wrote:
Fri Dec 04, 2020 9:39 am
Do not put the samples outside of lmms/samples, LMMS will forget them after 6 months or so.
This is not quite true - LMMS is not going to randomly change a sample filepath in a project without user intervention. As anecdotal evidence, I have several projects I'm working on right now that have existed for several years with all samples stored outside of the lmms/samples folder, and no issues with them being loaded. Perhaps the sample location changed, and thus LMMS could not load them, but LMMS stores the filepath, nothing more, nothing less. It won't forget that.

vortexsupernova wrote:
Fri Dec 04, 2020 9:39 am
Mods, is this suitable for Support forums instead?
Yep! Moving.
Stakeout Punch wrote:
Mon Dec 14, 2020 6:21 am
Do not put the samples outside of lmms/samples, LMMS will forget them after 6 months or so.
This is not quite true - LMMS is not going to randomly change a sample filepath in a project without user intervention. As anecdotal evidence, I have several projects I'm working on right now that have existed for several years with all samples stored outside of the lmms/samples folder, and no issues with them being loaded. Perhaps the sample location changed, and thus LMMS could not load them, but LMMS stores the filepath, nothing more, nothing less. It won't forget that.
Ah, my bad, I think this happens in 1.1.3 release or earlier. I remember having to reload every sample and SF2 every 6 months or so even their location hasnt changed, but it does not happen anymore in 1.2.0 release family. Or it was a strange bug.
vortexsupernova wrote:
Mon Dec 14, 2020 6:49 am
Ah, my bad, I think this happens in 1.1.3 release or earlier. I remember having to reload every sample and SF2 every 6 months or so even their location hasnt changed, but it does not happen anymore in 1.2.0 release family. Or it was a strange bug.
If you open a mmp in text-editor, you find xml-code like:

Code: Select all

                <instrument name="audiofileprocessor">
                  <audiofileprocessor looped="0" src="drums/kick_hard01.ogg" amp="100" lframe="0" reversed="0" sframe="0" stutter="0" eframe="1" interp="1">
                    <key/>
                  </audiofileprocessor>
                </instrument>
The path-important line is

Code: Select all

 <audiofileprocessor looped="0" src="drums/kick_hard01.ogg" amp="100" lframe="0" reversed="0" sframe="0" stutter="0" eframe="1" interp="1">
The actual address is

Code: Select all

src="drums/kick_hard01.ogg"
What LMMS does is to check what path you have for your samples, defined in Settings
With that folder as 'root' LMMS then
* find the subfolder

Code: Select all

drums
* open that folder and find the file

Code: Select all

kick_hard01.ogg
* loads that specific sound-file.

So how could that go wrong?
* The actual path to the subfolder is changed! -Obvious..
* The sound-file is embedded in a xpf! -Tricky....

In XPF files we can find a significant different structure!

Code: Select all

<audiofileprocessor reversed="0" looped="1" eframe="0.450001" sframe="0.23" src="E:/no ammo.wav" amp="100"/>
Here there is a complete path!

Code: Select all

src="E:/no ammo.wav"
...Now i do not know how i botched that saving, or if it indeed was lmms
My guess is that I did it! I most likely browsed to that folder, and saved there!
Then if i attempt to use that preset in an other project, it will fail! That preset can be found, but the path cant, so it loads a 'flatlined' AFP:
Image
Just as the one to the right!
Bottomline, if the sample is from the settings-defined library, you should not have loading issues, if the path-structure is not changed, but AFP-presets, imported into projects, could point to 'weird' non-existent folders, and you get a flatliner, with no output.
Thank you very much for Your responses and your time!

After reading Yours solutions, I am now thinking about one idea how to resolve my problem.

1. I will store my project as .nmpz, but also as .mmp, and then copy it to separate hard disk.
2. Then I will simply copy all my samples ant vst.dll into separate hard disk.
3. Then on another PC I should be able to open my .mmp file in text editor, manually change paths to directories witch stores samples and vsts on this other PC, and then run my project by LMMS from .mmp file.

If I understood properly, there should also be no problem with 'built in' LMMS presets, because they are given with every LMMS installation.

And then, if I also understood properly, settings of the knobs for each sample should be stored in the .mmp file, so my only 'hard work' is with showing LMMS the properly paths to each sample file and VST file.

I made some exercies about it on my current machine, and it looks fine. Now I must try it in real battle and try to open my project withc another PC.

I am not sure what will happen with every FX's that I added in LMMS on sample files? You know what I mean, I have a simple .wav recording which stores the sound of a drum, then in my project I added to it for example a reverb. Will the information about this extra FX's be stored in the .mmp file? Or maybe I should export each modified sample to a .xpf file and then on other PC use this exactly .xpf file in my project instead the 'raw' recording?

@vortexsupernova wrote:
The VST part.
3. LMMS saves the chunk data of the VST, so if you reload the project, the parameters (what knob values, settings, etc.) are not lost. But, in order to retrieve it, the location of your VST in your new versus older machine, should be EXACTLY the same as the new. If the VST is located in C:/Program Files/Steinberg/example_plugin.dll in your old machine, the VST in your newer computer should be also placed in C:/Program Files/Steinberg/example_example.plugin.dll.
OK, but what should I do if, for example, I create my project on Linux machine, and then I move to a Windows machine? Path to vst will be different and my previous experience is that manually changing path to VST in .mmp file will not work, there is issues with loading vst. Also if I will again use Linux machine, but if there will be another user name then the path and directories will differ.
Old machine: /home/markam/lmms/ABCvst
New machine: /home/my-wife-PC/lmms/ABCvst

Path are different and probably there will be problem with loading vst into the project on new machine.

You know what I mean?
I can use the same path if I will be the only owner of the PC, and I will make EXACTLY the same users, and the tree directory will be exactly the same. But what if I cannot make it?
markam wrote:
Sun Jan 03, 2021 11:18 am
what will happen with every FX's that I added in LMMS on sample files?
Lmms makes a section about added FXs in both xpf-preset-files, and in the projectfile. again ther presetfile is with full path. The projectfile is with relative path.
all information about dial-settings are stored in both types of files?
what should I do if, for example, I create my project on Linux machine, and then I move to a Windows machine?
That would not work with the full-path items, but with the relative paths it should not matter.
What is the purpose of 'ABCvst'?
VST-instruments?
I believe you are overthinking this whole issue. Saving as both .mmp and .mmpz is complete unnecessary. MMPZ is just the compressed format, but as mentioned it is not recoverable. Just save as MMP, don't worry about the rest. For an extra layer of security, automatically backup your project files with a service like DropBox. They offer file versioning, which has saved my projects several times when a certain save crash bug happens and project files are deleted. Yes, this does happen, but very rarely. Which is why it hasn't been fixed. Dropbox will let you undo the deletion via their web interface.

Regarding presets, samples, VSTs, automation tracks, etc. Don't worry about it. LMMS saves everything EXCEPT the actual samples and VST .dlls in the project file. This is why Vortex said to put files in lmms/samples. LMMS uses relative pathing for the lmms/ folder so it doesn't matter what the User folder is. Presets, FX, plugins that are not VST, are always saved fully and loaded perfectly within the same version of LMMS.

If your sample filepath changes because you didn't put them in lmms/samples, do not try to edit the filepath manually in the MMP file. This is a last ditch resort for projects that LMMS refuses to open. It's far easier to cause issues with typos and the like when doing it this way, and there's a far easier method built into LMMS. LMMS will save the container of the sample and all the tweaks, FX, etc. You just have to point LMMS at the new file location. This is the same as if you wanted to just change the sample out. Both Sample Tracks and the AudioFileProcessor have load file buttons. That's what they are for.

Regarding VST, you need to make sure they use the same path, period. If you use the standard file location, it will be the same on all your machines anyway. There is a catch here: VSTs apparently do not work the same way on Linux with wine. It always messes up the filepath. This will be an extreme headache to deal with, so if you care about your projects working, keep them on the same OS type. There are a lot of users on the Discord that have not been able to make this work properly. If someone that knows more about this have a magic bullet that I haven't heard of to make it seamlessly work, I'm all ears.

For anecdotal evidence, I open all my projects on several machines all the time, and sync them using Dropbox. I store my samples in the exact same locations on each machine, all my VSTs in the exact same locations, you get the idea. I never have issues this way, but all my machines are the same OS as well.
musikbear wrote:
Mon Jan 04, 2021 4:50 pm
What is the purpose of 'ABCvst'?
VST-instruments?
Yes, I mean VST-instruments, .dll files.
slapkev wrote: Both Sample Tracks and the AudioFileProcessor have load file buttons. That's what they are for.
(...)
VSTs apparently do not work the same way on Linux with wine
This is all true.

After taking all advices from this topic, and after making my own attempts to resolve my problem with fully backup I finally got the working solution. Here are few tips and mine observations , maybe somebody in the future will find it useful:

1. When I firstly created my project (months ago) on Linux machine I putted my samples and VSTs on the path "/home/markam/lmms v2/ ....." . Yes, now I know it is bad. But now when I was struggling with my backup, I tried to run my project on other Linux machine, I ensured that my source files also are in the same directories. So I made identical working tree. It works with most of the .wav files BUT.... not with VSTs. I had the opportunity to install new OS on new disk, so this was the ideal time for such a attempts.
2. On my default Linux machine i have installed Wine 6.0. So I tried to install it also in the second machine. After that VSTs started to work! (Firstly i tried to launch project when on the second machine was only Wine 3.0. It did not work so Wine versions is important.)
3. Not all samples were working on second machine. So i manually changed files in LMMS editor (using load buttons) and showed LMMS where to find this files. Works fine.

CONCLUSION:
A. Use the same directories / working tree.
B. Use the same Wine version, and same operating system.
C. When .wav doest not work, use load buttons to show LMMS where to find files.

I'm glad at this moment and I can sleep well. My project works fine on different machines/HDDs.

Thank you all for your time and your help!