Skip to content

Instantly share code, notes, and snippets.

View Jerry-Fix's full-sized avatar

Jerry Jerry-Fix

View GitHub Profile
@Jerry-Fix
Jerry-Fix / netperf throughput with diff rx-usecs
Last active December 21, 2015 01:58
ethtool -C eth2 rx-usecs VALUE, using netperf
1 5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 99
1 2041.01 4077.18 4075.96 4077.64 4078.49 4078.23 4077.77 4077.55 4075.57 4073.83 3835.18 3804.33 3517.88 3239.99 2888.15 2836.55 2099.06 2826.28 2816.87 2978.29 2751.34
5 4076.88 8840.97 8806.59 8570.26 6482.82 6517.91 5526.49 5658.80 5839.25 5650.23 4975.40 4608.14 4152.37 4009.54 4097.49 4193.13 4232.22 4416.80 4147.86 3969.60 4054.31
10 4065.66 4953.04 8212.56 7655.45 6282.05 6270.99 5515.62 4999.63 5670.66 5610.04 4975.48 4606.60 4146.67 3898.27 3789.99 4162.37 4022.47 4125.31 4115.48 3967.84 3811.37
15 4073.37 4933.31 7706.01 7030.65 6336.81 6136.97 5518.46 5028.43 5533.45 5467.29 4975.56 4606.75 4147.28 3911.52 3784.95 4179.39 4013.14 4287.48 4112.30 3967.48 4049.32
20 4074.41 6919.17 6797.47 6601.73 6026.18 5814.38 5529.56 5025.87 5295.08 5328.62 4974.21 4606.96 4147.07 3892.20 3974.47 4114.49 4259.82 4118.26 4106.69 3975.14 3821.38
2
01:00.0 0200: 14e4:163b (rev 20)
Subsystem: 1028:028c
Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
Latency: 0, Cache Line Size: 64 bytes
Interrupt: pin A routed to IRQ 36
Region 0: Memory at da000000 (64-bit, non-prefetchable) [size=32M]
Capabilities: [48] Power Management version 3
Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0+,D1-,D2-,D3hot+,D3cold+)
Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=1 PME-
01:00.1 0200: 14e4:1639 (rev 20)
Subsystem: 1028:0236
Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
Latency: 0, Cache Line Size: 64 bytes
Interrupt: pin B routed to IRQ 48
Region 0: Memory at d8000000 (64-bit, non-prefetchable) [size=32M]
Capabilities: [48] Power Management version 3
Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0+,D1-,D2-,D3hot+,D3cold+)
Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=1 PME-
@Jerry-Fix
Jerry-Fix / broadcom 5720 tg3 info
Last active December 21, 2015 01:39
broadcom 5720 tg3 info
01:00.0 0200: 14e4:165f
Subsystem: 1028:1f5b
Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx-
Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
Latency: 0, Cache Line Size: 64 bytes
Interrupt: pin A routed to IRQ 15
Region 0: Memory at d91a0000 (64-bit, prefetchable) [size=64K]
Region 2: Memory at d91b0000 (64-bit, prefetchable) [size=64K]
Region 4: Memory at d91c0000 (64-bit, prefetchable) [size=64K]
Expansion ROM at dc800000 [disabled] [size=256K]
@Jerry-Fix
Jerry-Fix / intel i350 igb info
Created August 14, 2013 08:32
intel i350 igb info
01:00.0 0200: 8086:1521 (rev 01)
Subsystem: 1028:1f60
Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
Latency: 0, Cache Line Size: 64 bytes
Interrupt: pin D routed to IRQ 38
Region 0: Memory at dcb00000 (32-bit, non-prefetchable) [size=1M]
Region 2: I/O ports at fc80 [size=32]
Region 3: Memory at dcff0000 (32-bit, non-prefetchable) [size=16K]
Expansion ROM at dc000000 [disabled] [size=512K]
@Jerry-Fix
Jerry-Fix / lsi megaraid health check
Created July 25, 2013 06:29
1. LSI Logic / Symbios Logic MegaRAID SAS 2208 2. LSI Logic / Symbios Logic MegaRAID SAS 9240 3. LSI Logic / Symbios Logic SAS2008 PCI-Express Fusion-MPT SAS-2
#!/bin/bash
# Checkresults are returned as text or integer.
# The script expects one parameter: The check you want to perform .
# The second paramter, the value you want to grep, is optional.
# The third parameter, the adapter number, is optional. If adapter number is missing, ALL is set.
# Thanks to https://twiki.cern.ch/twiki/bin/view/FIOgroup/DiskRefPerc
# for the nice overview
# LSI Logic / Symbios Logic MegaRAID SAS 2208
@Jerry-Fix
Jerry-Fix / zabbix megaraid
Created July 24, 2013 15:33
zabbix megaraid
#!/bin/bash
#
# Checks the status of the hardware raid.
# Checkresults are returned as text or integer.
# The script expects one parameter: The check you want to perform .
# The second paramter, the value you want to grep, is optional.
# The third parameter, the adapter number, is optional. If adapter number is missing, 0 is set.
# Thanks to https://twiki.cern.ch/twiki/bin/view/FIOgroup/DiskRefPerc
# for the nice overview
#!/usr/bin/php
<?php
// The service you're using. Choices include clickatell, budgetsms, nexmo and clockwork
$service = 'emay';
// The API key.
$apikey = "YOUR_APIKEY;
// Username and password. With BudgetSMS use userid as password. Username not needed for Nexmo or Clockwork
rh 6.0 kickstart with gpt.
1. add necessary service, remove unnecessary service
2. The last section starting with "#$SNIPPET('custom/xxyy')" are some post install scripts:
* modify /etc/hosts
127.0.0.1 localhost.localdomain localhost
private_ip hostname.jaseywang.me hostname
* remove zero route
* add some parameters to kernel options
* disable ipv6
* add ntp server for each server to sync time
@Jerry-Fix
Jerry-Fix / ubuntu 10.04 preseed
Created April 13, 2013 17:08
ubuntu 10.04 preseed
d-i debian-installer/locale string en_US
d-i debian-installer/language string en
d-i debian-installer/country string US
d-i debian-installer/locale string en_US.UTF-8
d-i debian-installer/allow_unauthenticated string true
d-i console-setup/ask_detect boolean false
d-i console-setup/layoutcode string us
d-i netcfg/choose_interface select eth0
d-i mirror/country string manual