how to force user logoff (disconnect)

Discussion in 'Windows Server' started by Elvyn Gutierrez, Oct 31, 2005.

  1. Hi. Sometimes upper management request to forcidbly logoff a user session,
    most of the time due to the fact that the person is going to be fired at
    that moment. I know that If I disable the account it won't kill the user
    sessions. Also in computer management I'm able to kill the session but in a
    per server basis. Is there any easier/faster way to accomplish this.

    TIA
     
    Elvyn Gutierrez, Oct 31, 2005
    #1
    1. Advertisements

  2. Best option in cases like this is to disable the account and escort the
    person out of the door.

    Kicking off the user from the computer might seem strange to the user and
    could give him/her a warning that he will get fired. In this case he/she
    could look for unlocked and unprotected computer and do some damage from
    there.
    Also, to do damage you don't have to network access to the computer.
    Physical access will also do. He/she can just kick few servers or steal a
    hard drive with valuable data etc.

    So again - best option is to escort such person out the door.
     
    Miha Pihler [MVP], Oct 31, 2005
    #2
    1. Advertisements

  3. Elvyn Gutierrez

    Brian Hoops Guest

    If you know the machine that they're working on you can use the shutdown
    command with a -l (that's a lowercase L) from an XP or 2K3 system.

    H:\>shutdown /?
    Usage: shutdown [-i | -l | -s | -r | -a] [-f] [-m \\computername] [-t xx]
    [-c "comment"] [-d up:xx:yy]

    No args Display this message (same as -?)
    -i Display GUI interface, must be the first
    option
    -l Log off (cannot be used with -m option)
    -s Shutdown the computer
    -r Shutdown and restart the computer
    -a Abort a system shutdown
    -m \\computername Remote computer to shutdown/restart/abort
    -t xx Set timeout for shutdown to xx seconds
    -c "comment" Shutdown comment (maximum of 127 characters)
    -f Forces running applications to close without
    warning
    -d [p]:xx:yy The reason code for the shutdown
    u is the user code
    p is a planned shutdown code
    xx is the major reason code (positive
    integer less than 256)
    yy is the minor reason code (positive
    integer less than 65536)
     
    Brian Hoops, Nov 1, 2005
    #3
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.