How to backup (create image) SunOS 5.10 sparc?

Hello guys! I'm a newbee in Solaris systems.
There is an issue, that I've got:

I have to make an iso image of my solaris system.

How can I do it? with dd utility?

Clonezilla does not support spark, so it cant do backup.

pls help!

Is this solution:
Creating a Solaris Flash Archive - Oracle Solaris 10 9/10 Installation Guide: Solaris Flash Archives (Creation and Installation)
the only one method to create image of system?

tnx in advise.

Is the purpose of this solely for backup? Or is there some other motive?

What type of filesystem(s) do you have? UFS or ZFS? and how many?

Flash archive is surely a portable format which can be used for recovery, even to dis-similar hardware.

Do you have another network node that you could send a backup to?

1 Like

I need to "copy/clone" one server to another "same" server, with the same options

 # cat /etc/vfstab       
#device         device          mount           FS      fsck    mount   mount
#to mount       to fsck         point           type    pass    at boot options
#
fd      -       /dev/fd fd      -       no      -
/proc   -       /proc   proc    -       no      -
/dev/md/dsk/d20       -       -       swap    -       no      -
/dev/md/dsk/d10 /dev/md/rdsk/d10        /       ufs     1       no      -
/dev/md/dsk/d50       /dev/md/rdsk/d50      /var    ufs     1       no      -
/dev/md/dsk/d60       /dev/md/rdsk/d60      /export/home    ufs     2       yes     -
/dev/md/dsk/d40       /dev/md/rdsk/d40      /opt    ufs     2       yes     -
/dev/md/dsk/d70       /dev/md/rdsk/d70      /u01    ufs     1       yes     -
/dev/md/dsk/d80       /dev/md/rdsk/d80      /u02    ufs     1       yes     -

Yes, I do. But I would like to clone it to the external hdd

PS. OS: SunOS 5.10 Generic_150400-38 sun4u sparc SUNW,Sun-Fire-V245

You have mirrored UFS filesystems and you want to clone the system.

How much Solaris experience do you have?

I have recently given extensive advice/assistance to another member wanting to clone a Solaris 9 system and this will equally apply to Solaris 10.

So read these threads first and post any questions you have. How easy this will be for you will depend on your prior knowledge.

In this order:

Park yourself beside a coffee machine and keep reading. Search this forum for your further questions and post back here if you can't find the answers.

2 Likes

Dear hicksd8. Thank u very much for ur efforts to help me! Actually I am a newbee in SunOS.

Even more, I have simple problems with mounting an external hdd to SunOs.

I've connected removeble NTFS 500gb hdd:

 # rmformat -l
Looking for devices...
     1. Volmgt Node: /vol/dev/aliases/rmdisk0
        Logical Node: /dev/rdsk/c1t0d0s2
        Physical Node: /pci@1e,600000/pci@0/pci@1/pci@0/usb@1c,3/storage@1/disk@0,0
        Connected Device: WDC WD50 00AZLX-08K2TA0   0107
        Device Type: Removable

trying to mount it:

mount -F ntfs /dev/dsk/c1t0d0s2 /mnt/usb
mount: Operation not applicable to FSType ntfs

ok, that makes sense...
Trying to format it to UFS:

 # newfs /dev/rdsk/c1t0d0s2
/dev/rdsk/c1t0d0s2: Device busy

hm...ok... trying to clear the old MS cruft:

 # dd if=/dev/zero of=/dev/rdsk/c1t0d0 bs=2048 count=10
10+0 records in
10+0 records out

 # rmformat -F long /dev/rdsk/c1t0d0s2
Formatting will erase all the data on disk.
Do you want to continue? (y/n)y

ok, nice...lets try again:

 # mkfs -F pcfs /dev/rdsk/c1t0d0s2:c
/dev/rdsk/c1t0d0s2: Device busy

 # newfs /dev/rdsk/c1t0d0s2
/dev/rdsk/c1t0d0s2: Device busy
# fdisk /dev/rdsk/c1t0d0
fdisk: /dev/rdsk/c1t0d0 must be a raw device.

 # fdisk /dev/rdsk/c1t0d0s2
fdisk: Cannot open device /dev/rdsk/c1t0d0s2.

 # fdisk -B /dev/rdsk/c1t0d0s2
fdisk: Cannot open device /dev/rdsk/c1t0d0s2.

# fdisk -W - /dev/rdsk/c1t0d0s2
fdisk: Cannot open device /dev/rdsk/c1t0d0s2

fdisk command does not work as well. says, that I need a raw device

ok, wanna to create slices:

# format
Searching for disks...done


