two owners for one dataset

pet1022

Dabbler
Joined
Oct 26, 2022
Messages
13
Hello to all,

While configuring my new Truenas installation, I noticed that it was possible for two users to own the same dataset.
Does Truenas allow this?
 

Ericloewe

Server Wrangler
Moderator
Joined
Feb 15, 2014
Messages
20,194
Possible where and how? Can you elaborate?
 

pet1022

Dabbler
Joined
Oct 26, 2022
Messages
13
In the profile of a user, when you assign him his main directory.
If Paul is the owner of the TOTO dataset, I noticed that I could also assign the TOTO dataset as the main dataset to Peter.
I hope I was more explicit.

Capture d’écran du 2022-10-26 22-19-07.png
 

pet1022

Dabbler
Joined
Oct 26, 2022
Messages
13
Hello,
Yes, that's what I thought at first.
In the web interface, when I assigned the "TOTO" directory as "main directory" to Peter, Truenas did not throw me out. He should have warned me that this dataset already had an owner.
Or, he de-assigned Paul's "TOTO" to Peter's profile record. But when I went to Paul's profile, "TOTO" was still assigned as Paul's "main directory".
I have not yet gone to see (in command line) who was the real owner of the "TOTO" dataset.
But in the web interface, there should be an "alert", because visually in their respective profiles, peter and paul are both owners of "TOTO".
 

pet1022

Dabbler
Joined
Oct 26, 2022
Messages
13
Hello,
I have done some tests.
Indeed, by doing an ls -l on the datasets, the owner has changed. But in the web interface, when you go to their respective profiles, Paul and Peter are both "owner" of the same dataset "TOTO". A restart of the server is not enough to update the right parameters.
Be careful who is the owner, because as in my case, it played tricks for my ssh connection.
To redefine the initial owner (without going through the command line), you have to unlink the two users defined on the same dataset (for example by putting them in /nonexistent), and only then redefine the initial user.
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,553
Being the owner of a directory is not the same thing as having it set to your homedir path. Generally speaking it's not a great idea to try to set identical homedir paths for multiple users.
 

pet1022

Dabbler
Joined
Oct 26, 2022
Messages
13
Hello,
It's not that obvious. In the web interface, and unless I'm mistaken, when you define a personal directory on a user's profile, this user automatically becomes the owner of it!
No, this is not a good idea, but this manipulation could be "forbidden" by Truenas.
In my case I was testing my datasets and I needed to put a user on another dataset, I didn't know if this one already had an owner defined, it's by pure chance that I discovered this. But this could happen in production mode, and we would not be notified that the owner of a dataset has changed.
 
Top