fs-root revision bc13c17b8e093e9582f8b62b4f13059b70f8d307
2N/A# The contents of this file are subject to the terms of the 2N/A# Common Development and Distribution License (the "License"). 2N/A# You may not use this file except in compliance with the License. 2N/A# See the License for the specific language governing permissions 2N/A# and limitations under the License. 2N/A# When distributing Covered Code, include this CDDL HEADER in each 2N/A# If applicable, add the following below this CDDL HEADER, with the 2N/A# fields enclosed by brackets "[]" replaced with your own identifying 2N/A# information: Portions Copyright [yyyy] [name of copyright owner] 2N/A# Copyright 2006 Sun Microsystems, Inc. All rights reserved. 2N/A# Use is subject to license terms. 2N/A# ident "%Z%%M% %I% %E% SMI" 2N/A# Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T. 2N/A# All rights reserved. 2N/A# Make sure that the libraries essential to this stage of booting can be found. 2N/A # If there is an optimized libc available in /usr that fits this 2N/A # processor, mount it on top of the base libc. # This mount function is sun4v only. It may be melded with the sun4u-us3 # This is specific to sun4u[-us3]. # try to intelligently handle the various ways that a hwcap library can # be present for libc_psr for sun4u. # first look for $PLAT specific # the string $HWCAP is not an env var but part of the argument to moe # try the 'generic' one under $ARCH # Discover architecture and find and mount optimal libc_psr if [ "$ARCH" = "sun4v" ]; then elif [ "$ARCH" = "sun4u" ]; then # Most of the operations in this script are only necessary in the global # zone but due to the way initialization scripts like this are packaged, # it needs to currently exist for all zones. # Root is already mounted (by the kernel), but still needs to be # checked, possibly remounted and entered into mnttab. First # mount /usr read only if it is a separate file system. This must # be done first to allow utilities such as fsck and setmnt to # reside on /usr minimizing the space required by the root file # Mount without the cache initially. We'll enable it # later at remount time. This lets us avoid # teaching the statically linked mount program about # cachefs. Here we determine the backfstype. # This is not pretty, but we have no tools for parsing # the option string until we get /usr mounted... msg=
'invalid vfstab entry for /usr' # Must use -o largefiles here to ensure the # read-only mount does not fail as a result of # having a large file present on /usr. This gives # fsck a chance to fix up the largefiles flag # before we remount /usr read-write. # Requesting logging on a read-only mount # causes errors to be displayed, so remove # "logging" from the list of options for now. # The read-write mount performed later will # specify the logging option if appropriate. # Also mount /boot now so that things like keymap.sh can access # boot properties through eeprom. Readonly isn't required because # /boot (and other pcfs filesystems) aren't fsck'ed at boot yet. # Also, we don't account for caching /boot as it must be on a local # disk. So what's in vfstab is fine as it stands; just look to see # if it's there and avoid the mount if not. # files found on /usr, and device permissions from /etc/minor_perm.