Sunday, January 23, 2011

Solaris 10 x86 on VMWare disk mirror


umount /export/home

bash-3.00# format
Searching for disks...done



AVAILABLE DISK SELECTIONS:
       0. c1t0d0
          /pci@0,0/pci15ad,1976@10/sd@0,0
       1. c1t1d0
          /pci@0,0/pci15ad,1976@10/sd@1,0
Specify disk (enter its number):


select 0
p
p
7
enter
enter
0
0
label
y
p
3
enter
enter
981
40mb
p
7
home
enter
987
$
label
y
name
root
q
disk
1
p
p
select
(select "root")
label
y

comment /export/home in /etc/vfstab
newfs /dev/rdsk/c1t0d0s7
uncomment /export/home
mount -a

metadb -afc 3 c1t0d0s3 c1t1d0s3
metainit -f d10 1 1 c1t0d0s0
metainit -f d20 1 1 c1t0d0s1
metainit -f d70 1 1 c1t0d0s7
#metainit -f d80 1 1 c1t0d0s8
metainit d1 -m d10
metainit d2 -m d20
metainit d7 -m d70
#metainit d8 -m d80

sub-mirror:
metainit -f d11 1 1 c1t1d0s0
metainit -f d21 1 1 c1t1d0s1
metainit -f d71 1 1 c1t1d0s7
#metainit -f d81 1 1 c1t1d0s8

metaroot d1

edit /etc/vfstab
tukar:
1. /dev/dsk/c1t0d0s1 jadi /dev/md/dsk/d2
2. /dev/dsk/c1t0d0s7 jadi /dev/md/dsk/d7 (/dev/md/rdsk...)


reboot

metattach d1 d11
metattach d2 d21
metattach d7 d71
#metattach d8 d81

bash-3.00# metastat
d7: Mirror
Submirror 0: d70
State: Okay
Submirror 1: d71
State: Resyncing
Resync in progress: 0 % done
Pass: 1
Read option: roundrobin (default)
Write option: parallel (default)
Size: 5060475 blocks (2.4 GB)

