How to start second Writer instance on custom user profile?

The aim is to have second Writer instance running on custom user profile in parallel to Writer primary instance? Latter one is linked to Writer user profile created by LO installer.
Both instances are interactive, GUI based.
The desire is to have two independent instances.
The primary used for working on .odt’s and .ott, Writer default user profile.
The secondary used for working on master document, a second user profile created by user.
Second profile is actually a clone of the Writer default profile however only till first use of second instance.
Cloning was performed by means of Safe Mode 2, Archive User Profile, then unpacking got archive
to separate folder. Both user profiles have one common parent directory.
Interchangeable activities in master and sub-documents documents result in frequent Writer crashes.
The aim is to have at least impacts of crash isolated to master document instance.

Second user profile, a custom one exists already.
How to start second instances?
Working on Linux Manjaro with XFCE. The main instance is started by a click on Writer icon in xfce Whisker menu. LibreOffice installed from package managament, not sandboxed.

The use of command argument -env:UserInstallation=<URL to 2nd user profile machine-local> is unfortunately ineffective >> invoked instance still uses the primary profile. Nor placing this one key - value pair in bootstrap.ini helps.

If your goal is to isolate two editing sessions, the simplest way IMHO is to have two separate user sessions.

Create a second user account. Open both user sessions (depends on the desktop; I am not very familiar with Xfce). You can switch from one GUI session to the other with Ctrl+Alt+Fn where Fn is one of F1, F2, … function keys. Note that not all desktops allocate sessions starting from 1. Experiment to find the assignment.

If you’re working on the same documents from both sessions, make sure your users are in the same group and adjust directory and documents access rights to grant write access to group.

But, as in the single-session case, pay special attention to write conflicts. Only one Writer should write to a document at any time. Managing multiple access without error requires strict methodology.

.odt’s with .ott in the one instance on one side and .odm in the another instance compile to one final document. User account in use is equipped with fair amount of working environment - customization needed for this writing work. It will be costly to reproduce it in second user account. Sharing documents storage must be established, sharing template storage, possibly much more. My feeling is that creating second user account will cost lot of work.

No. It’s simple.
LibreOffice doesn’t manage accounts but allows for different user profiles.
After a standard installation “for all users” (on system level) there is one shared user profile.
Creating a second profile is very simple:

  • Create a folder like libreoffice1 somewhere in your home folder or AppData or so.
  • Go to the folder where the shared profile is stored.
  • Copy the folder named user there.
  • Go to the folder in your home folder which you created in the first step.
  • Paste the copied folder and its content to that location.
  • If needed, do that again for libreoffice2 or similar.

All the settings, templates, user code ... are now also available if one of the secondary profiles is used. Changes to one of the new profiles are not shared with the others. This includes all the settings and the recent files history.

To specify which profile shall be used for an instance, call soffice exe (from the shared installation) with the option string
-env:UserInstallation= followed by the exact URL of one of the folders you created for the purpose (libreoffice1 e.g).

If you run 2 instances of LibreOffice at the same time under windows, an annoyance is that documents of same type opened by different instances get stacked their handles using one icon in the task bar. I don’t know if other OS can do better.

Thanks for proposal. As other TTY consoles run on default without graphical environment/session and have no clue how quick I will able to start such on other TTY console I prefer to use Switch User function. Linux and Windows graphical user sessions support it.

@Lupp’s kind proposal helps to workaround this limitation

Thanks for idea. Here on my Linux the package management of operating systems configures LO installation procedures that way every system user gets dedicated LO user profile; profile is located in user home. For me it means the existing Writer user needs to share his LO profile (primary one) in order the another one can clone to its home. This way I will able to continue your fashion. It allows me to achieve working setting close to my initial plan.
If second user start Writer once before your steps are conducted they will get in their home LO user profile created by LO. Copy&paste profile from first account will overwrite it.
I am aware of the fact that two profiles will diverge over time / Writer usage sessions. In lights of my goals it is a feature rather than a bug. My initial plan foresaw this behavior as well. Fortunately, I need only one secondary profile.

The write conflict is not related to some user profile. It is inherent to the fact that you open the same file from two different tools or instances.

Ironically, this doesn’t work in my setup for some reason I don’t understand:

I agree. I also agree you didn’t address a possible conflict the user profile level. LO installer for my operating system places user profile in user home tree. It is the reason why I hesitated (eventually still do it) to introduce in my settings a new quality at this point. Insecurity got strengthened by @Lupp’s kind input.

In my scenario the primary instance is used for editorial of .odt’s and of one .ott while the second instance is used for working on master document. Analysis conducted by external means revealed that master document opens .odt’s in read-only mode, hence I see limited (down to none) potential of conflicts. Also regarding the use of .ott in context of master document editorial code flows I don’t see the need for opening template in write-mode (Devin confirmed it).

I have to apologize for my “little workbook” above which presented things very badly.
Of course there isn’t an actually “shared profile” and my profiles used under the same login name are both in my “home range”, just that Win names that differently. There is a standard folder per user, only accessible to the current one named /(userID)/AppData/Roaming/LibreOffice/... and there I place all the user profiles I want to be able to use in parallel as “this user”.
In my case (e.g.) I have one profile which contains true lots of user code, and I use it mainly as a repository.
In another profile I maintain some very special templates .... There most of user code is only stored to these templates.
You see that our use-cases are very different, and I should probably better not have posted to this thread.

Under Fedora Linux, the equivalent path is ~/.config/libreoffice/4/user/. It is likely you have to create a new subdirectory aside user, e.g. ~/.config/libreoffice/4/alternate/. I have never fiddled with this directory. So, exercise caution.

My preferred workflow to add AutoCorrect, AutoText, templates, … is to alter Tools>Options, LO>Paths and add there dedicated user directories so that I don’t interfere with LO internals. This way, I can manage (rename, copy, backup, delete, …) my customisations without opening LO, nor creating a hazard with LO processing.

OK.
I prefer parallel user profiles which I can choose via the
-env:UserInstallation= construct, and I still think it is rather simple.
I’m an old retired teacher and don’t write books or use master documents. Actually I use Writer only for short texts, mainly letters filled into what was automatically created loading a personal template.
My usage of LibO is no longer “productive”, but trying to

  • help FLOSS survive.
  • play (kind of) with the capabilities of spreadsheets (API)
  • enhancing these capabilities here and there based on user code
  • have an opportunity to program a bit. (Kind of addiction since 1966).

Idea attracted me, so I did the attempt to have implemented it. A test few-days long revealed however in end-effect no achievement of the aimed goal - Writer still crashing. Eventually the rate of crash occurrences is a bit lower. In course of test the instance with .odt’s and .ott processed crashed once yet the another one also once. I am far from knowing the exact reason. Maybe it is my use of citations/bibliography app external to Writer; maybe some other component of my work settings or a combination of; maybe my own mistakes in underpinning operating system administration/maintenance (I am still on learning to do that for on Arch strain of distros properly); maybe constructional/implementation error in Writer or Zotero.

That’s one element of my trials so far, with no success finally. DeepWiKi Devin on LO-core code-base assisted on assessment regarding possible risks / the odds for success. Assuming my scenario no conflicts were identified. However subsequent test and Devin’s code analysis revealed a limitation concerning sharing document templates which in lights of scenario/goals turns to heavy one.