Help - Search - Members - Calendar
Full Version: need urgent help [solved]
MandrivaUsers.org > Advanced Topics > Other Linux and Unix Distributions
ilia_kr
Hi there,
After playing for some time with new Ubuntu 7.04 i somehow managed to destroy the account for the firs system user (so called root). Now i don't have an administrative authorities any more. I only have a normal user account that doesn't let me start any of the system GUI tools and I'm not familiar with Ubuntu CLI system tools neither.
The first user was "ilia". Its home folder doesn't exist in "/home". All i have now (if i get it right) is "iliakr" normal user.

Please help.
Soka
Boot ubuntu in runlevel 1 (recovery mode or single user mode in the boot menu, if you don't have those options edit the kernel booting option and add single at the end).
To add an account with administrative privileges run
CODE
user add "username" admin
or to enable the root account run
CODE
passwd root
ilia_kr
QUOTE (Soka @ Aug 10 2007, 02:21 PM) *
Boot ubuntu in runlevel 1 (recovery mode or single user mode in the boot menu, if you don't have those options edit the kernel booting option and add single at the end).

I don't know how to do that.
QUOTE (Soka @ Aug 10 2007, 02:21 PM) *
...or to enable the root account run
CODE
passwd root

and that will enable the the ordinary root account like in Mandriva for instance?
knoba
I don't know Ubuntu and I may be way off base here illia, but i found this on my travels. I do not vouch for it as i have never had to use it - but it's Linux - right? Maybe someone else can testify to its usefulness.

QUOTE
Boot next time giving 'init=/bin/sh' as argument to the kernel, and reset the root password with the 'passwd' command.
For lilo, at the prompt type 'linux init=/bin/sh', for grub, hit 'e' when you have you have selected the right entry in the menu).

Or as another alternative perhaps, boot with a linux live-cd or a rescue cd, look for the partition in which your etc/passwd file is
(cfdisk should give you insight into your partition table), and reset the root password by:

mount /dev/hda1 /mnt
(assuming the first partition on the first ide disk is your root partition, try hda2, 3, etc if the next step fails)
chroot /mnt
passwd
<type new root password twice>
reboot


...if nothing else it may help you build a solution.
arctic
Ubuntu, like Mandriva (since 2007) or Fedora uses grub as the default bootmanager. In order to boot into a command-line only system, press "esc" at the boot selection screen, then "e" for editing. Then select the line with the kernel path and hit "e" again in order to edit that specific line. Now add a "3" at the end of that line in order to boot into init 3 mode or "1" for an init 1 mode. Once you have finished editing the files, press "b" to boot that entry.

Remember that any changes done that way are only temprorary = if you reboot, you will have the default boot entry again.

"passwd root" should basically work.
ilia_kr
Thank you guys, I've fixed it with your help. Have to admit that this "sudo" thing is really annoying.
scarecrow
QUOTE (ilia_kr @ Aug 10 2007, 09:12 PM) *
Thank you guys, I've fixed it with your help. Have to admit that this "sudo" thing is really annoying.


I have to agree.
However, if you ask some 85% of the *buntu users about that user "root", they will reply "who the f&ck is he?" 18.gif
daniewicz
QUOTE
"who the f&ck is he?"


18.gif
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.