![]() |
ubuntu.com - launchpad.net - ubuntu help
|
|
|||||||
|
General Help All your general support questions for Ubuntu, Kubuntu, Edubuntu and Xubuntu. |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
5 Cups of Ubuntu
![]() Join Date: Feb 2007
Beans: 21
|
shutdown sound
I did kind of a hack workaround for the no sound on shutdown problem some people are having. I just put together some other fixes I read about and so far it seems to work. The only problem is if you want to change the sound that is played requires modifying the script. Not that big a deal I guess. Anyway, this is what I did. In a terminal type "gksudo nautilus" without the quotes. Enter password and your now in nautilus with root privilege. Navigate to the /sbin folder. From the 'File' menu select 'Create Document' > 'Empty File'. It will create a file called “new file”. Open this file and add the following:
#!/bin/sh #Put your custom commands after this line aplay /usr/share/sounds/shutdown.wav # The next line is the regular gnome logout command /sbin/shutdown -h now "Shut Down via gdm." Save the file and rename it “shutdown_mod”. Now make the file executable by right clicking on it then click on properties. Go to the 'Permissions' tab and check 'Allow executing file as program'. Close the properties window. Close Nautilus. Now go to the 'System' menu > 'Administration' > 'Login Window'. Click 'Edit Commands' at the bottom of the 'General' tab. Select 'Halt command' from the Command type box. Write down what you see in the Path box just in case you need to change it back. Now replace what's in the Path box with “/sbin/shutdown_mod” without the quotes. Now click 'Apply Command Changes' then close the window. Close the 'Login Window Preferences' window. You should also do this for the reboot command. The only difference will be to name the file “reboot_mod” and add the following lines: #!/bin/sh #Put your custom commands after this line aplay /usr/share/sounds/shutdown.wav # The next line is the regular gnome logout command /sbin/shutdown -r now "Rebooted via gdm." Don't forget to make this file executable also. Now modify the 'Reboot command' in the 'Login Window' the same way you did before. Type “/sbin/reboot_mod” without the quotes in the Path box. This worked for me on a fresh 8.04 install. As I said before, I just put this together using some other info I found in different places. I'm not really that knowledgeable about Linux so do this at your own risk. If anyone with more knowledge sees a problem with this, please let me know. Good luck. david |
|
|
|
|
|
#2 |
|
First Cup of Ubuntu
![]() Join Date: Apr 2008
Beans: 5
|
Re: shutdown sound
Thanks - This worked for me.
jdg |
|
|
|
|
|
#3 |
|
First Cup of Ubuntu
![]() Join Date: Jul 2007
Location: UK
My beans are hidden!
Ubuntu 8.04 Hardy Heron
|
Re: shutdown sound
Thanks for that David... it worked
![]() |
|
|
|
|
|
#4 |
|
Dark Roasted Ubuntu
![]() Join Date: Apr 2007
Location: Hartford City, Indiana US
Beans: 1,006
|
Re: shutdown sound
ebe326, thank you! Your solution worked perfectly!
|
|
|
|
|
|
#5 |
|
First Cup of Ubuntu
![]() Join Date: Oct 2007
Beans: 8
Ubuntu 8.04 Hardy Heron
|
Re: shutdown sound
It works!! Thanx man. I've been searching this for days.
now I have my shutdown and reboot sound back. Cheers |
|
|
|
|
|
#6 |
|
Fresh Brewed Ubuntu
![]() Join Date: Jul 2007
Location: The Shire, Canada
Beans: 1,288
Ubuntu 9.04 Jaunty Jackalope
|
Re: shutdown sound
First of all, thank you. I didn't know that there was a shutdown sound. Now though, we need to get to the serious part. I think that your hack was very well explained through and through. There was one thing that, though it was my fault entirely, made me stumble. When you said: "Now replace what's in the Path box with “/sbin/shutdown_mod” without the quotes." I took that to mean the WHOLE line. Again, my fault but someone else could make that mistake too. When I clicked apply I was whisked away from GNOME and dropped in what looked like a terminal gone rogue. I tried to do Ctrl+Backspace but got no response. I had to think back to my Window 98 days and hit Ctrl+Alt+Del to restart. Thank you for telling us to backup the line. Whew! Anyways none of the login sounds were working so I replaced the Path ONLY. Now it works perfectly.
Thanks again. Luke
__________________
Another round of Ubuntu for my friends here! Fighting to bring Pink back to The Pink Ponies archive. DELETE INSANITY! |
|
|
|
|
|
#7 |
|
5 Cups of Ubuntu
![]() Join Date: Jul 2005
Beans: 24
|
Hi.. I managed to do your step-by-step sound. Thanks... how to make it with logout sound ? please let me know in send4m3@yahoo.com
Thank you |
|
|
|
|
|
#8 | |
|
Ubuntu addict and loving it
![]() Join Date: Feb 2005
Location: Melbourne, Australia
Beans: 7,838
Ubuntu 9.04 Jaunty Jackalope
|
Re: shutdown sound
Quote:
I now have a (global) logout sound in my 8.04 system by doing the following:
__________________
Regards, David. The Forum search function is useful for immediate help (give it a try).
Please mark your thread as "Solved" (using the Thread Tools) when appropriate. Last edited by dcstar; February 10th, 2009 at 08:06 PM.. |
|
|
|
|
|
|
#9 | |
|
Quad Shot of Ubuntu
![]() |
Re: shutdown sound
I tried this & it didn't work. Btw, I'm using Linux Mint which, under the hood, is basically the same as Ubuntu, so if it works in Ubuntu it should work in Mint.... Anywho, I've had no shutdown sound like many others here, I just hear a beep instead. So I attempted this procedure unsuccessfully, & I'm wondering if I entered the wrong path? I put "bplay /username/filename.wav".... should I put "home" before the username? If anyone can help me get this issue fixed, I'd greatly appreciate it!
Quote:
__________________
|
|
|
|
|
|
|
#10 |
|
Dark Roasted Ubuntu
![]() Join Date: Jul 2008
Location: /$home/bin
Beans: 1,054
Ubuntu Karmic Koala (testing)
|
Re: shutdown sound
works for me
__________________
Ubuntu 9.10 (Karmic Koala) testing |
|
|
|
| Bookmarks |
| Tags |
| logout, shutdown, sound |
| Thread Tools | |
| Display Modes | |
|
|