Trouble setting up screen sharing on Fedora 27 Desktop - fedora

I'm running Fedora 27 Desktop edition with GNOME. I've tried instructions from all over the web, but haven't found anything that lets me set up sharing my screen with a remote user. Can anyone help me with this?
Thank you very much in advance for your response.
Here's the story so far:
========
I initially tried:
Activies -> Show Application -> Settings -> Sharing
and saw options:
File Sharing
Media Sharing
Remote Login
But saw no option for Screen Sharing, which one page suggested should be present.
========
I've looked at:
https://docs.fedoraproject.org/f27/system-administrators-guide/Wayland.html
and run
$ echo $WAYLAND_DISPLAY
which yields
wayland-0
but I can't find out how to use this information to solve my problem. I also don't find documentation that screen sharing on Wayland under Fedora 27 is working.
========
Of the many solutions I've tried, I made the best progress by following instructions at https://docs.fedoraproject.org/f27/system-administrators-guide/infrastructure-services/TigerVNC.html
The following commands worked:
sudo dnf install tigervnc-server
sudo cp /lib/systemd/system/vncserver#.service /etc/systemd/system/vncserver#.service
Then I edited /etc/systemd/system/vncserver#.service, replacing <USER> with my user name in the following two lines:
ExecStart=/sbin/runuser -l <USER> -c "/usr/bin/vncserver %i -geometry 1280x1024"
PIDFile=/home/<USER>/.vnc/%H%i.pid
Then I ran:
sudo systemctl daemon-reload
and set a password with:
vncpasswd
Next the site's instructions told me:
With a valid display number, execute the following command:
sudo systemctl enable vncserver#:display_number.service
I've tried using display numbers 0, 1, and 2.
With display number as 1, for example, I got different error messages depending on whether SELinux was set to Enforcing or Permissive.
sudo systemctl start vncserver#:1.service
With 'Enforcing':
Job for vncserver#:1.service failed because the service did not take the steps required by its unit configuration.
See "systemctl status vncserver#:1.service" and "journalctl -xe" for details.
After trying the following steps suggested by SELinux:
sudo ausearch -c 'systemd' --raw | audit2allow -M my-systemd
semodule -i my-systemd.pp
and:
sudo ausearch -c 'geoclue' --raw | audit2allow -M my-geoclue
sudo semodule -i my-geoclue.pp
the error message changed to be same as given here for 'Permissive':
Job for vncserver#:1.service failed because the control process exited with error code.
See "systemctl status vncserver#:1.service" and "journalctl -xe" for details.
The output of systemctl status vncserver#:1.service was as follows:
● vncserver#:1.service - Remote desktop service (VNC)
Loaded: loaded (/etc/systemd/system/vncserver#.service; disabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Mon 2018-03-26 12:24:12 EDT; 3min 4s ago
Process: 23294 ExecStart=/usr/sbin/runuser -l jazcap53 -c /usr/bin/vncserver :1 (code=exited, status=98)
Process: 23292 ExecStartPre=/bin/sh -c /usr/bin/vncserver -kill :1 > /dev/null 2>&1 || : (code=exited, status=0/SUCCESS)
Mar 26 12:24:12 localhost.localdomain systemd[1]: Starting Remote desktop service (VNC)...
Mar 26 12:24:12 localhost.localdomain systemd[1]: vncserver#:1.service: Control process exited, code=exited status=98
Mar 26 12:24:12 localhost.localdomain systemd[1]: Failed to start Remote desktop service (VNC).
Mar 26 12:24:12 localhost.localdomain systemd[1]: vncserver#:1.service: Unit entered failed state.
Mar 26 12:24:12 localhost.localdomain systemd[1]: vncserver#:1.service: Failed with result 'exit-code'.
And sudo journalctl -xe produced:
Mar 26 12:27:41 localhost.localdomain systemd[1]: Started SSSD Kerberos Cache Manager.
-- Subject: Unit sssd-kcm.service has finished start-up
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit sssd-kcm.service has finished starting up.
--
-- The start-up result is done.
Mar 26 12:27:41 localhost.localdomain audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=sssd-kcm c
Mar 26 12:27:41 localhost.localdomain sssd[kcm][23679]: Starting up
Mar 26 12:27:41 localhost.localdomain systemd[1]: Started SSSD Secrets Service responder.
-- Subject: Unit sssd-secrets.service has finished start-up
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit sssd-secrets.service has finished starting up.
--
-- The start-up result is done.
Mar 26 12:27:41 localhost.localdomain audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=sssd-secre
Mar 26 12:27:41 localhost.localdomain sssd[secrets][23680]: Starting up
Mar 26 12:30:04 localhost.localdomain sudo[23858]: jazcap53 : TTY=pts/0 ; PWD=/home/jazcap53 ; USER=root ; COMMAND=/bin/journalctl -xe
Mar 26 12:30:04 localhost.localdomain audit[23858]: USER_CMD pid=23858 uid=1001 auid=1001 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg
Mar 26 12:30:04 localhost.localdomain audit[23858]: CRED_REFR pid=23858 uid=0 auid=1001 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='
Mar 26 12:30:04 localhost.localdomain sudo[23858]: pam_systemd(sudo:session): Cannot create session: Already occupied by a session
Mar 26 12:30:04 localhost.localdomain audit[23858]: USER_START pid=23858 uid=0 auid=1001 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg=
Mar 26 12:30:04 localhost.localdomain sudo[23858]: pam_unix(sudo:session): session opened for user root by (uid=0)

If you do not have Vino installed, GNOME will not display Screen Sharing as an option.
sudo dnf install vino should do it. You can then set up screenshare as per your initial attempt.

Related

fail to start mysql on CentOS7

I installed mysql in my server. But it failed to start.
The error shows here:
the systemctl status mysqld.service info:
[root#localhost run]# systemctl status mysqld.service
● mysqld.service - MySQL Server
Loaded: loaded (/usr/lib/systemd/system/mysqld.service; enabled; vendor preset: disabled)
Active: failed (Result: start-limit) since Sat 2021-05-29 10:47:55 CST; 35s ago
Docs: man:mysqld(8)
http://dev.mysql.com/doc/refman/en/using-systemd.html
Process: 256566 ExecStartPre=/usr/bin/mysqld_pre_systemd (code=exited, status=217/USER)
May 29 10:47:55 localhost.localdomain systemd[1]: Failed to start MySQL Server.
May 29 10:47:55 localhost.localdomain systemd[1]: Unit mysqld.service entered failed state.
May 29 10:47:55 localhost.localdomain systemd[1]: mysqld.service failed.
May 29 10:47:55 localhost.localdomain systemd[1]: mysqld.service holdoff time over, sche...t.
May 29 10:47:55 localhost.localdomain systemd[1]: Stopped MySQL Server.
May 29 10:47:55 localhost.localdomain systemd[1]: start request repeated too quickly for...ce
May 29 10:47:55 localhost.localdomain systemd[1]: Failed to start MySQL Server.
May 29 10:47:55 localhost.localdomain systemd[1]: Unit mysqld.service entered failed state.
May 29 10:47:55 localhost.localdomain systemd[1]: mysqld.service failed.
Hint: Some lines were ellipsized, use -l to show in full.
thejournalctl -xeinfo:
May 29 10:48:00 localhost.localdomain postfix/master[21438]: warning: process /usr/libexec/postfix/pickup pid 257074 exit status 127
May 29 10:48:00 localhost.localdomain postfix/master[21438]: warning: /usr/libexec/postfix/pickup: bad command startup -- throttling
May 29 10:49:00 localhost.localdomain postfix/master[21438]: warning: process /usr/libexec/postfix/pickup pid 263057 exit status 127
May 29 10:49:00 localhost.localdomain postfix/master[21438]: warning: /usr/libexec/postfix/pickup: bad command startup -- throttling
May 29 10:50:00 localhost.localdomain postfix/master[21438]: warning: process /usr/libexec/postfix/pickup pid 269083 exit status 127
May 29 10:50:00 localhost.localdomain postfix/master[21438]: warning: /usr/libexec/postfix/pickup: bad command startup -- throttling
May 29 10:50:01 localhost.localdomain systemd[1]: Started Session 2986 of user root.
-- Subject: Unit session-2986.scope has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit session-2986.scope has finished starting up.
--
-- The start-up result is done.
I tried to run chown -R mysql:mysql /var/lib/mysql, It shows like this:
chown: invalid user: ‘mysql:mysql’
How can I start mysql?
You can fix this in few steps
Execute this command to check if mysql user exists: cat /etc/passwd | grep mysql
Validate if you have mysql in this file. It should look something like : mysql:x:27:27:MySQL Server:/var/lib/mysql:/bin/false
If mysql user is not present please create that user like this : useradd -d /var/lib/mysql mysql
If mysql user is present then make sure mysql user home path in /etc/passwd file actually exists and owned by mysql user (in the above case I mentioned /var/lib/mysql is home path and it has to be owned by mysql user)
Note: from what ever you have mentioned it looked like mysql user doesn't exist in your system. So it looks like creating the user with home path as /var/lib/mysql should solve the problem.

Can't start MariaDB on debian 10

I can't seem to be able to start mariadb sql anymore. Internet says a bunch of things but they all seem to be "risky" and it seems that it really depends on the case. So here is mine. I don't know what/when happened but I am afraid to lose my subscribers data. What do you, superheroes, suggest?
When I try to start mariadb :
me#server:# systemctl start mariadb.service
Job for mariadb.service failed because the control process exited with error code.
See "systemctl status mariadb.service" and "journalctl -xe" for details.
And with systemctl status mariadb.service:
me#server:# systemctl status mariadb.service
● mariadb.service - MariaDB 10.3.27 database server
Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Mon 2020-12-07 21:04:05 CET; 1min 53s ago
Docs: man:mysqld(8)
https://mariadb.com/kb/en/library/systemd/
Process: 13289 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysqld (code=exited, status=0/SUCCESS)
Process: 13290 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Process: 13292 ExecStartPre=/bin/sh -c [ ! -e /usr/bin/galera_recovery ] && VAR= || VAR=`cd /usr/bin/..; /usr/bin/galera_recovery`; [ $? -eq 0 ] && systemctl set-environm
Process: 13339 ExecStart=/usr/sbin/mysqld $MYSQLD_OPTS $_WSREP_NEW_CLUSTER $_WSREP_START_POSITION (code=exited, status=1/FAILURE)
Main PID: 13339 (code=exited, status=1/FAILURE)
Status: "MariaDB server is down"
Dec 07 21:03:59 server systemd[1]: Starting MariaDB 10.3.27 database server...
Dec 07 21:04:01 server mysqld[13339]: 2020-12-07 21:04:01 0 [Note] /usr/sbin/mysqld (mysqld 10.3.27-MariaDB-0+deb10u1) starting as process 13339 ...
Dec 07 21:04:05 server systemd[1]: mariadb.service: Main process exited, code=exited, status=1/FAILURE
Dec 07 21:04:05 server systemd[1]: mariadb.service: Failed with result 'exit-code'.
Dec 07 21:04:05 server systemd[1]: Failed to start MariaDB 10.3.27 database server.
And when I go to journalctl -xe, I only get:
Dec 07 21:10:04 vps69770 sshd[13784]: pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=161.35.121.130 user=root
Dec 07 21:10:04 sshd[13712]: Received disconnect from 124.239.216.233 port 59950:11: Bye Bye [preauth]
Dec 07 21:10:04 sshd[13712]: Disconnected from authenticating user root 124.239.216.233 port 59950 [preauth]
Dec 07 21:10:04 sshd[13771]: Failed password for root from 111.201.133.174 port 48444 ssh2
Dec 07 21:10:05 sshd[13771]: Received disconnect from 111.201.133.174 port 48444:11: Bye Bye [preauth]
Dec 07 21:10:05 sshd[13771]: Disconnected from authenticating user root 111.201.133.174 port 48444 [preauth]
Dec 07 21:10:05 systemd[1]: mariadb.service: Main process exited, code=exited, status=1/FAILURE
-- Subject: Unit process exited
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- An ExecStart= process belonging to unit mariadb.service has exited.
--
-- The process' exit code is 'exited' and its exit status is 1.
Dec 07 21:10:05 server systemd[1]: mariadb.service: Failed with result 'exit-code'.
-- Subject: Unit failed
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- The unit mariadb.service has entered the 'failed' state with result 'exit-code'.
Dec 07 21:10:05 server systemd[1]: Failed to start MariaDB 10.3.27 database server.
-- Subject: A start job for unit mariadb.service has failed
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- A start job for unit mariadb.service has finished with a failure.
--
-- The job identifier is 1241 and the job result is failed.
Dec 07 21:10:06 server sshd[13784]: Failed password for root from 161.35.121.130 port 37142 ssh2
Dec 07 21:10:06 server sshd[13784]: Received disconnect from 161.35.121.130 port 37142:11: Bye Bye [preauth]
Dec 07 21:10:06 server sshd[13784]: Disconnected from authenticating user root 161.35.121.130 port 37142 [preauth]
Which is not a big help
I have no idea what to do. I really don't want to lose my database.
Thanks for your input
Solved it by deleting/renaming the tc.log mv -vi /var/lib/mysql/tc.log /root And restarting the database service mysql restart

mysql does not restart

I've tried to restart mysql 5.7 :
service mysql restart
But it fails and i do not understand why :
Job for mariadb.service failed because the control process exited with error code.
See "systemctl status mariadb.service" and "journalctl -xe" for details.
And I dont see what's wrong in the logs :
systemctl status mariadb.service
● mariadb.service - MariaDB 10.1.37 database server
Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Mon 2019-02-25 22:02:52 GMT; 1min 9s ago
Docs: man:mysqld(8)
https://mariadb.com/kb/en/library/systemd/
Process: 15467 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysqld (code=exited, status=127)
Main PID: 28679 (code=exited, status=0/SUCCESS)
Feb 25 22:02:52 stretch systemd[1]: Starting MariaDB 10.1.37 database server...
Feb 25 22:02:52 stretch systemd[1]: mariadb.service: Control process exited, code=exited status=127
Feb 25 22:02:52 stretch systemd[1]: Failed to start MariaDB 10.1.37 database server.
Feb 25 22:02:52 stretch systemd[1]: mariadb.service: Unit entered failed state.
Feb 25 22:02:52 stretch systemd[1]: mariadb.service: Failed with result 'exit-code'.
Any help would be welcome...
I'm on Debian 9, with 1800Mo in ram free.
Here is what the journal says :
journalctl -xe
Feb 26 08:09:01 stretch CRON[16792]: pam_unix(cron:session): session opened for user root by (uid=0)
Feb 26 08:09:01 stretch CRON[16793]: (root) CMD ( [ -x /usr/lib/php/sessionclean ] && if [ ! -d /run/systemd/system ]; then /usr/lib/php/sessionclean; fi)
Feb 26 08:09:01 stretch CRON[16792]: pam_unix(cron:session): session closed for user root
Feb 26 08:17:01 stretch CRON[16794]: pam_unix(cron:session): session opened for user root by (uid=0)
Feb 26 08:17:01 stretch CRON[16795]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly)
Feb 26 08:17:01 stretch CRON[16794]: pam_unix(cron:session): session closed for user root
Feb 26 08:25:23 stretch systemd[1]: Starting MariaDB 10.1.37 database server...
-- Subject: Unit mariadb.service has begun start-up
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- Unit mariadb.service has begun starting up.
Feb 26 08:25:23 stretch systemd[1]: mariadb.service: Control process exited, code=exited status=127
Feb 26 08:25:23 stretch systemd[1]: Failed to start MariaDB 10.1.37 database server.
-- Subject: Unit mariadb.service has failed
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- Unit mariadb.service has failed.
--
-- The result is failed.
Feb 26 08:25:23 stretch systemd[1]: mariadb.service: Unit entered failed state.
Feb 26 08:25:23 stretch systemd[1]: mariadb.service: Failed with result 'exit-code'.
I also got this error when upgrading to Debian Buster (from MariaDB 10.1 to 10.3). Running mysqld myself and mysql_upgrade both worked anyways. Try executing the following command to restart systemd on the fly. See also https://unix.stackexchange.com/a/419375.
systemctl daemon-reexec
If you don't do this, a reboot will probably fix this as well. Commenting out the ExecStartPre in /etc/systemd/system/mysql.service was not enough as the other ExecStartPre commands then failed instead (also with the exit code 127, i.e. "command not found").
Under Process: is the ExecStartPre returning with an error exist status
Based on error 127, I'd suspect that /usr/bin/install doesn't exist.

MySQL Galera cluster can't initiate first node

I'm using Ubuntu 16.04 and installed MySQL version 5.7 via apt-get in AWS.
After that, I've managed to upgrade the MySQL to Galera Cluster by following the Documentation from the official website using apt-get install galera-3 galera-arbitrator-3 mysql-wsrep-5.6
After that I've configured the file /etc/mysql/conf.d/galera.cnf to be:
[mysqld]
binlog_format=ROW
default-storage-engine=innodb
innodb_autoinc_lock_mode=2
bind-address=0.0.0.0
# Galera Provider Configuration
wsrep_on=ON
wsrep_provider=/usr/lib/galera/libgalera_smm.so
# Galera Cluster Configuration
wsrep_cluster_name="test_cluster"
wsrep_cluster_address="gcomm://this_node_ip,second_ip,third_ip"
# Galera Synchronization Configuration
wsrep_sst_method=rsync
# Galera Node Configuration
wsrep_node_address="this_node_ip"
wsrep_node_name="this_node_name"
The step above is repeated for the other 2 nodes (with it's own IP address). And stop the mysql with the following command sudo service mysql stop for each of the node.
And in the first node, I'm trying to start with the following command:
sudo service mysql start --wsrep-new-cluster
But it returns: Job for mysql.service failed because the control process exited with error code. See "systemctl status mysql.service" and "journalctl -xe" for details.
In the systemctl status mysql.service, it says:
● mysql.service - LSB: start and stop MySQL
Loaded: loaded (/etc/init.d/mysql; bad; vendor preset: enabled)
Active: failed (Result: exit-code) since Fri 2018-02-09 15:53:16 +08; 33s ago
Docs: man:systemd-sysv-generator(8)
Process: 6264 ExecStart=/etc/init.d/mysql start (code=exited, status=1/FAILURE)
Feb 09 15:53:15 systemd[1]: Starting LSB: start and stop MySQL...
Feb 09 15:53:15 mysql[6264]: Starting MySQL
Feb 09 15:53:15 mysql[6264]: .180209 15:53:15 mysqld_safe Can't log to error log and syslog at the same time. Remove all --log-error configuration options for --syslog to take effect.
Feb 09 15:53:15 mysql[6264]: 180209 15:53:15 mysqld_safe Directory '/var/run/mysqld' for UNIX socket file don't exists.
Feb 09 15:53:16 mysql[6264]: * The server quit without updating PID file (/var/run/mysqld/mysqld.pid).
Feb 09 15:53:16 systemd[1]: mysql.service: Control process exited, code=exited status=1
Feb 09 15:53:16 systemd[1]: Failed to start LSB: start and stop MySQL.
Feb 09 15:53:16 systemd[1]: mysql.service: Unit entered failed state.
Feb 09 15:53:16 systemd[1]: mysql.service: Failed with result 'exit-code'.
Hope these information helps.

How can I reinstate a MariaDB server process that is simply no longer running?

For a particular project I wanted to have Mint (Sonja) appliance with all MariaDB and only MariaDB doing MySQL's work, without a hint of MySQL so I know I'm working with MariaDB.
The appliance is one where I've installed multiple open source projects that power their own website (Alfresco, Request Tracker, SuiteCRM, etc.), and all of them seem to have worked either with MariaDB, or just used Postgres without interesting difficulty, and up until I tried to create a new MariaDB database to add a clone of a specific Wordpress site, MariaDB worked predictably well with no headaches on the same system. Until now, where I can't seem to find a pulse.
The MariaDB troubleshooting page confirmed what I'd found in my investigations (in particular, a ps wwaux | grep mysql only turned up the grep process). The basic problem as I'd encountered it was when I tried to log in to create a database:
monk#toolchest ~ $ mysql -uroot -p
Enter password:
ERROR 2002 (HY000): Can't connect to local MySQL server through socket
'/var/run/mysqld/mysqld.sock' (2 "No such file or directory")
I've never gotten involved with MySQL's or MariaDB's /etc configuration files, but I looked briefly. They appeared sane to my uneducated eye.
Neither an aptitude reinstall mariadb-server nor a service mysql start produce any changes so far as I could tell.
For service mysql start, I got:
# service mysql start
Job for mysql.service failed because the control process exited with error code. See "systemctl status mysql.service" and "journalctl -xe" for details.
The details for systemctl status mysql.service were:
● mysql.service - LSB: Start and stop the mysql database server daemon
Loaded: loaded (/etc/init.d/mysql; bad; vendor preset: enabled)
Active: failed (Result: exit-code) since Fri 2017-07-14 18:16:38 EEST; 1min 11s ago
Docs: man:systemd-sysv-generator(8)
Process: 5011 ExecStart=/etc/init.d/mysql start (code=exited, status=1/FAILURE)
Jul 14 18:16:38 toolchest /etc/init.d/mysql[5479]: 0 processes alive and '/usr/bin/mysql
Jul 14 18:16:38 toolchest /etc/init.d/mysql[5479]: [61B blob data]
Jul 14 18:16:38 toolchest /etc/init.d/mysql[5479]: error: 'Can't connect to local MySQL
Jul 14 18:16:38 toolchest /etc/init.d/mysql[5479]: Check that mysqld is running and that
Jul 14 18:16:38 toolchest /etc/init.d/mysql[5479]:
Jul 14 18:16:38 toolchest mysql[5011]: ...fail!
Jul 14 18:16:38 toolchest systemd[1]: mysql.service: Control process exited, code=exited
Jul 14 18:16:38 toolchest systemd[1]: Failed to start LSB: Start and stop the mysql data
Jul 14 18:16:38 toolchest systemd[1]: mysql.service: Unit entered failed state.
Jul 14 18:16:38 toolchest systemd[1]: mysql.service: Failed with result 'exit-code'.
The recent (i.e. non-cronned) content of journalctl -xe ran:
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit mysql.service has failed.
--
-- The result is failed.
Jul 14 18:16:38 toolchest systemd[1]: mysql.service: Unit entered failed state.
Jul 14 18:16:38 toolchest systemd[1]: mysql.service: Failed with result 'exit-code'.
/etc/mysql/mariadb.cnf and /etc/mysql/my.cnf both read (comments stripped):
[client-server]
!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mariadb.conf.d/
/etc/mysql/my.cnf.fallback dropps the latter !includedir. Commenting out the latter /etc/mysql/my.cnf to match the fallback file produced identical results.
I can edit my question to include more of /etc/mysql/*, but I wanted to ask. Error messages similar to the ERROR 2002 are to be found in questions like Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (38), but these appear to be MySQL rather than MariaDB, and I suspect this may be a MariaDB-specific fluke.