如果可以如何添加同一uid下的多个用户名?
业精于勤,荒于嬉;行成于思,毁于随。
useradd-u user number specifies the uid. If the -o option is also present, the uid of other users can be reused.
Isn’t this design unreasonable? Why does one uid need multiple users? If you want to design it as one account that can add sub-accounts, then the uid is still unique, and you need to add a pid, pointing to the uid of the parent account
You should build a relationship table, one-to-many A table: id uid
B table (relationship table): A.id userName(1,2...)
Yes, the kernel ultimately identifies the user based on uid.
uid
Wouldn’t it be enough to set each username into a field, such as username1, username2...
useradd
-u user number specifies the uid. If the -o option is also present, the uid of other users can be reused.
Isn’t this design unreasonable? Why does one uid need multiple users? If you want to design it as one account that can add sub-accounts, then the uid is still unique, and you need to add a pid, pointing to the uid of the parent account
You should build a relationship table, one-to-many
A table:
id uid
B table (relationship table):
A.id userName(1,2...)
Yes, the kernel ultimately identifies the user based on
uid
.Wouldn’t it be enough to set each username into a field, such as username1, username2...