Total Pageviews

Friday, 19 December 2014

Issue faced while unzipping 10_Recommended.zip !!!

This month, I just want to post some small small issues I faced, so that it will be bit helpful for those who face them...

Recently small Issue faced while performing KJP Activiity, it was regarding unzipping the patch cluster. I have to upgrade my solaris V490 server to latest patch, then I faced this.

I copied my patch cluster zip file to /var/tmp directory of my server.
Then straight away i tried to unzip it as follows :

root@mytest1 # cd /var/tmp
root@mytest1 #
root@mytest1 # ls -lrth
total 4847856
-rw-r--r--   1 root     root        2.3G Dec 18 03:03 10_Recommended.zip
root@mytest1 #
root@mytest1 #
root@mytest1 # unzip 10_Recommended.zip
Archive:  10_Recommended.zip
  End-of-central-directory signature not found.  Either this file is not
  a zipfile, or it constitutes one disk of a multi-part archive.  In the
  latter case the central directory and zipfile comment will be found on
  the last disk(s) of this archive.
unzip:  cannot find zipfile directory in one of 10_Recommended.zip or
        10_Recommended.zip.zip, and cannot find 10_Recommended.zip.ZIP, period.
root@mytest1 #

Then I googled and tried in many ways. Finally I got "jar" command.

By using jar we can unzip any zip file....

root@mytest1 #             Takes longtime like unzip only, but I felt jar is bit faster than unzip.
root@mytest1 # jar -xf 10_Recommended.zip

root@mytest1 #
root@mytest1 #
root@mytest1 # cd /var/tmp
root@mytest1 #
root@mytest1 # ls -lrth
total 4847858
-rw-r--r--   1 root     root        2.3G Dec 18 03:03 10_Recommended.zip
drwxr-xr-x   3 root     root         512 Dec 18 03:15 10_Recommended
root@mytest1 #
root@mytest1 # cd 10_Recommended
root@mytest1 #
root@mytest1 # ls -lrth
total 670
-rw-r--r--   1 root     root          15 Dec 18 03:04 installcluster
-rw-r--r--   1 root     root         18K Dec 18 03:04 LEGAL_LICENSE.TXT
-rw-r--r--   1 root     root        7.4K Dec 18 03:04 Copyright
-rw-r--r--   1 root     root        107K Dec 18 03:04 10_Recommended.html
-rw-r--r--   1 root     root        4.8K Dec 18 03:04 patchset.conf
drwxr-xr-x 377 root     root        8.0K Dec 18 03:15 patches
-rw-r--r--   1 root     root        100K Dec 18 03:15 installpatchset
-rw-r--r--   1 root     root        3.7K Dec 18 03:15 patch_order
-rw-r--r--   1 root     root         57K Dec 18 03:15 10_Recommended.README
root@mytest1 #
root@mytest1 #

Then I took my console login and started activity,

RSC version 2.2.3 (D4XTESTDV)
Please login: admin
Please Enter password:
rsc> console
mytest1 console login: root
Password:
Last login: Thu Dec 18 02:53:34 from 10.66.37.14
Dec 18 03:18:17 mytest1 login: ROOT LOGIN /dev/console
Sun Microsystems Inc.   SunOS 5.10      Generic January 2005
root@mytest1 # 
root@mytest1 # df -kh
Filesystem             size   used  avail capacity  Mounted on
/dev/dsk/c1t0d0s0       30G   3.5G    26G    12%    /
/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                    47G   568K    47G     1%    /etc/svc/volatile
objfs                    0K     0K     0K     0%    /system/object
/platform/sun4u-us3/lib/libc_psr/libc_psr_hwcap2.so.1
                        30G   3.5G    26G    12%    /platform/sun4u-us3/lib/libc_psr.so.1
/platform/sun4u-us3/lib/sparcv9/libc_psr/libc_psr_hwcap2.so.1
                        30G   3.5G    26G    12%    /platform/sun4u-us3/lib/sparcv9/libc_psr.so.1
