Lasso uses the libpq environment variables to get the
Postgres connection parameters. You can find the list of the environment
variables in the PostgreSQL
documentation.
The connection parameters, among other options, can also be passed as command
line arguments:
You can also use a configuration file for Lasso, so you can omit most of the
command line options that your environment might require. Lasso looks
for configuration files in the following paths, in this order:
./edb-lasso.cfg in the same directory where Lasso is running
./edb-lasso.conf in the same directory where Lasso is running
$HOME/.edb-lasso.conf
/etc/edb-lasso.conf
It uses the first match .
A template file for the configuration file looks like this:
You can use this template to set up your configuration file. Uncomment
the desired parameters and set their values according to your
environment.
If you installed Lasso from DEB or RPM packages, You can find that same template configuration
file at /etc/edb-lasso.conf.templ.
Important
If you installed Lasso from DEB or RPM packages, then you
must have a configuration file that contains at least the customer
ID and token set. That isn't required if you're running the Lasso disposable
binary, which contains those variables embedded in the binary.
The script produces a TAR file containing the gathered data.
You must return this file to EDB engineers as part of the process
or send it automatically with the --upload option. upload
Important
Some companies have requested for Lasso to
operate in an isolated network. In that case, the --upload option isn't
permitted. (You can easily verify this setting from your company page
in the Portal or through the --version runtime option.)
To take advantage of this feature, make
sure that the server that's analyzed by Lasso can access the
443 port of any of the front-line websites listed in Servers accepting upload of reports.
You can also use Lasso on a server that has no
Postgres installation. In that case, use the
--system-only option, and the TAR file produced will contain only
system-related information.
Security considerations
When running queries in the database, Lasso tries to use a role that
has enough privileges to gather the required information from the tool from which
metrics are being gathered.
The following are the tools and the roles that Lasso tries to use for
each of them. Lasso tries to use the first available role in each
tool role list. Initial connection role means the role that was provided through
Lasso CLI when running the tool—usually postgres or enterprisedb.
PostgreSQL:
pg_monitor
initial connection role
PgLogical:
pglogical_superuser
initial connection role
PGD:
bdr_monitor
initial connection role
PEM:
pem_user
initial connection role
repmgr:
initial connection role
xDB:
initial connection role
Most of the PGD gatherings try using the bdr_monitor role. However, one of them,
which is in charge of gathering conflicts, tries to use the role
bdr_read_all_conflicts for that purpose. That's the only exception.
In any of the cases, it uses a read-only transaction while querying metrics
and configurations from the database.