Tuesday, 24 April 2012

SOLVED: "This disk drive does not have a valid label" .. Revert disk label back to SMI

Whilst installing a new OS of solaris on a machine, I realised I couldn't install the OS over both disks as one of them was used as a zpool primarily, this therefore labels the disk as a EFI (Extensible Firmware Interface) which is used for logical volumes. This caused problems as I wished to mirror the OS over the two disks for redundancy. I found a fix which was to change the label back from EFI to SMI (Sun Microsystems, Inc) which is the default used to boot Solaris. Below illustrates how I solved the problem:


Procedure
Try accessing a command line from exiting out of the solaris installation or booting up your OS (if you are running a solaris installation, you can perform this procedure and simply type "install-solaris" to revert back to the installation. Perform the following commands:


# format -e

AVAILABLE DISK SELECTIONS:
       0. c2t0d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848>
       1. c2t1d0 <HITACHI cyl 14087 alt 2 hd 24 sec 848>
Specify disk (enter its number):

Specify which disk you wish to label (in this case its 1, as you can see its not SUN microsystems labelled). and you will see the below output, run label.



FORMAT MENU:
        disk       - select a disk
        type       - select (define) a disk type
        partition  - select (define) a partition table
        current    - describe the current disk
        format     - format and analyze the disk
        repair     - repair a defective sector
        label      - write label to the disk
        analyze    - surface analysis
        defect     - defect list management
        backup     - search for backup labels
        verify     - read and display labels
        save       - save new disk/partition definitions
        inquiry    - show vendor, product and revision
        scsi       - independent SCSI mode selects
        cache      - enable, disable or query SCSI disk cache
        volname    - set 8-character volume name
        !<cmd>     - execute <cmd>, then return
        quit
format> label


Specify label type as SMI (Sun Microsystems, Inc)

[0] SMI Label
[1] EFI Label
Specify Label type[0]:0
Ready to label disk, continue? y
format> q

Quit out and run format again, you will see something similar like below:

     0. c2t0d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848>
     1. c2t1d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848> 

Done. Now you can carry on with the installation (if you quit the installation and have booted from disk or installation media, run install-solaris to revert back to installation).




No comments:

Post a Comment

Platform Engineering: Developer Experience

Intro The role of Platform Engineer as evolved through the ages. I’ve gone through all the names: Sys Admin, Infrastructure Engineer, DevOps...