8 votes

Is there a good way to allow non-root users to mount arbitrary external USB drives on Linux?

You could use udisks2, which allows users to manage and mount storage devices without root access. Setup Install the tool: sudo dnf install udisks2 ntfs-3g fuse-exfat Allow user to manage: sudo ...
Saxtheowl's user avatar
  • 1,172
7 votes

Upgrade OS on ZFS file server

If there is not much to configure, I'd perform a fresh install. But your plan looks sensible, and if there is much configuration (and it wasn't automated), the upgrade path is to go. I went it once (I ...
Nikita Kipriyanov's user avatar
3 votes
Accepted

Why does xinetd try to close file descriptors on startup?

Many traditional daemons do this, as part of their "daemonization" sequence which is meant to avoid inheriting anything from a user's environment, as traditionally (before IPC-oriented init ...
u1686_grawity's user avatar
3 votes

Why is pvscan skipping my devices?

This is probably down to the existence of /etc/lvm/devices/system.devices. If that file exists, LVM will use the contents as a device list. If it doesn't exist then I believe the behaviour will go ...
Colin's user avatar
  • 31
3 votes
Accepted

Why is pvscan skipping my devices?

Listing out all potential reasons which case pvscan skip it. An lvm.conf filter containing symlinks to the dev like /dev/disk/by-id/lvm-pv-uuid-xyz entries. To use a device with lvm, add it to the ...
asktyagi's user avatar
  • 2,934
3 votes
Accepted

CentOS: Admin user on xrdp session can't do admin

Having framed yesterday's frustrations more succinctly, I used a well-known search engine to look for "linux polkit local and remote sessions" and got this as the top result - Enabling ...
kbro's user avatar
  • 280
3 votes
Accepted

Enable BTRFS in kernel (running Rocky Linux 9.2)

EL has not included btrfs since 7, no. Options exist for Red Hat family distros, which to choose depends on whom you trust to maintain your OS. Fedora is an option, same as the source OS. Obvious ...
John Mahowald's user avatar
3 votes

Email all cron stdout+stderr output only on stderr

If the command exits with a non-zero status code, you could try: bash -c 'command 2>&1 > /tmp/err || mail -A /tmp/err [email protected]' where: bash -c '' enables using multiple commands on ...
Esa Jokinen's user avatar
  • 49.8k
2 votes
Accepted

Postfix causes issues when its service is enabled using systemctl and doesn't launch on boot

This sounds like a SysV and systemd conflict. Try to disable the service in systemd and reboot and see whether it runs. It probably will be running. sudo systemctl disable posfix sudo init 6 Note ...
Alexis Wilke's user avatar
  • 2,276
2 votes
Accepted

mariabackup fails with Error: cannot mkdir 2: /data/backups/mariadb/

You've got a typo in your commands. The commands mkdir -p /mnt/data/backup/mariadb chown -R mysql:mysql /mnt/data/backup/mariadb created the directory /mnt/data/backup/mariadb but the command ...
Tilman Schmidt's user avatar
2 votes
Accepted

Why is my Linux console polluted with messages?

Not sure what the default is on Rocky Linux, but there is a kernel configuration value kernel.printk that controls the level of alerts sent to the system console. You will want to adjust this. So ...
Zoredache's user avatar
  • 132k
2 votes
Accepted

Virsh command hangs when script runs in the background

I guess that this happens because of pkttyagent. This example shows, how the process is hanging in the background: # virsh list & [1] 2121077 # [1]+ Stopped virsh list # ps f ...
mre's user avatar
  • 36
2 votes

Install QEMU for Docker Buildx on Rocky Linux 8

Install the Fedora 28 qemu-user-static package: The following instructions will download the Fedora 28 GPG key and RPMs needed to load qemu, then import the GPG key and install the RPMs: mkdir qemu-...
Compholio's user avatar
  • 121
2 votes

nftables firewall configuration on Rocky 9.1

Answer to myself - the best understanding up-to date. Please correct me if I'm wrong. Linux uses netfilter for the actual firewall functionality. There are a couple of inspiring pictures in this ...
user2780979's user avatar
2 votes
Accepted

Disabling GSSAuthentication in sshd_conf has no effect

What do you have in /etc/ssh/sshd_config.d? 50-redhat.conf seems to enable it and it is included early on. As far as I remember the first occurrence in sshd_config wins. Following on the comment: ...
Tomek's user avatar
  • 3,563
2 votes

Is there a good way to allow non-root users to mount arbitrary external USB drives on Linux?

I think I nailed it. Add the following polkit rule to /etc/polkit-1/rules.d/10-allow-usb-mounts.rules: polkit.addRule(function(action, subject) { if (action.id == "org.freedesktop.udisks2....
bolind's user avatar
  • 201
2 votes

I want to make Linux Kernel Source an RPM file

I found the answer. The following has been omitted. sed -ri '/CONFIG_SYSTEM_TRUSTED_KEYS/s/=.+/=""/g' .config Found in the rockylinuxs document. https://docs.rockylinux.org/guides/custom-...
gotothesky's user avatar
2 votes

How to fix NetworkManager-dispatcher script permission denied error?

I had the exact same issue (with a different service) and the short answer is SELinux is preventing the NetworkManager dispatcher script from restarting zerotier-one.service. You'll need to create a ...
JoelG's user avatar
  • 53
2 votes

NGINX 403 ACCESS DENIED

As you have SELinux enabled you need to put your files into /var/www/html as this directory has httpd_sys_content_t context which allows read access to files for the php-fpm. Otherwise, you need to ...
AlexD's user avatar
  • 10.3k
1 vote
Accepted

Could not bind to address no listening sockets available

My solution was to override /usr/lib/systemd/system/httpd.service: # systemctl edit httpd Adding network-online.target to After: ### Editing /etc/systemd/system/httpd.service.d/override.conf ### ...
Clodoaldo's user avatar
  • 433
1 vote
Accepted

SELinux support for OpenStack deployment on Rocky Linux 9

It looks like the RDO project, which has OpenStack packaged for CentOS-9-stream, uses the same repository to which you've linked. If you look at the available packages, they're using openstack-selinux ...
larsks's user avatar
  • 44.9k
1 vote

Is there a good way to allow non-root users to mount arbitrary external USB drives on Linux?

You could configure sudo to let users execute some specially crafted script to mount usb drives on a fixed mount point indicating only the device. As an example, they could run: sudo mount-usb /dev/...
Fjor's user avatar
  • 216
1 vote
Accepted

SystemD memcached service - (code=exited, status=1/FAILURE)

What you're doing right now -- creating /var/run/memcached via ExecStartPre -- is fine, but the canonical way of handling this is via the systemd-tmpfiles service. You create /etc/tmpfiles.d/memcache....
larsks's user avatar
  • 44.9k
1 vote

How to use cgroup v2 to limit memory and cpu per user group?

Is there anything similar like cgconfig and cgred for cgroup v2? Cgred is a part of libcgroup. General support for cgroup v2 was added in libcgroup v2.0. Cgconfigparser and cgred works with cgroup v2 ...
wirt's user avatar
  • 11
1 vote

NFSv4 and CentOS

Don't specify fsid=0 for /hpc. Doing this turns the directory into the "export root" for NFSv4, meaning that e.g. your /hpc/projects directory is exported as server:/projects instead of ...
u1686_grawity's user avatar
1 vote

Kubelet Error - the container runtime endpoint address was not specified or empty

I managed to bring my cluster up. First thing that I did was to put --container-runtime-endpoint=unix:///run/containerd/containerd.sock in /usr/lib/systemd/system/kubelet.service.d/10-kubeadm.conf ...
Lucian's user avatar
  • 11
1 vote
Accepted

SSL error "unexpected eof while reading" on same server as the originating request

A useful error message would have been helpful, but essentially this boiled down to curl not negotiating one of the limited (but available) ciphers and so failing during the handshake. I had to ...
oucil's user avatar
  • 598
1 vote

CentOS 7 upgrade to RockyLinux 8 fails using leapp/elevate

I suspect you were lead astray by an outdated article that has not been revised recently. I happen to use leapp and have performed OS migrations, via convert2rhel, as well as major distro upgrades via ...
Illuminatus's user avatar
1 vote
Accepted

ceph-deploy install command fails with [ceph_deploy][ERROR ] RuntimeError: configparser.NoSectionError: No section: 'main'

The deployment tool ceph-deploy has been deprecated in favor if cephadm a couple of releases ago. Although this doesn't really answer your question it's gonna be difficult to keep ceph-deploy ...
eblock's user avatar
  • 467
1 vote
Accepted

Make IP route and routing rules permanent using nmcli on RHEL 8 / Rocky 8

I'm pretty new to networking, so please bear with me! I'm seeing extra terms such as proto static on the first line... You see proto static because you have created a static route. Routes created by ...
larsks's user avatar
  • 44.9k

Only top scored, non community-wiki answers of a minimum length are eligible