Anything related with user accounts and user management on Unix-like systems.

learn more… | top users | synonyms

1
vote
3answers
150 views

Is the user with UID 1 “daemon” on all systems?

I'm writing some testing code, and I'd like to know if it will be portable if it assumes that the user with UID 1 is named "daemon" on all Unix systems? EDIT: If not (the answer seems to be no), are ...
0
votes
2answers
214 views

Creating an automated idle process kill script

I would like to implement a solution to a specific instance of the generic problem wherein idle users tie up resources. I know the user list can be retrieved with w, the associated PID with ps, and ...
1
vote
1answer
101 views

How to switch a group without asking for a password?

In linux, there's two files where group definitions are specified. One of them is /etc/group and the other is /etc/gshadow. I want my regular user to be able to switch a group while starting a process ...
1
vote
1answer
58 views

Chdir fails even though the user has a home directory assigned

I'm facing this problem - when I ssh to the server, the user is authenticated correctly, but then the connection is closed with: Could not chdir to home directory /home/blazej: No such file or ...
2
votes
3answers
99 views

What does it mean a ! before the username field in /etc/passwd?

After doing some googling I could not find why in the /etc/passwd shows a ! at the beginning of the line. It looks like this: !user:x:0:0:user:/home/user:/bin/bash any ideas? my only guess is ...
2
votes
1answer
39 views

How do I set a script to randomly print to a user's SSH session without setting it up as a Cron job?

