How to conveniently switch between different user profiles

Different user profiles for the ThinLinc client can be useful when regularly connecting to multiple different ThinLinc servers, e.g. to save the hostname of the server, swap between different authentication methods or use different levels of security restrictions. This guide shows two ways to create such user profiles.

ThinLinc handles user profiles through files called tlclient-files, which in this text will be referred to as user profile files. In short, these files are configuration files that open a ThinLinc client with the settings defined in the file. Changes made in the client GUI are saved to the user profile file upon exit of the client. Note that for some parameters, e.g. hostname and username, a save is instead triggered when logging in to a server.

Preparations

It is assumed that the ThinLinc client is installed on your platform of choice before starting this guide. User profiles are only available for the installed client, not for Web Access.

Other information

All available configuration parameters for user profiles can be found in Client Configuration Parameters - ThinLinc Administrator’s Guide.

Create a user profile using the ThinLinc client GUI

  1. Create an empty file with the suffix .tlclient, e.g. profile1.tlclient.
    tlclient_file_example2

  2. Double-click the file to open the ThinLinc client, or run tlclient -C <user profile file> from the command line.

  3. Open the settings by clicking “Options…” and make the changes of your choice.

  4. Click “OK” to save the settings.

  5. Connect to your server.

  6. The username, hostname and settings are now saved to the user profile file.

Create a user profile directly in file

Handling configuration files manually allows for extra configuration not available in the GUI settings. Here is a full list of configuration parameters.

  1. Create an empty file with the suffix .tlclient, e.g. profile1.tlclient.

  2. Open the file with an editor of your choice.

  3. Add the wanted configuration parameters.

  4. Save and close the file.

  5. Double-click the file to open the ThinLinc client, or run tlclient -C <user profile file> from the command line. Your configuration should be transferred to the opened client.

As a point of reference, the standard client configuration file can be inspected. On Linux and macOS it is found at ~/.thinlinc/tlclient.conf, and on Windows the configuration is saved in the registry.

Known issues on the topic

5 Likes

The way user profiles work today, changes made to the settings will always automatically be saved. This complicates using the profiles as a template, where parameters should be unchanged from one usage to the next.

It is possible to make user profiles behave as templates, but there are drawbacks to the solution.

To prevent the user profiles files from being updated, all write permissions on the file should be removed. However, note that this will cause a warning prompt to be shown every time you log in or save your settings, see screenshot below.

tlclient_couldnt_store_settings

If this warning and its frequency doesn’t bother you, feel free to modify the write permissions of the file. For example on Linux, it can be done running chmod 400 <user profile file>.

2 Likes