Questions tagged [non-root-user]

Use for questions where tasks usually considered as "system-administrative" are to be performed by a regular, non-admin user, and/or for tasks or configurations that should not be performed system-wide but only apply for one such user (e.g. local software installation). Don't use for questions about a specific way to gain root privileges if there is an appropriate tag for that available.

Filter by
Sorted by
Tagged with
0 votes
1 answer
56 views

How do I switch users with their groups groups in Python?

How do I switch to an admin-user account from this python script named root_and_user.py that was run with doas or sudo? #!/usr/bin/env python3 from os import geteuid, seteuid from subprocess import ...
2 votes
1 answer
111 views

Why doesn't this script succeed from crontab as it does when manually run?

This script works when executed with doas ./backup_cron_root.sh #!/usr/bin/bash /usr/bin/crontab -l> "/tmp/cron.$(whoami).$(hostname)" && /bin/date>>"/tmp/cron.$(...
0 votes
2 answers
104 views

How to install Git on a CentOS 7 host as a non-root user?

As a non-root user, I want to install git (version = 2.38.1-1) on a shared host CentOS 7 server because the original version of git on the host is too old. I tried to use the method in this answer to ...
  • 1
0 votes
1 answer
73 views

how to check whether some dependencies are lack before a rpm package is installed by a non-root user

I am a non-root user on a shared centos7 server host.I try to install some softwares on this machine according to the method in the link. How can I check whether some dependencies are lack before ...
  • 1
0 votes
2 answers
473 views

Podman w/Docker Compose - run as user?

I'm trying out docker-compose with Podman which according to this is now supported. I run the instructions and can indeed hit the socket when running as root but when I try as user I get: permission ...
0 votes
1 answer
46 views

How to exit from root to user in the recovery menu?

