User Management

Fun with Linux - Changing the root user name

So, here is the crazy thing that I have been doing lately - changing the root username! It may seem absurd to some and simple/straightforward to others, but it was one of the most fun and learning times I had with Linux for a long time. In this post, I’ll tell you how I approached the issue and screwed up badly multiple times until I finally got it right.

Before we start, I want you to keep a few things in mind.

How to - Change the default shell of a user using chsh

You must have noticed that every time you open a terminal or login on a text console, you get a bash shell. And we don’t remember where was this option asked during the installation, right? The option for a shell is actually one of the user properties just like a user’s home directory, password, full name etc. Using chsh command we can change our default shell.

How to allow users in a group to run all commands in Fedora / CentOS using sudo

This tutorial will guide you on how to allow a group of users to run all the commands without sharing your system root password in Fedora / Redhat / CentOS based Distros.

How to add user to a Group on Linux

Managing users is an important activity in Linux. For a Sysadmin, you want different access permissions for developers, maintainers and moderators. Groups are an easy way to categorize users. Rights/permissions given to a group will be applicable to all its members. In this howto, I will tell you how to add users to a group.

I would suggest you to read about the two types of groups - Primary and Secondary, before proceeding.

The difference between Primary and Secondary groups in Linux

The security of a file on Linux is managed very well using the concept of ownership and permissions. There can be three kind of permissions - read, write and execute and similary the ownership is divided into three kinds too - a user, group and others. Groups are a great way to share your work or work in collaboration with others by defining a group, whose members have the write to contribute/modify/see the work.

How to Change Ownership of a file on Linux

File ownership is a way to manage files of different users and share files between users of same groups. Every file in linux is managed by a specific user and a group. The chmod command helps to define file permissions separately for user, group and others.

How to change username or UserID/uid on Linux

Usermod is a useful command to manage user settings. It modifies the system account files to reflect the changes that are specified on the command line. It is capable of doing a lot of things, but here we will see how to change username and UserID or uid on Linux using usermod.

Linux SysAdmin: Use w and ps commands to find out what other users are doing

There are several utilities to find out what other logged in users are doing on a system, who is currently active, remote host one has used to login, what processes are they runnning and similar such info. In this howto, I will show you how to use 'w' and 'ps' commands to get such information. Such info comes in handy to a sysadmin.

How to force inactive users to logout automatically after time out on Linux?

When you work on different servers from your system, the sessions are scattered over various terminals across different workspaces. Its a common mistake people usually make by leaving one or more of those server sessions open. Such sessions can lead to bad things if they get in hands of someone else. So, instead of blaming the user its always a good practice for sys-admins to automatically logout a user who is inactive for quite sometime.

How to force users to change their password upon first login?

In this tutorial we will force a new user to change the password upon first login. This is usually used by sysadmins. We will use a linux command 'chage' - which will change user password expiry information.

Syndicate content