AVAILABLE DISK SELECTIONS:
       0. c0t0d0 <SUN72G cyl 14087 alt 2 hd 24 sec 424>
          /pci@1e,600000/pci@0/pci@a/pci@0/pci@8/scsi@1/sd@0,0
       1. c0t1d0 <SUN72G cyl 14087 alt 2 hd 24 sec 424>
          /pci@1e,600000/pci@0/pci@a/pci@0/pci@8/scsi@1/sd@1,0
       2. c0t2d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848>
          /pci@1e,600000/pci@0/pci@a/pci@0/pci@8/scsi@1/sd@2,0
       3. c0t3d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848>
          /pci@1e,600000/pci@0/pci@a/pci@0/pci@8/scsi@1/sd@3,0
Specify disk (enter its number):

it doesnot show my external hdd

plz, help...
I feel so helpless:(

Firstly, I appreciate why you are trying to connect an external HDD but do you realize just how slow it might be? If your (Sun) hardware is USB1 then it will be hopeless!! If it's USB2 it will be better but not fast and I doubt you have USB3 which would be ideal.

Having said that......

Secondly, from what you've posted I reckon that the volume manager is getting in your way and interfering with USB operations. So let's shoot that down because I doubt it's needed for anything else. On Solaris 10 as root that is:

# svcadm disable volfs

You've obviously done some highly relevant research and you have the right idea. Try again with rmformat (to find the device node once you've plugged the USB drive in), fdisk to delete existing/create new partition, and newfs to write down a new filesystem.

Try again to do all that once you've stopped volume manager messing up your life.

EDIT: You may not see the external HDD listed by format . Don't worry about that.

1 Like

it works! tnx u man, u r the best!

 # svcadm disable volfs

 # rmformat 
Looking for devices...
     1. Logical Node: /dev/rdsk/c1t0d0s2
        Physical Node: /pci@1e,600000/pci@0/pci@1/pci@0/usb@1c,3/storage@1/disk@0,0
        Connected Device: WDC WD50 00AZLX-08K2TA0   0107
        Device Type: Removable

 # fdisk /dev/rdsk/c1t0d0
fdisk: Cannot stat device /dev/rdsk/c1t0d0.

# fdisk /dev/rdsk/c1t0d0s2
No fdisk table exists. The default partition for the disk is:

  a 100% "SOLARIS System" partition

Type "y" to accept the default partition,  otherwise type "n" to edit the
 partition table.
y


# newfs /dev/rdsk/c1t0d0s2
newfs: construct a new file system /dev/rdsk/c1t0d0s2: (y/n)? y
Warning: 5056 sector(s) in last cylinder unallocated
/dev/rdsk/c1t0d0s2:     976768064 sectors in 158980 cylinders of 48 tracks, 128 sectors
        476937.5MB in 9937 cyl groups (16 c/g, 48.00MB/g, 5824 i/g)
super-block backups (for fsck -F ufs -o b=#) at:
 32, 98464, 196896, 295328, 393760, 492192, 590624, 689056, 787488, 885920,
Initializing cylinder groups:
...............................................................................
...............................................................................
........................................
super-block backups for last 10 cylinder groups at:
 975864736, 975963168, 976061600, 976160032, 976258464, 976356896, 976455328,
 976553760, 976652192, 976750624
# dd if=/dev/dsk/c0t0d0s2 of=/mnt/usb/image.iso

143349312+0 records in
143349312+0 records out
# df -h
Filesystem                     size   used  avail capacity  Mounted on
/dev/dsk/c1t0d0s2      459G    69G   385G    16%    /mnt/usb

hicksd8, could u recommend me any liveCD, wich supports SPARC cpu, memory?
Google recommended me this product: SystemRescue - System Rescue Homepage_for_Sparc/
tnx in advise

___ upd: sparc 240 does not support external usb cdrom :mad: pls kill me someone)

___upd2. ok, now im doing flar archive of OS. and later will try to recover a new server from the flar archive which will be located on the external hdd drive

 # flarcreate -c -n "icr001"  -R / -x /mnt  /mnt/usb/icr001.flar
Full Flash
Checking integrity...
Integrity OK.
Running precreation scripts...
Precreation scripts done.
Determining the size of the archive...

Why do you think that you need a 'live' DVD?

If you have the installation media for the Solaris 10 version that you are running then you can:

ok> boot cdrom -s

to boot into single user running off the DVD. From there you can mount hard disk filesystems (typically under /a on the DVD) and mount recovery archive tape/disk (typically under /mnt). That way you can manipulate/edit a hard disk root filesystem to make it boot. (Read again those links I posted of previous threads which explains all this.)

Yes, you can use flarcreate (aka flash) to backup, or fssnap & ufsdump for backup.

I don't remember ever connecting an external USB drive to a system booted single user from DVD but I don't see why it wouldn't work.

1 Like

mr. hicksd8, as I said I've created icr001.flar archive.

Now its located on my External USB HDD, NFS and FTP as well.

