Re: [gentoo-user] First Install - Help Setting Root Password

2005-05-09 Thread Sami Samhuri
* On Sun May-08-2005 at 03:27:41 PM -0700, Drew Tomlinson said:
 I've followed the directions in the handbook and installed from a 
 Knoppix boot.  I've made it all the way to section 10.d (reboot).  
 However upon reboot, I'm presented with a login prompt.  I log in as 
 root and enter the password I set in section 8.c but it tells me 'login 
 incorrect'.  I boot Knoppix again, perform the required steps and enter 
 my chroot environment.  I repeat section 8.c and reset the password.  I 
 also move ahead to section 11 and create a user account for myself, 
 passing along '-G wheel', so I can su if necessary.  I reboot again back 
 to Gentoo but get the same problem when logging on as root.  I can log 
 on with the new user account I've created but 'su' does not work (can't 
 setguid), probably due to the same password issue I have when logging on 
 as root.
 
 Any idea?  I'm almost there.

My only stab in the dark here:

In /etc/fstab do you have the nosuid option enabled on any of your
filesystems?

-- 
Sami Samhuri


pgpi502HPmYTa.pgp
Description: PGP signature


Re: [gentoo-user] First Install - Help Setting Root Password -- Almost SOLVED!

2005-05-09 Thread Neil Bothwick
On Sun, 08 May 2005 17:53:26 -0700, Drew Tomlinson wrote:

 OK, I've done some more reading and found that the reason I couldn't
 use 'su' as myself was because /bin/su didn't have the setuid bit set.
 So in all my fooling around, I have file ownership and modes screwed up 
 from the default.  What user:group should own all (or most) of the
 files after a install?  What files should be setuid?  Is there a list 
 somewhere?  Or will some incantation of  'emerge' fix all of this for
 me?

# qpkg -f /bin/su
sys-apps/shadow

So emerge --oneshot shadow should restore things to their defaults.  


-- 
Neil Bothwick

Multitasking?? But I only have one PC!


pgpglMQYH6GNy.pgp
Description: PGP signature


Re: [gentoo-user] First Install - Help Setting Root Password -- SOLVED!!!

2005-05-09 Thread Drew Tomlinson
On 5/9/2005 4:17 AM Neil Bothwick wrote:
On Sun, 08 May 2005 17:53:26 -0700, Drew Tomlinson wrote:
 

OK, I've done some more reading and found that the reason I couldn't
use 'su' as myself was because /bin/su didn't have the setuid bit set.
So in all my fooling around, I have file ownership and modes screwed up 
from the default.  What user:group should own all (or most) of the
files after a install?  What files should be setuid?  Is there a list 
somewhere?  Or will some incantation of  'emerge' fix all of this for
me?
   

# qpkg -f /bin/su
sys-apps/shadow
So emerge --oneshot shadow should restore things to their defaults.
 

Setting the setuid bit on /bin/su and /bin/login fixed my login 
problems.  I'm tried this suggestion and it worked.   However I don't 
quite understand exactly what the oneshot option does.  The man page says:

Emerge  as normal, but do not add the packages to the world profile for 
later updating.

So it rebuilds it but we don't add it to the world profile because it's 
part of the base system and we wouldn't want it upgraded unless we 
rebuilt everything else?  I'm brand spankin' new to both Linux and 
Gentoo but I have experience with FreeBSD.  In FreeBSD, I know one 
doesn't want to get his kernel and world out of sync.  Is the idea 
behind oneshot similar to this?

A big THANK YOU to all for helping this noob get up to speed.
Drew
--
Visit The Alchemist's Warehouse
Magic Tricks, DVDs, Videos, Books,  More!
http://www.alchemistswarehouse.com
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] First Install - Help Setting Root Password -- SOLVED!!!

2005-05-09 Thread Neil Bothwick
On Mon, 09 May 2005 10:20:23 -0700, Drew Tomlinson wrote:

 So emerge --oneshot shadow should restore things to their defaults.

 Setting the setuid bit on /bin/su and /bin/login fixed my login 
 problems.  I'm tried this suggestion and it worked.   However I don't 
 quite understand exactly what the oneshot option does.  The man page
 says:
 
 Emerge  as normal, but do not add the packages to the world profile for 
 later updating.

That's it. When you emerge a package, the package is added to your world
file, but any dependencies that are emerged are not. So the world file
contains only those packages that you explicitly want, not their
dependencies. Whenever I re-emerge anything I always use --oneshot, on
the basis that if it belongs in world, it is already there and if it
doesn't, I don't want to spoil things by adding it now.

shadow is a clear example of this, as it is a package you would never
install manually (in fact it is part of system).


-- 
Neil Bothwick

Groucho Borg: That's the silliest thing I ever assimilated...