fd                       0K     0K     0K     0%    /dev/fd
swap                    47G    32K    47G     1%    /tmp
swap                    47G    40K    47G     1%    /var/run
root@mytest1 #
root@mytest1 # uname -a
SunOS mytest1 5.10 Generic_118833-33 sun4u sparc SUNW,Sun-Fire-V490

Above is my older kernel version...

root@mytest1 #
root@mytest1 # cd /var/tmp
root@mytest1 #
root@mytest1 # ls -lrth
total 4847858
-rw-r--r--   1 root     root        2.3G Dec 18 03:03 10_Recommended.zip
drwxr-xr-x   3 root     root         512 Dec 18 03:15 10_Recommended
root@mytest1 #
root@mytest1 # cd 10_Recommended
root@mytest1 #
root@mytest1 # ls -lrth
total 670
-rw-r--r--   1 root     root          15 Dec 18 03:04 installcluster
-rw-r--r--   1 root     root         18K Dec 18 03:04 LEGAL_LICENSE.TXT
-rw-r--r--   1 root     root        7.4K Dec 18 03:04 Copyright
-rw-r--r--   1 root     root        107K Dec 18 03:04 10_Recommended.html
-rw-r--r--   1 root     root        4.8K Dec 18 03:04 patchset.conf
drwxr-xr-x 377 root     root        8.0K Dec 18 03:15 patches
-rw-r--r--   1 root     root        100K Dec 18 03:15 installpatchset
-rw-r--r--   1 root     root        3.7K Dec 18 03:15 patch_order
-rw-r--r--   1 root     root         57K Dec 18 03:15 10_Recommended.README
root@mytest1 #
root@mytest1 #
root@mytest1 # ./installpatchset --s10patchset
./installpatchset: cannot execute
root@mytest1 #

I checked and provided permissions for " installpatchset "

root@mytest1 # pwd
/var/tmp/10_Recommended
root@mytest1 #
root@mytest1 # ls -lrth
total 670
-rw-r--r--   1 root     root          15 Dec 18 03:04 installcluster
-rw-r--r--   1 root     root         18K Dec 18 03:04 LEGAL_LICENSE.TXT
-rw-r--r--   1 root     root        7.4K Dec 18 03:04 Copyright
-rw-r--r--   1 root     root        107K Dec 18 03:04 10_Recommended.html
-rw-r--r--   1 root     root        4.8K Dec 18 03:04 patchset.conf
drwxr-xr-x 377 root     root        8.0K Dec 18 03:15 patches
-rw-r--r--   1 root     root        100K Dec 18 03:15 installpatchset
-rw-r--r--   1 root     root        3.7K Dec 18 03:15 patch_order
-rw-r--r--   1 root     root         57K Dec 18 03:15 10_Recommended.README
root@mytest1 #
root@mytest1 # chmod 755 installpatchset        --- Now let's try again....
root@mytest1 #
root@mytest1 # ./installpatchset --s10patchset
Setup .....

Recommended OS Patchset Solaris 10 SPARC (2014.05.08)
Patch 118833-36 will be applied shortly. Installation of the patch set will
halt after this patch is applied, and it will be necessary to reboot before
installation of the patch set can continue.
Application of patches started : 2014.12.18 03:22:12
Applying 120900-04 (  1 of 375) ... skipped
Applying 121133-02 (  2 of 375) ... skipped
Applying 119254-89 (  3 of 375) ... failed
Application of patches finished : 2014.12.18 03:22:16

Following patches were skipped :
 Patches already applied
 120900-04     121133-02
Following patch failed to apply :
 119254-89
Aborting due to failure while applying patch 119254-89.
Application of this patch should have succeeded - this failure is unexpected.
Please assess cause of failure and verify system integrity before proceeding.
Install log files written :
  /var/sadm/install_data/s10s_rec_patchset_short_2014.12.18_03.22.12.log
  /var/sadm/install_data/s10s_rec_patchset_verbose_2014.12.18_03.22.12.log
  /var/sadm/install_data/s10s_rec_patchset_failed_2014.12.18_03.22.12.log
