July 11, 2008 at 3:16 pm
· Filed under Scripts, Soalris X86, Solaris, Solaris 10, Solaris Sparc, Veritas Volume Manager
1. Detach each submirror
ex. metadetach -f d0 d20
d0: submirror d20 is detached
2. Clear each submirror
ex. metaclear d20
d20: Concat/Stripe is cleared
3. Delete the db replica on the failed drive (you can find the replica output by issuing metadb command with no arguments):
ex. metadb -d c0t2d0s7
4. Remove failed drive. Replace with new drive.
5. Run the format command and place the correct partition table, using the layout of the non-replaced drive.
6. re-create the metadb replica on the new disk
ex. metadb -a c0t2d0s7
7. Run metainit for each replaced submirror
ex. metainit d21 1 1 c0t2d0s1
d21: Concat/Stripe is setup
8. Run metattach for each submirror
ex. metattach d0 d20
d0: submirror d20 is attached
ex. metattach d1 d21
d1: submirror d21 is attached
Permalink
July 11, 2008 at 8:12 am
· Filed under Unix
So you just logged into your unix system and you started typing and then oops you typed a wrong letter I mean charater.
root@server# ssfdkjfkjf^?^?^?^?
What are those funky charaters at the end, yup they are me trying to use the back space, but I just end up getting further away from the charaters that I am tryign to delete.
So now for the majick solution.
root@server# stty erase ^?
so the command stty sets options for the terminal session. Then you are telling it what key you want to use to erase with. Which is what the ^? is the erase key being used, so type stty erase space key then back space key then Enter, and you should be back to sanity once again.
Permalink
July 11, 2008 at 8:12 am
· Filed under Soalris X86, Solaris, Solaris Sparc
If you want to set the nic speed and duplex of a Solaris machine you need to basically set up a script that wil be run at start up in one of the run levels preferably /etc/rc2.d/
/etc/rc2.d/S70ndd
1000 full duplex autoneg
#!/sbin/sh
#
PATH=/sbin:/usr/bin:/usr/sbin
echo “Configuring Network Interfaces”
interface=bge0
case “$1″ in
# Example setting Gigabit Ethernet to Auto Negotiate
’start’)
ndd -set /dev/$interface adv_1000fdx_cap 1
ndd -set /dev/$interface adv_1000hdx_cap 0
ndd -set /dev/$interface adv_100fdx_cap 0
ndd -set /dev/$interface adv_100hdx_cap 0
ndd -set /dev/$interface adv_10fdx_cap 0
ndd -set /dev/$interface adv_10hdx_cap 0
ndd -set /dev/$interface adv_autoneg_cap 1
;;
esac
exit 0_cap 0
Permalink