Home > OS >  Small white first consult
Small white first consult

Time:09-27

Recently in learning python, learn some Linux based operating,
The first figure is to create a new user group after xiaohu, first give the xiaohu gives use sudo permissions, then switch to xiaohu users touch a file named xiaohu, found xiaohu file owner and user groups are root, rather than the new user's information, is this why?
The second picture is create a new user through adduser haha and xiaohu, then use the userdel -r command, found xiaohu and haha corresponds to the home directory has not been deleted, is this why? And then try to enter/home and then to delete the corresponding folder, also can't successful operation, also please predecessors advice

CodePudding user response:

Second question seems to have to deal with the because the most began to use userdel command is to use su to switch to the original user and not the exit, so delete users when they failed to remove success  but a second attempt to create a new user and delete, pop up a" xiaobai mail pool (/var/mail/xiaobai) was not found ", while the corresponding home directory to delete, but don't understand this popup information express what mean?

CodePudding user response:

You look it up in the su - & lt; Users & gt; And the su & lt; Users & gt; The difference between the "-" of the problem

CodePudding user response:

refer to the second floor Peg bigman response:
you look it up in the su - & lt; Users & gt; And the su & lt; Users & gt; The problem of the difference between the "-"
su - this like it and the first question is what relationship

CodePudding user response:

Xiaohu you create this file, use the sudo, sudo is to make ordinary users to perform some instructions as root, you create it's quite so root

CodePudding user response:

reference 4 floor zhouchao6 response:
xiaohu you create this file, use the sudo, sudo is to make ordinary users as root to perform some instruction, it's quite so you root created
that have a way to do it after creating a user by the name of the user as its owner?
  • Related