Skip to content

Instantly share code, notes, and snippets.

jaseywang jaseywang

Block or report user

Report or block jaseywang

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:9047151
RH & CentOS
1. mv /etc/modprobe.d/ipv6.conf /var/tmp
2. cat /etc/modprobe.d/bonding.conf
alias bond0 bonding
options bond0 mode=0 miimon=100 downdelay=200 updelay=200
@jaseywang
jaseywang / ubuntu_rhel_bonding_config_template
Last active Aug 29, 2015
Ubuntu&RHEL bonding network config template
View ubuntu_rhel_bonding_config_template
# yum install ifenslave iputils
# apt-get install ifenslave
# cat /etc/modprobe.d/bonding.conf
alias bond0 bonding
options bonding mode=6 miimon=100 downdelay=200 updelay=200
Ubuntu
# cat /etc/network/interfaces
auto eth0
View kernel log
Apr 22 11:33:24 umid2 kernel: [42351054.583918] java: page allocation failure: order:4, mode:0x4020
Apr 22 11:33:24 umid2 kernel: [42351054.583926] Pid: 28567, comm: java Tainted: G WC 3.2.0-29-generic #46-Ubuntu
Apr 22 11:33:24 umid2 kernel: [42351054.583930] Call Trace:
Apr 22 11:33:24 umid2 kernel: [42351054.583933] <IRQ> [<ffffffff8111c966>] warn_alloc_failed+0xf6/0x150
Apr 22 11:33:24 umid2 kernel: [42351054.583953] [<ffffffff8112a081>] ? wakeup_kswapd+0x101/0x160
Apr 22 11:33:24 umid2 kernel: [42351054.583960] [<ffffffff811207cb>] __alloc_pages_nodemask+0x64b/0x820
Apr 22 11:33:24 umid2 kernel: [42351054.583969] [<ffffffff81645115>] kmalloc_large_node+0x57/0x85
Apr 22 11:33:24 umid2 kernel: [42351054.583979] [<ffffffff811657a5>] __kmalloc_node_track_caller+0x195/0x1e0
Apr 22 11:33:24 umid2 kernel: [42351054.583986] [<ffffffff810d8949>] ? handle_irq_event_percpu+0xa9/0x220
Apr 22 11:33:24 umid2 kernel: [42351054.583995] [<ffffffff81532c2b>] ? __alloc_skb+0x4b/0x240
@jaseywang
jaseywang / messages
Created Apr 25, 2014
pkg loss to other server
View messages
Apr 21 16:02:42 dp23 kernel: [ 21.994395] bonding: bond0: doing slave updates when interface is down.
Apr 21 16:02:42 dp23 kernel: [ 21.994398] bonding: bond0: doing slave updates when interface is down.
Apr 21 16:02:42 dp23 kernel: [ 21.994401] bonding: bond0: doing slave updates when interface is down.
Apr 21 16:02:42 dp23 kernel: [ 21.994403] bonding: bond0: doing slave updates when interface is down.
Apr 21 16:02:42 dp23 kernel: [ 21.994406] bonding: bond0: doing slave updates when interface is down.
Apr 21 16:02:42 dp23 kernel: [ 21.994409] bonding: bond0: doing slave updates when interface is down.
Apr 21 16:02:42 dp23 kernel: [ 21.994411] bonding: bond0: doing slave updates when interface is down.
Apr 21 16:02:42 dp23 kernel: [ 21.994414] bonding: bond0: doing slave updates when interface is down.
Apr 21 16:02:42 dp23 kernel: [ 21.994416] bonding: bond0: doing slave updates when interface is down.
Apr 21 16:02:42 dp23 kernel: [ 21.994420] bonding: bond0: enslaving eth0 as an active
@jaseywang
jaseywang / jetty parameters
Last active Aug 29, 2015
--list-config/--list-classpath/--help/--list-modules
View jetty parameters
[jaseywang@unode-test1 jetty]$ java -jar start.jar --list-classpath
Jetty Server Classpath:
-----------------------
Version Information on 35 entries in the classpath.
Note: order presented here is how they would appear on the classpath.
changes to the --module=name command line options will be reflected here.
0: (dir) | ${jetty.home}/resources
1: 3.1.0 | ${jetty.home}/lib/servlet-api-3.1.jar
2: 3.1.0.M0 | ${jetty.home}/lib/jetty-schemas-3.1.jar
View keyerror during ks installation
$ cat abrt.log
executable: /mnt/runtime/usr/bin/python
hashmarkername: anaconda
kernel: 2.6.32-220.el6.x86_64
product: Red Hat Enterprise Linux
reason: KeyError: '/dev/sda'
time: Tue 06 May 2014 10:42:15 AM CST
version: 6.2
anaconda-tb-JAZH2E: Text file, 213992 bytes
@jaseywang
jaseywang / rx_discards rate,
Created Oct 13, 2014
ethtool rx_discard(dropped) rate/s, different pkg size
View rx_discards rate,
while true; do echo "---- $(date +'%H:%M:%S')" ;R1=$(ethtool -S em1 | grep rx_dis | cut -d":" -f 2) ;sleep 1;R2=$(ethtool -S em1 | grep rx_dis| cut -d ":" -f 2); R=`expr $R2 - $R1`; echo $R ; done;
1400Byte:
---- 23:11:30
3186
---- 23:11:31
0
---- 23:11:32
0
@jaseywang
jaseywang / strace ping baidu.com
Created Oct 28, 2014
strace ping baidu.com, default setting
View strace ping baidu.com
$ strace -t ping baidu.com
21:08:23 execve("/bin/ping", ["ping", "baidu.com"], [/* 29 vars */]) = 0
21:08:23 brk(0) = 0x7f64d70e7000
21:08:23 fcntl(0, F_GETFD) = 0
21:08:23 fcntl(1, F_GETFD) = 0
21:08:23 fcntl(2, F_GETFD) = 0
21:08:23 access("/etc/suid-debug", F_OK) = -1 ENOENT (No such file or directory)
21:08:23 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f64d6e78000
21:08:23 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
21:08:23 open("/etc/ld.so.cache", O_RDONLY) = 3
@jaseywang
jaseywang / strace -t ping baidu.com(options timeout:1)
Created Oct 28, 2014
strace -t ping baidu.com(options timeout:1)
View strace -t ping baidu.com(options timeout:1)
$ strace -t ping baidu.com
21:25:06 execve("/bin/ping", ["ping", "baidu.com"], [/* 29 vars */]) = 0
21:25:06 brk(0) = 0x7fb70fcc2000
21:25:06 fcntl(0, F_GETFD) = 0
21:25:06 fcntl(1, F_GETFD) = 0
21:25:06 fcntl(2, F_GETFD) = 0
21:25:06 access("/etc/suid-debug", F_OK) = -1 ENOENT (No such file or directory)
21:25:06 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb70f5ec000
21:25:06 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
21:25:06 open("/etc/ld.so.cache", O_RDONLY) = 3
@jaseywang
jaseywang / strace -t getent hosts baidu.com
Created Oct 28, 2014
strace -t getent hosts baidu.com(default setting)
View strace -t getent hosts baidu.com
$ strace -t getent hosts baidu.com
21:13:09 execve("/usr/bin/getent", ["getent", "hosts", "baidu.com"], [/* 29 vars */]) = 0
21:13:09 brk(0) = 0x1168000
21:13:09 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f779687f000
21:13:09 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
21:13:09 open("/etc/ld.so.cache", O_RDONLY) = 3
21:13:09 fstat(3, {st_mode=S_IFREG|0644, st_size=68446, ...}) = 0
21:13:09 mmap(NULL, 68446, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f779686e000
21:13:09 close(3) = 0
21:13:09 open("/lib64/libc.so.6", O_RDONLY) = 3
You can’t perform that action at this time.