Which is a Comparable Command in Solaris to PC-Reformat; Mac-Initialize

Posted on 2005-05-01
Last Modified: 2013-12-21
Hello!  Everyone!

I have been a Long time Sun Unix user for 10 years, but never been an administrator, and now I am becoming an Administrator, finally.   I just started using Sun Ultra5 at home.   And needless to say, I have a lot of trials and errors of Operating System Installation.   I may need to ask several questions, but let me get started one at a time.

When I loaded something in messed-up configuration, and I wanted to start from clean installation (I mean, I want to load to empty hard disk), I usually do Fdisk/Formatting for PC;  Disk_Utilities Initialization for Macintosh.   Which command is the same function in Sun Solaris OS installation.  

This is my first priority, because I am keep messing-up, so I have to keep cleaning up.   Thank you for your help.
Mitsuru Kido (mkido)
Question by:mkido
    LVL 34

    Expert Comment

    Simply boot from the Solaris installation CD. Partitioning the disk and installing an appropriate boot-block will be performed as part of the installation process.
    LVL 20

    Accepted Solution

    The "format" command under Solaris is equivalent to Windows Fdisk; Once you have created partitions, you "newfs" them (equivalent to Windows format) to prepare them for use. (Apart from swap partitions, which don't need formatting)

    PsiCop has told you the simplest way to do this; Once the OS is installed, you can add new partitions on the free space on your disk.

    You may want to consider creating a data partition at the "end" of the disk, that won't get trashed if you reinstall the OS; Just remember to make a note of the start and end points of the data partition.
    LVL 38

    Assisted Solution

    Simply use Solaris Software CD 1 to boot up and perform a fresh installation.

    1. Power on the box and then type in <Stop> A, put the CD into cdrom
    2. type in:
       boot cdrom
    3. Following the screen instructions to preform a fresh installation (you need to fill in
       the network and hostname infor for the installation).

    Author Comment

    Thank you folks.   Let me explain a little bit more about my environment.   My Ultra 5 is placed in my Home Office where I only have Comcast Cable Access.   I doubt whether I have a static Domain Name or Number.   At least I haven't done IP address registration to any Network Registration Administrator of Area's Net.   (If it is easy to do, and it doesn't cost much, I will do so.  I just don't know how to.)   Second, I have three versions of OS Solaris 2.5;  7;  8.   I believe 7 means 2.7 and 8 means 2.8, am I right?   Anyway, 2.5 had a problem of Mouse recognition;  7 had a problem at the middle of installation.   I usually did,
    at OK prompt,

      ok boot cdrom

    and No Network option I chose.
    Up to now, the installation was imcomplete.   So, I wanted to clean up before another trial.   Talk to you later.

    Author Comment

    Hello!  I tried "format" and "newfs" at OK-prompt but they don't work.   Here is my brief report.   After Solaris 2.5.1 doesn't seem to work well at Ultra5, I over-loaded Solaris 7, no-Network, both "Upgrade" way then "Initial" way.    "Upgrade" interruptted, because I couldn't locate the backup location other than upgrading place.   "Initial" way (I tried a few times) mostly went on to all loading (County, Time, Partitions, so on), and went on to All System Loading and Patches Loading.   Then, Re-boot starts.   Here comes my error messages.

    (a lot of undefined symbol at rootnet)  for example
    /platform/sun4u/kernel/drv//sparcv9/rootnet: undefined symbol 'fhc_bd_test'
    WARNING: mod_load: cannot load module 'rootnex'
    WARNING: Cannot load /dev/rootnex
    Can't load the root filesystem
    Type 'go' to resume

    Obviously, it is still OK-prompt, not Root-login prompt.   The System isn't running at normal condition.      What do you think?   What will you try here?   Should I try Solaris 8 rather than 7.   Should I get Solaris 9 before any other thing I will try?   I have whole set of CDs 2.5.1;  7, and 8, so if you point  me to any diagnostic Tool on CDs, I can try.   Thank you.
    LVL 38

    Assisted Solution

    "format" and "newfs" are Solaris commands, NOT OBP command, if you want to use them, you can use a Solaris Software CD to boot up to single user mode:

    put the CD into the cdrom, in ok promt, type in:

    boot cdrom -s

    after your boot up the system, then use the command. (you can also box up the box from
    HD and use the commands.

    Author Comment

    Hello !  PsiCop, tfewster, and yuzh.  
    My major problem is unsuccessful installation of Solaris OS.   I am trying to fix it, but still I couldn't figure yet.   Here is a few my guess.  
    (1)   Without appropritate Cable connection, Solaris 7 doesn't run well ???     OR
    (2)  Does any bad previous installation harm the following OS installation ???    OR
    (3)  Just my installation procedure isn't good enough to get through complete installation.   Recently I almost accepted all default option during installation.

    Anyway, I am finally getting other than OK prompt by
       OK boot cdrom -s      

    Now,  I can see inside of machine, it is much better.   A few question related with Question Title are,
    # format
    -> One time shows the disk   0.  t0s0d0 (alike)
    -> Second time, it said,  
        "Searching for disks ... done.   No disks found!"
        This message doesn't make sense.   There is a hard disk.

    Regarding "newfs", I needed a "raw device name", and what should I say??    "t0s0d0"   OR something else.   Excuse me, many things are still so messy.

    LVL 38

    Assisted Solution

    after you type in "format" command, you should see something like:

           0. c0t0d0 <SUN36G cyl 24620 alt 2 hd 27 sec 107>  boot

      Specify disk (enter its number):
           you need to type in 0 to select the HD
        If you have more than one HD, it will show more HD.  then goes to the FORMAT MENU,
    I suggest you to do "verify" to see how the HD was partioned, and then get out of the
    format menu, use newfs to get rid of the old stuff.

        Please have a look at the following page to learn more about "format":

       man format
       man newfs

        You can download the Solaris installation manuals, adm/Network manuals from:

    Author Comment

    Hello ! yuzh,
    I have a little progess on "format" and "newfs", but "man" commands are not available at root # under single user mode.   Because nothing is there.  
    Usually # format said,
       0.  c0t0d0 <FUJITSU MPG 3204AT ...>
    then, I select number "0".   It said format completed.   Then, I tried,
    # newfs /dev/dsk/c0t0d0s0
    It went, and created 129 MB in 17 cyl group.   But I think this isn't enough.   My hard disk should be 20 Gig bytes.   Well, I am slowly reading the documents you pointed to.   So, just this is a trial feedback.    Bye now.
    LVL 38

    Expert Comment

    You can use format to re-partion the HD, if you change the partion size the data in that
    partion will lost, make sure you back it up it you still need them.

    Have a nice weekend!

    Author Comment

    Hello!   I am almost closing this first question.   I will likely start posting another quetion soon from different angles until I will achive that my system is running well.   Installation of OS isn't easy.   The last question before closing this is,

    What is the differece between,

     /dev/rdsk/c0t0d0       ??

    "format" or "newfs" may need to address the "raw specific device".   I am assuming the above the way to address the raw specific device.   Am I right?   Now, what is the differece between "dsk" and "rdsk", in which the latter has an extra "r" in it?   Are they are totally different disk location?  OR a kind of alias name ?    If anyone know.    Bye now.

    LVL 20

    Assisted Solution

    /dev/dsk/c0t0d0 is the block device and /dev/rdsk/c0t0d0 is the character or raw device; They are different ways of communicating with the same physical disk.  

    Each  slice (partition) will also have its own device files e.g. /dev/dsk/c0t0d0s6 and /dev/rdsk/c0t0d0s6 - newfs needs to be run against the raw device, then when the filesystem has been created on that slice, all input/output (I/O) uses the block device

    Author Comment

    Thank, tfewster and yuzh, talk to you sometime later.  

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Free Trending Threat Insights Every Day

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Suggested Solutions

    When you do backups in the Solaris Operating System, the file system must be inactive. Otherwise, the output may be inconsistent. A file system is inactive when it's unmounted or it's write-locked by the operating system. Although the fssnap utility…
    Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
    Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
    Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

    759 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    8 Experts available now in Live!

    Get 1:1 Help Now