Sunday, November 13, 2016

MAC OS error "no matching host key type found. Their offer: ssh-dss "

edit file /etc/ssh/ssh_config
1. Scroll down until you see this line: 
         #   MACs hmac-md5,hmac-sha1,umac-64@openssh.com,hmac-ripemd160
2.  Delete the pound sign, which will un-comment that line and make it active.

3. Now scroll down to the bottom of the document and add this line:  
        HostkeyAlgorithms ssh-dss

Tuesday, November 8, 2016

Dynamic Link aggregate Alcatel Lucent

lacp linkagg 11 size 2 actor admin key 11
lacp agg 1/15 actor admin key 11
lacp agg 1/16 actor admin key 11

lacp linkagg 12 size 2 actor admin key 12
lacp agg 1/17 actor admin key 12
lacp agg 1/18 actor admin key 12

lacp agg no sw_port
no lacp linkagg link_num

Tuesday, October 18, 2016

VMware ESXi 5.5 host fails to detect local disk after patching or applying Update 1 on HP Proliant Gen 9 servers

SSH to esxi-server.domain.local



esxcli software vib update -n esx-base -d  /vmfs/volumes/550a56a5-7d0cb318-161c-90b11c44d433/Patch/ESXi550-201609001.zip
esxcli software vib update -n tools-light -d /vmfs/volumes/550a56a5-7d0cb318-161c-90b11c44d433/Patch/ESXi550-201609001.zip
esxcli software vib update -n misc-drivers -d /vmfs/volumes/550a56a5-7d0cb318-161c-90b11c44d433/Patch/ESXi550-201609001.zip
esxcli software vib update -n scsi-bnx2i -d /vmfs/volumes/550a56a5-7d0cb318-161c-90b11c44d433/Patch/ESXi550-201609001.zip
esxcli software vib update -n sata-ahci -d /vmfs/volumes/550a56a5-7d0cb318-161c-90b11c44d433/Patch/ESXi550-201609001.zip
esxcli software vib update -n lsu-lsi-lsi-mr3-plugin -d /vmfs/volumes/550a56a5-7d0cb318-161c-90b11c44d433/Patch/ESXi550-201609001.zip
esxcli software vib update -n lsu-lsi-megaraid-sas-plugin -d /vmfs/volumes/550a56a5-7d0cb318-161c-90b11c44d433/Patch/ESXi550-201609001.zip

Wednesday, September 28, 2016

Basic Shell Script for Oracle RMAN backup


#Oracle RMAN backup by Surapong Naowasate
#!/bin/bash
cd
. .bash_profile
export BACKUPPATH="/Path_to_Store_RMAN_BACKUPSET"

for i in DB1 DB2....DBn
do
export DATAFILE="BACKUP_${i}_DATA_$(date '+%Y%m%d')"
echo $DATAFILE
export ARCHIVEDLOG="BACKUP_${i}_ARC_$(date '+%Y%m%d')"
echo $ARCHIVEDLOG
export CONTROLFILE="BACKUP_${i}_CTL_$(date '+%Y%m%d')"
echo $CONTROLFILE
export RMAN_LOG_FILE="BACKUP_${i}_$(date '+%Y%m%d').out"
echo $RMAN_LOG_FILE
echo Backup_data_file_path=$BACKUPPATH

export ORACLE_SID=$i

#EXPORT pfile
sqlplus '/ as sysdba' << EOF
CREATE pfile='${BACKUPPATH}/${i}/pfile-$i-$(date '+%Y%m%d').ora' from spfile;
EXIT;
EOF

