Jmeter(四十九)jmeter+influxdb+Granfna集成win部署

其實(shí)很多時(shí)候敞掘,群眾是很好說話的,因?yàn)樗麄兯枰牟⒎翘貦?quán),而是公平

--當(dāng)年明月《明朝那些事兒》

由于是win本地部署芒炼,jmeter部署看前面文章即可,本篇主要記錄influxdb+granfna

一术徊、influxdb

1本刽、influxdb官網(wǎng)下載win的安裝包

2、解壓至本地

3赠涮、修改配置文件子寓,下載下來的配置文件為:influxdb.conf;一般win都推薦influxdb.config使用config后綴的配置笋除,其實(shí)兩種配置文件都試了試斜友,都可用

4、修改配置文件內(nèi)容垃它,路徑改成自己本地路徑

meta部分:

<pre style="color: rgb(0, 0, 0); font-family: "Courier New"; font-size: 12px; margin: 5px 8px; padding: 5px;">[meta]

Where the metadata/raft database is stored

dir = "D:\usuallySoftwere\influxdb-1.7.7-1\meta" # Automatically create a default retention policy when creating a database.
retention-autocreate = true # If log messages are printed for the meta service
logging-enabled = true</pre>

data部分:

<pre style="color: rgb(0, 0, 0); font-family: "Courier New"; font-size: 12px; margin: 5px 8px; padding: 5px;">[data]

The directory where the TSM storage engine stores TSM files.

dir = "D:\usuallySoftwere\influxdb-1.7.7-1\data" # The directory where the TSM storage engine stores WAL files.
wal-dir = "D:\usuallySoftwere\influxdb-1.7.7-1\wal"</pre>

retention部分:

<pre style="color: rgb(0, 0, 0); font-family: "Courier New"; font-size: 12px; margin: 5px 8px; padding: 5px;">[retention]

Determines whether retention policy enforcement enabled.

enabled = true # The interval of time when retention policy enforcement checks run.
check-interval = "30m"</pre>

shard-precreation部分:

<pre style="color: rgb(0, 0, 0); font-family: "Courier New"; font-size: 12px; margin: 5px 8px; padding: 5px;">[shard-precreation]

Determines whether shard pre-creation service is enabled.

enabled = true # The interval of time when the check to pre-create new shards runs.
check-interval = "10m" # The default period ahead of the endtime of a shard group that its successor

group is created.

advance-period = "30m"</pre>

http部分:

<pre style="color: rgb(0, 0, 0); font-family: "Courier New"; font-size: 12px; margin: 5px 8px; padding: 5px;">[http]

Determines whether HTTP endpoint is enabled.

enabled = true # Determines whether the Flux query endpoint is enabled.

flux-enabled = false # Determines whether the Flux query logging is enabled.

flux-log-enabled = false # The bind address used by the HTTP service.

bind-address = ":8086" # Determines whether user authentication is enabled over HTTP/HTTPS.
auth-enabled = false # The default realm sent back when issuing a basic auth challenge.

realm = "InfluxDB" # Determines whether HTTP request logging is enabled.

log-enabled = true # Determines whether the HTTP write request logs should be suppressed when the log is enabled.

suppress-write-log = false # When HTTP request logging is enabled, this option specifies the path where # log entries should be written. If unspecified, the default is to write to stderr, which

intermingles HTTP logs with internal InfluxDB logging.

If influxd is unable to access the specified path, it will log an error and fall back to writing

the request log to stderr.

access-log-path = "" # Filters which requests should be logged. Each filter is of the pattern NNN, NNX, or NXX where N is # a number and X is a wildcard for any number. To filter all 5xx responses, use the string 5xx.

If multiple filters are used, then only one has to match. The default is to have no filters which

will cause every request to be printed.

access-log-status-filters = []

Determines whether detailed write logging is enabled.

write-tracing = false # Determines whether the pprof endpoint is enabled. This endpoint is used for # troubleshooting and monitoring.

pprof-enabled = true # Enables a pprof endpoint that binds to localhost:6060 immediately on startup.

This is only needed to debug startup issues.

debug-pprof-enabled = false # Determines whether HTTPS is enabled.

https-enabled = false # The SSL certificate to use when HTTPS is enabled.

https-certificate = "/etc/ssl/influxdb.pem" # Use a separate private key location.

https-private-key = "" # The JWT auth shared secret to validate requests using JSON web tokens.

shared-secret = "" # The default chunk size for result sets that should be chunked.