A newcomer to linux here, I was trying to set a custom display resolution and make the changes permanent but looks like I've forgotten something and the login screen won't come up (the only thing I'm ...
0 votes
0 answers
140 views

run openconnect without sudo

I want to start a VPN connection without needing to type in the password to the VPN connection or the password for sudo and without saving the password on my pc accessible to any normal users. ATM I ...
1 vote
1 answer
200 views

How to add a non-root user when building a Docker image with Nix

I can use Nix to specify a Docker image: { pkgs ? import <nixpkgs> { } , pkgsLinux ? import <nixpkgs> { system = "x86_64-linux"; } }: pkgs.dockerTools.buildImage { name = "...
  • 365
1 vote
1 answer
140 views

systemd run fossil as non-root user

I want to run fossil as systemd service under non-root user. useradd -r fossil touch /etc/systemd/system/fossil.service fossil.service file: [Unit] User=fossil Group=fossil Description=Fossil ...
1 vote
1 answer
84 views

Im having useradd error in arch-linux

Im installing arch-linux for the first time and im following a video on youtube and im creating a non root user with the command '' 'useradd -G wheel.audio.video - m nour11''' But im getting the error ...
0 votes
0 answers
49 views

I lost my Amazone Lightsail root permission

I have an amazon lightsail account with free credits that I was using for my educational purpose. With that account, I created an instance and installed a free trial of cpanel. I was doing some stuff ...
0 votes
0 answers
34 views

Ramifications of renaming a user [duplicate]

I'm setting up two computers with MX Linux that will be nearly identical, with a lot of customization from the original distro. I installed and customized the first one for User1, and will basically ...
  • 623
0 votes
1 answer
47 views

Is there a user-level utility which offers the features of "cron" or "at" and only within a particular session?

I want to run a some scheduled commands on a timed basis within a manually startedscreen session and only within that screen session, because it uses an ssh authentication tied to that session. ...
  • 7,021
2 votes
2 answers
392 views

Best practices for running a rootless container as a systemd service with User= or --user?

I'm experimenting with running rootless containers with Podman as systemd services. I'd also like to run the services themselves with non-root privileges, either: a) as a system service, but with User=...
  • 131
0 votes
1 answer
380 views

Sudo Command Not Found for Plesk User

After adding a user to sudoers, it doesn't have access to run sudo. I'm really stumped as to what the issue is but I am running CentOs 7.9 with Plesk installed. I have added the main Plesk ...
  • 153
0 votes
0 answers
25 views

Giving ownership and permission to non-root user from inside script

I have an automated process that installs a script on an Ubuntu 20.04 server as root, and then runs it, as root. Inside the script, I create a directory, say, foobaz and install an executable in that ...
0 votes
0 answers
17 views

Categorizing Debian Linux VPS

I like to Categorize or Divide one Debian VPS for different Tasks and Testing. For Example two Apache Web Servers with no any connection between both. Something like installing apache2 web server only ...
1 vote
0 answers
297 views

Figuring out which user is best to start pm2

I'm about to deploy a highly secure production server, which is running an nginx reverse proxy, which points to the backend server on nodeJS. When a user starts the server by typing in the "pm2 ...
3 votes
0 answers
142 views

Alternative to "gksu" in "su" mode for non-root users

On an Oracle Linux 8 installation, I am trying to implement a desktop launcher for the GNOME shell where the (graphical) program is to be run as a different (non-root) user. However, I want to enforce ...
  • 21.1k
0 votes
1 answer
96 views

blocking commands as non-root

This is a very specific request, I am afraid. I am a non-root user at a CentOS Linux 7 machine. The admin team is normally very helpful but there is zero response for that case, unfortunately. So I ...
0 votes
0 answers
45 views

can something like --rsync-path be done with scp?

scp is handy sometmes because of its -3 feature. Systems here are configured to disallow root login, however sudo is configured to allow certain folks to pass --rsync-path=sudo\ rsync. i'd like to ...
  • 61
4 votes
1 answer
3k views

How to allow non root users to access root directories?

I want to secure my linux server by not permitting the root user to login. For this I've created another user with: useradd username mkdir /home/username/ mkdir /home/username/.ssh chmod 700 /home/...
  • 143
0 votes
1 answer
53 views

Creating a soft link

I'm trying to create a soft link for a file but keep getting a permission denied message. I don't want to create it under the root user but a different user I have created. This user has rwx ...
0 votes
0 answers
100 views

Create a new user in linux that does not have access to old user's applications

I am using Manjaro, I have a admin account with virt-manager installed to it. But I want to make some modifications to virt-manager package and build it again. I want to do this in a new account, ...
  • 1
1 vote
1 answer
2k views

How to make a loopback device writable for normal user?

I setup a loopback device following this guide. The device is OK, but only writable for root. I searched solutions and found some answer such as using fusermount, fstab etc., e.g. this one. I would ...
  • 151
0 votes
1 answer
53 views

Can I require per-user AuthenticationMethods when switching from a non-root user to a root user?

I currently SSH into a root user from another machine with an SSH key & 2FA, so I set AuthenticationMethods publickey,keyboard-interactive. If possible, I would like to be able to SSH into a non-...
0 votes
0 answers
173 views

Unmount without sudo

I know that I can declare in /etc/fstab that a user can mount and unmount a partition without root permission using user(s). But I seem to be unable to achieve the same in a mount command without ...
  • 489
1 vote
1 answer
77 views

Installing software by ./configure, make, make install

I have access to a computer through SSH, and need to install Davinci Resolve without the root access. I only have access to the command line, and cannot use sudo for installation. The documentation of ...
  • 11
1 vote
0 answers
17 views

Catch the root command exit code from a regular user [duplicate]

I've been researching umount exit codes for some error cases, running the following command repeatedly: $ sudo sh -c "umount /home; echo $?" And got surprisingly strange results. The error ...
  • 111
1 vote
1 answer
178 views

Custom daemon: which user could I use to run as, to avoid using root?

I want to write a daemon that launches after boot, before login, that does background communication over USB-rawhid with an Arduino microcontroller. I would like to run this daemon as non-root. I ...
  • 797
0 votes
2 answers
396 views

Is it possible to install Clash on the Server without root access?

I asked this question a few years back but it seems like it is not useful for all softwares. I am in the same scenario but with different software. Is it possible to install Clash on the Server ...
  • 131
0 votes
0 answers
40 views

Permission to read /var/log/ files on separate system (Chrome OS Linux terminal)

I need to access two drives which won't boot to their original systems (Raspberry Pi OS on SD card & Ubuntu 20.04 on HDD). As both of these devices are (mostly) inaccessible, my only option is to ...
0 votes
1 answer
430 views

What's the most appropriate directory where to place development software shared between users?

About share data (files and directories) among users within the same machine, has sense use the /srv directory it according with: What's the most appropriate directory where to place files shared ...
2 votes
1 answer
242 views

In a user namespace as non-root, on a nosuid,nodev filesystem, why does a bind mount succeed but a remount fails?

In a Linux user namespace, as non-root, I bind mount /tmp/foo to itself. This succeeds. Then, I try to remount /tmp/foo to be read-only. If /tmp is mounted with nosuid or nodev, then the remount ...
  • 1,386
2 votes
1 answer
552 views

Non root user is not able to open any ports

I have an embedded Linux System built using Yocto. Just out of build, it only had a root user. I created a new user. This new user is not able to open any ports on the system even though they are ...
  • 131
2 votes
2 answers
818 views

Why would having a user without a password be a bad idea (in this scenario)?

I thought about whether to post this here or in security SE... but decided to go with Unix SE since this isn't really a question about cryptography stuff but more about Linux users / privileges. Maybe ...
  • 551
0 votes
1 answer
171 views

Change the Owner access Charlie root to user at a media device, possible?

how can I change owner access from Charlie root to user access for my media devices (partitions /media/da0s1) on FreeBSD?
1 vote
1 answer
793 views

Change shell from bash to ksh permanently with no admin rights

I need to change my PuTTY shell from bash to ksh permanently. The chsh command and editing /etc/passwd are not available to me as I don't have admin rights. Please help me understand what needs to be ...
  • 13
0 votes
1 answer
816 views

Disabling root and creating a new user Ubuntu 20.04 to run/install applications

There's been a lot of articles that state to disable root user and create a new user. One of the reasons is that root is a known account and bots can easily target. So I need to create a new user with ...
1 vote
2 answers
326 views

During the installation of Kali Linux when I set username and password, this user is root user or non-root user?

During the installation of Kali Linux when I set username and password, this user is root user or non-root user? If I login into m Linux system using this username and password and type whoami, it ...
  • 13
0 votes
1 answer
65 views

How to run a command from /etc/sudoers.d/ file noninteractive way?

I am automating dpkg-sig installation for one of my project purpose. Now I want to install it noninteractive way. I have added the following in a file inside /etc/sudoers.d/ Cmnd_Alias DPKGSIG_INSTALL ...
2 votes
2 answers
932 views

Non root user unable to conect wifi network on the standard way [LINUX MINT]

I am a enthusiastic linux user and I offered my experience to perform system upgrade on 40 old Classmate PCs (SEE system information on image bellow ) which were runing a deprecated ubuntu version. So,...
  • 79
0 votes
1 answer
323 views

How to locate Alien/Package/Deb.pm?

Try to install alien without root. cd /tmp; mkdir alien; cd alien yumdownloader --destdir ./ --resolve alien for rpm in glob.glob("*.rpm"): rpm2cpio rpm | cpio -id cd usr; export PATH=./...
  • 163
0 votes
1 answer
340 views

Run services as user without X (systemctl)

I have a small server running a minimal centos8. I need to create services as a user and would like to use systemctl to do so. I found I can use systemctl --user to create services without root ...
  • 101
0 votes
3 answers
391 views

How to selectively provide root access to only files that need it? [closed]

Sometimes a command I'm executing needs to access a directory that's owned by root, e.g. npm install -g ... might put a symlink in /usr/local/bin I don't wish to run the command using sudo because ...
1 vote
1 answer
216 views

Shut down after offline updates with PackageKit from command line

When PackageKit has updates fetched for installation and you use the Gnome GUI to shut down the machine, it is possible to set a checkbox to install updates before shut down. How can this be ...
  • 31
0 votes
0 answers
152 views

Pipe to the clipboard in command line, with no root privilege to install

Normally I use xclip to pipe results into the clipboard. However, on a cluster I am accessing I don't have the required root privileges to install it. (I tried copying over files but then got into ...
  • 321
16 votes
2 answers
7k views

What does the `--system` flag for **adduser** do?

What is the purpose and benefit of using the --system option when adding a user, or even a group? I'd like to know why I'm seeing this added to many Docker containers and recommended as a best ...
  • 4,194
1 vote
1 answer
201 views

How to restrict users so that they can only execute commands from /bin?

I was provided an assignment with several questions. One of the questions is: How to restrict users can only execute the commands in the directory /bin? I tried to solve it by using the following ...
1 vote
3 answers
410 views

Rootless "unshare -m" like bubblewrap?

On my Linux host unshare -m refuse to go without root. Bubblewrap bwrap --dev-bind / / --ro-bind-data xxxx xxxx and bwrap --dev-bind / / --tmpfs doesn't require root. (no setuid on bwrap) How can I ...

1
2 3 4 5
9