Hi,
Deleting a userprofile in a RDS environment which has a broker and a filecluster with UPD is quite cumbersome so I would like to automate the process.
The function:
1.queries the number of the disk attached to a user on RDS: you can see on the vhdx (in security) who is the owner, but howto via powerhsell?
2.query on which server the user is logged on and LOG HIM OFF
3.ONLY WHEN USER IS LOGGED OF, deatach the disk (number) from server (the id)
4.deletes the vhd (via sid of user.vhdx) on filecluster
I can do steps 2 tot 4 in Powershell but how to find the number of attached disk to the user on the broker and/or server?
Please advise.
J.
Jan Hoedt