root@mytest1 #
root@mytest1 # pwd
/var/tmp/10_Recommended
root@mytest1 # 
root@mytest1 # ls -lrth
total 670
-rw-r--r--   1 root     root          15 Dec 18 03:04 installcluster
-rw-r--r--   1 root     root         18K Dec 18 03:04 LEGAL_LICENSE.TXT
-rw-r--r--   1 root     root        7.4K Dec 18 03:04 Copyright
-rw-r--r--   1 root     root        107K Dec 18 03:04 10_Recommended.html
-rw-r--r--   1 root     root        4.8K Dec 18 03:04 patchset.conf
drwxr-xr-x 377 root     root        8.0K Dec 18 03:15 patches
-rw-r--r--   1 root     root        100K Dec 18 03:15 installpatchset
-rw-r--r--   1 root     root        3.7K Dec 18 03:15 patch_order
-rw-r--r--   1 root     root         57K Dec 18 03:15 10_Recommended.README
root@mytest1 # 
root@mytest1 # cd patches
root@mytest1 #
root@mytest1 # ls -lrth | more
total 800
drwxr-xr-x   4 root     root         512 Dec 18 03:04 120812-32
drwxr-xr-x   5 root     root         512 Dec 18 03:04 119282-01
drwxr-xr-x   7 root     root         512 Dec 18 03:04 118712-23
drwxr-xr-x   3 root     root         512 Dec 18 03:04 119317-01
drwxr-xr-x   5 root     root         512 Dec 18 03:04 122259-06
drwxr-xr-x   6 root     root         512 Dec 18 03:04 124204-04
drwxr-xr-x   7 root     root         512 Dec 18 03:04 139520-02
drwxr-xr-x   6 root     root         512 Dec 18 03:04 148027-03
drwxr-xr-x   3 root     root         512 Dec 18 03:04 149646-02
drwxr-xr-x   7 root     root         512 Dec 18 03:04 118777-16   OUTPUT TRUNCATED

Then I wanted to install that single patch manually,

root@mytest1 # patchadd 119254-89
Validating patches...
Loading patches installed on the system...
Done!
Loading patches requested to install.
Done!
Checking patches that you specified for installation.
Done!

Approved patches will be installed in this order:
119254-89

ERROR: The /var/tmp/10_Recommended/patches/119254-89/prepatch script contains invalid permissions. Please make the script executable and reinstall 119254-89.
WARNING: Skipping patch
root@mytest1 #

This time I got to know that, this is due to file permissions...So I gave permissions as below,

root@mytest1 #
root@mytest1 # pwd
/var/tmp/10_Recommended
root@mytest1 #
root@mytest1 #  ls -lrth patches/119254-89/postpatch
-rw-r--r--   1 root     root        2.9K Dec 18 03:06 patches/119254-89/postpatch
root@mytest1 #
root@mytest1 #
root@mytest1 # chmod 755 patches/119254-89/postpatch
root@mytest1 #
root@mytest1 # ls -lrth patches/119254-89/prepatch
-rw-r--r--   1 root     root         539 Dec 18 03:06 patches/119254-89/prepatch
root@mytest1 #
root@mytest1 # chmod 755 patches/119254-89/prepatch
root@mytest1 #
root@mytest1 #  ls -lrth patches/119254-89/prepatch
-rwxr-xr-x   1 root     root         539 Dec 18 03:06 patches/119254-89/prepatch
root@mytest1 #
root@mytest1 #
root@mytest1 # pwd
/var/tmp/10_Recommended
root@mytest1 #

Now let's try again,

root@mytest1 # ./installpatchset --s10patchset
Setup ...

