Can't shutdown as user

Hi,
I just followed the Wiki-Entry on how to make users able to shutdown/reboot the system, but I get the following error:
user /home/user $ sudo halt
sudo: sorry, you are not allowed to preserve the environment
My sudoers file:
Defaults:user timestamp_timeout=0
Defaults insults
root ALL=(ALL) ALL
user ALL=(ALL) ALL
user localhost=NOPASSWD: /sbin/halt
user localhost=NOPASSWD: /sbin/reboot
On my old installation I had this working already, I really appreciate all help.

t4k1t wrote:
Lone_Wolf wrote:
This has worked fine for me in etc/sudoers file for ages :
%powerusers ALL = (root) NOPASSWD: /sbin/poweroff
%powerusers ALL = (root) NOPASSWD: /sbin/reboot
Now when I type
sudo reboot
bash prompts me for the password.
Sorry if I'm insulting your intelligence t4k1t, but is you group named powerusers or power? If it's power then that should be %power on those lines.
It's usually the little mistakes that cause problems like this. I should know, I've made quite a few myself since coming to arch.
t4k1t wrote:Is it blocked by default from anything?
No. I was thinking of the problems you can get into with HAL stopping WMs from shutting down. Shouldn't be the cause, but mentioned it just in case.

Similar Messages

  • System Shutdown and User Logout Freeze

    Recently my Powerbook 15" G4 (FW800) compute running 10.5.7 has been having issues with both shutting down and switching to a different user from the Finder Apple menu.
    You can select "Shutdown" from the Apple Menu and the system appears to close all programs properly including the Finder but my desktop image still appears on the screen and I have to hold down the Power button for about 5-10 seconds to force the computer to turn off.
    In addition, if I try to log out of the current user using the Apple menu to try to switch to my other one the system again appears to "hang" with just the desktop image on the screen.
    Initially when either of these attempts are being done you can hear disk drive activity but the desktop image stays on the screen even after leaving the computer alone for 10 minutes or more.
    I've tried resetting the Parameter Ram at startup and even went as far as trying to reset the PMU by holding down the Open Apple-Control-Shift & Power Button (Apple says to hold down Shift-Control-Option-Power though) and I thought that had fixed the issue but after another reboot the computer is back to just sitting there with the desktop picture on the screen after shutting down.
    I've run the computer in "Verbose Mode" and when the computer properly shuts down you can see the desktop photo go away and the verbose mode come up on the screen for a moment before the computer completely shuts down. But recently, after selecting shutdown on the screen, the computer never makes it to the verbose screen meaning "something" is causing it to hang after it closes all the processes but before it gets a chance to get to the verbose screen and close up shop.
    Does anyone know of a preference file I can delete or something else I can try to get this computer happy again? Other than the above listed problem the computer works completely fine.
    Any suggestions or other people that have had similar experiences are appreciated, thanks!
    Mike

    Friend, I feel for you. I have the same problem on two PPC machines. I have watched posts about this problem for about a year now, and I have yet to see anyone come close to a fix.
    I'm going to tell you how we keep it from happening 97% of the time (on both our machines). It's really weird, but it works. When we're going to shut down, we open a few folders and let the machine calculate the sizes of the items inside. We use the Applications folder and the Utilities folder for this. Once the machine has shown the sizes of the items in the window, we close the window. Then, from the Apple Menu, we choose Shut Down (or Restart, if that's what we're doing). The dialogue window appears, asking to confirm that is what we want to do. Now, WAIT as it counts down. Click "OK" when the countdown hits 55 seconds remaining. I know it sounds goofy, but believe me, it works. If we do not follow this routine, the shutdown or restart will fail and we have to force quit the machine.
    Now, we've been doing this for a long time - probably about a year. Since we started having to follow this silliness, we have installed a second hard drive in the desktop machine and also now use a portable FW HD with my laptop. On the laptop, I always eject the external HD before shutdown or restart. On the desktop machine, we simply open at least one big folder (usually Applications on a clone backup partition, and on the other partition just some big folder), let it calculate the sizes of the enclosed items, then close those folders. Following these actions, we use the previously described procedure.
    Try it and let me know here if it works for you.
    I know it sounds totally insane, but it works. It's a pain to do it every time, but it beats a forced shutdown and the chance of data corruption. I've given up on a solution; we'll probably replace these machines before there's a fix - judging from the lack of success other have with this problem.

  • [SOLVED] Can not shutdown/restart from KDE with systemd

    Hello,
      Recently, following I switched to a pure systemd setup.  The process was simple and most things worked "right out of the bpx".  However, I can not shutdown or restart from KDE!
    Let's say that I do the 3 finger salute (ALT-CTRL-DEL) and select "Turn off computer" what I get is KDE shutting down, but then I will only get a console (TTY) login prompt.  Pressing ALT-CTRL-DEL then will trigger a reboot.  I can also login and use "systemctl poweroff".  However, I don't understand why it doesn't work straight from KDE.
    Are there some packages I must install?  Are there some systemd services that I must enable?  What other relevant info should I include in this post?
    Active units :
    UNIT LOAD ACTIVE SUB JOB DESCRIPTION
    proc-sys...misc.automount loaded active waiting Arbitrary Executable File Formats File System Automount Point
    sys-devi...d-card0.device loaded active plugged MCP79 High Definition Audio
    sys-devi...da-sda1.device loaded active plugged ST9500420ASG
    sys-devi...da-sda2.device loaded active plugged ST9500420ASG
    sys-devi...da-sda3.device loaded active plugged ST9500420ASG
    sys-devi...da-sda4.device loaded active plugged ST9500420ASG
    sys-devi...da-sda5.device loaded active plugged ST9500420ASG
    sys-devi...da-sda6.device loaded active plugged ST9500420ASG
    sys-devi...ock-sda.device loaded active plugged ST9500420ASG
    sys-devi...et-eth0.device loaded active plugged RTL8111/8168B PCI Express Gigabit Ethernet controller
    sys-devi...t-wlan0.device loaded active plugged AR928X Wireless Network Adapter (PCI-Express)
    sys-devi...y-ttyS0.device loaded active plugged /sys/devices/platform/serial8250/tty/ttyS0
    sys-devi...y-ttyS1.device loaded active plugged /sys/devices/platform/serial8250/tty/ttyS1
    sys-devi...y-ttyS2.device loaded active plugged /sys/devices/platform/serial8250/tty/ttyS2
    sys-devi...y-ttyS3.device loaded active plugged /sys/devices/platform/serial8250/tty/ttyS3
    sys-module-fuse.device loaded active plugged /sys/module/fuse
    -.mount loaded active mounted /
    dev-hugepages.mount loaded active mounted Huge Pages File System
    dev-mqueue.mount loaded active mounted POSIX Message Queue File System
    home.mount loaded active mounted /home
    run-user-1000-gvfs.mount loaded active mounted /run/user/1000/gvfs
    sys-fs-f...nections.mount loaded active mounted FUSE Control File System
    sys-kernel-debug.mount loaded active mounted Debug File System
    tmp.mount loaded active mounted /tmp
    cups.path loaded active waiting CUPS Printer Service Spool
    systemd-...d-console.path loaded active waiting Dispatch Password Requests to Console Directory Watch
    systemd-...word-wall.path loaded active waiting Forward Password Requests to Wall Directory Watch
    bluetooth.service loaded active running Bluetooth service
    colord-sane.service loaded active running Daemon for monitoring attached scanners and registering them with colord
    colord.service loaded active running Manage, Install and Generate Color Profiles
    console-...daemon.service loaded active running Console Manager
    console-...-start.service loaded active exited Console System Startup Logging
    cups.service loaded active running CUPS Printing Service
    dbus.service loaded active running D-Bus System Message Bus
    [email protected] loaded active running Getty on tty1
    kdm.service loaded active running K Display Manager
    NetworkManager.service loaded active running Network Manager
    sshd.service loaded active running OpenSSH Daemon
    systemd-journald.service loaded active running Journal Service
    systemd-logind.service loaded active running Login Service
    systemd-...s-load.service loaded active exited Load Kernel Modules
    systemd-...unt-fs.service loaded active exited Remount Root and Kernel File Systems
    systemd-sysctl.service loaded active exited Apply Kernel Variables
    systemd-...-setup.service loaded active exited Recreate Volatile Files and Directories
    systemd-...rigger.service loaded active exited udev Coldplug all Devices
    systemd-udevd.service loaded active running udev Kernel Device Manager
    systemd-...ssions.service loaded active exited Permit User Sessions
    systemd-...-setup.service loaded active exited Setup Virtual Console
    udisks2.service loaded active running Storage Daemon
    upower.service loaded active running Daemon for power management
    wpa_supplicant.service loaded active running WPA supplicant
    cups.socket loaded active running CUPS Printing Service Sockets
    dbus.socket loaded active running D-Bus System Message Bus Socket
    systemd-initctl.socket loaded active listening /dev/initctl Compatibility Named Pipe
    systemd-journald.socket loaded active running Journal Socket
    systemd-shutdownd.socket loaded active listening Delayed Shutdown Socket
    systemd-...control.socket loaded active listening udev Control Socket
    systemd-...-kernel.socket loaded active running udev Kernel Socket
    basic.target loaded active active Basic System
    cryptsetup.target loaded active active Encrypted Volumes
    getty.target loaded active active Login Prompts
    graphical.target loaded active active Graphical Interface
    local-fs-pre.target loaded active active Local File Systems (Pre)
    local-fs.target loaded active active Local File Systems
    multi-user.target loaded active active Multi-User
    network.target loaded active active Network
    remote-fs.target loaded active active Remote File Systems
    sockets.target loaded active active Sockets
    sound.target loaded active active Sound Card
    swap.target loaded active active Swap
    sysinit.target loaded active active System Initialization
    systemd-...es-clean.timer loaded active waiting Daily Cleanup of Temporary Directories
    LOAD = Reflects whether the unit definition was properly loaded.
    ACTIVE = The high-level unit activation state, i.e. generalization of SUB.
    SUB = The low-level unit activation state, values depend on unit type.
    JOB = Pending job for the unit.
    72 units listed. Pass --all to see inactive units, too.
    Last edited by Prozzaks (2012-08-20 17:35:48)

    Demon wrote:For me the system only halts, it does not poweroff. How I can solve this?
    As bgc1954 said, there is also a symlink "/sbin/poweroff". Just edit the file "/usr/share/config/kdm/kdmrc", go to [shutdown] an replace the line "HaltCmd=/sbin/halt" with "HaltCmd=/sbin/poweroff".

  • M60 Shutdown without user action

    Hello,
    i use a Satellite M60 Notebook with Win XP and i bought this notebook on 11/15/2005.
    I use an actuell anti-virus software and some anti-sypware tools.
    But from the first use of the notebook it shutdown without user action.
    I can't solve the problem because the settings for the notebook are "Desktop" and "Never Shutdown" for the harddisk and monitor in the energyoptions.
    "Standby" is set on "never" too.
    I thought, that the Toshiba tools are the problem and so i uninstall them, but this didn't solve the problem.
    Who have had the same problem and solved it?
    Many thanks for all answers.
    Wolfgang

    Hi
    Well, one of the reasons why the notebook shuts down without any user action is a overheating issue. If the temperature goes to a critical limit inside of notebook so the OS shuts down the unit and protect it.
    Well, its not easy to say why it happens. Maybe the cooling modules dont work properly.
    I see that your notebook is under warranty and all replacements and repair procedures will be done for free. In this case I propose to contact the ASP (Toshiba service partner). He can make some diagnostic test and replace some parts if its necessary.
    But first of all I would recommend to recover the unit with the Recovery CD for testing if its a software or hardware issue.
    Bye

  • I can only shutdown arch linux using the terminal.

    Recently I started using SLIM to log into Arch Linux. I was having trouble with the gnome-keyring window popping up everytime I logged in while using GDM. I downloaded SLIM and changed some settings so that gnome-keyring wouldn't pop up everytime.
    Here are the changes I made:
    ~/.xinitrc using this article https://bugs.archlinux.org/task/18930
    exec ck-launch-session gnome-session
    eval $(gnome-keyring-daemon -s --components=pkcs11,secrets,ssh)
    And /etc/pam.d/slim
    #%PAM-1.0
    auth requisite pam_nologin.so
    auth required pam_env.so
    auth required pam_unix.so
    account required pam_unix.so
    password required pam_unix.so
    session required pam_limits.so
    session required pam_unix.so
    session optional pam_loginuid.so
    session optional pam_ck_connector.so
    auth optional pam_gnome_keyring.so*
    session optional pam_gnome_keyring.so auto_start*
    *= the changes I made to the file.
    I was hoping to just stop gnome-keyring from popping up everytime I log into Arch Linux (ideally I wanted to auto log in) and now I can't shutdown unless I use the $ sudo shutdown -h now command in the terminal. When I click on the "Power Off" button in Gnome 3 it basically logs me out to the SLIM log in screen. I was able to shutdown the computer before by shutting the laptop screen/lid but that doesn't do anything now for some reason. Is there a way for me to auto log into arch without the gnome-keyring popping up everytime?
    Additionally, with the gnome keyring dialog I wasn't able to click the "Automatically log in....." radio button because it was grayed out for some reason.
    Last edited by rg_arc (2011-09-06 19:45:05)

    $ ck-list-sessions
    Session2:
    unix-user = '1000'
    realname = 'Ricky ******'
    seat = 'Seat1'
    session-type = ''
    active = TRUE
    x11-display = ':0.0'
    x11-display-device = '/dev/tty7'
    display-device = ''
    remote-host-name = ''
    is-local = TRUE
    on-since = '2011-09-06T10:32:31.899610Z'
    login-session-id = '1'
    Session1:
    unix-user = '1000'
    realname = 'Ricky *******'
    seat = 'Seat2'
    session-type = ''
    active = FALSE
    x11-display = ':0.0'
    x11-display-device = ''
    display-device = ''
    remote-host-name = ''
    is-local = TRUE
    on-since = '2011-09-06T10:32:31.706583Z'
    login-session-id = '1'
    $
    I believe everything is working smoothly after I rebooted... I think this is solved... but its good measure to double check.
    thanks for the input guys
    Last edited by rg_arc (2011-09-06 15:37:05)

  • How can I have multiple users on iTunes (in order to connect to a shared office iPad)?

    How can I have multiple users on iTunes (in order to connect to a shared office iPad)? Currently each of us has our own iTunes account, so I've made an "all office" Apple ID. However, I can't seem to get two different accounts (my personal and the office) to work on my machine. Even when I login as "the office", my personal library is still showing. Additionally, when I try to setup with a first-time use in iTunes, I get an error that I don't meet the minimum age requirement - no matter what birthdate I enter!

    The library exists regardless of which user is logged in.
    The only way around that is to create different user accounts on the computer.
    There is no way to have 20 unique iTunes users access a shared iTunes under a single login on the computer.

  • How do you use Time Machine to restore a specific users account?  I can't do it from the user screen because I am not allowed.  I can't do it from the admin because I can't see other users in Time machine.

    I can't restore my user account from the users screen because I get an alert that Mac OS needs something.  I can't restore in TimaeMachine from the Admin screen because I can't see other users home folders.  What can I do?

    See Pondini's TM FAQs for starters.

  • Can not list all user in Sun Iplant Directory Server5.0

    wls61sp1 sun directory server5.0
    when I config the LDAP v1 Realm,
    can only get the users from one user dn
    such as "o=NetscapeRoot,ou=beagz,cn=group1"
    but if group1 include another group group1-1,
    and a user include in group1-1,such user can not
    be see in the wls admin console.
    how can I see all users or all groups in the
    user dn?

    Hi, Eric:
    What are your LDAP configuration settings? Is the "Group Is Context"
    flag set to false?
    - Jim
    Jim Brown
    Developer Relations Engineer
    BEA Support
    "Eric.Nie" wrote:
    >
    wls61sp1 sun directory server5.0
    when I config the LDAP v1 Realm,
    can only get the users from one user dn
    such as "o=NetscapeRoot,ou=beagz,cn=group1"
    but if group1 include another group group1-1,
    and a user include in group1-1,such user can not
    be see in the wls admin console.
    how can I see all users or all groups in the
    user dn?

  • How can I get all users associated with my VSO

    I see here: https://www.visualstudio.com/en-us/integrate/api/shared/profiles that I can get my profile info from the API, but can I get all users associated with an account?

    Hello!
    If you want to see all of that in a single mailbox, you can create a Smart Mailbox from the "file" menu in the top left corner of your screen. It's a bit of trial and error before you get the rules correct, perhaps, but that will work.

  • I have multiple devices (imacs, lap tops and ipads) all connected to a NAS server.  Can I create a user for myself and one for my wife, and each have our own apple ID, and Itunes accounts, but all share the same media on NAS drives?

    I have multiple devices (iMacs, Lap tops, Ipads) all connected to a Nas Drive.  Can I create a user for myself and one for my wife and we each have our own apple ID's, Itunes etc, but share the same data on the hard drives?  So when she logs in, and sync's her ipads, they will sync with her stuff and when I do the same under my user account, on the same device, my ipads will sync with my stuff?

    You can share the same Apple ID for purchasng form the iTunes and app stores without any problems, but you should all used separate iCloud accounts with separate Apple IDs.  (You are not required to use the same ID for iCloud and other services as you do for the iTunes store.)  This will prevent you from ending up with merged data.  You should also use separate Apple IDs for iMessage and FaceTime or you will end up getting each other's text messages and FaceTime calls.
    This article may be of interest: http://www.macstories.net/stories/ios-5-icloud-tips-sharing-an-apple-id-with-you r-family/, as well as this video: http://macmost.com/setting-up-multiple-ios-devices-for-messages-and-facetime.htm l.

  • How can I have multiple users on one apple id?

    How can I have multiple users on one apple ID?
    ie: I have my apple ID with my own credit, how can I set up credit for my son under the same apple ID, so that he can still access the same apps I've already downloaded and paid for?

    I've been trying to figure out a clean way to do this too. I think you may need more than one Apple ID – one that is shared and used to purchase "sharable" items and then "individual" Apple IDs for you and your son. That's the idea that I'm pursuing for the moment.
    It seems that there must be a way to do this, App Store purchases for the Mac are licensed across multiple machines. iPhone app purchases have "all your devices" licensing. Makes me think that Apple has a process in mind for sharing an account (or associating a device with multiple accounts).
    Other things I've learned:
    - Apparently you can't merge Apple ID accounts. I asked about this once at an Apple Store and was told that there was no way to do it.
    - If you share an Apple ID the Messages app behaves in a somewhat surprising manner. It must use your Apple ID to decide where messages should be sent because all users get all messages. This can make it very hard to organize a surprise party :-)

  • TS5223 can I have multiple users use one apple account?

    can I have multiple users use one apple account?

    I interpreted his post to mean that he meant multiple human users, not multiple devices.  Hopefully, he'll clarify.

  • How can I allow other users on my macbook to view my iphoto library when th

    How can I allow other users on my macbook to view my iphoto library when they are logged in. I do not have a network, and the users (my family) all log in seperately when they use the computer. Does anyone know? Thank you.

    rdoss
    Welcome to the Apple Discussions.
    If you want others to be able to see the pics, but not add to, change or alter your library, then enable Sharing in your iPhoto (Preferences -> Sharing), leave iPhoto running and use Fast User Switching to open the other account(s). In the other account(s), enable 'Look For Shared Libraries'. Your Library will appear in their source pane.
    Remember iPhoto must be running in both accounts for this to work.
    Regards
    TD

  • Can I allow multiple users on a blog?

    I would like to have remote users who can update and add pages to a blog in iweb.  Is this possible?

    You can't have multiple users manage an iWeb blog.  That's because you need the domain file that's in your Users/Home/Library/Application Support/iWeb folder to be able to do that.  That would mean all of them would have to have access to the same file and all be running on Macs with the same version of iWeb.
    I suggest you create your blog on one of the online blogging sites, embed it into your iWeb page like in this demo page, Embed a Site Within an iWeb Page, and then give those you want to have access the username and password for managing the blog.  This way you can update the blog from any computer anywhere and from many mobile devices.
    OT

  • I bought 26 new songs under my work e-mail and now i can't copy them to my i-pod because it has another music library on it. How can i combine both user id's to the same purchased account

    I have 2 user id's with apple, i bought 26 songs from my laptop recently using my work e-mail. I plug my i-pod to sync it and it says that my i-pod is tuned with another library. i don't want to erase the songs I have already because they are about 760 and the new ones are 26 only. how can I combine both user id's and consolidate all the music into one user id?
    everytime i try to do something it asks me to reset the password. I have done it already 6 times.
    there is no phone # to call.
    Thanks
    Elena

    Alright, please follow these steps in order to get it working properly again.
    Please change your Apple ID back to your old email address (that you used as Apple ID before) here: http://appleid.apple.com
    Then go to all your devices - iPhones, iPads, Mac etc. - ("Settings > iCloud") and delete your iCloud account from this devices (+ turn off Find My iPhone, but I guess it will ask you that anyway)
    After that go back to http://appleid.apple.com sign in again, and now change your Apple ID again to your new email address.
    Finally, set up your iCloud account on all your devices again.
    Now, everything should working properly again.