My actions:
1) ok> boot net - install
2) configuring net, dns, etc...
3) reached the �Solaris Interactive Installation� part, and selected �Flash�.
4) trying to recovery via NFS:

q Flash Archive Addition qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq

  Please specify the path to the network file system where the Flash archive
  is located.  For example:

     NFS Location: syrinx:/export/archive.flar

  ============================================================================

            NFS Location: tjk-netshare:/edb4tel/shuhrat/icr001.flar











  ERROR: Could not find archive
qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq
     F2_Continue    F5_Cancel    F6_Help

Could not find archive

5) trying to recovery via FTP:

q Flash Archive Addition qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq

  Please specify the FTP server, path, username, and password for the Flash
  Archive.  If you are behind a firewall, enter proxy information. For
  example:

             Host: ftp.sun.com
             Path: /path/to/archive.flar
             Username: bob
             Password: ********
             Proxy Host: firewall.eng
             Proxy Port: 8080

  ============================================================================

              FTP Server: tjk-ftp001
            Path to file: /SOFT/icr001.flar
            FTP Username: ftp_icr001
            FTP Password: ********
              Proxy Host:
              Proxy Port: 0
  ERROR: Could not find archive
qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq
     F2_Continue    F5_Cancel    F6_Help

same ERROR: Could not find archive

What else can I do?

ps. there are another methods available:

q Flash Archive Retrieval Method qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq

  On this screen you must select a method to retrieve the Flash archive. The
  retrieval method depends on where the archive is stored.  For example, if
  the archive is stored on a tape, select "Local Tape".

            Available Retrieval Methods
            ========================================
            [X]  HTTP
            [ ]  FTP
            [ ]  NFS
            [ ]  Local File
            [ ]  Local Tape
            [ ]  Local Device








qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq
     F2_Continue    F5_Cancel    F6_Help

Thinking about "Local Device" method: But not sure, how to mount external usb HDD, or where do I need to place/locate my icr001.flar image in the internal/local hdd?

https://docs.oracle.com/cd/E19253-01/817-5504/eyavn/index.html

Obvious questions are:

Does the network interface configure correctly? Is there a DHCP server supplying the parameters needed?

When you try to mount with a nodename "tjk-netshare" is there a method to resolve that address? Or should you substitute tjk-netshare's ip address instead?

Have you properly shared the NFS handle on the node you are trying to reach? (assuming it is on the same subset)

1 Like

Network configured correctly.
To check, that problem not in the 'network', i wrote wrong ip/hostname of FTP and system warned me: " ERROR: Could not connect to host'.
When i wrote right hostname/ip, but wrong ftp password, system warned me: 'Could not authenticate'

When I wrote wrong ip NFS location, system warned me: " ERROR: Could not mount archive"

As I said, I tryed both of them hostname and ip

Yes, they are on the same subset.
I shared properly NFS. I tryed to mount from another server my NFS folder, and it mounted properly:

# df -h |grep tjk-netshare

Filesystem                       size   used  avail   capacity  Mounted on
tjk-netshare:/edb4tel/shuhrat   300G    83G   213G    29%    /mnt/network

___________________________________________________

Exited from the installation menu.

^

# df -h
Filesystem             size   used  avail capacity  Mounted on
/ramdisk-root:a        197M   175M   2.3M    99%    /
/devices                 0K     0K     0K     0%    /devices
ctfs                     0K     0K     0K     0%    /system/contract
proc                     0K     0K     0K     0%    /proc
mnttab                   0K     0K     0K     0%    /etc/mnttab
swap                   3.5G   360K   3.5G     1%    /etc/svc/volatile
objfs                    0K     0K     0K     0%    /system/object
sharefs                  0K     0K     0K     0%    /etc/dfs/sharetab
swap                   3.6G   100M   3.5G     3%    /tmp
/tmp/dev               3.6G   100M   3.5G     3%    /dev
fd                       0K     0K     0K     0%    /dev/fd
172.28.192.160:/mnt/usb
                       2.1G   2.1G     0K   100%    /cdrom
df: cannot statvfs /platform/sun4u-us3/lib/libc_psr.so.1: Operation not applicable
df: cannot statvfs /platform/sun4u-us3/lib/sparcv9/libc_psr.so.1: Operation not applicable
swap                   3.5G    32K   3.5G     1%    /tmp/root/var/run
/usr/sbin/install.d/install_config
                       197M   175M   2.3M    99%    /tmp/_install_config
tjk-netshare:/edb4tel/shuhrat/icr001.flar
                       300G    83G   213G    29%    /tmp/flarAAAILaGkb
tjk-netshare:/edb4tel/shuhrat/icr001.flar
                       300G    83G   213G    29%    /tmp/flarBAAJLaGkb
172.28.192.160:/edb4tel/shuhrat/icr001.flar
                       300G    83G   213G    29%    /tmp/flarCAAKLaGkb

