среда, 29 августа 2018 г.

TOSHIBA THNSN8960PCSE SDD Health

smartctl -xa /dev/sda
or
smartctl -l devstat /dev/sda

Device Statistics (GP Log 0x04)
Page  Offset Size        Value Flags Description
0x01  =====  =               =  ===  == General Statistics (rev 2) ==
0x01  0x008  4              26  ---  Lifetime Power-On Resets
0x01  0x018  6      8322929196  ---  Logical Sectors Written
0x01  0x020  6        87479037  ---  Number of Write Commands
0x01  0x028  6     16328289796  ---  Logical Sectors Read
0x01  0x030  6       165688129  ---  Number of Read Commands
0x04  =====  =               =  ===  == General Errors Statistics (rev 1) ==
0x04  0x008  4               0  ---  Number of Reported Uncorrectable Errors
0x04  0x010  4               0  ---  Resets Between Cmd Acceptance and Completion
0x05  =====  =               =  ===  == Temperature Statistics (rev 1) ==
0x05  0x008  1              22  ---  Current Temperature
0x05  0x010  1              21  ---  Average Short Term Temperature
0x05  0x018  1              20  ---  Average Long Term Temperature
0x05  0x020  1              34  ---  Highest Temperature
0x05  0x028  1              18  ---  Lowest Temperature
0x05  0x030  1              27  ---  Highest Average Short Term Temperature
0x05  0x038  1              19  ---  Lowest Average Short Term Temperature
0x05  0x040  1              24  ---  Highest Average Long Term Temperature
0x05  0x048  1              20  ---  Lowest Average Long Term Temperature
0x05  0x050  4               0  ---  Time in Over-Temperature
0x05  0x058  1              55  ---  Specified Maximum Operating Temperature
0x05  0x060  4               0  ---  Time in Under-Temperature
0x05  0x068  1               5  ---  Specified Minimum Operating Temperature
0x06  =====  =               =  ===  == Transport Statistics (rev 1) ==
0x06  0x008  4             164  ---  Number of Hardware Resets
0x06  0x018  4               0  ---  Number of Interface CRC Errors
0x07  =====  =               =  ===  == Solid State Device Statistics (rev 1) ==
0x07  0x008  1               0  N--  Percentage Used Endurance Indicator
                                |||_ C monitored condition met
                                ||__ D supports DSN
                                |___ N normalized value

241 Total_LBAs_Written      -O--C-   100   100   000    -    126997

8322929196  * 512 / 32 / 1024 / 1024 = 126997,8209838867

PS:Sector size = 512Byte

четверг, 16 августа 2018 г.

the freenas zfs pool maintenance (removing the failed disk, add new spare disk)

Remove failed disk

# zpool status
...
            spare-9                                       DEGRADED     0     0     0
              4476675803796633449           UNAVAIL      0     0     0  was /dev/gptid/0e055d9c-9442-11e3-84bc-00259085d290
              gptid/7cf7d0d3-00d8-11e4-af38-00259085d290  ONLINE       0     0     0
...
        spares
          14921416118237907720              INUSE     was /dev/gptid/7cf7d0d3-00d8-11e4-af38-00259085d290
          gptid/559401b1-0725-11e4-af38-00259085d290      AVAIL
...

# zpool offline backup 4476675803796633449
# zpool detach backup 4476675803796633449

Add new spare disk to backup volume



Insert new disk to the server.
In freenas GUI Storage\Volumes\Volume Manager
Select Volume to extend, + Available disks
Select Spare in the Volume layout, Click on the Extend volume.

вторник, 19 июня 2018 г.

Create bootable media using the CLI for systemx servers

#Update packages
ibm_utl_bomc_9.64_windows_i386.exe --function=uxspi -m 7945 -l "C:\workingdir"
#Create iso
ibm_utl_bomc_9.64_windows_i386.exe --function=uxspi -m 7945 -l "C:\workingdir" --iso=x3650m3_firm.iso --autorun=uxspi
#Create boot usb flash
ibm_utl_bomc_9.64_windows_i386.exe --function=uxspi -m 7945 -l "C:\workingdir" --usbkey=E:

четверг, 10 мая 2018 г.

Proxmox 5.x bond+vlan+openvswitch

1. Bond+Vlan (active-backup)
1.1 /etc/network/interfaces
auto eno1
auto eno2
auto bond0
iface bond0 inet manual
slaves eno1 eno2
bond-mode active-backup
bond-miimon 100
bond-downdelay 200
bond-updelay 200
auto vlan316
iface vlan316 inet static
address 10.1.18.6
netmask 255.255.255.0
network 10.1.18.0
broadcast 10.1.18.255
gateway 10.1.18.254
dns-nameservers 10.1.18.1
dns-search cloud.example.com
vlan-raw-device bond0

2. Openvswitch bond+vlan (active-backup)
2.1 Install openvswitch
# apt-get install openvswitch-switch
2.2 Check net-tools (need ifconfig)
# dpkg -l | grep net-tools
ii  net-tools                            1.60+git20161116.90da8a0-1     amd64        NET-3 networking toolkit

2.3 /etc/network/interfaces

auto lo
iface lo inet loopback

allow-vmbr0 bond0
iface bond0 inet manual
        ovs_bridge vmbr0
        ovs_type OVSBond
        ovs_bonds eno1 eno2
        pre-up ( ifconfig eno1 mtu 9000 && ifconfig eno2 mtu 9000 )
        ovs_options bond_mode=active-backup vlan_mode=native-untagged trunks=316,317
        mtu 9000

auto vmbr0
allow-ovs vmbr0
iface vmbr0 inet manual
        ovs_type OVSBridge
        ovs_ports bond0 vlan316
        mtu 9000

allow-vmbr0 vlan316
iface vlan316 inet static
        ovs_type OVSIntPort
        ovs_bridge vmbr0
        ovs_options vlan_mode=access tag=316
        ovs_extra set interface ${IFACE} external-ids:iface-id=$(hostname -s)-${IFACE}-vif
        address 10.1.18.6
        netmask 255.255.255.0
        gateway 10.1.18.254
        mtu 9000

auto eno1
iface eno1 inet manual

auto eno2
iface eno2 inet manual