Maybe you are looking for

  • I do not know how to use i cloud. or i tunes anymore for that matter. can someone help me?

    I had not updated my Itunes in a while. when i got my mac i updated it to the latest version and i guess i set up i cloud but I have no idea how to use it. i have 1163 songs in my itunes library but they literally only show up some times and others t

  • Who can tell me about his forms2adf experience?

    Hello! Why is forms2adf not part of the evaluation version? This makes no sense to me. It is hard for me to convince my chef, to buy a software and I can't even tell him, if we will need it or not. All the reports and demos on forms2adf look very nic

  • Java install OS X Mavericks 10.9.5

    Hello, I am new to mac and recently received a MBP as a gift.  My operating system is OS X 10.9.5 (Mavericks).   I apologize if this has been answered numerous times in the forum but I have not been able to find a solution to my problem. I am trying

  • Os x Server 3.1 breaks Profile Manager

    Hi all, since i update to server 3.1, the Profile Manager wont start. In the ive got these Error: 0:: [245] [2014/03/20 20:15:14.725] Waiting for postgres to startup.... 0:: [245] [2014/03/20 20:15:18.445] +[PGConnection reloadPreferences]: DBDebug =

  • Lots of WAITS on database

    my database is 10g and when we fire sqls then it shows lots of waits. we are selecting records from partition tables and we are using ASM (normal redundancy) i have collected some data it shows Metrics "Database Time Spent Waiting (%)" is at 71.60994