Hi Mary,

the changes look good to me.

Thank you,
Jan


On 09/10/11 22:17, Mary Ding wrote:
Hi:

Can I get two people to do code review for me for this bug ??? This will be put back pending Dave's approval.

7089049 <http://monaco.us.oracle.com/detail.jsf?cr=7089049> need to replace md5sum with digest -a sum in order for usbcopy to work.

https://cr.opensolaris.org/action/browse/caiman/md5645/7089049

Dave Miner suggested that I replace md5sum with digest -a sum so that we do no need to declare a pkg dependency on file/gnu-coreutils

I had done the following:

1. I ran slim install unit test and there is no failure

Testing is done this way:

1.  Do a net TI install with snv_173.

2. Then set the publisher and do pkg install install/distribution-constructor

root@tcu27-01:~# pkg publisher
PUBLISHER                             TYPE     STATUS   URI
solaris origin online http://pkg.oracle.com/solaris/release/ root@tcu27-01:~# pkg set-publisher -O http://ipkg.us.oracle.com/solaris11/dev solaris
root@tcu27-01:~# pkg install install/distribution-constructor
           Packages to install:  3
     Variants/Facets to change: 20
       Create boot environment: No
Create backup boot environment: No

DOWNLOAD                                  PKGS       FILES    XFER (MB)
Completed                                  3/3       65/65      0.2/0.2

PHASE                                        ACTIONS
Install Phase                                127/127

PHASE                                          ITEMS
Package State Update Phase                       3/3
Image State Update Phase                         2/2
root@tcu27-01:~#

3.  Do usbcopy and it fails:

root@tcu27-01:/net/ins3525-svr/export/osol/x# usbcopy `pwd`/sol-11-dev-173-live-x86.usb
Found the following USB devices:
0:      /dev/rdsk/c7t0d0p0      1.9 GB  Kingston DataTraveler G3  1.00
Enter the number of your choice: 0

WARNING: All data on your USB storage will be lost.
Are you sure you want to install to
Kingston DataTraveler G3 1.00, 1900 MB at /dev/rdsk/c7t0d0p0 ?  (y/n) y
Copying and verifying image to USB device
/usr/bin/usbcopy: line 202: md5sum: command not found
Read from image failed.
root@tcu27-01:/net/ins3525-svr/export/osol/x# which usbcopy
/usr/bin/usbcopy
root@tcu27-01:/net/ins3525-svr/export/osol/x#

4.  Now use usbcopy that got my fix and it works:

root@tcu27-01:/net/ins3525-svr/export/osol/x# /usr/bin/usbcopy.fix `pwd`/sol-11-dev-173-live-x86.usb
Found the following USB devices:
0:      /dev/rdsk/c7t0d0p0      1.9 GB  Kingston DataTraveler G3  1.00
Enter the number of your choice: 0

WARNING: All data on your USB storage will be lost.
Are you sure you want to install to
Kingston DataTraveler G3 1.00, 1900 MB at /dev/rdsk/c7t0d0p0 ?  (y/n) y
Copying and verifying image to USB device
Finished 978 MB in 369 seconds (2.6MB/s)
0 block(s) re-written due to verification failure
Installing grub to USB device /dev/rdsk/c7t0d0s0
Completed copy to USB
root@tcu27-01:/net/ins3525-svr/export/osol/x# root@tcu27-01:/net/ins3525-svr/export/osol/x# diff /usr/bin/usbcopy /usr/bin/usbcopy.fix
202c202
<       iseek=$s if=$img 2>/dev/null | md5sum)
---
>       iseek=$s if=$img 2>/dev/null | digest -a md5)
212c212
< devsum=$(dd bs=$bs count=$recs iseek=$s if=$s0cdev 2>/dev/null | md5sum)
---
> devsum=$(dd bs=$bs count=$recs iseek=$s if=$s0cdev 2>/dev/null | digest -a md5)
root@tcu27-01:/net/ins3525-svr/export/osol/x#


I also confirm that the usb stick can boot without any problem.


_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss

Reply via email to