1

How do I close Gnome desktop session on the console in VMware? I have a user that left the console in Gnome desktop. Of course root can not login via the gnome desktop but can using the console. All the key stroke stuff will not work because VMware picks up the interrupts from key strokes. I need the actual $ goaway -and-do-not--ever-come-back gnome_desktop

thanks in advance for any help you can throw my way.

1 Answers1

2

Ending gnome session

Users can logoff the gnome session as follows from terminal

gnome-session-quit

It might needs the --force option to suppress the confirmation dialog that would appear without it.

Unlike applications run from an X terminal emulator, ending a session from a TTY requires you to append the DISPLAY variable to indicate which X display is running the session. Hence:

DISPLAY=:0 gnome-session-quit --force

Killing all users processes

You could as well kill all processes of that user. Not a perfect solution but should do the job as well.

sudo pkill -u nameOfUser
dufte
  • 14,198
  • 5
  • 41
  • 43