pgpxyNwHCWADn.pgp
Description: PGP signature


[gentoo-user] First Install - Help Setting Root Password

2005-05-08 Thread Drew Tomlinson
I've followed the directions in the handbook and installed from a 
Knoppix boot.  I've made it all the way to section 10.d (reboot).  
However upon reboot, I'm presented with a login prompt.  I log in as 
root and enter the password I set in section 8.c but it tells me 'login 
incorrect'.  I boot Knoppix again, perform the required steps and enter 
my chroot environment.  I repeat section 8.c and reset the password.  I 
also move ahead to section 11 and create a user account for myself, 
passing along '-G wheel', so I can su if necessary.  I reboot again back 
to Gentoo but get the same problem when logging on as root.  I can log 
on with the new user account I've created but 'su' does not work (can't 
setguid), probably due to the same password issue I have when logging on 
as root.

Any idea?  I'm almost there.
Thanks,
Drew
--
Visit The Alchemist's Warehouse
Magic Tricks, DVDs, Videos, Books,  More!
http://www.alchemistswarehouse.com
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] First Install - Help Setting Root Password

2005-05-08 Thread Drew Tomlinson
On 5/8/2005 4:20 PM Mike Williams wrote:
On Monday 09 May 2005 00:09, Drew Tomlinson wrote:
 

I thought I did that with the '-G wheel' option I passed to useradd.  I
also think that if I'm not part of the wheel group, I wouldn't even have
the opportunity to enter a password after doing 'su'.  How can I check
to be sure I'm part of the wheel group?
   

You will still get asked.
id
 

OK, thanks.  I have confirmed that I'm part of the 'wheel' group with 
both the 'id' and 'groups' command, thus my problems must be from not 
setting the initial root password properly.  So any ideas on what I'm 
missing setting the root password in 8.c of the handbook?  From the 
chrooted environment as 'root' I issued 'passwd' and then typed in my 
new password.  I have also tried 'passwd root' with the same effect.  Do 
I need to do something different since I booted with Knoppix?

Thanks,
Drew
--
Visit The Alchemist's Warehouse
Magic Tricks, DVDs, Videos, Books,  More!
http://www.alchemistswarehouse.com
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] First Install - Help Setting Root Password

2005-05-08 Thread Drew Tomlinson
On 5/8/2005 4:42 PM Drew Tomlinson wrote:
On 5/8/2005 4:20 PM Mike Williams wrote:
On Monday 09 May 2005 00:09, Drew Tomlinson wrote:
 

I thought I did that with the '-G wheel' option I passed to useradd.  I
also think that if I'm not part of the wheel group, I wouldn't even 
have
the opportunity to enter a password after doing 'su'.  How can I check
to be sure I'm part of the wheel group?
  

You will still get asked.
id
 

OK, thanks.  I have confirmed that I'm part of the 'wheel' group with 
both the 'id' and 'groups' command, thus my problems must be from not 
setting the initial root password properly.  So any ideas on what I'm 
missing setting the root password in 8.c of the handbook?  From the 
chrooted environment as 'root' I issued 'passwd' and then typed in my 
new password.  I have also tried 'passwd root' with the same effect.  
Do I need to do something different since I booted with Knoppix?
One more update.  I found out how to boot in single user mode by adding 
'single' to the end of the kernel line in grub.  Booted to single user 
mode and issued 'passwd' command from there.  It still doesn't work.  My 
session goes like this:

sh-2.05b# passwd
New UNIX password:
BAD PASSWORD:  it is based on a dictionary word.
Retype new UNIX password:
passwd:  password updated successfully
I get the 'BAD PASSWORD' message no matter what password I use.  I tried 
this one '[EMAIL PROTECTED]' which I'm sure is not in the dictionary but still 
got that message.  I don't know if that provides any clues or not. 

To test the various new passwords, I used this string of commands after 
each attempt to set root's password:

sh-2.05b# su user
su(pam_unix)[1911]:  session opened for user user by (uid=0)
bash-2.05b$ su
Password:
setgid: Operation not permitted
bash-2.05b$
I repeated to two scenarios above with several different passwords.  All 
attempts failed.  So I have a bright shiny new system that I'd just love 
to be able to get in to.  :)  Any suggestions?

Thanks,
Drew
--
Visit The Alchemist's Warehouse
Magic Tricks, DVDs, Videos, Books,  More!
http://www.alchemistswarehouse.com
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] First Install - Help Setting Root Password

2005-05-08 Thread Brett I. Holcomb
If you're worried about the bad password message ignore it.  Mine always 
give that but if you notice it updates your password anyway.