max-row-limit = 0 # The maximum number of HTTP connections that may be open at once. New connections that

would exceed this limit are dropped. Setting this value to 0 disables the limit.

max-connection-limit = 0 # Enable http service over unix domain socket

unix-socket-enabled = false # The path of the unix domain socket.

bind-socket = "/var/run/influxdb.sock" # The maximum size of a client request body, in bytes. Setting this value to 0 disables the limit.

max-body-size = 25000000 # The maximum number of writes processed concurrently.

Setting this to 0 disables the limit.

max-concurrent-write-limit = 0 # The maximum number of writes queued for processing.

Setting this to 0 disables the limit.

max-enqueued-write-limit = 0 # The maximum duration for a write to wait in the queue to be processed.

Setting this to 0 or setting max-concurrent-write-limit to 0 disables the limit.

enqueued-write-timeout = 0</pre>

graphite部分:

<pre style="color: rgb(0, 0, 0); font-family: "Courier New"; font-size: 12px; margin: 5px 8px; padding: 5px;">[[graphite]]

Determines whether the graphite endpoint is enabled.

enabled = true database = "jmeter" # retention-policy = "" bind-address = ":2003" protocol = "tcp" consistency-level = "one" # These next lines control how batching works. You should have this enabled

otherwise you could get dropped metrics or poor performance. Batching

will buffer points in memory if you have many coming in.

Flush if this many points get buffered

batch-size = 5000 # number of batches that may be pending in memory

batch-pending = 10 # Flush at least this often even if we haven't hit buffer limit

batch-timeout = "1s" # UDP Read buffer size, 0 means OS default. UDP listener will fail if set above OS max.

udp-read-buffer = 0 ### This string joins multiple matching 'measurement' values providing more control over the final measurement name.

separator = "." ### Default tags that will be added to all metrics. These can be overridden at the template level

or by tags extracted from metric

tags = ["region=us-east", "zone=1c"]

Each template line requires a template pattern. It can have an optional

filter before the template and separated by spaces. It can also have optional extra

tags following the template. Multiple tags should be separated by commas and no spaces

similar to the line protocol format. There can be only one default template.

templates = [

"*.app env.service.resource.measurement",

# Default template

"server.*",

]

[collectd]

Controls one or many listeners for collectd data.

</pre>

可以看到基本上都是對(duì)配置的打開鲜屏,graphite部分和http部分涉及自定義配置

5、啟動(dòng)influxdb国拇,指定配置文件

命令:influxd -config influxdb.config

6洛史、啟動(dòng)成功

二、Granfna

1贝奇、官網(wǎng)下載win安裝包

2虹菲、配置influxdb庫信息(注意:庫有設(shè)置密碼就填入密碼,未設(shè)置密碼便不用填寫掉瞳,直接連接即可)

3毕源、導(dǎo)入jmeter模板(模板很多,百度一下陕习,或者官網(wǎng)查找)

三霎褐、jmeter配置

1、添加后置監(jiān)聽器進(jìn)行配置

后端監(jiān)聽器實(shí)現(xiàn)選擇:org.apache.jmeter.visualizers.backend.influxdb.InfluxdbBackendListenerClient

參數(shù)配置:

<pre style="color: rgb(0, 0, 0); font-family: "Courier New"; font-size: 12px; margin: 5px 8px; padding: 5px;">influxdbUrl :http://localhost:8086/write?db=jmeter
application :jmeter

measurement :jmeter

summaryOnly : false samplersRegex :* 其余默認(rèn)即可</pre>

配置完成该镣。

[圖片上傳失敗...(image-1b44dc-1678761108982)]

