6
votes
1answer
89 views

What are the side effects of having several UNIX users share one UID?

The sys-apps/shadow package on my GNU / Linux system comes with a useradd command that supports an option that I have previously overlooked: --non-unique. For the sake of convenience when shellig home ...
3
votes
2answers
1k views

How to change default shell to ZSH - chsh says “invalid shell”

I installed ZSH on a VM of mine, where I compiled it from source. The location of ZSH is /usr/local/bin/zsh when I run chsh -s /usr/local/bin/zsh it outputs chsh: /usr/local/bin/zsh is an invalid ...
1
vote
1answer
7k views

How can I create an SFTP user in CentOS?

I'd like to give temporary SFTP access to a support guy. How do I create an SFTP user? And how can I delete it once the job is done? Also, how do I specify a home directory for them? Can I prevent ...
0
votes
1answer
149 views

Why can my gentoo systemd installation only execute files as root?

If I try to login as any other user, via su it says 'permission denied'. If I use su -l it says 'canot cd to /home/<user>'. Logging in via the tty just kicks anyone without a message out except ...
1
vote
2answers
116 views

Wrong number of logged in users using “w”

There was a temporary network glitch and all user terminal ssh sessions were broken. Upon logging in to the CentOS server again and running the "w" command lists a higher number of users logged in ...
3
votes
2answers
47 views

Why does “logging out” of a session activate a newly added supplementary group? [duplicate]

I asked the following question Added user supplementary group, but 'groups(1)' not showing change earlier today. Now I'd like to know why the answer works. After running adduser user group ...
3
votes
3answers
206 views

How to switch back and forth between users quickly on a single terminal?

I'd like to switch to another user without logging out the first user, then log in as a third user without logging out the other two, and so on, then switch between all users quickly. I'd like to ...
2
votes
1answer
113 views

Is it possible to log directly into chroot?

Lets say I boot up my computer and I see the login screen. When I log in as myuser, I want to be restricted to a certain root directory via. chroot. Let's assume that the directory is ...
5
votes
3answers
6k views

Disable user shell for security reasons

We have several user accounts that we create for automated tasks that require fine-grained permissions, such as file transfer across systems, monitoring, etc. How do we lock down these user accounts ...
1
vote
2answers
412 views

Can't SSH/FTP into new user account in Ubuntu?

Created new user from shell script using following command: sudo useradd $1 -p $2 --home /var/www/$1 I'm not able to login to FTP or SSH as that user, do i need to add the user to some group for ...
12
votes
3answers
14k views

Which users are allowed to log in via SSH by default?

When I set up my Debian 6, I was wondering, which users apart from root whose password I know can log into my system via SSH? When I install Apache 2 a user called www-data gets created. Does this ...
5
votes
1answer
466 views

Run script when specific users logout

I need to run my application in screen when specific users are logged out and kill the screen when someone from my user list logged in. So I am thinking about bash script, which will be called ...
2
votes
1answer
443 views

Why am I not able to login directly using SSH

Suppose, the server address is abcd.com. On my local machine at my workplace, I have to login to that server, using ssh <my employeeid>@abcd.com Then, to login to user myname , I have to use ...
3
votes
2answers
4k views

new user can't login in Mint

I have created a new user in Mint 12, with this commands: sudo useradd irene sudo passwd irene //here I entered the password But if I try to login with this user the screen goes black for a ...
21
votes
5answers
1k views

Recovering from setting root's shell to a bad file

Let's say I've gone and done a silly thing, such as using 'chsh' to change the root user's shell to a bad file path. Future logins to the root account will abruptly fail, citing /bin/whatever not ...
27
votes
4answers
24k views

Disable a user's login without disabling the account

Let's say I create a user named "bogus" using the adduser command. How can I make sure this user will NOT be a viable login option, without disabling the account. In short, I want the account to be ...
5
votes
3answers
2k views

Can I allow a non-root user to log in when /etc/nologin exists?

Suppose a non-root user with sudo privileges executes a delayed shutdown (shutdown +10 or whatever) and logs out. Then, before the shutdown occurs, he wants to log back in and cancel the shutdown. The ...
4
votes
1answer
477 views

Why do I need to use newgrp or su (or logout and login again) to have new group memberships applied?

What is it that makes new group membership require a new login (or new login shell as started by su or newgrp) to be visible? Just running another bash (or whatever other shell) instance with --login ...
1
vote
2answers
5k views

How do I log out of all my active sessions?

For some reason, I have a few open sessions on an SSH server that I don't know about. I assume they're leftovers from when my pipe broke. $ users user1 user2 user3 me me me me Is there a way to log ...
6
votes
2answers
310 views

Using NIS without NFS

I'm configuring several computers in a lab to operate with the same login credentials shared between the computers, but without sharing the home directories. I'm considering using NIS for sharing the ...
10
votes
3answers
3k views

How can I make a user able to log in with ssh keys but not with a password?

I would like to create a user and have no password. As in you cant log in with a password. I want to add keys to its authorized_keys by using root. This is for my automated backup system.
57
votes
3answers
198k views

How to switch between users on one terminal?

I'd like to log in as a different user without logging out of the current one (on the same terminal). How do I do that?
6
votes
7answers
2k views

Is it bad practice to set root's shell to something other than the default?

Once a friend of mine (who is an experienced Unix/Linux user) told me that setting root's shell to something other than sh (i.e bash or zsh) might create problems, because some script might assume ...
9
votes
2answers
23k views

User's Login date and login time

I want to fetch user's login time and login date, is there any command in Unix providing User's login date and User's login time ? this problem i want to perform in Shell-script where username is ...
12
votes
11answers
1k views

Concern about logging in as root overrated?

For personal linux on my personal notebooks, I've usually set my environment to autologin as root even under X or lower runlevels. I've found my workflow is very pleasant and fast, without any ...
20
votes
6answers
11k views

How do you create a user with no password?

In os X it's possible to have users without passwords. If you inspect them with dscl their password show up as *. This is used for system users such as users for databases like mysql, pgsql etc. ...