NFS mounted 3 times wtih different directories O_o.

When trying to open:

# cd /tmp/flarCAAKLaGkb
/tmp/flarCAAKLaGkb: not a directory

dismounted all of NFS directories and mounted to /tmp/mnt. Will try to install once again, but from local device

Hmmmm.....

I shared properly NFS. I tryed to mount from another server my NFS folder, and it mounted properly:

but can you also prove that you can access the archive. What access rights are set on the archive? Perhaps, temporarily set to 777? Try copying the archive to the local system (you can interrupt it once it starts to copy). Also check the access rights on the directory above.

This does seem like an access rights (or wrong path/filename given) issue to me; although I could be wrong.

Still thinking about this one.

directory and flar archive has 777 permission.

 # pwd
/edb4tel/shuhrat
 # ls -l
total 53485552
-rwxrwxrwx   1 nobody   nobody   27371219774 Feb 14 16:05 icr001.flar

in which directory shoud i place the archive file? cp is working properly

I wasn't proposing that you copy it to use (locally), only to prove that a remote node is allowed to read it. If you:

# cp <remote node>:<dir>/<dir>/<flashfile> /tmp

does it complain or begin the copy. Obviously, interrupt it if it start to copy.

Another, perhaps silly, question is could the two nodes be running different versions of NFS? What is the remote node OS holding the flash archive?

You could try this just to test.

Boot from CD into single user.

ok> boot cdrom -s

Plumb, configure, and up, the network interface manually. See this thread post#12 where I explain how to do that:

You should then be able to ping the remote host, and then mount the remote NFS handle, and read the archive. That will prove workability.

1 Like

ping is ok, is I said

ping tjk-netshare
tjk-netshare is alive

ping tjk-ftp001
tjk-ftp001 is alive

ping 172.28.192.160
172.28.192.160 is alive

After

ok> boot cdrom -s

when I came to Instalation part:

q Flash Archive Retrieval Method qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq

  On this screen you must select a method to retrieve the Flash archive. The
  retrieval method depends on where the archive is stored.  For example, if
  the archive is stored on a tape, select "Local Tape".

            Available Retrieval Methods
            ========================================
            [X]  HTTP
            [ ]  FTP
            [ ]  NFS
            [ ]  Local File
            [ ]  Local Tape
            [ ]  Local Device








qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq
     F2_Continue    F5_Cancel    F6_Help

I've chosen many times FTP, NFS, Local File methods. All of them gave me 1 error:
ERROR: Could not find archive

Even more, I tryed to mount external Hdd (and nfs) manualy :
closed the installation by pressing F5 and entered to the shell.

mount -F ufs /dev/dsk/c0t0d0s2 /mnt/hdd
cd /mnt/hdd
ls 
icr001.flar

and then went back to the installation by entering

# install-solaris


- Flash Archive Addition -------------------------------------------------------

  Please specify the local file path where the Flash archive is located.  For
  example:

     Path: /export/archive.flar

  ============================================================================

                    Path: /mnt/hdd/icr001.flar                                                











  ERROR: Could not find archive
--------------------------------------------------------------------------------
     F2_Continue    F5_Cancel    F6_Help

Same ERROR: Could not find archive with manual NFS:

mount tjk-netshare:/edb4tel/shuhrat /mnt/net
cd /mnt/net
ls
icr001.flar

I suspect the flar install routine is seeing the archive as 'busy' because it's already mounted. The flar recovery routine will try to mount the NFS disk itself. See this Oracle page:

Recovery Image Procedures - Oracle Solaris 10 1/13 Installation Guide: Flash Archives (Creation and Installation)

Otherwise, perhaps the archive is not as expected. What command did you use to create it?

Ofc, I've tryed this method:
"Solaris Istallation" mounted the NFS disk itself, as i described in the post # 10 of this topic.
But it didnt find the flar archive.

is everything ok with my command? Here it is:

 # flarcreate -c -n "icr001"  -R / -x /mnt  /mnt/usb/icr001.flar
Full Flash
Checking integrity...
Integrity OK.
Running precreation scripts...
Precreation scripts done.
Determining the size of the archive...

Hi 2fat2fly,

I have had a look through this thread and must confess I'm a little confused as to why it's proving so trouble some. I'm pretty sure this is something stupid that's being missed, but I do have to tar myself with the "stupid brush" as for the life of me I can't actually see what the problem is.

I've had a look here but there doesn't seem to be any additional information.

When you are attempting this boot from cdrom and install from a from flar image, I'm assuming that you are having success in selection the appropriate install mechanism through the install menu. So selecting NFS or Local does actually go to the next menu, I have had one occasion in the past where it didn't and we were forced for some unknown reason to install the flar on a web server and install it from there.

Regards

Gull04

2 Likes