I'm managing a small server at work that we use for Samba and SSH. I'd like to mess around with my coworkers by having a script run at random times of the day where it fetches a random quote (...
2
votes
1answer
70 views

Editing passwd files other than /etc/passwd

UNIX users are usually managed in the well-known passwd file format. The corresponding file usually resides at /etc/passwd. Since editing this file by hand is very inconvenient (mostly because of the ...
0
votes
2answers
217 views

List logged in users (name, terminal, logintime)

I'm trying to print a list of users, who are currently logged on a terminal. It should look like this: I only got this so far: I'm missing the Terminal and the Login time. How can I display them?...
3
votes
1answer
150 views

Hyphen's availability in UNIX username

It is said that in UNIX and other alike systems, we can use hyphen for username in addition to Latin characters, numerics and underscore. On the other hand, the hyphen character is used as operator in ...
1
vote
3answers
92 views

Audit simultaneous logins in AIX

We are in a banking enviornment and our core system is based on AIX. Multiple users are logging in with the same userID at the same time using SSH. I know I can see who SSHed into the system from ...
2
votes
1answer
101 views

Can't send local mail message between users on linux

In http://unix.stackexchange.com/a/21336/99621 it says that if you do echo 'body' | mail -s 'subject' myuser It will send a mail message to the myuser linux account on the local system that this ...
3
votes
3answers
823 views

sudoer file how to give a particular user full access to only certain file

I want to give a user full access to only certain files, can someone show me how to do that? For example, I want to modify the sudoer file to grant user access to only certain file. Thanks.
3
votes
1answer
125 views

Access a file in PHP through a symbolic link from a user that normally doesn't have permission

I have this website, where if the user submits a form, a python script is executed through a php page, and the python script creates a zip file and should offer it to the user for download through a ...
-1
votes
1answer
65 views

Allowed group can't access a folder [closed]

I've a weird problem on my linux machine, I've multiple users, we can say u1, u2, u3... who all belong to a group G. I have a group folder in /home who belong to one of these user (we'll say u1), and ...
0
votes
6answers
1k views

How can I find out which users are in a group within Linux?

I've recently been creating new users and assigning them to certain groups. I was wondering if there is a command that shows all the users assigned to a certain group? I have tried using the 'groups' ...
1
vote
0answers
70 views

Is this a Hacker? What to do?

My sites are hosted in a shared server at Hostgator. Server details: uname -a Linux xxxx.hostgator.com x.xx.x.x86_64 #1 SMP Fri May 1 18:21:30 CDT 2015 x86_64 x86_64 x86_64 GNU/Linux I was curious ...
2
votes
0answers
335 views

How could a user log in via tty

I rented this cloud server, and it is kind of attacked recently. I can see a suspicious user logged in via tty. leetom@S152:~$ last -x ayn1 ayn1 tty1 Wed Oct 28 18:59 - ...
3
votes
2answers
102 views

Creating a user having only access to folder & sub-folder which is present in other user of the same System

I have 2 users on my ubuntu system, User1 and User2. I have a directory(folder) in User1 as /home/User1/Software and I want to set this Software folder as home directory of User2 so that whenever ...
0
votes
2answers
33 views

User-dependent packages/files in /lib

I have setup a 2-seat computer. I start one X11 server using the computer's onboard graphics card (intel) and another in the dedicated one (nvidia). Everything runs fine, except opengl. Currently, ...
1
vote
1answer
95 views

Security - Runing Daemon, program as root or user vs sudo su

I have some questions about Linux security: Running a process as root is a big mistake (root has too much power + a program get too much permissions in the system). I always ran processes as a user (...
3
votes
1answer
70 views

chpasswd and openssl

I'm trying to pass an MD5 password to chpasswd but it doesn't seem to work. echo username:$(openssl passwd -1 -salt salt password) Then I try to pass this to chpasswd to change the password echo '...
2
votes
1answer
45 views

how to prevent access to other user with same user id (UID)

I have two Linux OS installed in two partitions in my system. However I have few usernames which are common in both partitions. For ex, I have user friend in both the OS. I have noticed that friend ...
2
votes
0answers
49 views

How to kill all vpns on switch user Mint 17.2

I'm using mint 17.2 cinnamon. I'm not particular about the method, just want it to stop all vpn connections (openvpn, listed in network manager) when I switch users or logout. nmcli doesnt provide a ...
9
votes
1answer
155 views

How can I create an account with a copy of the same home folder?

I have a 'user1' account with the home folder set up. I'd like to create a 'user2' account with a copy of the same home folder setup. Is it possible to do this?
3
votes
1answer
216 views

Why useradd -m doesn't fill created home dir with some defaults?

My motives: I want to create deployment script which prepare all system with just 1 click, and although learn Linux this way. So I don't want to use interactive utils like adduser (all interaction ...
3
votes
1answer
104 views

Why there is a group member field in both /etc/group and /etc/gshadow

I am learning more about Linux user and groups in depth and noticed fourth field in both /etc/gshadow/ and /etc/group are exactly same. Do they have any difference or is there any special reason why ...
0
votes
1answer
206 views

user exists when trying to add user to systemd-journal group.

I have been wanting to read systemd-journal by running/using journalctl -b . Now if I run it as a user I get the following :- $ journalctl -b Hint: You are currently not seeing messages from other ...
2
votes
4answers
200 views

Authentication failure on Amazon Linux

There is an authentication failure when I'm trying to enter password for any of my accounts. I am logged in using ssh to my AWS EC2 instance. After a while I checked the privileges to files that ...
1
vote
2answers
106 views

Which user is running the most processes?

My top looks like this: PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 6524 asjzdiwq 30 10 500m 41m 24m S 0.0 0.3 0:15.27 php-cgi 21274 asjzdiwq 30 ...
0
votes
0answers
29 views

newusers causes segfault

I am trying to bulk-add 433 users via newusers. The newuserlist.txt file I have contains users with up to 16 chars usernames with questionable patterns (numbers at the beginning and capital letters). ...
0
votes
1answer
2k views

$USER != whoami

I'm trying to re-install homebrew on my mac. I get this error: michaels-1856:~ michael.snowden$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" ==> This ...
2
votes
0answers
51 views

Changed username - Could not update ICE authority file

I tried to change my username by creating another admin account, restarting, then logging into that new account. Then, I entered the following command: sudo usermod -l NewUserName -d /home/...
2
votes
2answers
4k views

When trying to change username, terminal tells me user is currently used by process

I am trying to change my username, as per advice here however after running the following command: CurrentName@HostName ~ $ sudo usermod -l TheNameIWantToChange -d /home/TheNameIWantToChange -m ...
0
votes
2answers
132 views

How to add “system” local user like mysql or tomcat?

My system has a lot of users, I'v never created, like mysql or tomcat. These users have no home directories inside /home Obviously, a daemon programs run under these users. What is the term for such ...
0
votes
1answer
281 views

Creating a new FTP user and giving him only the right to 1 folder [duplicate]

I have a Linux Debian machine that I own (root access). I would like to create a new user called "testuser" and give him the right to view, edit and delete files from only one specific folder ...
3
votes
3answers
159 views

How can I run a program as another user in every way?

Background I'm trying to restart some programs (mail-notification and stalonetray) regularly, as they appear to die frequently. I want to set restart them whenever NetworkManager reconnects. Hence, I ...
7
votes
2answers
101 views

How to completely remove the user subsystem from Linux?

Is it possible to completely remove the user subsystem from Linux. I'm NOT talking about preventing people from logging in. I'm talking about removing the parts of the system that even make it ...
0
votes
0answers
64 views

root's login shell is invalid, how do I restore it?

I have accidentally changed the root user's shell from /sbin/sh to /sbin/false. I don't have any other login and the only way I can access to system is through SSH. How can I retrieve back root ...
0
votes
0answers
77 views

Creating a new user for FTP with access to a specific dir

After following all of the instructions found here: How to create a FTP user with specific /dir/ access only on a Centos / linux installation I am having some troubles. For some reasons the new ...
2
votes
1answer
115 views

How to Use who/w with Non-Interactive SSH logins

I'd like to perform selective shutdown of a server in my house after backing-up over SSH. My post-backup script waits for five minutes and then runs a very short 'safe shutdown' script located on the ...
-2
votes
1answer
467 views

Changing normal user uid to 0 to normal uid

I have given a normal user root permissions on Linux by using this command: usermod -u 0 -o username How can I go back and make the user a normal user again? ex: # grep Jack /etc/passwd Jack :x:...
1
vote
2answers
114 views

Lock a user with his home folder

Is there any way of making a user only able to see and modificate his home folder? I am currently on arch linux. Just explaining a little better, the user would not be able to see /etc or any other ...
3
votes
0answers
99 views

Use network-manager in different netns

In continuation of my last question about using netns as a relugar user, I'm now looking for a way to open VPN tunnels as a regular user. So I naturally thought about network-manager. Any user can ...
0
votes
2answers
303 views

What user should I create and execute cron jobs as? Apache? Root? Me?

I'm setting up a new Webserver and having trouble getting cron to execute as expected. I am using a script to create cron jobs in .tmp/crontab.txt, which is then moved to /var/spool/cron under the ...
0
votes
0answers
29 views

sftp user with appropriate permission

I'm new to linux user permissions and having trouble configuring a user. So the scenario is, I have apache installed on centos. I've a virtual host with document root at /var/www/sitename/public_html ...
0
votes
0answers
75 views

How to Duplicate user?

I'm in Cloud 9 IDE, and I want to clone the default user for better collaboration. I know it's not just a simple copy of the /home/<username> folder from Archlinux wiki, which tells me about ...
2
votes
1answer
410 views

Checking how long a user has been logged in

Is it possible to check for how long a user has been logged in? Or when the user logged in on an Unix/Linux system? I logged in as another user on my system a while ago and I would like to now how ...
0
votes
1answer
79 views

Where do service permissions come from

I'm trying to broaden my knowledge of the events surrounding system startup. I see that there are many process which are started without root level permissions. e.g. rsyslogd is listed as running ...
1
vote
1answer
748 views

usermod always reports user does not exist on RHEL 6.6

My RHEL 6.6 VM is running behind Centrify Active Directory. When I do sudo id 'any_existing_user' it will give back info about that user. But when I do sudo usermod -c 'Comments' '...
2
votes
2answers
284 views

Can I log in into a system user after I create him?

On an Ubuntu machine, if I run the following command: adduser --system --no-create-home system-user I create a system user named system-user without home directory with /bin/false as the shell. This ...