No automount - shutdown/restart in openbox

Hello
I was still using hal until today when I tried to browse my usb flash disk a "failed to mount, not authorized to perform operation message appeared"
Ok, time to remove hal I said. And I did.. I then replaced slim with lxdm, replaced the entry in innitab and rebooted.
Now automount doesn't work at all, neither does shutdown/restart..
Any help would be much appreciated
xinitrc is
exec ck-launch dbus-launch openbox-session

The solution suggested in the link worked for me! (except this ). Also for the shutdown/restart issues this worked for me:
For anyone else having issues, it looks like this package has been abandoned by the dev.
First, assuming you have consolekit and dbus running correctly --
Edit /etc/oblogout.conf
Change usehal=true to usehal=false
Change the shutdown and restart commands to
shutdown = dbus-send --system --print-reply --dest="org.freedesktop.ConsoleKit" /org/freedesktop/ConsoleKit/Manager org.freedesktop.ConsoleKit.Manager.Stop
restart = dbus-send --system --print-reply --dest="org.freedesktop.ConsoleKit" /org/freedesktop/ConsoleKit/Manager org.freedesktop.ConsoleKit.Manager.Restart
As for suspending, I dont do it but the above command should work.
There's absolutely no good reason to have to edit sudoers to shutdown your machine if you are in the power group. It took me 2 minutes to research the correct dbus commands to shutdown and restart, instead of throwning the commands "shutdown -h now" and "reboot" into a script.