Recommended OS Patchset Solaris 10 SPARC (2014.05.08)
Patch 118833-36 will be applied shortly. Installation of the patch set will
halt after this patch is applied, and it will be necessary to reboot before
installation of the patch set can continue.
Application of patches started : 2014.12.18 03:26:36
Applying 120900-04 (  1 of 375) ... skipped
Applying 121133-02 (  2 of 375) ... skipped
Applying 119254-89 (  3 of 375) ... success
Applying 119317-01 (  4 of 375) ... skipped
Applying 121296-01 (  5 of 375) ... skipped
Applying 138215-01 (  6 of 375) ... success
Applying 148336-01 (  7 of 375) ... failed
Application of patches finished : 2014.12.18 03:26:56

Following patches were applied :
 119254-89     138215-01
Following patches were skipped :
 Patches already applied
 120900-04     121133-02     119317-01     121296-01
Following patch failed to apply :
 148336-01
Aborting due to failure while applying patch 148336-01.
Application of this patch should have succeeded - this failure is unexpected.
Please assess cause of failure and verify system integrity before proceeding.
Install log files written :
  /var/sadm/install_data/s10s_rec_patchset_short_2014.12.18_03.26.36.log
  /var/sadm/install_data/s10s_rec_patchset_verbose_2014.12.18_03.26.36.log
  /var/sadm/install_data/s10s_rec_patchset_failed_2014.12.18_03.26.36.log
root@mytest1 #

Ohho again I faced the same, this time I felt like due to "jar" command after unzipping there were no perfect permissions for files, so I wanted to give 755 permission and try.

root@mytest1 #
root@mytest1 # pwd
/var/tmp/10_Recommended
root@mytest1 #
root@mytest1 #
root@mytest1 # cd ../
root@mytest1 #
root@mytest1 # chmod -R 755 10_Recommended
root@mytest1 #
root@mytest1 #
root@mytest1 # cd 10_Recommended
root@mytest1 #
root@mytest1 # ls -lrth
total 670
-rwxr-xr-x   1 root     root          15 Dec 18 03:04 installcluster
-rwxr-xr-x   1 root     root         18K Dec 18 03:04 LEGAL_LICENSE.TXT
-rwxr-xr-x   1 root     root        7.4K Dec 18 03:04 Copyright
-rwxr-xr-x   1 root     root        107K Dec 18 03:04 10_Recommended.html
-rwxr-xr-x   1 root     root        4.8K Dec 18 03:04 patchset.conf
drwxr-xr-x 377 root     root        8.0K Dec 18 03:15 patches
-rwxr-xr-x   1 root     root        100K Dec 18 03:15 installpatchset
-rwxr-xr-x   1 root     root        3.7K Dec 18 03:15 patch_order
-rwxr-xr-x   1 root     root         57K Dec 18 03:15 10_Recommended.README
root@mytest1 #

Hoping that the issue will be resolved....

root@mytest1 #
root@mytest1 # ./installpatchset --s10patchset
Setup ...

Recommended OS Patchset Solaris 10 SPARC (2014.05.08)
Patch 118833-36 will be applied shortly. Installation of the patch set will
halt after this patch is applied, and it will be necessary to reboot before
installation of the patch set can continue.
Application of patches started : 2014.12.18 03:30:37
Applying 120900-04 (  1 of 375) ... skipped
Applying 121133-02 (  2 of 375) ... skipped
Applying 119254-89 (  3 of 375) ... skipped
Applying 119317-01 (  4 of 375) ... skipped
Applying 121296-01 (  5 of 375) ... skipped
Applying 138215-01 (  6 of 375) ... skipped
Applying 148336-01 (  7 of 375) ... success
Applying 146054-07 (  8 of 375) ... success
Applying 142251-02 (  9 of 375) ... success
Applying 125555-15 ( 10 of 375) ... success
Applying 118367-04 ( 11 of 375) ... skipped
Applying 118666-65 ( 12 of 375) ...

Finally I got succeeded and patch was successfully installed...

###############################################################

2 comments: