shanenin Posted February 8, 2008 Report Share Posted February 8, 2008 I am running OS X 10.5.1. I am not sure why, but when using a shell I am not able to su to another user. When ever I try it, it says my password failed. Quote Link to post Share on other sites
shanenin Posted February 8, 2008 Author Report Share Posted February 8, 2008 Now it seems to be working like it should. Strange. Quote Link to post Share on other sites
shanenin Posted February 9, 2008 Author Report Share Posted February 9, 2008 su is not working the way I am used to using it with Linux, it seems broke, but maybe it is just the way they have OS X configured. Here is what it is doing. I first open the shell from a regular user, I then try to use the command, su root to login in the account called "root". The password just fails, and I can't log in. The strange part is, If I first switch users to my other admin account called shanelindberg, I can then log into the account called "root". Quote Link to post Share on other sites
hitest Posted February 9, 2008 Report Share Posted February 9, 2008 su is not working the way I am used to using it with Linux, it seems broke, but maybe it is just the way they have OS X configured. Here is what it is doing. I first open the shell from a regular user, I then try to use the command, su root to login in the account called "root". The password just fails, and I can't log in. The strange part is, If I first switch users to my other admin account called shanelindberg, I can then log into the account called "root".Hmmmmm......that's weird. OS X is kinda BSD under the hood so that should work. Maybe it is some permission type thing. Maybe if you log-on as admin you can check the privileges that your regular user has and give your regular user more access. I'm not a mac super user so I could be wrong here. Quote Link to post Share on other sites
isteve Posted February 9, 2008 Report Share Posted February 9, 2008 Try sudo -s this should work. Quote Link to post Share on other sites
shanenin Posted February 9, 2008 Author Report Share Posted February 9, 2008 I am just more curious to why I can't log into the root account. Their is no reason I need to; for any administrative stuff I can use my other admin account called shanelindberg. Quote Link to post Share on other sites
isteve Posted February 9, 2008 Report Share Posted February 9, 2008 Did you enable root in the directory utility? Quote Link to post Share on other sites
jcl Posted February 9, 2008 Report Share Posted February 9, 2008 (edited) Is your account a member of groups wheel or admin?(You should get a complaint about group membership if that's the problem, but I don't recall su producing particularly helpful error messages.) Edited February 9, 2008 by jcl Quote Link to post Share on other sites
shanenin Posted February 9, 2008 Author Report Share Posted February 9, 2008 Did you enable root in the directory utility?no, I just set the root password. I will have to check out the directory utility when i get home. Quote Link to post Share on other sites
shanenin Posted February 9, 2008 Author Report Share Posted February 9, 2008 Is your account a member of groups wheel or admin?(You should get a complaint about group membership if that's the problem, but I don't recall su producing particularly helpful error messages.)still trying to find where that info is stored on Leopard. Unlike Linux(I have not used it in over a year, my skills are rusty), it does not seemed to be stored in /etc/groups.It is just a standard account, so I am assuming it is not a member of admin. I should be able to add it to the wheel group. Quote Link to post Share on other sites
jcl Posted February 9, 2008 Report Share Posted February 9, 2008 (edited) still trying to find where that info is stored on Leopard. Unlike Linux(I have not used it in over a year, my skills are rusty), it does not seemed to be stored in /etc/groups.It's in a database somewhere. It looks like you use the dscl utility to access the database. The user-interface seems to be a bit opaque from the examples I've seen. Not unlike accessing the Windows registry via the command-line utilities. I think# dscl . append /Groups/wheel GroupMembership $USERwill add $USER to wheel but I offer no warranty. Also, I don't know if OS X has a wheel group or if being a member of wheel lets you su. Edited February 9, 2008 by jcl Quote Link to post Share on other sites
shanenin Posted February 9, 2008 Author Report Share Posted February 9, 2008 what does the "." between dscl and append do?edit //by the way, that command worked. I am now in the wheel group and can su to root Quote Link to post Share on other sites
shanenin Posted February 9, 2008 Author Report Share Posted February 9, 2008 This is kind of interesting. According to the ouptut of the following command only "root" and "shane" are in the wheel group, yet the admin account called shanelindberg could also su to root.bash-3.2$ dscl . -read /groups/wheelAppleMetaNodeLocation: /Local/DefaultGeneratedUID: ABCDEFAB-CDEF-ABCD-EFAB-CDEF00000000GroupMembership: root shanePassword: *PrimaryGroupID: 0RealName: System GroupRecordName: wheelRecordType: dsRecTypeNative:groupsSMBSID: S-1-5-21-100 Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.