Hot answers tagged logout
11.10 and above gnome-session-quit 11.04 and previous versions dbus-send --session --type=method_call --print-reply --dest=org.gnome.SessionManager /org/gnome/SessionManager org.gnome.SessionManager.Logout uint32:1 (via DoR, see his answer to "Reboot without sudoer privileges?" for more dbus goodness!) or alternatively, you can use gnome-session-save ...
11.10 and above Here's my personal solution! In the terminal, run: gedit ~/.bash_aliases And add: alias log-out="gnome-session-quit" to the file! Now you just have to run log-out!
I had installed mate desktop and none of the menus worked, even the f-keys didn't work. I managed to get xterm through browsing with file manager. The only thing that worked was : sudo pkill -u username
Here's a easy way to do that using SysVInit. Instructions: Create the start and the stop script of your application. Put it on some directory, in our example is: Start Script: /usr/local/bin/myapp-start.sh Stop Script: /usr/local/bin/myapp-stop.sh Each one will provide the instructions to run/stop the app. For instance the myapp-start.sh content can be ...
Creating custom keyboard shortcuts: For 12.04 LTS and later: To add a new shortcut open System Settings -> Keyboard and choose the Shortcuts tab: Press the '+' sign on the bottom left to enter the name of your custom shortcut and the command you want to run (e.g. gnome-session-quit --logout --no-prompt). After having applied this you are able to select ...
To end all user processes and be sent back to the login screen, you can use: kill -9 -1 Don't run it as root though, for reasons discussed here.
No need to remove cairo-dock from start-up applications. Use one of the these solutions: Find cairo-dock.desktop file ~/.config/autostart and add this code,X-GNOME-Autostart-Delay=20 Steps to solve easily (tested in Ubuntu 14.04) Run gedit without root Click open file menu and press Ctrl+H Open file ~/.config/autostart/cairo-dock.desktop Add this ...
Looks like gnome-session-save was renamed to gnome-session-quit for 11.10. Everything else in the main answer should still work with that single change. http://mail.gnome.org/archives/desktop-devel-list/2011-February/msg00147.html
This can be done using the gnome-session-quit command. It 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 ...
When I have this problem, I simply Ctrl + Alt + F2 into a terminal, log in, and type killall -u [username] gnome-session This will basically kill all of your processes and log you out. If you want to logout all users at the same time in this manner, then you leave out the -u [username] part. I guess you could create a new keyboard shortcut that runs ...
If .bash_profile exists, then Bash will not read .bash_login (or .profile). This annoying feature is described in some versions of the Bash manual, but not all. .bash_profile and .bash_loginare analogous, so I recommend you put your commands in .bash_profile, because it's is commonly used and .bash_login is relatively unknown. Also consider putting your ...
You could restart the desktop manager, which is similar to restarting X. On Ubuntu 11.10: sudo service lightdm restart On earlier versions: sudo service gdm restart If that fails or you are on a very old system, try: sudo /etc/init.d/gdm restart One of these should take you back to the login screen. Be aware that you will not be prompted, so save ...
To execute a script upon logout: Add the following line: session-cleanup-script=/path/to/script in /etc/lightdm/lightdm.conf file. You have to restart lightdm in order that this change to take effect. To do this go in tty1 using Ctrl+Alt+F1, login with your username and password and run the following command: sudo service lightdm restart To execute a ...
gnome-session-quit --no-prompt will log you out of an existing Unity session, without a prompt.
I don't know if it would be exactly the same case, but this happened to me because somehow I corrupted the .Xautority file in my home. I think it's something related with remote access to the X server. Log into a tty (Control+Alt+F6) and after typing your username and password: sudo rm -v .Xauthority Then restart lightdm with: sudo service lightdm ...
Sadly this is a known bug in (probably) consolekit LP #838792 The workaround for the time is sudo reboot sudo shutdown now -P
I don't know of any place where this is plumbed through to the GUI. sudo pkill -u <username> is really the simple way to do it, followed by sudo pkill -KILL -u <username> a bit later if it doesn't all shut down like it should. If the "non-technical" user in question isn't capable of remembering that, a script to prompt for a username ...
It seems that the latest update added an "options" menu on the keyboard preferences-->layouts that lets me activate the "control-alt-delete" shortcut like before. Or it might have always been there and i missed it.
In Ubuntu 11.10 you could write a script containing #/bin/bash gnome-session-quit --logout --no-prompt make it executable with chmod +x script-name, then set a global shortcut to execute this script in Gnome Control Center -> Keyboard. In previous Ubuntu versions there was gnome-session-save --logout.
For gnome sessions, gnome-session-quit works well. By default it asks for confirmation and then logs you out (i.e., the --logout argument is assumed unless overridden with --power-off explicitly). You can also tell the command to not prompt for confirmation on logout: --no-prompt End the session without user interaction. This only works with ...
Your system was likely not attacked. Teamviewer starts with the system by default (annoying I know, but true anyway) in the latest version I've tried. The solution is to check both startup programs, and the following locations: /home/rolandixor/.config/autostart /usr/share/autostart for an entry for Teamviewer, and if it exists, to remove it. You were ...
Open a terminal (ctrl + alt + T) or use a TTY (ctrl + alt + F1.) Then you have to login using administrative account or root. sudo shutdown -P now
After logging in with ssh, run: env DISPLAY=:0.0 gnome-session-quit --logout This will force a logout on the remote machine just as if you had logged out from the menu (but without prompting). You may need to run gnome-session-quit with --force-logout if there's an application with, for example, unsaved work, that would otherwise prevent a clean logout. ...
You can override the default shortcut by creating your custom shortcut for this purpose. Go to System Settings -> Keyboard -> Shortcuts -> Custom Shortcuts Add a shortcut with any name with following command in command box qdbus org.gnome.ScreenSaver /org/gnome/ScreenSaver org.gnome.ScreenSaver.Lock Now click on this newly created shortcut and assign it ...
sudo apt-get install indicator-datetime indicator-messages indicator-power indicator-session or sudo apt-get install --reinstall indicator-datetime indicator-messages indicator-power indicator-session or sudo dpkg-reconfigure indicator-datetime indicator-messages indicator-power indicator-session If none of these solve it then please provide more ...
This is the step by step procedure of gnome_save_yourself method. Let's do a test. Save following code as ~/Desktop/execute_script_on_shutdown.sh (From http://www.linuxquestions.org/questions/linux-desktop-74/gnome-run-script-on-logout-724453/#post3560301) #!/usr/bin/env python #Author: Seamus Phelan #This program runs a custom command/script ...
I usually do a killall -u <your-user-name> to stop my current session and clean-up any remaining processes of mine.
If you get this: (Clean Install, added gnome-panel, gnome-shell, and gnome-system-tools) What actually works is pressing Ctrl+Alt+Del and then choosing Log out.
This should solve your problem: https://www.grendelman.net/wp/policykit-adventures/
Only top voted, non community-wiki answers of a minimum length are eligible