I've received lots of help on this. Most everyone's suggestions were
to boot from cdrom. This procedure is in the archive, as some
of you pointed out.
So the problem was resolved by:
boot cdrom -s
mount /dev/dsk/<root partition> /a
vi /a/etc/passwd
halt
ok> boot
Two persons suggested ftp the password file to another machine
(logging in as root ) edit the password file and ftp it back.
I would have preferred this approach, but the problem was already
corrected.
Thanks to the following respondents:
Otto, Doug" <otto@alldata.com>
"Eric D. Pancer" <eric@outlook.net>
Stefan Jon Silverman <sjs@sjsinc.com>
David Evans <DJEVANS@au.oracle.com>
Brion Leary <brion@dia.state.ma.us>
Tim Evans <tkevans@eplrx7.es.dupont.com>
Marina Daniels <Marina.Daniels@cs.tas.gov.au>
"Scott D. Yelich" <scott@scottyelich.com>
Benjamin Kearns <bkearns@ftpoint.com>
sam.vilain@nz.unisys.com
Tim Carlson <tim@santafe.edu>
foster@bial1.ucsd.edu
Matthew Stier <Matthew.Stier@tddny.fujitsu.com>
Michael Cunningham <malice@exit109.com>
Robert Hayne <robert@pegasus.cuug.ab.ca>
Krishna Kumar K <KrishnaKK@microland.co.in>
Umesh Shrikrishna Potbhare <upotbhar@cvimail.cv.com>
Andy De Petter <andy@abcomp.be>
Rodney Wines <Rodney.Wines@ahqps.alcatel.fr>
Olafur Osvaldsson <oli@isnet.is>
Scott Pitsley <Pitsley.Scott@oscsystems.com>
Alan Reichert <aareichert@tommy.dulles.tasc.com>
Peter Polasek <pete@cobra.brass.com>
Rick Niziak <rniziak@kappys.med.iacnet.com>
Greg Polanski <greg_polanski@adc.com>
Jonathan.Loh@BankAmerica.com
=====================================================================
Original question:
My co-worker editted his password file on a Solaris 2.5.1 to change
root's shell from sh to csh. Unfortunately, the editting change was
from /usr/sbin/sh to /usr/sbin/csh. On his system, sh exist on /usr/sbin,
but csh did not. So now, he is unable to log-in as root nor reboot
as single-user ( No shell error ). The OS did not offer a default shell!
What is the procedure to reboot from cdrom in order to correct the
/etc/passwd file. Or, is there a simpler way to gain root access??
This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:13:14 CDT