Re: how to change root passwd (if forgotten)
Le Wed, 10 Aug 2011 18:10:02 +0200, Thierry Chatelet a écrit : On Wednesday 10 August 2011 17:53:26 Umarzuki Mochlis wrote: if i'm not mistaken you can just go to single user mode on centos by appending 1 or single (without quotes) on boot parameter, no need for any live cd Not with debian, but lots of trail if you google it. Thierry But init=/sbin/bash should work, then mount, modify, dont forget to umount everything and reboot -- Francois -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e43814f$0$16474$426a7...@news.free.fr
Re: how to change root passwd (if forgotten)
Francois Cerbelle franc...@cerbelle.net writes: Le Wed, 10 Aug 2011 18:10:02 +0200, Thierry Chatelet a écrit: On Wednesday 10 August 2011 17:53:26 Umarzuki Mochlis wrote: if i'm not mistaken you can just go to single user mode on centos by appending 1 or single (without quotes) on boot parameter, no need for any live cd Not with debian, but lots of trail if you google it. But init=/sbin/bash should work, then mount, modify, dont forget to umount everything and reboot Instead of rebooting, one may exec the proper init(8) here, like: # exec /sbin/init -- FSF associate member #7257 -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/86k4akb7gg@gray.siamics.net
Re: how to change root passwd (if forgotten)
On 08/11/11 00:35, abdelkader belahcene wrote: On 8/10/11, Lucas Limalcs.freirel...@gmail.com wrote: the passwords are stored in /etc/shadow and you deleted the file, you should restore it. I just removed the second field , the password for th root. no more things You can copy a password from other user or even from other machine. Wawrzek -- Wawrzyniec (Wawrzek) Niewodniczan'ski - (niewod @ LinkedIn http://uk.linkedin.com/in/niewod) System Administrator - Engineering Services Team (XenServer) Citrix Systems, Building 101, Cambridge Science Park, CB4 0FY, Cambridge PhD in Quantum Chemistry, MSc in Molecular EngineeringM
Re: how to change root passwd (if forgotten)
On Wed, Aug 10, 2011 at 11:25 AM, abdelkader belahcene abelahc...@gmail.com wrote: Hi, I ve forgotten my root passwd on centos 6 (red hat based), I tried to change it as I used in debian (in debian it works perfectly) , that is: use a cd live (or installation cd1), to access the hd, I mount my root partition and mount proc and devices Definitely the wrong newsgroup, but: * boot with CentOS, RHEL, or Scientific Linux rescue CD * Select linux rescue or rescue mode from the CD boot process. * Allow it to mount your old system at /mnt/sysimage with all the relevant /dev and /dev/sys utilities under it. * Do chroot /mnt/sysimage to enter the environment of the mounted directories, in a chroot cage. * THEN do passwd root * Exit the chroot. (Just type exit). * Sync the disk changes, just as a precaution. (Just type sync) * Reboot and eject CD. I generally setup PXE to make these tools available without a CD in large environments,. The chroot business is core to updating messed up grub configurations, password files, kernels, fstab, or core system libraries. I tried the command passwd, no error reprorted, but after reboot the passwd had´t changed. then I decided to remove passwd from /etc/shadow (delete the second field). OK, now I can access my machine without passwd, BUT I CAN´T GIVE ANY PASSWORD I RECEIVE THIS ERROR # passwd Changing password for user root. New password: Retype new password: passwd: Authentication token manipulation error any idea to fix the problem. thanks a lot -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/caocn9rwfnvvgrs7c3zcyask-be070x-kzr3oso8g4ptxhpo...@mail.gmail.com
Re: how to change root passwd (if forgotten)
On Thu, 11 Aug 2011 07:14:23 + (GMT) Francois Cerbelle franc...@cerbelle.net wrote: Le Wed, 10 Aug 2011 18:10:02 +0200, Thierry Chatelet a écrit : On Wednesday 10 August 2011 17:53:26 Umarzuki Mochlis wrote: if i'm not mistaken you can just go to single user mode on centos by appending 1 or single (without quotes) on boot parameter, no need for any live cd Not with debian, but lots of trail if you google it. Thierry But init=/sbin/bash should work, then mount, modify, dont forget to umount everything and reboot You mean init=/bin/bash right? and you'll probably have to mount -o remount,rw / before you passwd. -- rbmj -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20110811105926.39792...@blairasus.mason.homeunix.org
Re: how to change root passwd (if forgotten)
On Thu, 11 Aug 2011 10:23:17 -0400, Nico Kadel-Garcia wrote: On Wed, Aug 10, 2011 at 11:25 AM, abdelkader belahcene abelahc...@gmail.com wrote: Hi, I ve forgotten my root passwd on centos 6 (red hat based), I tried to change it as I used in debian (in debian it works perfectly) , that is: use a cd live (or installation cd1), to access the hd, I mount my root partition and mount proc and devices Definitely the wrong newsgroup, but: * boot with CentOS, RHEL, or Scientific Linux rescue CD * Select linux rescue or rescue mode from the CD boot process. * Allow it to mount your old system at /mnt/sysimage with all the relevant /dev and /dev/sys utilities under it. * Do chroot /mnt/sysimage to enter the environment of the mounted directories, in a chroot cage. * THEN do passwd root * Exit the chroot. (Just type exit). * Sync the disk changes, just as a precaution. (Just type sync) * Reboot and eject CD. I generally setup PXE to make these tools available without a CD in large environments,. The chroot business is core to updating messed up grub configurations, password files, kernels, fstab, or core system libraries. I tried the command passwd, no error reprorted, but after reboot the passwd had´t changed. then I decided to remove passwd from /etc/shadow (delete the second field). OK, now I can access my machine without passwd, BUT I CAN´T GIVE ANY PASSWORD I RECEIVE THIS ERROR # passwd Changing password for user root. New password: Retype new password: passwd: Authentication token manipulation error any idea to fix the problem. thanks a lot All the responses (except one) have me mystified. Why can't OP just boot into single user mode? -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/j2181p$mlt$1...@dough.gmane.org
Re: how to change root passwd (if forgotten)
On 11/08/11 19:46, Walter Hurry wrote: On Thu, 11 Aug 2011 10:23:17 -0400, Nico Kadel-Garcia wrote: On Wed, Aug 10, 2011 at 11:25 AM, abdelkader belahcene abelahc...@gmail.com wrote: Hi, I ve forgotten my root passwd on centos 6 (red hat based), I tried to change it as I used in debian (in debian it works perfectly) , that is: (snippage) All the responses (except one) have me mystified. Why can't OP just boot into single user mode? Because you need the root password to enter single user mode? -- Dom -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e442d61.30...@rpdom.net
Re: how to change root passwd (if forgotten)
On Thu, 11 Aug 2011 20:28:33 +0100, Dom wrote: On 11/08/11 19:46, Walter Hurry wrote: On Thu, 11 Aug 2011 10:23:17 -0400, Nico Kadel-Garcia wrote: On Wed, Aug 10, 2011 at 11:25 AM, abdelkader belahcene abelahc...@gmail.com wrote: Hi, I ve forgotten my root passwd on centos 6 (red hat based), I tried to change it as I used in debian (in debian it works perfectly) , that is: (snippage) All the responses (except one) have me mystified. Why can't OP just boot into single user mode? Because you need the root password to enter single user mode? Not in RHEL and clones. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/j21hts$l5i$1...@dough.gmane.org
Re: how to change root passwd (if forgotten)
On Thu, 11 Aug 2011 15:48:02 -0600 Aaron Toponce aaron.topo...@gmail.com wrote: sulogin is easy enough to bypass. * Boot Live CD * Mount / * Edit /etc/inittab * Comment out si::sysinit:/etc/init.d/rcS * Reboot into single user mode Much easer than chroots, or any of the other previous suggestion, IMO. Easier than: * Add init=/bin/bash to the end of kernel in grub * mount -o remount,rw / * passwd * sync reboot ? Most people I know would rather blindly type commands than edit a file, and I for one lose my Live CDs a lot :D -- rbmj -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20110811224731.27c48...@blairasus.mason.homeunix.org
Re: how to change root passwd (if forgotten)
Robert Blair Mason r...@verizon.net writes: On Thu, 11 Aug 2011 15:48:02 -0600 sulogin is easy enough to bypass. * Boot Live CD * Mount / * Edit /etc/inittab * Comment out si::sysinit:/etc/init.d/rcS * Reboot into single user mode Much easer than chroots, or any of the other previous suggestion, IMO. Easier than: * Add init=/bin/bash to the end of kernel in grub * mount -o remount,rw / * passwd * sync reboot I'd rather recommend # umount -a instead of # sync here. Then, to my experience, # exec /sbin/init is by no way inferior to # reboot. ? Most people I know would rather blindly type commands than edit a file, and I for one lose my Live CDs a lot :D -- FSF associate member #7257 -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/86sjp79t6i@gray.siamics.net
how to change root passwd (if forgotten)
*Hi, I ve forgotten my root passwd on centos 6 (red hat based), I tried to change it as I used in debian (in debian it works perfectly) , that is: use a cd live (or installation cd1), to access the hd, I mount my root partition and mount proc and devices I tried the command passwd, no error reprorted, but after reboot the passwd had´t changed. then I decided to remove passwd from /etc/shadow (delete the second field). OK, now I can access my machine without passwd, BUT I CAN´T GIVE ANY PASSWORD I RECEIVE THIS ERROR # passwd* *Changing password for user root. New password: Retype new password: passwd: Authentication token manipulation error any idea to fix the problem. thanks a lot *
Re: how to change root passwd (if forgotten)
if i'm not mistaken you can just go to single user mode on centos by appending 1 or single (without quotes) on boot parameter, no need for any live cd 2011/8/10 abdelkader belahcene abelahc...@gmail.com *Hi, I ve forgotten my root passwd on centos 6 (red hat based), I tried to change it as I used in debian (in debian it works perfectly) , that is: use a cd live (or installation cd1), to access the hd, I mount my root partition and mount proc and devices I tried the command passwd, no error reprorted, but after reboot the passwd had´t changed. then I decided to remove passwd from /etc/shadow (delete the second field). OK, now I can access my machine without passwd, BUT I CAN´T GIVE ANY PASSWORD I RECEIVE THIS ERROR # passwd* *Changing password for user root. New password: Retype new password: passwd: Authentication token manipulation error any idea to fix the problem. thanks a lot * -- Regards, Umarzuki Mochlis http://debmal.my
Re: how to change root passwd (if forgotten)
On Wednesday 10 August 2011 17:53:26 Umarzuki Mochlis wrote: if i'm not mistaken you can just go to single user mode on centos by appending 1 or single (without quotes) on boot parameter, no need for any live cd Not with debian, but lots of trail if you google it. Thierry -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/201108101801.45163.tchate...@free.fr
Re: how to change root passwd (if forgotten)
On Wed, Aug 10, 2011 at 5:25 PM, abdelkader belahcene abelahc...@gmail.com wrote: Hi, I ve forgotten my root passwd on centos 6 (red hat based), I tried to change it as I used in debian (in debian it works perfectly) , that is: ... any idea to fix the problem. thanks a lot http://www.centos.org/docs/5/html/Installation_Guide-en-US/ch-rescuemode.html -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/campsvvyx37xfzy4dyscmzszr3khyjaitysbykhnyw_gjpak...@mail.gmail.com
Re: how to change root passwd (if forgotten)
abdelkader belahcene abelahc...@gmail.com writes: […] then I decided to remove passwd from /etc/shadow (delete the second field). OK, now I can access my machine without passwd, BUT I CAN´T GIVE ANY PASSWORD I RECEIVE THIS ERROR # passwd* *Changing password for user root. New password: Retype new password: passwd: Authentication token manipulation error any idea to fix the problem. Running pwck(8) may give one more information on the issue. Then, I'd make a backup for shadow(5) and try to use pwconv(8) to fix the inconsistencies reported by pwck(8). thanks a lot * -- FSF associate member #7257 -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/86y5z1b0ir@gray.siamics.net
Re: how to change root passwd (if forgotten)
you forgot chroot. might also need to do ldconfig -v to make sure the path to shared libraries is correct (but i don't think so). you used to be able to clear out the field in the shadow file or clear out the x (iirc) in passwd, but i think default pam will stop you from doing this :) On Wed, Aug 10, 2011 at 11:25, abdelkader belahcene abelahc...@gmail.comwrote: *Hi, I ve forgotten my root passwd on centos 6 (red hat based), I tried to change it as I used in debian (in debian it works perfectly) , that is: use a cd live (or installation cd1), to access the hd, I mount my root partition and mount proc and devices I tried the command passwd, no error reprorted, but after reboot the passwd had´t changed. then I decided to remove passwd from /etc/shadow (delete the second field). OK, now I can access my machine without passwd, BUT I CAN´T GIVE ANY PASSWORD I RECEIVE THIS ERROR # passwd* *Changing password for user root. New password: Retype new password: passwd: Authentication token manipulation error any idea to fix the problem. thanks a lot *
Re: how to change root passwd (if forgotten)
On 8/10/11, Lucas Lima lcs.freirel...@gmail.com wrote: the passwords are stored in /etc/shadow and you deleted the file, you should restore it. I just removed the second field , the password for th root. no more things restore it ?? how?? starting with level 1, (single ) is not a solution, the password is required. regards And to set a new root password read more, its quite easy 2011/8/10 abdelkader belahcene abelahc...@gmail.com *Hi, I ve forgotten my root passwd on centos 6 (red hat based), I tried to change it as I used in debian (in debian it works perfectly) , that is: use a cd live (or installation cd1), to access the hd, I mount my root partition and mount proc and devices I tried the command passwd, no error reprorted, but after reboot the passwd had´t changed. then I decided to remove passwd from /etc/shadow (delete the second field). OK, now I can access my machine without passwd, BUT I CAN´T GIVE ANY PASSWORD I RECEIVE THIS ERROR # passwd* *Changing password for user root. New password: Retype new password: passwd: Authentication token manipulation error any idea to fix the problem. thanks a lot * -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/caf3f0sq9v-jesslulzxqz-yrukv7uktrcy-oy15y7xzd+g0...@mail.gmail.com