#RMAN REPORT DATABASE INFORMATION
rman target / msglog ${BACKUPPATH}/${i}/DATABASE_${i}_info.txt <<EOF
run
{
REPORT SCHEMA;
}
EXIT;
EOF
#<<'test'
#RMAN BACKUPSET FOR Migration
rman target / msglog ${BACKUPPATH}/log/$RMAN_LOG_FILE <<EOF
run
{
ALLOCATE CHANNEL ch00 TYPE DISK;
ALLOCATE CHANNEL ch01 TYPE DISK;
ALLOCATE CHANNEL ch02 TYPE DISK;
ALLOCATE CHANNEL ch03 TYPE DISK;

BACKUP
TAG "${DATAFILE}"
FORMAT '${BACKUPPATH}/${i}/DATA_${i}_%s_%p_%t'
DATABASE;
sql 'alter system archive log current';
RELEASE CHANNEL ch00;
RELEASE CHANNEL ch01;
RELEASE CHANNEL ch02;
RELEASE CHANNEL ch03;

ALLOCATE CHANNEL ch00 TYPE DISK;
ALLOCATE CHANNEL ch01 TYPE DISK;

BACKUP
TAG "${ARCHIVEDLOG}"
FORMAT '${BACKUPPATH}/${i}/arc_${i}_%s_%p_%t'
ARCHIVELOG ALL ;
RELEASE CHANNEL ch00;
RELEASE CHANNEL ch01;

ALLOCATE CHANNEL ch00 TYPE DISK;
BACKUP
TAG "${CONTROLFILE}"
FORMAT '${BACKUPPATH}/${i}/cntrl_${i}_%s_%p_%t'
CURRENT CONTROLFILE;
RELEASE CHANNEL ch00;
}
EXIT;
EOF
#test
echo $i
done

Wednesday, August 3, 2016

Manual FIX IP and Change Hostname on Solaris 11

1. Switch From Automatic Network Configuration Mode to Manual Network Configuration Mode
   
# netadm enable -p ncp DefaultFixed

2. Verify that DefaultFixed profile is applied
   
# netadm list
netadm: DefaultFixed NCP is enabled;
automatic network management is not available.
'netadm list' is only supported when automatic network management is active.

3. Determine the interface that you want to configure
   
# dladm show-phys

4. Configure the vmxnet3s0 interface
   
# ipadm create-ip net0
# ipadm create-addr -T static -a 192.168.1.10/24 vmxnet3s0/v4

5. Verify
   
# ipadm show-addr
ADDROBJ           TYPE     STATE        ADDR
lo0/v4            static   ok           127.0.0.1/8
vmxnet3s0/v4      static   ok           192.168.1.10/24
lo0/v6            static   ok           ::1/128
   
root@solaris:~# dladm show-link
LINK                CLASS     MTU    STATE    OVER
net0                phys      1500   up       --

6. Add default route
   
# route -p add default 192.168.1.1

7. Add DNS Name Server
   
root@solaris:~# svccfg -s dns/client
svc:/network/dns/client> setprop config/nameserver = (8.8.8.8 8.8.4.4)
svc:/network/dns/client> listprop config
config                      application
config/value_authorization astring     solaris.smf.value.name-service.dns.client
config/nameserver          net_address 8.8.8.8 8.8.4.4
svc:/network/dns/client> exit

root@solaris:~#
root@solaris:~# svcadm refresh dns/client
root@solaris:~# svcadm restart dns/client

8. Set name service switch
   
root@solaris:~# svccfg -s name-service/switch
svc:/system/name-service/switch> setprop config/host = "files dns"
svc:/system/name-service/switch> listprop config
config                      application
config/default             astring     files
config/value_authorization astring     solaris.smf.value.name-service.switch
config/printer             astring     "user files"
config/host                astring     "files dns"
svc:/system/name-service/switch> exit

9. Testing
   
root@solaris:~# ping google.com
google.com is alive

10. Change Hostname
root@solaris:~# svccfg <
select /system/identity:node
#listprop config
setprop config/nodename="newhost"
setprop config/loopback="newhost"
refresh

Monday, August 1, 2016

Clear iSCSI Configuration VSphere ESXi 6.0

- Winscp to the host using SFTP -> navigate to /etc/vmware/vmkiscsid/ and copy the contents to your workstation
- Once copied, delete the contents in /etc/vmware/vmkiscsid/
- Reboot the host
- Create a new software iscsi adapter - > write over the IQN with the old one we copied earlier
- Add iscsi port bindings and targets.

Tuesday, July 19, 2016

ALCATEL 6900

write memory copy running certified reload from working no rollback-timeout