Tag Archives: sessions

Windows Terminal Server: Microsoft Edge does not open when the same user has edge already opened

Hi,

Edge and Chrom can only be opened one time for a user. If a user has multiple sessions opened on a Windows Terminal Server with the same credenitals, edge can only start once time because the profile (UserDataDir) can only used by one instance. Otherwise the profile is getting corrupt.

A workaround is to assign each session a seperate UserDataDir. This has one disadvantage: Bookmarks and so on depends on the sessionname.

To start edge in multiple RDP session I used the following command line parameter. This sets the DataDir to the sessionname.

edge --user-data-dir=C:\Users\%UserName%\AppData\Local\Microsoft\Edge\Profile\%SESSIONNAME%

Another option is the %CLIENTNAME% variable. CLIENTNAME contains the Computername of the machine from which you establish the RDP session.

Michael

Windows: List all users who are currently logged on

Hi,

if you want to list all Users which are currently logged on to the box use the query command.

List all sessions


c:\> query session
 SESSIONNAME       USERNAME                 ID  STATE   TYPE        DEVICE
 services                                    0  Disc
 console                                     1  Conn
>rdp-tcp#0         user1                     2  Active  rdpwd
 rdp-tcp                                 65536  Listen

Or list all users


c:\> query user
 USERNAME              SESSIONNAME        ID  STATE   IDLE TIME  LOGON TIME
>user1                 rdp-tcp#0           2  Active          .  21.02.2015 19:42

You can also list the processes of the user


c:\> query process
 USERNAME              SESSIONNAME         ID    PID  IMAGE
>user1                 rdp-tcp#0            2   6076  taskhost.exe
>user1                 rdp-tcp#0            2   6592  rdpclip.exe
>user1                 rdp-tcp#0            2   4840  dwm.exe
>user1                 rdp-tcp#0            2   4680  explorer.exe
>user1                 rdp-tcp#0            2   7092  vmtoolsd.exe
....

Michael