Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 25 Oct 1997 18:17:32 +0930
From:      Greg Lehey <grog@lemis.com>
To:        jwlo@ms11.hinet.net
Cc:        freebsd-questions@FreeBSD.ORG
Subject:   Re: **URGENT** Upgrading 2.2.5-R problem,somebody help me,please.
Message-ID:  <19971025181732.45229@lemis.com>
In-Reply-To: <3451A9EA.9F4544CE@ms11.hinet.net>; from Doug Lo on Sat, Oct 25, 1997 at 04:12:26PM %2B0800
References:  <3451A9EA.9F4544CE@ms11.hinet.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Oct 25, 1997 at 04:12:26PM +0800, Doug Lo wrote:
> Hi, FreeBSD gurus,
>
> Today I upgrade 2.2.5-Release from 2.2.2-Release on my machine.
> The following procedures that I upgrade it:
> 1. Make and boot floppy disk.
> 2. Backup /etc directory.
> 3. Boot from floppy disk and select 'upgrade' option.
> 4. Mount my original filesystems and NOT newfs them.
> 5. Select distributions(just /BIN)
> 6. It copies lastest /etc directory all files to /etc/upgrade directory.
>
> 7. Exit install menu and reboot.
>
> When I reboot, the problem is I CAN'T use 'root' or any user from login,
> seems these
> passwords not right, and it appears login failed.
> I try to boot 'single user mode', I check my original /etc directory
> files are the same,
> because the the lastest file move to /etc/upgrade directory.
> So why I can't use 'root' or any user accounts that I've created.
> Would anyone know how to solve this "serious issue"(for me), PLEASE
> tell me.

It would involve a bit of messing around.  Obviously something has
changed.  I'd recommend:

1.  Make doubly sure you have your backup of /etc.
2.  Boot in single user mode and run vipw.  To do this, you will first
    need to remount /, mount /usr, and set your TERM to cons25.

If that's OK, you should then be able to continue into multiuser mode.

I'm attaching an extract from "The Complete FreeBSD" telling you more
about how to do step 2.

Greg

Single user mode
Sometimes it's inconvenient that multiple users can  access  the  system.   For
example,  if  you're repartitioning a disk, you don't want other people walking
all over the disk while you're doing so.  Even if you're the only user  on  the
system,  daemons may be doing things in the background.  In order to avoid this
problem, you can stop the boot process before most of  the  daemons  have  been
started  and  enter  single user mode.  To do this, specify the -s flag at boot
time:

Boot: -s

The system startup will be interrupted as soon as the device probes  have  been
completed,  and you will be prompted for a shell.  Always choose sh: some other
shells, notably bash, get confused in single user  mode.  Only  the  root  file
system  will  be  accessible, and it will be mounted read-only.  The reason for
this is that the file system may be damaged and require repair before  you  can
write to it.  If you do need to write to the root file system, you should first
check the consistency of the file system with fsck (see the man  page  on  page
*******).  For example,

npx0 on motherboard
npx0: INT 16 interface        end of the probes (high intensity display)
Enter pathname of shell or RETURN for sh:  hit RETURN
erase ^H, kill ^U, intr ^C
# fsck -y /dev/rwd0a          check the integrity of the root file system
** /dev/rwd0a
** Last Mounted on /
** Root file system
** Phase 1 - Check Blocks and Sizes
** Phase 2 - Check Pathnames
** Phase 3 - Check Connectivity
** Phase 4 - Check Reference Counts
** Phase 5 - Check Cyl groups
1064 files, 8190 used, 6913 free (61 frags, 1713 blocks, 0.4% fragmentation)
# mount -u /             remount root file system read/write
# mount /usr             mount any other file systems you need

To  leave  single  user  mode and enter multi user mode, just  enter CTRL-D:

# ^D
Skipping file system checks...
(the rest of the boot sequence)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19971025181732.45229>