On Sat, 23 Nov 2019 at 16:51, Helmut Walle <[email protected]> wrote:

> Not sure what you have on that USB drive, but if it just is a downloaded
> image, they usually
> come with a blank root password. So to login as root, you just enter
> "root" at the username
> prompt if there is one at all, and hit Enter if it prompts for a password
> at all. If you are
> already logged in under a non-root account, use 'sudo su' to get root
> access (again with an
> empty password).
>
> So for recovering your root password stored in the system on the HD...
> usually recovering that
> password would be a lot of work if possible at all, because passwords are
> only stored encrypted
> these days. It is usually easier to just delete the password. To do that:
>
> 1. Boot a rescue system of some sort from a USB medium (or CD / DVD if
> that's easier).
>

I have created a rescue USB flash drive thanks to Rik Tindall.


> 2. Log in as root, or 'sudo su' if you are already logged in (see above).
>

Funnily enough, the command "sudo su" puts you into root mode.  Is that
because I have deleted my root password (see later on in this email).
Does this mean that I need to amend my documentation for my
installer module from the following:

su ENTER
<enter the root password here> ENTER
apt-get install bash ENTER
apt-get install dos2uni ENTER
apt-get install grep ENTER
apt-get install make ENTER
apt-get install sed ENTER
exit ENTER

to what follows:

sudo su ENTER
apt-get install bash ENTER
apt-get install grep ENTER
apt-get install make ENTER
apt-get install sed ENTER
exit ENTER

3. Mount the partition with your system files somewhere (/mnt usually is
> already there and can
> be used).
> 4. Find the shadow password file where the encrypted passwords are stored
> (probably /etc/shadow
> - so if you have mounted your HD at /mnt , then it would be /mnt/etc/shadow
>

The file shadow is located at the following location: /etc/shadow

2. Log in as root, or 'sudo su' if you are already logged in (see above).
3. Mount the partition with your system files somewhere (/mnt usually is
already there and can
be used).
4. Find the shadow password file where the encrypted passwords are stored
(probably /etc/shadow
- so if you have mounted your HD at /mnt , then it would be /mnt/etc/shadow
5. Make a backup copy of that file in the same folder, just in case.
6. Open the shadow file in a text editor, and find the line that begins
with "root". The shadow
file contains the passwords and other parameters for all user accounts, one
account per line
(details available via 'man 5 shadow'). The fields separator is a colon. So
all the gibberish
between the colon after "root" and the next colon is your encrypted root
password...
7. Delete the entire encrypted root password.
8. Insert an asterisk '*' between the two colons following "root", where
the encrypted password
was before.
9. Save the file.
10. Reboot from HD. Your root password should now be void - so to log in as
root, enter "root"
at the username prompt, and then hit Enter at the password prompt.

Is that what you are looking for?

Kind regards,

Helmut.


On 24/11/2019 03:24, Davin Pearson wrote:
> After much trying I finally got the BIOS screen
> online.  Running the USB drive by deleting
> the Ubuntu partition works well but at no point
> does it ask for the root user password.
>
> What gives?  I need the root user account
> for accessing miscellaneous files in GNU/Linux.
>
> Thank you.
>
>
>
> On Sun, 24 Nov 2019 at 02:53, Davin Pearson <[email protected]
> <mailto:[email protected]>> wrote:
>
>
>
>     On Sun, 24 Nov 2019 at 02:48, Davin Pearson <[email protected]
>     <mailto:[email protected]>> wrote:
>
>         Sorry I have gone and forgotten my root password.
>
>         I need to boot from my USB stick drive to
>         retrieve it.
>
>         Holding down the Esc key while booting
>         doesn't help with the matter.  Instead, it
>         asks me if I want to install Linux or Windows.
>
>
>     Actually it asks me if I want to boot under
>     Ubuntu or Windows rather than install.
>     That was a typo on my part.
>
>
>         I can't seem to get access to the BIOS menu.
>
>         Thank you in advance for your help.
>
>         On Tue, 19 Nov 2019 at 16:02, Rik Tindall <[email protected]
>         <mailto:[email protected]>> wrote:
>
>             If it's not a clickable link icon on your desktop, you can
quickly make it so.
>
>             Just find / navigate to the appropriate volume in the file
manager, then click it to
>             mount and open it (producing the desktop link). You can then
right-click for a menu
>             to make such a link permanent if it isn't already.
>
>             Cheers, Rik
>
>             On 2019-11-19 15:14, Davin Pearson wrote:
>
>>             I am having some difficulties in accessing my C:\ drive from
>>             inside of Linux.   Under Lubuntu (my old computer's O.S.)
>>             you simply type in:
>>
>>             cd /media/www/C1TB
>>
>>             And then you can access the C drive using
>>             ls etc.
>>
>>             What is the way forward?
>>
>>             A brief google search did not come up with any useful
information.
>>
>>             <trim>
>>             --
>>             Sincerely and kindest regards, Davin.
>>             Davin Pearson    http://davin.50webs.com
>             _______________________________________________
>             Linux-users mailing list
>             [email protected] <mailto:
[email protected]>
Attachments area
Preview attachment pEpkey.asc
<https://mail.google.com/mail/u/0?ui=2&ik=d93452af4c&attid=0.1&permmsgid=msg-f:1650963101673577199&th=16e966319c87daef&view=att&disp=safe>





*I have removed the crud between the :.*:* regep

> 5. Make a backup copy of that file in the same folder, just in case.
> 6. Open the shadow file in a text editor, and find the line that begins
> with "root". The shadow
> file contains the passwords and other parameters for all user accounts,
> one account per line
> (details available via 'man 5 shadow'). The fields separator is a colon.
> So all the gibberish
> between the colon after "root" and the next colon is your encrypted root
> password...
> 7. Delete the entire encrypted root password.
> 8. Insert an asterisk '*' between the two colons following "root", where
> the encrypted password
> was before.
> 9. Save the file.
> 10. Reboot from HD. Your root password should now be void - so to log in
> as root, enter "root"
> at the username prompt, and then hit Enter at the password prompt.
>
> Is that what you are looking for?
>
> Kind regards,
>
> Helmut.
>
>
> On 24/11/2019 03:24, Davin Pearson wrote:
> > After much trying I finally got the BIOS screen
> > online.  Running the USB drive by deleting
> > the Ubuntu partition works well but at no point
> > does it ask for the root user password.
> >
> > What gives?  I need the root user account
> > for accessing miscellaneous files in GNU/Linux.
> >
> > Thank you.
> >
> >
> >
> > On Sun, 24 Nov 2019 at 02:53, Davin Pearson <[email protected]
> > <mailto:[email protected]>> wrote:
> >
> >
> >
> >     On Sun, 24 Nov 2019 at 02:48, Davin Pearson <[email protected]
> >     <mailto:[email protected]>> wrote:
> >
> >         Sorry I have gone and forgotten my root password.
> >
> >         I need to boot from my USB stick drive to
> >         retrieve it.
> >
> >         Holding down the Esc key while booting
> >         doesn't help with the matter.  Instead, it
> >         asks me if I want to install Linux or Windows.
> >
> >
> >     Actually it asks me if I want to boot under
> >     Ubuntu or Windows rather than install.
> >     That was a typo on my part.
> >
> >
> >         I can't seem to get access to the BIOS menu.
> >
> >         Thank you in advance for your help.
> >
> >         On Tue, 19 Nov 2019 at 16:02, Rik Tindall <[email protected]
> >         <mailto:[email protected]>> wrote:
> >
> >             If it's not a clickable link icon on your desktop, you can
> quickly make it so.
> >
> >             Just find / navigate to the appropriate volume in the file
> manager, then click it to
> >             mount and open it (producing the desktop link). You can then
> right-click for a menu
> >             to make such a link permanent if it isn't already.
> >
> >             Cheers, Rik
> >
> >             On 2019-11-19 15:14, Davin Pearson wrote:
> >
> >>             I am having some difficulties in accessing my C:\ drive from
> >>             inside of Linux.   Under Lubuntu (my old computer's O.S.)
> >>             you simply type in:
> >>
> >>             cd /media/www/C1TB
> >>
> >>             And then you can access the C drive using
> >>             ls etc.
> >>
> >>             What is the way forward?
> >>
> >>             A brief google search did not come up with any useful
> information.
> >>
> >>             <trim>
> >>             --
> >>             Sincerely and kindest regards, Davin.
> >>             Davin Pearson    http://davin.50webs.com
> >             _______________________________________________
> >             Linux-users mailing list
> >             [email protected] <mailto:
> [email protected]>
> >             http://lists.canterbury.ac.nz/mailman/listinfo/linux-users
> >
> >
> >
> >         --
> >         Sincerely and kindest regards, Davin.
> >         Davin Pearson    http://davin.50webs.com
> >
> >
> >
> >     --
> >     Sincerely and kindest regards, Davin.
> >     Davin Pearson    http://davin.50webs.com
> >
> >
> >
> > --
> > Sincerely and kindest regards, Davin.
> > Davin Pearson    http://davin.50webs.com
> >
> > _______________________________________________
> > Linux-users mailing list
> > [email protected]
> > http://lists.canterbury.ac.nz/mailman/listinfo/linux-users
> >
> _______________________________________________
> Linux-users mailing list
> [email protected]
> http://lists.canterbury.ac.nz/mailman/listinfo/linux-users
>


-- 
Sincerely and kindest regards, Davin.
Davin Pearson    http://davin.50webs.com
_______________________________________________
Linux-users mailing list
[email protected]
http://lists.canterbury.ac.nz/mailman/listinfo/linux-users

Reply via email to