d70: Submirror of d7
State: Okay
Size: 5060475 blocks (2.4 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t0d0s7 0 No Okay Yes


d71: Submirror of d7
State: Resyncing
Size: 5060475 blocks (2.4 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t1d0s7 0 No Okay Yes


d2: Mirror
Submirror 0: d20
State: Okay
Submirror 1: d21
State: Resyncing
Resync in progress: 4 % done
Pass: 1
Read option: roundrobin (default)
Write option: parallel (default)
Size: 1076355 blocks (525 MB)

d20: Submirror of d2
State: Okay
Size: 1076355 blocks (525 MB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t0d0s1 0 No Okay Yes


d21: Submirror of d2
State: Resyncing
Size: 1076355 blocks (525 MB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t1d0s1 0 No Okay Yes


d1: Mirror
Submirror 0: d10
State: Okay
Submirror 1: d11
State: Resyncing
Resync in progress: 0 % done
Pass: 1
Read option: roundrobin (default)
Write option: parallel (default)
Size: 14667345 blocks (7.0 GB)

d10: Submirror of d1
State: Okay
Size: 14667345 blocks (7.0 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t0d0s0 0 No Okay Yes


d11: Submirror of d1
State: Resyncing
Size: 14667345 blocks (7.0 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t1d0s0 0 No Okay Yes


Device Relocation Information:
Device Reloc Device ID
c1t1d0 Yes id1,sd@f13b360d84d3b15f40006e7540000
c1t0d0 Yes id1,sd@f000000004d3b6fa3000592b50000
bash-3.00#

disk status after mirror sync'ed:
bash-3.00# metastat
d7: Mirror
Submirror 0: d70
State: Okay
Submirror 1: d71
State: Okay
Pass: 1
Read option: roundrobin (default)
Write option: parallel (default)
Size: 5060475 blocks (2.4 GB)

d70: Submirror of d7
State: Okay
Size: 5060475 blocks (2.4 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t0d0s7 0 No Okay Yes


d71: Submirror of d7
State: Okay
Size: 5060475 blocks (2.4 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t1d0s7 0 No Okay Yes


d2: Mirror
Submirror 0: d20
State: Okay
Submirror 1: d21
State: Okay
Pass: 1
Read option: roundrobin (default)
Write option: parallel (default)
Size: 1076355 blocks (525 MB)

d20: Submirror of d2
State: Okay
Size: 1076355 blocks (525 MB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t0d0s1 0 No Okay Yes


d21: Submirror of d2
State: Okay
Size: 1076355 blocks (525 MB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t1d0s1 0 No Okay Yes


d1: Mirror
Submirror 0: d10
State: Okay
Submirror 1: d11
State: Okay
Pass: 1
Read option: roundrobin (default)
Write option: parallel (default)
Size: 14667345 blocks (7.0 GB)

d10: Submirror of d1
State: Okay
Size: 14667345 blocks (7.0 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t0d0s0 0 No Okay Yes


d11: Submirror of d1
State: Okay
Size: 14667345 blocks (7.0 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c1t1d0s0 0 No Okay Yes


Device Relocation Information:
Device Reloc Device ID
c1t1d0 Yes id1,sd@f13b360d84d3b15f40006e7540000
c1t0d0 Yes id1,sd@f000000004d3b6fa3000592b50000
bash-3.00#

read more...

Solaris 10 x86 on VMWare


read more...

Tuesday, January 18, 2011

MacOSX 10.6.4 running on AMD Phenom X2 555

Finally I managed to install 10.6.4 on my AMD Phenom X2 555 system with Asus M4A88T-V EVO/USB3.

The problem that I'm facing right now is to get my onboard AT HD4250 to work, at least to change resolution to 1920x1080. So far I found out that 4250 is NOT supported. Tried installing RadeonHD kext but somehow couldn't get it to work. Will continue to work on this later on.

USB 2.0 seems to work (haven't check whether it's 1.1 or 2.0 - later), USB 3.0 not tested (i don't have USB 3.0 device), Firewire not tested

Anyway, I'm using retail DVD 10.6.4, created USB install disk using nawcom method in Ubuntu, repartition my 2TB to make root disk < 1TB (I learned that OSX cannot boot if root disk is more than 1TB). Install Chameleon RC4 and legacy kernel 10.6.4.

Haven't test my onboard audio after install VoodooHDA kext but I got no sound via HDMI. Next is to fix my GFX, and then to get audio to work via HDMI (if possible, haven't research thoroughly yet)

Final step is to install XBMC and Jdownloader :) That is my sole purpose.

Complete hardware specs:
AMD Phenom X2 555 BE
Asus M4A88T-V EVO/USB3 (onboard ATI HD4250, onboard ALC892 8-channel HD Audio, ..)
Seasonic 520W modular PSU (not related to OSX but what the heck :P )
Silverstone LC17B
750GB Samsung HDD (running Ubuntu 10.10)
2TB WD Green Ed. (running MacOSX 10.6.4 - not yet finished completely)
Connected to LG LCD LD420 via HDMI
Asus USB wireless 54g stick (can't remember the model and haven't configure/test in MacOSX as well)

read more...

MacOSX 10.6.4 ISO/DVD offset

dump everything in DVD to ISO (change /dev/sr0 to your DVD device):
# cat /dev/sr0 > macosx_10.6.4_install.iso

find your offset (it is gonna take quite some time, so be patience):
# hexdump -C macosx_10.6.4_install.iso | grep "48 2b 00 04"
31b4b400 48 2b 00 04 80 00 01 00 31 30 2e 30 00 00 00 00 |H+......10.0....|


convert 31b4b400 to decimal and minus 1024

example:
$ echo `printf "%d\n" 0x31b4b400` - 1024 | bc
833925120

so:
10.6.4 ISO/DVD offset: 833925120

maybe you can try to find your offset if you're using DVD (haven't try this one):
# hexdump -C /dev/sr0 | grep "48 2b 00 04"

then mount your ISO:
# losetup -o 833925120 /dev/loop0 ./mac osx_10.6.4_install.iso
# mkdir /media/osx-dvd
# mount -t hfsplus /dev/loop0 /media/osx-dvd/


to unmount:
# umount /media/osx-dvd
# losetup -d /dev/loop0

you might ask, why "48 2b 00 04" and why minus 1024? refer here: http://www.64lines.com/mounting-hfs-plus
[snip]
Finding an HSF+ Partition

How do you find an HFS+ partition? Well according to docs at http://developer.apple.com/technotes/tn/tn1150.html#VolumeHeader an HFS+ partition starts with 1024 reserved bytes for boot code followed by the VolumeHeader structure. The first 4 bytes of the VolumeHeader structure are a signature and a version number. Essentially "H+" followed by version 4 (or HX followed by 5 for HFSX). Therefore we are looking for the following hexadecimal sequence within the file: "48 2b 00 04" (or "48 58 00 05" for HFSX).

[/snip]

read more...

Thursday, January 13, 2011

Cron (solaris) "bad user" error

cron (solaris) "bad user" error message in /var/log/cron
--------------------------------------------------------

Cron needs to be able to access a shell as the cron user in order to
do its thing. The easiest work-around for this is to edit the
/etc/shadow file and change the *LK* to *NP* for the affected
accounts.

read more...

Tuesday, January 11, 2011

vxrestore / vxdump

# vxdump 0fu /dev/rmt/0m /var ; dump vxfs file system /var to tape /dev/rmt/0m using level 0 and update /var/adm/dumpdates

# vxrestore tf /dev/rmt/0m | grep eaaa ; obtain table of contents from tape /dev/rmt/0m and look for filename containing "eaaa"

# vxrestore -yxf /dev/rmt/0m ; restore the whole content of the tape into current dir, answer 1 and y

# mt -f /dev/rmt/0m rewind ; rewind tape after listing the tape

read more...

Friday, April 2, 2010

New future lies ahead..

Hopefully everything will turns out as planned! Insya Allah

read more...