Enable user for (enabled) Cockpit?

Can someone help a bit more on how to allow root in Cockpit?
Docs say that after enabling Cockpit I need to login as a member of wheel group and then enable administrative access.
wheel group has no users.
I added root to the group, still no go.

I need to make a new user and even if it doesn’t even have any other authority, just by adding that new user to wheel, will allow for managing the server?

Can u check please

1 Like

Don’t touch that file! As the Steph’s link says:

On all operating systems, logging in as root with a username/password via SSH has been disallowed for a long time. Cockpit now also disallows it by default on new installations

This is the default policy of Rocky Linux, the Release notes refer to it (Cockpit removed from pre-built image – Release notes — NS8 documentation).

The steps to create a user as member of wheel are a common Linux procedure, documented also for the SSH access to the pre-built image – Installation — NS8 documentation. As root execute:

useradd -G wheel ethan.smith
passwd ethan.smith

If the user already exists, usermod can be executed instead – usermod(8) — Arch manual pages

usermod -a -G wheel ethan.smith

In both cases you can then login from console or SSH as “ethan.smith”, and get a root shell by typing:

sudo su -

In Cockpit you can login as “ethan.smith” and enter the “Administrative mode”.

3 Likes

I didn’t touch the file “by hand”. :smiley:
I used usermod.

Anyway, thanks.

1 Like