Results 1 to 6 of 6

Thread: log out using terminal ?

  1. #1
    Join Date
    Mar 2006
    Beans
    4,373
    Distro
    Ubuntu Development Release

    log out using terminal ?

    how do I log out of the desktop using the terminal ? I logged out of gnome-shell and into unity but unity is crippled on my sys and I have no top bar and can't get to the launcher or logout ,restart etc with the mouse , I can get to a terminal an launch things that way .
    if it ain't broke you haven't tweaked it enough

  2. #2
    Join Date
    Apr 2012
    Beans
    5,140

    Re: log out using terminal ?

    you could restart the display manager - should return you to the greeter screen where you can select gnome-shell again

    Code:
    sudo service lightdm restart

  3. #3
    Join Date
    Nov 2011
    Location
    /dev/root
    Beans
    7,148

    Re: log out using terminal ?

    I don't know the logout command in Unity (I use Lubuntu and LXDE most of the time), but I know these self-explaining commands, that work in all Ubuntu flavours

    Code:
    sudo reboot
    Code:
    sudo poweroff
    They perform actions of the same quality as the corresponding graphical actions.

  4. #4
    Join Date
    Jun 2007
    Beans
    12,926

    Re: log out using terminal ?

    May not help because requires accepting
    Code:
    /usr/lib/indicator-session/gtk-logout-helper --logout

  5. #5
    Join Date
    Mar 2006
    Beans
    4,373
    Distro
    Ubuntu Development Release

    Re: log out using terminal ?

    thanks all, I used mc4man's suggestion and that got me back to the login screen so I could get back into gnome-shell . ( I was able to "accept " the logout , everything worked except the top panel and launcher) .
    Last edited by ronacc; March 10th, 2013 at 06:52 PM.
    if it ain't broke you haven't tweaked it enough

  6. #6
    Join Date
    Aug 2012
    Beans
    242
    Distro
    Ubuntu Development Release

    Re: log out using terminal ?

    Code:
    ~❯ ps -ef | grep gnome-session
    1000      1601  1461  0 14:34 ?        00:00:00 gnome-session --session=ubuntu
    1000      1647  1601  0 14:34 ?        00:00:00 /usr/bin/ssh-agent /usr/bin/dbus-launch --exit-with-session /usr/bin/im-launch gnome-session --session=ubuntu
    1000      1650     1  0 14:34 ?        00:00:00 /usr/bin/dbus-launch --exit-with-session /usr/bin/im-launch gnome-session --session=ubuntu
    1000      1668     1  0 14:34 ?        00:00:00 /usr/lib/at-spi2-core/at-spi2-registryd --use-gnome-session
    1000      2284  2188  0 14:36 pts/1    00:00:00 grep --color=auto gnome-session
    ~❯ kill -15 1601

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •