SF6800 boot problem, / is read-only

SF6800 boot problem, / is read-only

Post by Equis U » Sat, 13 Sep 2003 01:40:21



Hello,

I'm looking for some trouble shooting tips.

I've encountered a Solaris box which is in a strange state.

The box is a SF6800:
http://www.sun.com/servers/midrange/sunfire6800/

I gained access to the system controller and I see this:

System Controller 'xsc':

    Type  0  for Platform Shell

    Type  1  for domain A console
    Type  2  for domain B console
    Type  3  for domain C console
    Type  4  for domain D console

    Input: 0
Enter Password:
Platform Shell

xsc:SC> showboards

Slot     Pwr Component Type                 State      Status    
Domain
----     --- --------------                 -----      ------    
------
SSC0     On  System Controller              Main       Passed     -
SSC1     On  System Controller              Spare      -          -
ID0      On  Sun Fire 6800 Centerplane      -          OK         -
PS0      On  A152 Power Supply              -          OK         -
PS1      On  A152 Power Supply              -          OK         -
PS2      On  A152 Power Supply              -          OK         -
PS3      On  A152 Power Supply              -          OK         -
PS4      On  A152 Power Supply              -          OK         -
PS5      On  A152 Power Supply              -          OK         -
FT0      On  Fan Tray                       Low Speed  OK         -
FT1      On  Fan Tray                       Low Speed  OK         -
FT2      On  Fan Tray                       Low Speed  OK         -
FT3      On  Fan Tray                       Low Speed  OK         -
RP0      On  Repeater Board                 -          OK         -
RP1      On  Repeater Board                 -          OK         -
RP2      On  Repeater Board                 -          OK         -
RP3      On  Repeater Board                 -          OK         -
/N0/SB0  On  CPU Board V2                   Active     Passed     A
/N0/SB1  On  CPU Board V2                   Active     Passed     A
/N0/SB2  Off CPU Board V2                   Assigned   Not tested B
/N0/SB3  Off CPU Board V2                   Assigned   Not tested B
/N0/SB4  Off CPU Board V2                   Assigned   Not tested B
/N0/SB5  Off CPU Board V2                   Assigned   Not tested B
/N0/IB6  Off PCI I/O Board                  Assigned   Not tested B
/N0/IB7  Off PCI I/O Board                  Assigned   Not tested B
/N0/IB8  Off PCI I/O Board                  Assigned   Not tested B
/N0/IB9  On  PCI I/O Board                  Active     Passed     A

xsc:SC>
xsc:SC>
xsc:SC>

Next, I connected to the Domain A console:

xsc:SC> console A
Enter Password:
Connected to Domain A

red#
red#
red# touch /xyz
touch: /xyz cannot create

It appears that / is mounted read-only.

I look for clues:

red# df -k
Filesystem            kbytes    used   avail capacity  Mounted on
/ssm@0,0/pci@1f,700000/scsi@2/disk@1,0:a
                     4131866   62189 4028359     2%    /
/dev/dsk/c0t0d0s6    2056211 1034779  959746    52%    /usr
/proc                      0       0       0     0%    /proc
fd                         0       0       0     0%    /dev/fd
mnttab                     0       0       0     0%    /etc/mnttab
/dev/dsk/c0t0d0s3    2056211  110507 1884018     6%    /var
swap                 16059600      16 16059584     1%    /var/run
red#

The device underneath / sure has a long name.

I'd expect something like:
/dev/dsk/c0t0d0s0

I looked at /etc/vfstab:

red# cat /etc/vfstab
#device         device          mount           FS      fsck    mount
 mount
#to mount       to fsck         point           type    pass    at
boot options
#
#/dev/dsk/c1d0s2 /dev/rdsk/c1d0s2 /usr          ufs     1       yes  
 -
fd      -       /dev/fd fd      -       no      -
/proc   -       /proc   proc    -       no      -
/dev/dsk/c0t0d0s1       -       -       swap    -       no      -
/dev/dsk/c0t0d0s0       /dev/rdsk/c0t0d0s0      /       ufs     1    
 no      -
/dev/dsk/c0t0d0s6       /dev/rdsk/c0t0d0s6      /usr    ufs     1    
 no      -
/dev/dsk/c0t0d0s3       /dev/rdsk/c0t0d0s3      /var    ufs     1    
 no      -
/dev/dsk/c0t0d0s4       /dev/rdsk/c0t0d0s4      /export/home    ufs  
 2       yes     -
/dev/dsk/c0t0d0s5       /dev/rdsk/c0t0d0s5      /opt    ufs     2    
 yes     -
swap    -       /tmp    tmpfs   -       yes     -
red#

I'm not sure what to do at this point.

I know enough to ask a couple questions:

1.
How do I get this host to use /dev/dsk/c0t0d0s0
as the / partition?

2.
How do I check the contents of /dev/dsk/c0t0d0s0 to make
sure that it contains appropriate data?

I did what I could to answer question #2:

red#  mount -F ufs /dev/dsk/c0t0d0s0 /mnt
red# cd /mnt
red# touch xyz
red# ls -latr
total 106
drwx------   2 root     root        8192 May 29 18:45 lost+found
drwxr-xr-x   2 root     root         512 May 29 18:47 usr
drwxr-xr-x   2 root     root         512 May 29 18:47 var
drwxr-xr-x   2 root     root         512 May 29 18:47 opt
drwxr-xr-x   3 root     sys          512 May 29 18:47 export
dr-xr-xr-x   2 root     root         512 May 29 18:49 proc
drwxr-xr-x   2 root     sys          512 May 29 18:49 mnt
lrwxrwxrwx   1 root     root           9 May 29 18:49 lib -> ./usr/lib
lrwxrwxrwx   1 root     root           9 May 29 18:49 bin -> ./usr/bin
dr-xr-xr-x   2 root     root         512 May 29 18:56 home
-rw-r--r--   1 root     root           2 May 29 19:25 .rhosts
drwxr-xr-x   4 root     sys          512 May 29 19:30 devices
dr-xr-xr-x   2 root     root         512 May 29 19:34 net
dr-xr-xr-x   2 root     root         512 May 29 19:34 xfn
drwxr-xr-x   2 root     root         512 May 29 19:34 vol
drwxr-xr-x  41 root     sys         1536 May 30 17:12 platform
drwxr-xr-x   9 root     sys          512 May 30 17:13 kernel
drwxr-xr-x   2 root     sys         1024 May 30 19:50 sbin
drwxr-xr-x   2 root     other        512 Jun  3 14:42 cdrom
drwxr-xr-x   2 root     other        512 Jun  3 14:47 test
-rw-r--r--   1 root     other         56 Jun  3 15:51 .profile
drwxr-xr-x   2 root     other        512 Jun  6 14:26 vyant
drwxr-xr-x   2 root     other        512 Jun  6 17:57 vyant2
-rw-------   1 root     other       6641 Jun 15 13:20 .bash_history
drwxrwxrwt   2 root     sys          512 Jun 16 17:47 tmp
drwxr-xr-x  15 root     sys         4096 Jun 16 17:48 dev
-rw-------   1 root     other       3084 Jun 18 13:42 .sh_history
drwxr-xr-x  44 root     sys         3584 Jun 18 13:43 etc
drwxr-xr-x  20 root     root         512 Aug  1 19:46 ..
-rw-r--r--   1 root     other          0 Sep 12 00:25 xyz
drwxr-xr-x  24 root     root         512 Sep 12 00:25 .
red#

red# cd /mnt/etc
red# cat vfstab
#device         device          mount           FS      fsck    mount
 mount
#to mount       to fsck         point           type    pass    at
boot options
#
#/dev/dsk/c1d0s2 /dev/rdsk/c1d0s2 /usr          ufs     1       yes  
 -
fd      -       /dev/fd fd      -       no      -
/proc   -       /proc   proc    -       no      -
/dev/dsk/c0t0d0s1       -       -       swap    -       no      -
/dev/dsk/c0t0d0s0       /dev/rdsk/c0t0d0s0      /       ufs     1    
 no      -
/dev/dsk/c0t0d0s6       /dev/rdsk/c0t0d0s6      /usr    ufs     1    
 no      -
/dev/dsk/c0t0d0s3       /dev/rdsk/c0t0d0s3      /var    ufs     1    
 no      -
/dev/dsk/c0t0d0s4       /dev/rdsk/c0t0d0s4      /export/home    ufs  
 2       yes     -
/dev/dsk/c0t0d0s5       /dev/rdsk/c0t0d0s5      /opt    ufs     2    
 yes     -
swap    -       /tmp    tmpfs   -       yes     -

/dev/dsk/c6t17d8s6      /dev/rdsk/c6t17d8s6     /opt/sybase     ufs  
 2       no      -
#/dev/dsk/c2t1d0s7      /dev/rdsk/c2t1d0s7      /vyant2 ufs     2    
 no      -
/dev/dsk/c9t6d13s0      /dev/rdsk/c9t6d13s0     /vyant  ufs     2    
 no      -
red#

It looks like the data on c0t0d0s0 might be okay.
So that leaves me with question #1:

How do I get this host to use /dev/dsk/c0t0d0s0
as the / partition?

-moi

 
 
 

SF6800 boot problem, / is read-only

Post by Fr3aK3rMa » Sat, 13 Sep 2003 01:40:24


Equis Uno wrote:
> Hello,

> I'm looking for some trouble shooting tips.

> I've encountered a Solaris box which is in a strange state.

> The box is a SF6800:
> http://www.sun.com/servers/midrange/sunfire6800/

> I gained access to the system controller and I see this:

> System Controller 'xsc':

>     Type  0  for Platform Shell

>     Type  1  for domain A console
>     Type  2  for domain B console
>     Type  3  for domain C console
>     Type  4  for domain D console

>     Input: 0
> Enter Password:
> Platform Shell

> xsc:SC> showboards

> Slot     Pwr Component Type                 State      Status    
> Domain
> ----     --- --------------                 -----      ------    
> ------
> SSC0     On  System Controller              Main       Passed     -
> SSC1     On  System Controller              Spare      -          -
> ID0      On  Sun Fire 6800 Centerplane      -          OK         -
> PS0      On  A152 Power Supply              -          OK         -
> PS1      On  A152 Power Supply              -          OK         -
> PS2      On  A152 Power Supply              -          OK         -
> PS3      On  A152 Power Supply              -          OK         -
> PS4      On  A152 Power Supply              -          OK         -
> PS5      On  A152 Power Supply              -          OK         -
> FT0      On  Fan Tray                       Low Speed  OK         -
> FT1      On  Fan Tray                       Low Speed  OK         -
> FT2      On  Fan Tray                       Low Speed  OK         -
> FT3      On  Fan Tray                       Low Speed  OK         -
> RP0      On  Repeater Board                 -          OK         -
> RP1      On  Repeater Board                 -          OK         -
> RP2      On  Repeater Board                 -          OK         -
> RP3      On  Repeater Board                 -          OK         -
> /N0/SB0  On  CPU Board V2                   Active     Passed     A
> /N0/SB1  On  CPU Board V2                   Active     Passed     A
> /N0/SB2  Off CPU Board V2                   Assigned   Not tested B
> /N0/SB3  Off CPU Board V2                   Assigned   Not tested B
> /N0/SB4  Off CPU Board V2                   Assigned   Not tested B
> /N0/SB5  Off CPU Board V2                   Assigned   Not tested B
> /N0/IB6  Off PCI I/O Board                  Assigned   Not tested B
> /N0/IB7  Off PCI I/O Board                  Assigned   Not tested B
> /N0/IB8  Off PCI I/O Board                  Assigned   Not tested B
> /N0/IB9  On  PCI I/O Board                  Active     Passed     A

> xsc:SC>
> xsc:SC>
> xsc:SC>

> Next, I connected to the Domain A console:

> xsc:SC> console A
> Enter Password:
> Connected to Domain A

> red#
> red#
> red# touch /xyz
> touch: /xyz cannot create

> It appears that / is mounted read-only.

> I look for clues:

> red# df -k
> Filesystem            kbytes    used   avail capacity  Mounted on
> /ssm@0,0/pci@1f,700000/scsi@2/disk@1,0:a
>                      4131866   62189 4028359     2%    /
> /dev/dsk/c0t0d0s6    2056211 1034779  959746    52%    /usr
> /proc                      0       0       0     0%    /proc
> fd                         0       0       0     0%    /dev/fd
> mnttab                     0       0       0     0%    /etc/mnttab
> /dev/dsk/c0t0d0s3    2056211  110507 1884018     6%    /var
> swap                 16059600      16 16059584     1%    /var/run
> red#

> The device underneath / sure has a long name.

> I'd expect something like:
> /dev/dsk/c0t0d0s0

> I looked at /etc/vfstab:

> red# cat /etc/vfstab
> #device         device          mount           FS      fsck    mount
>  mount
> #to mount       to fsck         point           type    pass    at
> boot options
> #
> #/dev/dsk/c1d0s2 /dev/rdsk/c1d0s2 /usr          ufs     1       yes  
>  -
> fd      -       /dev/fd fd      -       no      -
> /proc   -       /proc   proc    -       no      -
> /dev/dsk/c0t0d0s1       -       -       swap    -       no      -
> /dev/dsk/c0t0d0s0       /dev/rdsk/c0t0d0s0      /       ufs     1    
>  no      -
> /dev/dsk/c0t0d0s6       /dev/rdsk/c0t0d0s6      /usr    ufs     1    
>  no      -
> /dev/dsk/c0t0d0s3       /dev/rdsk/c0t0d0s3      /var    ufs     1    
>  no      -
> /dev/dsk/c0t0d0s4       /dev/rdsk/c0t0d0s4      /export/home    ufs  
>  2       yes     -
> /dev/dsk/c0t0d0s5       /dev/rdsk/c0t0d0s5      /opt    ufs     2    
>  yes     -
> swap    -       /tmp    tmpfs   -       yes     -
> red#

> I'm not sure what to do at this point.

> I know enough to ask a couple questions:

> 1.
> How do I get this host to use /dev/dsk/c0t0d0s0
> as the / partition?

> 2.
> How do I check the contents of /dev/dsk/c0t0d0s0 to make
> sure that it contains appropriate data?

> I did what I could to answer question #2:

> red#  mount -F ufs /dev/dsk/c0t0d0s0 /mnt
> red# cd /mnt
> red# touch xyz
> red# ls -latr
> total 106
> drwx------   2 root     root        8192 May 29 18:45 lost+found
> drwxr-xr-x   2 root     root         512 May 29 18:47 usr
> drwxr-xr-x   2 root     root         512 May 29 18:47 var
> drwxr-xr-x   2 root     root         512 May 29 18:47 opt
> drwxr-xr-x   3 root     sys          512 May 29 18:47 export
> dr-xr-xr-x   2 root     root         512 May 29 18:49 proc
> drwxr-xr-x   2 root     sys          512 May 29 18:49 mnt
> lrwxrwxrwx   1 root     root           9 May 29 18:49 lib -> ./usr/lib
> lrwxrwxrwx   1 root     root           9 May 29 18:49 bin -> ./usr/bin
> dr-xr-xr-x   2 root     root         512 May 29 18:56 home
> -rw-r--r--   1 root     root           2 May 29 19:25 .rhosts
> drwxr-xr-x   4 root     sys          512 May 29 19:30 devices
> dr-xr-xr-x   2 root     root         512 May 29 19:34 net
> dr-xr-xr-x   2 root     root         512 May 29 19:34 xfn
> drwxr-xr-x   2 root     root         512 May 29 19:34 vol
> drwxr-xr-x  41 root     sys         1536 May 30 17:12 platform
> drwxr-xr-x   9 root     sys          512 May 30 17:13 kernel
> drwxr-xr-x   2 root     sys         1024 May 30 19:50 sbin
> drwxr-xr-x   2 root     other        512 Jun  3 14:42 cdrom
> drwxr-xr-x   2 root     other        512 Jun  3 14:47 test
> -rw-r--r--   1 root     other         56 Jun  3 15:51 .profile
> drwxr-xr-x   2 root     other        512 Jun  6 14:26 vyant
> drwxr-xr-x   2 root     other        512 Jun  6 17:57 vyant2
> -rw-------   1 root     other       6641 Jun 15 13:20 .bash_history
> drwxrwxrwt   2 root     sys          512 Jun 16 17:47 tmp
> drwxr-xr-x  15 root     sys         4096 Jun 16 17:48 dev
> -rw-------   1 root     other       3084 Jun 18 13:42 .sh_history
> drwxr-xr-x  44 root     sys         3584 Jun 18 13:43 etc
> drwxr-xr-x  20 root     root         512 Aug  1 19:46 ..
> -rw-r--r--   1 root     other          0 Sep 12 00:25 xyz
> drwxr-xr-x  24 root     root         512 Sep 12 00:25 .
> red#

> red# cd /mnt/etc
> red# cat vfstab
> #device         device          mount           FS      fsck    mount
>  mount
> #to mount       to fsck         point           type    pass    at
> boot options
> #
> #/dev/dsk/c1d0s2 /dev/rdsk/c1d0s2 /usr          ufs     1       yes  
>  -
> fd      -       /dev/fd fd      -       no      -
> /proc   -       /proc   proc    -       no      -
> /dev/dsk/c0t0d0s1       -       -       swap    -       no      -
> /dev/dsk/c0t0d0s0       /dev/rdsk/c0t0d0s0      /       ufs     1    
>  no      -
> /dev/dsk/c0t0d0s6       /dev/rdsk/c0t0d0s6      /usr    ufs     1    
>  no      -
> /dev/dsk/c0t0d0s3       /dev/rdsk/c0t0d0s3      /var    ufs     1    
>  no      -
> /dev/dsk/c0t0d0s4       /dev/rdsk/c0t0d0s4      /export/home    ufs  
>  2       yes     -
> /dev/dsk/c0t0d0s5       /dev/rdsk/c0t0d0s5      /opt    ufs     2    
>  yes     -
> swap    -       /tmp    tmpfs   -       yes     -

> /dev/dsk/c6t17d8s6      /dev/rdsk/c6t17d8s6     /opt/sybase     ufs  
>  2       no      -
> #/dev/dsk/c2t1d0s7      /dev/rdsk/c2t1d0s7      /vyant2 ufs     2    
>  no      -
> /dev/dsk/c9t6d13s0      /dev/rdsk/c9t6d13s0     /vyant  ufs     2    
>  no      -
> red#

> It looks like the data on c0t0d0s0 might be okay.
> So that leaves me with question #1:

> How do I get this host to use /dev/dsk/c0t0d0s0
> as the / partition?

> -moi

Hiya,

Can you try to bring down solaris first and then the domain ?
Get the hardware to do a diag test and try to boot up normally.
If there are any errors then feel free to send me a direct mail tpo
discuss the problems.

Cheers.

 
 
 

SF6800 boot problem, / is read-only

Post by Gavin Maltb » Sat, 13 Sep 2003 08:55:18


Equis Uno wrote:
> Hello,

> I'm looking for some trouble shooting tips.

> I've encountered a Solaris box which is in a strange state.

You make it sounds like this is not a box you administer?
Who does, and what was their last action?

> The box is a SF6800:
> http://www.sun.com/servers/midrange/sunfire6800/

> I gained access to the system controller and I see this:

[cut]

> Next, I connected to the Domain A console:

> xsc:SC> console A
> Enter Password:
> Connected to Domain A

> red#
> red#
> red# touch /xyz
> touch: /xyz cannot create

> It appears that / is mounted read-only.

Yes.  This happens when a machine gets part way into boot and when
things go wrong.  There would have been some messages during the
boot that would tell a little more.  Most likely cause is a
misedit of /etc/vfstab but there are other ways.

> I look for clues:

> red# df -k
> Filesystem            kbytes    used   avail capacity  Mounted on
> /ssm@0,0/pci@1f,700000/scsi@2/disk@1,0:a
>                      4131866   62189 4028359     2%    /
> /dev/dsk/c0t0d0s6    2056211 1034779  959746    52%    /usr
> /proc                      0       0       0     0%    /proc
> fd                         0       0       0     0%    /dev/fd
> mnttab                     0       0       0     0%    /etc/mnttab
> /dev/dsk/c0t0d0s3    2056211  110507 1884018     6%    /var
> swap                 16059600      16 16059584     1%    /var/run
> red#

> The device underneath / sure has a long name.

> I'd expect something like:
> /dev/dsk/c0t0d0s0

Things like /dev/dsk/c0t0d0s0 are logical device names and are just symlinks
into the /devices tree which represents the physical names.  Each
component of /ssm@0,0/pci@1f,700000/scsi@2 identifies
a branch down the device tree and disk@1,0:a identifies a particular
disk and partition at that node.

The boot prom knows only physical device paths.  It reads it's environment
variable 'boot-device' which in your case is set to
/ssm@0,0/pci@1f,700000/scsi@2/disk@1,0:a or some alias of that.
It then read the ufsboot code from that physical device, which
has about enough code in it to mount the physical device
read-only as a ufs filesystem and to start the kernel running.
The initial part of the boot is performed with just this
read-only filesystem mounted;  after a while one of the
/etc/rcS.d scripts remounts read-write using the options
and names in vfstab.  If the remount fails we're unable to
continue and you drop to a prompt like you see with
a read-only / with the physical device name mounted.

A common cause of this is for the logical name in vfstab
(/dev/dsk/c0t0d0s0 for / in the vfstab below) to not link
to the physical path you booted from.  This happens most
often when someone ufsdumps on one root disk and restores
to another proposed root disk without editing vfstab;
you can boot most of the way but the remount fails.

I'd be suspicious that the cause is something along those
lines: check out the bogus (commented out) line
mentioning c1d0s2 (no d? ofr lun).

- Show quoted text -

> I looked at /etc/vfstab:

> red# cat /etc/vfstab
> #device         device          mount           FS      fsck    mount
>  mount
> #to mount       to fsck         point           type    pass    at
> boot options
> #
> #/dev/dsk/c1d0s2 /dev/rdsk/c1d0s2 /usr          ufs     1       yes  
>  -
> fd      -       /dev/fd fd      -       no      -
> /proc   -       /proc   proc    -       no      -
> /dev/dsk/c0t0d0s1       -       -       swap    -       no      -
> /dev/dsk/c0t0d0s0       /dev/rdsk/c0t0d0s0      /       ufs     1    
>  no      -
> /dev/dsk/c0t0d0s6       /dev/rdsk/c0t0d0s6      /usr    ufs     1    
>  no      -
> /dev/dsk/c0t0d0s3       /dev/rdsk/c0t0d0s3      /var    ufs     1    
>  no      -
> /dev/dsk/c0t0d0s4       /dev/rdsk/c0t0d0s4      /export/home    ufs  
>  2       yes     -
> /dev/dsk/c0t0d0s5       /dev/rdsk/c0t0d0s5      /opt    ufs     2    
>  yes     -
> swap    -       /tmp    tmpfs   -       yes     -
> red#

> I'm not sure what to do at this point.

You can 'reboot' with no harm and watch the failure message to
get more clues.  Since / is the only f/s mounted and it's
read-only you can't lose anything.

It's often easiest to boot off the net (single user) or
cdrom and mount your root device and fix it
(mount /devices/ssm@0,0/pci@1f,700000/scsi@2/disk@1,0:a /mnt
will do it).

With a read-only / and a prompt as you have you can also
manually remount read-write and hack around.  I suspect
mount -F ufs -o remount,rw \
        /devices/ssm@0,0/pci@1f,700000/scsi@2/disk@1,0:a /
will do it.  Your /usr may not be mounted so editing
is a bit tricky.  You can work out which f/s should be
usr (or guess) and mount it manually.

> I know enough to ask a couple questions:

> 1.
> How do I get this host to use /dev/dsk/c0t0d0s0
> as the / partition?

Why do you insist that c0t0d0s0 is the root disk?  That may
be common for some workstations, but often is not the
root disk for bigger systems.  For example, the disk you
have actually booted off of is

/ssm@0,0/pci@1f,700000/scsi@2/disk@1,0:a

The bit up to scsi@2 identifies a particular controller, I can't
tell which number on your system.  The disk@1,0:a tells
us it is target 1, lun 0 slice 0 (a) so your root slice
is c?t1d0s0

- Show quoted text -

> 2.
> How do I check the contents of /dev/dsk/c0t0d0s0 to make
> sure that it contains appropriate data?

> I did what I could to answer question #2:

> red#  mount -F ufs /dev/dsk/c0t0d0s0 /mnt
> red# cd /mnt
> red# touch xyz
> red# ls -latr
> total 106
> drwx------   2 root     root        8192 May 29 18:45 lost+found
> drwxr-xr-x   2 root     root         512 May 29 18:47 usr
> drwxr-xr-x   2 root     root         512 May 29 18:47 var
> drwxr-xr-x   2 root     root         512 May 29 18:47 opt
> drwxr-xr-x   3 root     sys          512 May 29 18:47 export
> dr-xr-xr-x   2 root     root         512 May 29 18:49 proc
> drwxr-xr-x   2 root     sys          512 May 29 18:49 mnt
> lrwxrwxrwx   1 root     root           9 May 29 18:49 lib -> ./usr/lib
> lrwxrwxrwx   1 root     root           9 May 29 18:49 bin -> ./usr/bin
> dr-xr-xr-x   2 root     root         512 May 29 18:56 home
> -rw-r--r--   1 root     root           2 May 29 19:25 .rhosts
> drwxr-xr-x   4 root     sys          512 May 29 19:30 devices
> dr-xr-xr-x   2 root     root         512 May 29 19:34 net
> dr-xr-xr-x   2 root     root         512 May 29 19:34 xfn
> drwxr-xr-x   2 root     root         512 May 29 19:34 vol
> drwxr-xr-x  41 root     sys         1536 May 30 17:12 platform
> drwxr-xr-x   9 root     sys          512 May 30 17:13 kernel
> drwxr-xr-x   2 root     sys         1024 May 30 19:50 sbin
> drwxr-xr-x   2 root     other        512 Jun  3 14:42 cdrom
> drwxr-xr-x   2 root     other        512 Jun  3 14:47 test
> -rw-r--r--   1 root     other         56 Jun  3 15:51 .profile
> drwxr-xr-x   2 root     other        512 Jun  6 14:26 vyant
> drwxr-xr-x   2 root     other        512 Jun  6 17:57 vyant2
> -rw-------   1 root     other       6641 Jun 15 13:20 .bash_history
> drwxrwxrwt   2 root     sys          512 Jun 16 17:47 tmp
> drwxr-xr-x  15 root     sys         4096 Jun 16 17:48 dev
> -rw-------   1 root     other       3084 Jun 18 13:42 .sh_history
> drwxr-xr-x  44 root     sys         3584 Jun 18 13:43 etc
> drwxr-xr-x  20 root     root         512 Aug  1 19:46 ..
> -rw-r--r--   1 root     other          0 Sep 12 00:25 xyz
> drwxr-xr-x  24 root     root         512 Sep 12 00:25 .
> red#

That looks like a root filesystem, but isn't the one you booted
off of (boot-device in obp).  Perhaps somebody has copied one
to another and failed to edit vfstab?  Check it's timestamps.

Happy hacking

Gavin

- Show quoted text -

> red# cd /mnt/etc
> red# cat vfstab
> #device         device          mount           FS      fsck    mount
>  mount
> #to mount       to fsck         point           type    pass    at
> boot options
> #
> #/dev/dsk/c1d0s2 /dev/rdsk/c1d0s2 /usr          ufs     1       yes  
>  -
> fd      -       /dev/fd fd      -       no      -
> /proc   -       /proc   proc    -       no      -
> /dev/dsk/c0t0d0s1       -       -       swap    -       no      -
> /dev/dsk/c0t0d0s0       /dev/rdsk/c0t0d0s0      /       ufs     1    
>  no      -
> /dev/dsk/c0t0d0s6       /dev/rdsk/c0t0d0s6      /usr    ufs     1    
>  no      -
> /dev/dsk/c0t0d0s3       /dev/rdsk/c0t0d0s3      /var    ufs     1    
>  no      -
> /dev/dsk/c0t0d0s4       /dev/rdsk/c0t0d0s4      /export/home    ufs  
>  2       yes     -
> /dev/dsk/c0t0d0s5       /dev/rdsk/c0t0d0s5      /opt    ufs     2    
>  yes     -
> swap    -       /tmp    tmpfs   -       yes     -

> /dev/dsk/c6t17d8s6      /dev/rdsk/c6t17d8s6     /opt/sybase     ufs  
>  2       no      -
> #/dev/dsk/c2t1d0s7      /dev/rdsk/c2t1d0s7      /vyant2 ufs     2    
>  no      -
> /dev/dsk/c9t6d13s0      /dev/rdsk/c9t6d13s0     /vyant  ufs     2    
>  no      -
> red#

> It looks like the data on c0t0d0s0 might be okay.
> So that leaves me with question #1:

> How do I get this host to use /dev/dsk/c0t0d0s0
> as the / partition?

> -moi

 
 
 

1. Reading a directory and knowing which type of file am I reading

        I'm developing a program that reads a directory (using dirent.h
functions) and if a file is a directory it displays a messagebefore the name
of the directory.

        Whoever it doesn't seems to work properly, i don't know what I 'm
doing wrong. The program lists the content of the directory but it doesn't
seem to work properly.

        This is a snippet of my program:
#include <errno.h>
#include <dirent.h>
#include <stdio.h>

int main(void){
        DIR *dir;
        struct dirent *ent;
        if (!(dir=opendir("."))) {
                perror("opendir");
                return 1;
        }

        errno=0;
        while ((ent = readdir(dir))) {
                if (ent->d_type == DT_DIR)
                        printf("DIRECTORY\t%s\n",ent->d_name);
                else
                        printf("%s\t\t%d\n",ent->d_name,ent->d_type);
                errno =0;
        }
        if (errno) {
                perror("readdir");
                return 1;
        }
        closedir(dir);
        return 0;

                Any idea is welcome

                                    Andres Tarallo

pD: I'm working under SuSE 6.3 english version

2. sis 6326 driver for redhat 7.3

3. I've read/am reading the faq's - but what is a Segmentation fault?

4. Compiling Problem

5. Problem: Mounting / read-only when booting

6. dual boot/replacing Corel

7. Boot disk problems: Am I a moron, or is my system not supported?

8. X install problem

9. Kernel Booting Problems: I am a newbie

10. SF6800 configuration queries

11. Is E6900 == SF6900? Application(SF6800) -->Application(SF6900) ??

12. cfgadm -c disconnect (Internal error) on SF6800...

13. read-only file permissions when booting