this post was submitted on 13 Oct 2023
38 points (85.2% liked)

Linux

48193 readers
1664 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

My user account doesnt have sudo despite being in sudoers. I cant run new commands i have to execute the binary. Grub takes very long to load with "welcome to grub" message. I just wanted a stable distro as arch broke and currupted my external ssd

you are viewing a single comment's thread
view the rest of the comments
[–] jasondj@ttrpg.network 2 points 1 year ago (3 children)

Nah Debian 12 is weird. I recently installed on a few systems and they all do the same — usermod isn’t in roots $PATH by default, and my user account wasn’t a sudoer by default.

I’ve added myself to sudo but I keep getting “kicked out” when I start a new shell. Have to newgrp sudo to be able to sudo again.

[–] penquin@lemm.ee 2 points 1 year ago* (last edited 1 year ago)

On the Debian installer when it gets to entering the password when you create the user, you just skip the first password page (leave it empty) and enter your password on the next page. This adds you to the sudoers group. I've found this out the hard way.

[–] tal@lemmy.today 2 points 1 year ago* (last edited 1 year ago)

I’ve added myself to sudo but I keep getting “kicked out” when I start a new shell.

Group permissions from the /etc/group file get assigned at login. Each process will inherit group memberships from its parent.

You can see them for a process (self being the current process) in:

$ grep ^Groups: /proc/self/status

The gids there correspond to the gids in /etc/group.

That's why the need to log out the user in question after adding the user to a group, unless you're gonna use sg or similar to add that gid and then have all your new processes started by that process that you just started with the new gid.

You'll see this with all user memberships in groups on Linux. It's not behavior specific to Debian or specific to membership in the wheel or sudo group.