Try su - and see what happens.
On Sun, 8 May 2005, Drew Tomlinson wrote:
On 5/8/2005 4:42 PM Drew Tomlinson wrote:
 On 5/8/2005 4:20 PM Mike Williams wrote:
  On Monday 09 May 2005 00:09, Drew Tomlinson wrote:
 
 
   I thought I did that with the '-G wheel' option I passed to useradd. 
'single' to the end of the kernel line in grub.  Booted to single user mode 
and issued 'passwd' command from there.  It still doesn't work.  My session 
goes like this:

sh-2.05b# passwd
New UNIX password:
BAD PASSWORD:  it is based on a dictionary word.
Retype new UNIX password:
passwd:  password updated successfully
I get the 'BAD PASSWORD' message no matter what password I use.  I tried this 
one '[EMAIL PROTECTED]' which I'm sure is not in the dictionary but still got that 
message.  I don't know if that provides any clues or not. 
To test the various new passwords, I used this string of commands after each 
attempt to set root's password:

sh-2.05b# su user
su(pam_unix)[1911]:  session opened for user user by (uid=0)
bash-2.05b$ su
Password:
setgid: Operation not permitted
bash-2.05b$
I repeated to two scenarios above with several different passwords.  All 
attempts failed.  So I have a bright shiny new system that I'd just love to 
be able to get in to.  :)  Any suggestions?

Thanks,
Drew

--
Brett I. Holcomb
[EMAIL PROTECTED]
Registered Linux User #188143
Remove R777 to email
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] First Install - Help Setting Root Password -- Almost SOLVED!

2005-05-08 Thread Drew Tomlinson
On 5/8/2005 5:29 PM Drew Tomlinson wrote:
On 5/8/2005 4:42 PM Drew Tomlinson wrote:
On 5/8/2005 4:20 PM Mike Williams wrote:
On Monday 09 May 2005 00:09, Drew Tomlinson wrote:
 

I thought I did that with the '-G wheel' option I passed to 
useradd.  I
also think that if I'm not part of the wheel group, I wouldn't even 
have
the opportunity to enter a password after doing 'su'.  How can I check
to be sure I'm part of the wheel group?
  

You will still get asked.
id
 

OK, thanks.  I have confirmed that I'm part of the 'wheel' group with 
both the 'id' and 'groups' command, thus my problems must be from not 
setting the initial root password properly.  So any ideas on what I'm 
missing setting the root password in 8.c of the handbook?  From the 
chrooted environment as 'root' I issued 'passwd' and then typed in my 
new password.  I have also tried 'passwd root' with the same effect.  
Do I need to do something different since I booted with Knoppix?

One more update.  I found out how to boot in single user mode by 
adding 'single' to the end of the kernel line in grub.  Booted to 
single user mode and issued 'passwd' command from there.  It still 
doesn't work.  My session goes like this:

sh-2.05b# passwd
New UNIX password:
BAD PASSWORD:  it is based on a dictionary word.
Retype new UNIX password:
passwd:  password updated successfully
I get the 'BAD PASSWORD' message no matter what password I use.  I 
tried this one '[EMAIL PROTECTED]' which I'm sure is not in the dictionary but 
still got that message.  I don't know if that provides any clues or not.
To test the various new passwords, I used this string of commands 
after each attempt to set root's password:

sh-2.05b# su user
su(pam_unix)[1911]:  session opened for user user by (uid=0)
bash-2.05b$ su
Password:
setgid: Operation not permitted
bash-2.05b$
I repeated to two scenarios above with several different passwords.  
All attempts failed.  So I have a bright shiny new system that I'd 
just love to be able to get in to.  :)  Any suggestions? 
OK, I've done some more reading and found that the reason I couldn't use 
'su' as myself was because /bin/su didn't have the setuid bit set.  So 
in all my fooling around, I have file ownership and modes screwed up 
from the default.  What user:group should own all (or most) of the files 
after a install?  What files should be setuid?  Is there a list 
somewhere?  Or will some incantation of  'emerge' fix all of this for me?

Thanks,
Drew
--
Visit The Alchemist's Warehouse
Magic Tricks, DVDs, Videos, Books,  More!
http://www.alchemistswarehouse.com
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] First Install - Help Setting Root Password

2005-05-08 Thread Andreas Claesson
On 5/9/05, Drew Tomlinson [EMAIL PROTECTED] wrote:
snip
 To test the various new passwords, I used this string of commands after
 each attempt to set root's password:
 
 sh-2.05b# su user
 su(pam_unix)[1911]:  session opened for user user by (uid=0)
 bash-2.05b$ su
 Password:
 setgid: Operation not permitted

Because of the setgid error I don't think it is a password problem. 
The normal output on wrong passwords are:

# su
Password:
su: Authentication failure
Sorry.

Something else (pam?) is not allowing you to become root.

-- 
gentoo-user@gentoo.org mailing list