FreeBSD

Add users to wheel group in FreeBSD

Add users to wheel group in FreeBSD
This mini-tutorial is about adding users to the wheel group in FreeBSD. While usually, we use the pw command to add users to groups in FreeBSD, you can also edit the group ID file to achieve the same. However, using the pw command-line utility is sufficient for this task; thus, our tutorial will focus on using the pw command to add users to the wheel group.

You'll need root access to configure groups with the pw command.

To add an existing user account to the wheel group, you'd use the command with the following syntax:

$ pw group mod GROUP-NAME-HERE -m USERNAME-HERE

For example, to add the user younis, we'd issue the following command:

$ pw groupmod wheel -m younis

Let's add a new user to the wheel group now. The command simultaneously creates a new user and add it to the group; the command syntax should be:

$ pw useradd USERNAME-HERE -G GROUP-NAME-HERE

As an illustration, we'll add a new user sai to the wheel group.

$ pw useradd younis -G wheel


The user sai will be created a new and also be added to the wheel group.

Check group memberships on FreeBSD with the commands below:

$ pw groupshow wheel

$ pw groupshow younis


To check the group memberships of particular users, use the id command as follows:

$ id younis

Wrapping things up

This tutorial showed you how to add both new users and existing user accounts to the wheel group. We used different variations of the pw command for our demonstration.

Gry Zainstaluj najnowszy emulator Dolphin dla Gamecube i Wii w systemie Linux
Zainstaluj najnowszy emulator Dolphin dla Gamecube i Wii w systemie Linux
Emulator Dolphin pozwala grać w wybrane gry Gamecube i Wii na komputerach osobistych z systemem Linux (PC). Będąc ogólnodostępnym emulatorem gier o o...
Gry Jak korzystać z GameConqueror Cheat Engine w systemie Linux
Jak korzystać z GameConqueror Cheat Engine w systemie Linux
Artykuł zawiera przewodnik dotyczący korzystania z silnika oszukującego GameConqueror w systemie Linux. Wielu użytkowników, którzy grają w gry w syste...
Gry Najlepsze emulatory konsoli do gier dla systemu Linux
Najlepsze emulatory konsoli do gier dla systemu Linux
W tym artykule wymienimy popularne oprogramowanie do emulacji konsoli do gier dostępne dla systemu Linux. Emulacja to warstwa kompatybilności oprogram...