Similar Messages

  • HOWTO: Startup/Shutdown Sounds in Openbox

    In this tutorial, I will show you how to add startup and shutdown sounds with Openbox, a light-weight window manager. In theory, this should work with any window manager that uses a startup script (or, if you use the startx command, .xinitrc could be used for the same effect); however, I will be focusing on Openbox, so you will have to adapt these instructions for use with other window managers.
    We'll start with a quick background story: I was in a "tweaking" mood a few days ago, and I figured I'd try to set up some startup and shutdown noises for use with Openbox. After a few minutes of messing around, I got it working. I searched to see if there were any tutorials like this, and since there weren't, I figured I would share my knowledge--that's what tutorials are for, right?
    NOTE: I originally posted this on ubuntuforums.org; therefore, there may be some differences (I tried to fix most of them). Even though I did this on Arch originally, I wrote it targeted toward Ubuntu users. I didn't get much of a response--there must not have been too many Ubuntu/Openbox users looking for that. Please point out any inconsistencies, and I'll fix them as soon as possible.
    Now that we have that out of the way, let's get started.
    Step 1: Installing the necessary application(s).
    First off, we will be using a commandline program called play. It is part of the sox package, so let's install that first (you likely have most of its dependancies already).
    # pacman -S sox
    If you'd like, you can cd to a directory with music in it and type play name-of-sound-file.extension to test that it is working. If you don't have any files to try it on, you can do this later after downloading your desired sound files in step 3.
    I also have sudo set up; you will need to set this up to run the shutdown commands from a script as I have them. There is a section in the ArchWiki that will help in setting it up if you want. As for the commands with sudo in them, you can just run them in a root terminal.
    In addition to that, I will be working with obmenu, a program for editing Openbox's menu from a GUI; however, it will work just as well to edit the menu by hand. I assume you already have a preferred method of editing your menu, but if you want to try obmenu, it's only a pacman command away:
    # pacman -S obmenu
    Step 2: Setting up shutdown privileges.
    For this section, I will be adapting a section from a great guide written by urukrama here. We're going to be running a shutdown command from a script, so we need to have it set up to work without any interaction--in this case, that means removing the need for a password for the shutdown command.
    To do this, type in the following command into the terminal:
    sudo visudo
    This will open up the sudoers file, which is used to specifiy user permissions for actions that require root priveleges. For those of you unfamiliar with Vim (I'm with you ), just press i on your keyboard to enter interactive mode, which allows you to edit the file. Then, enter the following line at the end of the file:
    %wheel ALL=NOPASSWD:/sbin/shutdown
    Then press escape to exit interactive mode. Lastly, type in :wq followed by pressing enter to save and exit. Now you can use the sudo shutdown command without entering a password.
    Step 3: Getting the desired sound files.
    Now we come to the fun part of the guide--finding the sounds that we want.
    There are plenty of startup and shutdown noises floating around the web; I went to gnome- and kde-look to check out theirs (the same are available at both sites). Here's a link to the System Sounds section at gnome-look. You can look through and download the ones that interest you; once you have listened to a few and found one that you like, go on. Just for reference, I chose the Dream pack. It fits very nicely with my current setup and theme.
    Step 4: Setting up the shutdown/startup scripts.
    If you haven't already (in the last step), extract the sound files from the package that they downloaded in. Then, look through the files and find the startup and shutdown noises. For me, they were titled Dream Intro.ogg and shutdown.ogg, respectively. Move these files into their own folder. I chose ~/.startup--on my Arch install, it was empty. You may want to put it into a different folder/sub-folder, preferably somewhere in your home folder. You can now remove all the other sound files--hypothetically speaking, it probably wouldn't be too hard to get other sounds (such as minimize, maximize, etc., if provided in the sounds package you chose) working with Openbox, but that is beyond the scope of this tutorial. Now, go to the folder in which you placed the startup and shutdown noises. For simplicity's sake, we're going to place the scripts in this same folder.
    We're going to be making two scripts here--one for reboot and one for shutdown. Open up your text editor of choice here and enter the following line (replacing the "/path/to/file.extension" with the path to your shutdown sound):
    play /path/to/file.extension && sudo shutdown -r now
    For me, it looked like this:
    play ~/.startup/shutdown.ogg && sudo shutdown -r now
    What this does is play the sound file specified and, once that is done, moves on to the reboot process (that's what && does). Save this as reboot.sh. Now make a new file, this time for the actual shutdown. It will be the same as the first except the shutdown command will now be sudo shutdown -h now. Here's what mine looks like:
    play ~/.startup/shutdown.ogg && sudo shutdown -h now
    Save that one as shutdown.sh. At this point, we have completed the scripts for both shutdown commands. Next, open up your Openbox autostart script (should be in /home/<user>/.config/openbox/autostart.sh, where <user> is your username) with the text editor of your choice. You probably already have a few different things in here; if not, it doesn't really matter. Just add the following line to your autostart file (as you can see, I used quotes around this one because this file had a space in its name--you'll want to do the same. You can also use a backslash before the space):
    play "/home/<user>/.startup/Dream Intro.ogg"&
    Make sure you keep the ampersand (&) in tact; otherwise, the script will wait until the sound is done playing before completing the rest of the processes. I recommend that you place the sound file at the beginning of the script so that it starts first--the way I have it set up, everything is ready to go by the time the login sound ends (sooner, actually). Now that we've come this far, we're almost done.
    Step 5: Adding the shutdown options to the Openbox menu.
    At this point, the login sound will be working; however, we still need to set up the shutdown sounds. To do this, we will add a section to the Openbox menu that runs the two scripts we made in the last step.
    Either open up obmenu or use your preferred text editor and open up menu.xml (should be in ~/.config/openbox/menu.xml). As I said, we will be adding two items: one for rebooting and another for shutting down. In obmenu, you can add a new submenu wherever you want (I chose the bottom of the menu) and name it Power (or whatever else you'd like). The first we'll add is named Restart. For the execute line, add the following:
    bash /path/to/reboot.sh
    For me, this path is ~/.startup/reboot.sh. As for the second, name it Shut Down and for the execute command put the following:
    bash /path/to/shutdown.sh
    Again, for me this is ~/.startup/shutdown.sh. Here is what the section in my obmenu looks like:
    As for the pure XML, here it is (I replaced my name with <user> ):
    <item label="Restart">
    <action name="Execute">
    <execute>bash /home/<user>/.startup/reboot.sh</execute>
    </action>
    </item>
    <item label="Shut Down">
    <action name="Execute">
    <execute>bash /home/<user>/.startup/shutdown.sh</execute>
    </action>
    </item>
    With obmenu, just save it, and your menu will be refreshed. When hand-editing the menu.xml file, you have to remember to Reconfigure Openbox (it will be in your menu unless you've removed it).
    And with that, you should have working startup and shutdown sounds. You can test it by right clicking on your desktop and selecting one of your new shutdown options. You should have a sound play followed by the normal shutdown routine. Then when your computer starts back up, you will have a pleasant noise after logging on.
    I hope that helped you! Please point out any errors that you see, and I'll correct them as soon as possible.

    Nice tutorial. I was wondering, I noticed you have a games tab. Do you know how to properly execute games. I am trying to get steam games working also Call of duty 4 as tabs under obmenu. Could you help me out?
    Thanks!

  • Import of photos is not working. Moreover 'photos' app is not getting closed, it says 'closing all libraries'. Even it is stopping shutdown/restart of my mac.

    Import of photos is not working. Moreover 'photos' app is not getting closed, it says 'closing all libraries'. Even it is stopping shutdown/restart of my mac.

    Next time you open the photos application hold down both of the keys suggested and then launch the application in the usual way. If you do this you will be presented with the opportunity to repair your library.

  • Time Machine:  When it's backing up, can't open new apps/shutdown/restart

    Running Snow Leopard. I just did a MS Office 2008 Service pack 3 upgrade. And noticed that while Time Machine is backing up, I can no longer open any new apps or shutdown/restart the macbook. Nothing responds anymore.
    Related issued: If it's been sleeping, I can't type anything to unlock my computer.
    In either situation, I have to hold down the power button to shut down and restart. Anyone else experiencing this issue?

    Have you seen these...
    User Contributed Tips:
    Pondini - Time Machine - TROUBLESHOOTING (Sept 25, 2009)
    http://discussions.apple.com/thread.jspa?threadID=2057525
    Pondini - Time Machine -- Frequently Asked Questions (Apr 3, 2009)
    http://discussions.apple.com/thread.jspa?threadID=1964018

  • Can I download a file in different sessions or should it be in a single session? In other words can I pause the download of a file, shutdown/restart my system and then resume download from where I left off? Or will it start from the very beginning?

    Can I download a file in different sessions or should it be in a single session? In other words can I pause the download of a file, shutdown/restart my system and then resume download from where I left off? Or will it start from the very beginning?

    If a server supports resuming downloads then the download should continue where it left off.<br />
    You can test that by simple starting a large download and wait a minute or so before pausing it.<br />
    Then you can close and restart Firefox and see if resuming works.
    You can set the pref browser.download.manager.quitBehavior to 2 on the about:config page.<br />
    That will make Firefox ask for confirmation if you want to cancel the download if you close Firefox.
    See:
    * http://kb.mozillazine.org/browser.download.manager.quitBehavior

  • How to disable GNOME logout/shutdown/restart beep???

    Hello, when I logout/shutdown/restart and the volume is not mute, I hear a large beep sound which annoys me very much. I tried to untick alart sound in System->Preference->Sound, but it does not help.

    That module only affects the system PC speaker. You say "when the volume is not mute[d]"; is the beep coming from the soundcard or the PC speaker? If it's coming from the latter, unload the pcspkr module (and be sure to unload snd_pcsp as well if you're on a 2.6.28 or higher kernel).
    -dav7

  • [SOLVED] Gnome 3.2 shutdown/restart button as menu options

    hi there.
    i have recently add gnome as gui and i have difficulty finding how to add the buttons shutdown/restart at the top right position where logout is right now.
    for the moment to shutdown or restart i have to either logout and do it from there (if it doesn't freeze, sometimes does that) or open console and shutdown or reboot from there.
    can anyone help with this matter?
    thank you in advanced.
    Last edited by ironwiller (2011-11-09 21:26:43)

    lmao....come on...where in the heck is that written on???
    thanks....a lot ....
    PS: is there any guide with shortcuts for gnome? sorry for asking that question but trully i come from kde and i want to break out

  • MacBook Late 2008 (Unibody Aluminum) running Lion cannot shutdown, restart, or logout

    After upgrading to mac os x lion, my macbook has not been able to restart or shutdown or even logout properly. This problem was not present when the laptop was in snow leopard. Currently, I am able to do a shutdown through the terminal by using the command:
    sudo shutdown -h now
    or restart by using the command:
    sudo shutdown -r -h now
    This is fine for most situations but when I am trying to install an update or a program that needs a restart, I am unable to do so. When still at the login screen, I am able to shutdown properly leading me to think that a process is preventing shutdown but I can't find anything in the console. The power button also becomes unresponsive (normally pressing it brings up the window asking whether to shutdown, restart, etc.) and can only be used to do a forced shutdown (i.e. holding it down for 10 seconds). The sleep, restart, and shutdown functions in the apple menu also do not work.
    Any ideas anyone?

    After upgrading to mac os x lion, my macbook has not been able to restart or shutdown or even logout properly. This problem was not present when the laptop was in snow leopard. Currently, I am able to do a shutdown through the terminal by using the command:
    sudo shutdown -h now
    or restart by using the command:
    sudo shutdown -r -h now
    This is fine for most situations but when I am trying to install an update or a program that needs a restart, I am unable to do so. When still at the login screen, I am able to shutdown properly leading me to think that a process is preventing shutdown but I can't find anything in the console. The power button also becomes unresponsive (normally pressing it brings up the window asking whether to shutdown, restart, etc.) and can only be used to do a forced shutdown (i.e. holding it down for 10 seconds). The sleep, restart, and shutdown functions in the apple menu also do not work.
    Any ideas anyone?

  • Finder is not running.  Relaunch doesn't work.  Shutdown/restart doesn't work

    Unable to get FInder running.
    Applications trying to access files on the hardrive get stuck with the spinning wheel.
    Finder relaunch doesn't do anything.
    Shutdown/restart doesn't help.

    Hi:
    PRAM:
    http://docs.info.apple.com/article.html?path=Mac/10.6/en/26871.html
    SMC:
    http://support.apple.com/kb/HT3964
    Barry

  • API to lock/shutdown/restart the Phone from wp8.1 App

    Hi 
    is there any apis available to lock/shutdown/restart the Phone from wp 8.1 App

    Microsoft may allow you to access the API if you are a device manufacturer or carrier. Also possibly if you are building a company app for private distribution. In general, 3rd party apps in the Windows Store are not allowed to access API that affect the
    device as a whole.
    iOS and Android also don't allow programmatic restart or shutdown (unless the device is jailbroken/unlocked). They are dangerous API that will be exploited if generally allowed.

  • Is it possible to shutdown & restart Red Hat AS 3.1 remotely?

    Hello All,
    OS:Red Hat AS 3.1
    Is it possible to shutdown & restart Red Hat AS 3.1 remotely?
    Genrally I connect to OS via SSH.
    I think I can shutdown OS by shutdown -h now.
    But how will I start remotely.
    Actually servers are different location and I need to shutdown OS for few hours and then make it starts.
    Regards,
    D

    >
    Actually servers are different location and I need to
    shutdown OS for few hours and then make it starts.I think this is hardware capability.
    Some computer/motherboard and bios have the capability to startup it self if it detects signal from a modem or serial ports provided its plugin to a power supply.
    Try to check you hardware capability.

  • ITunes causes gray screen on shutdown/restart

    Hi guys! I recently noticed that when I shutdown/restart my MBP, i get stuck in a gray screen with spining wheel. I  can't remember if and what i instaled, but I know that this problem happens when I open up ITunes and keep showing up even when I close/force quit manually ITunes.
    Can anyone help me please?!

    MacBook Pro
    iTunes for Mac

  • Where is the shutdown/restart buttons from the logout dialog

    After I followed the almost all postinstall in Howto(s) from Archlinux Wiki, I lost the shutdown/restart buttons from the logout dialog box.
    Where are they?
    I set in the kcontrol:
    KDE Components -> Session Manager -> General (Offer shutdown options) and Default Shutdown Option (Turn off computer)
    has no effect.
    Could someone give me a hint?
    Thanks.
    Regards,
    Jerry

    dauphin wrote:
    See if this thread helps:
    http://bbs.archlinux.org/viewtopic.php?t=11624
    Yep, it works.
    Remove
    export DISPLAY=localhost:0
    I did not read it carefully
    I put
    xhost+ localhost
    export DISPLAY=localhost:0
    together in my user .bash_profile
    I should split this:
    xhost+ localhost
    in my user .bash_profile
    and
    export DISPLAY=localhost:0
    in my root's .xinitrc
    That should do the job.

  • My imac restore everything to the default after i shutdown/restart

    ANy activity or im trying to switch a gesture, or download any changes that i made will restore to default after i shutdown/restart. I cant even upgrade to yosemite ! Help;(( even browser home page change and dialog appear ask me to choose which browser to be my default browser.:((

    3) You have changed the boot sector by doing a manual installation, the script to start R&R is missing.
    You could try using the Rescue and Recovery Repair Diskette to modify the boot sector, a floppy will be required. It would also be sensible to backup any important files beforehand. If everything works and you then run R&R it will install Vista.
    1) I'm not sure if this would work, it would be intersesting to know. I doubt it as R&R is different for XP and Vista.
    2) You could use the recovery discs from the other TP and return yours to factory state. This will delete everything on the hard drive. R&R will work afterwards.
    Message Edited by andyP on 06-19-2008 08:36 AM
    Andy  ______________________________________
    Please remember to come back and mark the post that you feel solved your question as the solution, it earns the member + points
    Did you find a post helpfull? You can thank the member by clicking on the star to the left awarding them Kudos Please add your type, model number and OS to your signature, it helps to help you. Forum Search Option T430 2347-G7U W8 x64, Yoga 10 HD+, Tablet 1838-2BG, T61p 6460-67G W7 x64, T43p 2668-G2G XP, T23 2647-9LG XP, plus a few more. FYI Unsolicited Personal Messages will be ignored.
      Deutsche Community     Comunidad en Español    English Community Русскоязычное Сообщество
    PepperonI blog 

  • Sever node shutdown/restart

    Having four dialog instances and each with 3 server nodes ( server0,server1 & server2) respectiviely.  Is it possible to shutdown/restart the server nodes individually of a dialog instance.if so, will it bring down the system while stopping or restarting.
       For instance If I stop server2 ..then server0 & server1 should be up
      Please lend your hand for help and guidance with procedure

    Hi,
    Go to /sapmnt/<SID>/profile directory.
    Then run jcmon pf=<instance profile>. Then it will show you few options then select 20. Then on next screen it will show you a number of menu based options. Then is one option to Restart the process. Select it and then enter index number of server node you want to restart then it will restart it.
    Thanks
    Sunny

Maybe you are looking for

  • GUI_DOWNLOAD binary file download as XLS

    All, Using the following code i am generating a binary file and downloading as XLS using GUI_DOWNLOAD. But Everything working fine. But the problem is in the excel I am getting blank row and Blank column in the sheet. ie First row and First column in

  • Error executing Maven

    I have installed the Axis2 and tried to run the application using "maven-package". I am getting this error. How to create this settings.xml file [ERROR] Error executing Maven. [ERROR] The specified user settings file does not exist: C:\Documents and

  • Cenvat suspense and cenvat clearing

    Hi Please tell me how to clear cenvat suspense and cenvat clearing in case of sales return and purchase return? pls give the T-codes and the entries thanks in advance

  • Different Colors between flash & adobe

    I import RGB images from Photoshop but they are changed ... they look with less saturation... and even the hex code is changed if I look into it with my drop tool... why this happens ? Please I would appreciate any answer from the Adobe-Macromedia Te

  • Unable to download OS Mavericks

    I'm on 10.8.5. Every time I click the Free Upgrade button on the App Store, the download prompt comes up. However, even after I click download, nothing happens, and the prompt just keeps coming up. Any help is appreciated!