This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package net | |
| import ( | |
| "errors" | |
| "net" | |
| "strings" | |
| "time" | |
| ) | |
| // 给定网卡名称,获取该网卡出口链接 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "use strict"; | |
| var page = require('webpage').create(), | |
| system = require('system'), | |
| address, output, size; | |
| address = system.args[1]; | |
| output = system.args[2]; | |
| page.onLoadFinished = function() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "use strict"; | |
| var url = require('url'); | |
| var port, server, service, | |
| system = require('system'); | |
| var webpage = require('webpage'); | |
| function main() { | |
| if (system.args.length !== 2) { | |
| console.log('Usage: serverkeepalive.js <portnumber>'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "use strict"; | |
| var url = require('url'); | |
| var port, server, service, | |
| system = require('system'); | |
| var webpage = require('webpage'); | |
| function main() { | |
| if (system.args.length !== 2) { | |
| console.log('Usage: serverkeepalive.js <portnumber>'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # $1 like 127.0.0.1:27029 | |
| mongoUrl=$1 | |
| querydb="echo 'show dbs;'| mongo "$mongoUrl" |awk '{if (NR>2 && NF==2){print \$1}}'" | |
| dbs=`eval $querydb` | |
| for db in $dbs; do | |
| mongodump -h $mongoUrl -d $db -o ./ | |
| done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "encoding/json" | |
| "io/ioutil" | |
| "log" | |
| "net/http" | |
| "net/url" | |
| "strconv" | |
| "sync" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "crypto/aes" | |
| "encoding/base64" | |
| "fmt" | |
| "log" | |
| "github.com/kierdavis/cfb8" | |
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "encoding/json" | |
| "flag" | |
| "io/ioutil" | |
| "log" | |
| "net/http" | |
| "os" | |
| "strings" |
NewerOlder