?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
  • 序言:七十年代末冻璃,一起剝皮案震驚了整個(gè)濱河市,隨后出現(xiàn)的幾起案子,更是在濱河造成了極大的恐慌省艳,老刑警劉巖娘纷,帶你破解...
    沈念sama閱讀 217,277評(píng)論 6 503
  • 序言:濱河連續(xù)發(fā)生了三起死亡事件,死亡現(xiàn)場離奇詭異跋炕,居然都是意外死亡赖晶,警方通過查閱死者的電腦和手機(jī),發(fā)現(xiàn)死者居然都...
    沈念sama閱讀 92,689評(píng)論 3 393
  • 文/潘曉璐 我一進(jìn)店門辐烂,熙熙樓的掌柜王于貴愁眉苦臉地迎上來遏插,“玉大人,你說我怎么就攤上這事纠修「斐埃” “怎么了?”我有些...
    開封第一講書人閱讀 163,624評(píng)論 0 353
  • 文/不壞的土叔 我叫張陵扣草,是天一觀的道長了牛。 經(jīng)常有香客問我,道長德召,這世上最難降的妖魔是什么白魂? 我笑而不...
    開封第一講書人閱讀 58,356評(píng)論 1 293
  • 正文 為了忘掉前任,我火速辦了婚禮上岗,結(jié)果婚禮上,老公的妹妹穿的比我還像新娘蕴坪。我一直安慰自己肴掷,他們只是感情好,可當(dāng)我...
    茶點(diǎn)故事閱讀 67,402評(píng)論 6 392
  • 文/花漫 我一把揭開白布背传。 她就那樣靜靜地躺著呆瞻,像睡著了一般。 火紅的嫁衣襯著肌膚如雪径玖。 梳的紋絲不亂的頭發(fā)上痴脾,一...
    開封第一講書人閱讀 51,292評(píng)論 1 301
  • 那天,我揣著相機(jī)與錄音梳星,去河邊找鬼赞赖。 笑死,一個(gè)胖子當(dāng)著我的面吹牛冤灾,可吹牛的內(nèi)容都是我干的前域。 我是一名探鬼主播,決...
    沈念sama閱讀 40,135評(píng)論 3 418
  • 文/蒼蘭香墨 我猛地睜開眼韵吨,長吁一口氣:“原來是場噩夢啊……” “哼匿垄!你這毒婦竟也來了?” 一聲冷哼從身側(cè)響起,我...
    開封第一講書人閱讀 38,992評(píng)論 0 275
  • 序言:老撾萬榮一對(duì)情侶失蹤椿疗,失蹤者是張志新(化名)和其女友劉穎漏峰,沒想到半個(gè)月后,有當(dāng)?shù)厝嗽跇淞掷锇l(fā)現(xiàn)了一具尸體届榄,經(jīng)...
    沈念sama閱讀 45,429評(píng)論 1 314
  • 正文 獨(dú)居荒郊野嶺守林人離奇死亡芽狗,尸身上長有42處帶血的膿包…… 初始之章·張勛 以下內(nèi)容為張勛視角 年9月15日...
    茶點(diǎn)故事閱讀 37,636評(píng)論 3 334
  • 正文 我和宋清朗相戀三年,在試婚紗的時(shí)候發(fā)現(xiàn)自己被綠了痒蓬。 大學(xué)時(shí)的朋友給我發(fā)了我未婚夫和他白月光在一起吃飯的照片童擎。...
    茶點(diǎn)故事閱讀 39,785評(píng)論 1 348
  • 序言:一個(gè)原本活蹦亂跳的男人離奇死亡,死狀恐怖攻晒,靈堂內(nèi)的尸體忽然破棺而出顾复,到底是詐尸還是另有隱情,我是刑警寧澤鲁捏,帶...
    沈念sama閱讀 35,492評(píng)論 5 345
  • 正文 年R本政府宣布芯砸,位于F島的核電站,受9級(jí)特大地震影響给梅,放射性物質(zhì)發(fā)生泄漏假丧。R本人自食惡果不足惜,卻給世界環(huán)境...
    茶點(diǎn)故事閱讀 41,092評(píng)論 3 328
  • 文/蒙蒙 一动羽、第九天 我趴在偏房一處隱蔽的房頂上張望包帚。 院中可真熱鬧,春花似錦运吓、人聲如沸渴邦。這莊子的主人今日做“春日...
    開封第一講書人閱讀 31,723評(píng)論 0 22
  • 文/蒼蘭香墨 我抬頭看了看天上的太陽谋梭。三九已至,卻和暖如春倦青,著一層夾襖步出監(jiān)牢的瞬間瓮床,已是汗流浹背。 一陣腳步聲響...
    開封第一講書人閱讀 32,858評(píng)論 1 269
  • 我被黑心中介騙來泰國打工产镐, 沒想到剛下飛機(jī)就差點(diǎn)兒被人妖公主榨干…… 1. 我叫王不留隘庄,地道東北人。 一個(gè)月前我還...
    沈念sama閱讀 47,891評(píng)論 2 370
  • 正文 我出身青樓磷账,卻偏偏與公主長得像峭沦,于是被迫代替她去往敵國和親。 傳聞我的和親對(duì)象是個(gè)殘疾皇子逃糟,可洞房花燭夜當(dāng)晚...
    茶點(diǎn)故事閱讀 44,713評(píng)論 2 354

推薦閱讀更多精彩內(nèi)容