不多说,直接上干货!

  我这里呢,分两种常用的Suricata。

一、源码编译安装的Suricata

  这里不多说,大家可以去看我下面写的博客

使用 Suricata 进行入侵监控(一个简单小例子访问百度)

[root@suricata suricata]# ls
certs eve.json fast.log files stats.log suricata.log
[root@suricata suricata]# cat suricata.log
9/8/2017 -- 21:13:33 - <Notice> - This is Suricata version 3.1 RELEASE
9/8/2017 -- 21:13:42 - <Warning> - [ERRCODE: SC_ERR_NO_RULES(42)] - No rule files match the pattern /etc/suricata/rules/tls-events.rules
9/8/2017 -- 21:13:42 - <Warning> - [ERRCODE: SC_ERR_NO_RULES(42)] - No rule files match the pattern /etc/suricata/rules/test.rules
9/8/2017 -- 21:13:42 - <Error> - [ERRCODE: SC_ERR_NO_RULES(42)] - No rules loaded from /etc/suricata/rules/test.rules
9/8/2017 -- 21:13:49 - <Notice> - all 1 packet processing threads, 4 management threads initialized, engine started.
9/8/2017 -- 21:19:41 - <Notice> - Signal Received. Stopping engine.
9/8/2017 -- 21:19:41 - <Notice> - Stats for 'eth0': pkts: 11525, drop: 0 (0.00%), invalid chksum: 0
[root@suricata suricata]# pwd
/var/log/suricata
[root@suricata suricata]#

二、SELKS里的Suricata

root@SELKS:/var/log/suricata# pwd
/var/log/suricata
root@SELKS:/var/log/suricata# ll
total
drwxr-xr-x logstash logstash Jul : certs
drwxr-xr-x logstash logstash Jul : core
-rw-r----- logstash logstash Aug : eve.json
-rw-r----- logstash logstash Aug : fast.log
drwxr-xr-x logstash logstash Jul : files
drwxr-xr-x logstash logstash Jul : StatsByDate
-rw-r----- logstash logstash Aug : stats.log
-rw-r--r-- root root Aug : suricata.log
-rw-r--r-- root root Aug : suricata-start.log
root@SELKS:/var/log/suricata#

  这里,建议大家如我这样,先保留一份默认的权限。免得以后自己修改后了,返回去会有权限问题。

  好比,我这里想把eve.json下载下来,查看。

  最好比如这里eve.json本来的权限是640,则可建议先chmod 777 eve.json,用完之后,再640回去即可。

{"timestamp":"2017-08-17T16:32:04.007125+0800","flow_id":,"event_type":"flow","src_ip":"192.168.1.106","src_port":,"dest_ip":"192.168.1.110","dest_port":,"proto":"TCP","app_proto":"tls","flow":{"pkts_toserver":,"pkts_toclient":,"bytes_toserver":,"bytes_toclient":,"start":"2017-08-17T16:30:52.309149+0800","end":"2017-08-17T16:31:02.250921+0800","age":,"state":"closed","reason":"timeout","alerted":false},"tcp":{"tcp_flags":"1b","tcp_flags_ts":"1b","tcp_flags_tc":"1b","syn":true,"fin":true,"psh":true,"ack":true,"state":"closed"}}
{"timestamp":"2017-08-17T16:32:04.007306+0800","flow_id":,"event_type":"flow","src_ip":"192.168.1.106","src_port":,"dest_ip":"192.168.1.110","dest_port":,"proto":"TCP","app_proto":"tls","flow":{"pkts_toserver":,"pkts_toclient":,"bytes_toserver":,"bytes_toclient":,"start":"2017-08-17T16:30:52.311506+0800","end":"2017-08-17T16:31:02.250232+0800","age":,"state":"closed","reason":"timeout","alerted":false},"tcp":{"tcp_flags":"1b","tcp_flags_ts":"1b","tcp_flags_tc":"1b","syn":true,"fin":true,"psh":true,"ack":true,"state":"closed"}}
{"timestamp":"2017-08-17T16:32:04.007491+0800","flow_id":,"event_type":"flow","src_ip":"192.168.1.106","src_port":,"dest_ip":"192.168.1.110","dest_port":,"proto":"TCP","app_proto":"tls","flow":{"pkts_toserver":,"pkts_toclient":,"bytes_toserver":,"bytes_toclient":,"start":"2017-08-17T16:30:52.311506+0800","end":"2017-08-17T16:31:02.250232+0800","age":,"state":"closed","reason":"timeout","alerted":false},"tcp":{"tcp_flags":"1b","tcp_flags_ts":"1b","tcp_flags_tc":"1b","syn":true,"fin":true,"psh":true,"ack":true,"state":"closed"}}
{"timestamp":"2017-08-17T16:32:05.056241+0800","flow_id":,"in_iface":"enp0s3","event_type":"http","src_ip":"192.168.1.106","src_port":,"dest_ip":"121.14.88.17","dest_port":,"proto":"TCP","tx_id":,"http":{"hostname":"121.14.88.17","url":"\/gchatpic_new\/4178047381\/4178047381-2618102286-9FB3C79268791082715EA1BC1E0E710B\/0?vuin=1138410364&term=1&srvver=26719&rf=naio","http_user_agent":"Mozilla\/4.0 (compatible; MSIE 6.0; Windows NT 5.1)","accept":"*\/*","accept_encoding":"gzip, deflate","cache_control":"no-cache","http_refer":"http:\/\/im.qq.com","http_method":"GET","protocol":"HTTP\/1.1","length":}}
{"timestamp":"2017-08-17T16:32:05.102122+0800","flow_id":,"in_iface":"enp0s3","event_type":"http","src_ip":"192.168.1.106","src_port":,"dest_ip":"121.14.88.53","dest_port":,"proto":"TCP","tx_id":,"http":{"hostname":"121.14.88.53","url":"\/gchatpic_new\/4178047381\/4178047381-2618102286-9FB3C79268791082715EA1BC1E0E710B\/0?vuin=1138410364&term=1&srvver=26719&rf=naio","http_user_agent":"Mozilla\/4.0 (compatible; MSIE 6.0; Windows NT 5.1)","http_content_type":"image\/jpeg","accept":"*\/*","accept_encoding":"gzip, deflate","cache_control":"no-cache","connection":"keep-alive","content_length":"","content_type":"image\/jpeg","last_modified":"Thu, 17 Aug 2017 16:31:00 GMT","server":"ImgHttp3.0.0","http_refer":"http:\/\/im.qq.com","http_method":"GET","protocol":"HTTP\/1.1","status":,"length":}}
{"timestamp":"2017-08-17T16:32:06.004897+0800","flow_id":,"event_type":"flow","src_ip":"fe80:0000:0000:0000:39ab:5a7f:5970:65bd","src_port":,"dest_ip":"ff02:0000:0000:0000:0000:0000:0001:0003","dest_port":,"proto":"UDP","app_proto":"failed","flow":{"pkts_toserver":,"pkts_toclient":,"bytes_toserver":,"bytes_toclient":,"start":"2017-08-17T16:31:35.446457+0800","end":"2017-08-17T16:31:35.547314+0800","age":,"state":"new","reason":"timeout","alerted":false}}
{"timestamp":"2017-08-17T16:32:06.005310+0800","flow_id":,"event_type":"flow","src_ip":"fe80:0000:0000:0000:39ab:5a7f:5970:65bd","src_port":,"dest_ip":"ff02:0000:0000:0000:0000:0000:0001:0003","dest_port":,"proto":"UDP","app_proto":"failed","flow":{"pkts_toserver":,"pkts_toclient":,"bytes_toserver":,"bytes_toclient":,"start":"2017-08-17T16:31:35.446457+0800","end":"2017-08-17T16:31:35.547314+0800","age":,"state":"new","reason":"timeout","alerted":false}}
{"timestamp":"2017-08-17T16:32:07.001918+0800","flow_id":,"event_type":"flow","src_ip":"192.168.1.106","src_port":,"dest_ip":"119.29.29.29","dest_port":,"proto":"UDP","app_proto":"dns","flow":{"pkts_toserver":,"pkts_toclient":,"bytes_toserver":,"bytes_toclient":,"start":"2017-08-17T16:27:06.957002+0800","end":"2017-08-17T16:27:06.983538+0800","age":,"state":"established","reason":"timeout","alerted":false}}
{"timestamp":"2017-08-17T16:32:07.002123+0800","flow_id":,"event_type":"flow","src_ip":"192.168.1.106","src_port":,"dest_ip":"119.29.29.29","dest_port":,"proto":"UDP","app_proto":"dns","flow":{"pkts_toserver":,"pkts_toclient":,"bytes_toserver":,"bytes_toclient":,"start":"2017-08-17T16:27:06.957002+0800","end":"2017-08-17T16:27:06.983538+0800","age":,"state":"established","reason":"timeout","alerted":false}}
{"timestamp":"2017-08-17T16:32:08.000546+0800","event_type":"stats","stats":{"uptime":,"capture":{"kernel_packets":,"kernel_packets_delta":,"kernel_drops":,"kernel_drops_delta":},"decoder":{"pkts":,"pkts_delta":,"bytes":,"bytes_delta":,"invalid":,"invalid_delta":,"ipv4":,"ipv4_delta":,"ipv6":,"ipv6_delta":,"ethernet":,"ethernet_delta":,"raw":,"raw_delta":,"null":,"null_delta":,"sll":,"sll_delta":,"tcp":,"tcp_delta":,"udp":,"udp_delta":,"sctp":,"sctp_delta":,"icmpv4":,"icmpv4_delta":,"icmpv6":,"icmpv6_delta":,"ppp":,"ppp_delta":,"pppoe":,"pppoe_delta":,"gre":,"gre_delta":,"vlan":,"vlan_delta":,"vlan_qinq":,"vlan_qinq_delta":,"teredo":,"teredo_delta":,"ipv4_in_ipv6":,"ipv4_in_ipv6_delta":,"ipv6_in_ipv6":,"ipv6_in_ipv6_delta":,"mpls":,"mpls_delta":,"avg_pkt_size":,"avg_pkt_size_delta":,"max_pkt_size":,"max_pkt_size_delta":,"erspan":,"erspan_delta":,"ipraw":{"invalid_ip_version":,"invalid_ip_version_delta":},"ltnull":{"pkt_too_small":,"pkt_too_small_delta":,"unsupported_type":,"unsupported_type_delta":},"dce":{"pkt_too_small":,"pkt_too_small_delta":}},"flow":{"memcap":,"memcap_delta":,"tcp":,"tcp_delta":,"udp":,"udp_delta":,"icmpv4":,"icmpv4_delta":,"icmpv6":,"icmpv6_delta":,"spare":,"spare_delta":,"emerg_mode_entered":,"emerg_mode_entered_delta":,"emerg_mode_over":,"emerg_mode_over_delta":,"tcp_reuse":,"tcp_reuse_delta":,"memuse":,"memuse_delta":-},"defrag":{"ipv4":{"fragments":,"fragments_delta":,"reassembled":,"reassembled_delta":,"timeouts":,"timeouts_delta":},"ipv6":{"fragments":,"fragments_delta":,"reassembled":,"reassembled_delta":,"timeouts":,"timeouts_delta":},"max_frag_hits":,"max_frag_hits_delta":},"tcp":{"sessions":,"sessions_delta":,"ssn_memcap_drop":,"ssn_memcap_drop_delta":,"pseudo":,"pseudo_delta":,"pseudo_failed":,"pseudo_failed_delta":,"invalid_checksum":,"invalid_checksum_delta":,"no_flow":,"no_flow_delta":,"syn":,"syn_delta":,"synack":,"synack_delta":,"rst":,"rst_delta":,"segment_memcap_drop":,"segment_memcap_drop_delta":,"stream_depth_reached":,"stream_depth_reached_delta":,"reassembly_gap":,"reassembly_gap_delta":,"overlap":,"overlap_delta":,"overlap_diff_data":,"overlap_diff_data_delta":,"insert_data_normal_fail":,"insert_data_normal_fail_delta":,"insert_data_overlap_fail":,"insert_data_overlap_fail_delta":,"insert_list_fail":,"insert_list_fail_delta":,"memuse":,"memuse_delta":,"reassembly_memuse":,"reassembly_memuse_delta":-},"detect":{"alert":,"alert_delta":},"app_layer":{"flow":{"http":,"http_delta":,"ftp":,"ftp_delta":,"smtp":,"smtp_delta":,"tls":,"tls_delta":,"ssh":,"ssh_delta":,"imap":,"imap_delta":,"msn":,"msn_delta":,"smb":,"smb_delta":,"dcerpc_tcp":,"dcerpc_tcp_delta":,"dns_tcp":,"dns_tcp_delta":,"failed_tcp":,"failed_tcp_delta":,"dcerpc_udp":,"dcerpc_udp_delta":,"dns_udp":,"dns_udp_delta":,"failed_udp":,"failed_udp_delta":},"tx":{"http":,"http_delta":,"ftp":,"ftp_delta":,"smtp":,"smtp_delta":,"tls":,"tls_delta":,"ssh":,"ssh_delta":,"smb":,"smb_delta":,"dcerpc_tcp":,"dcerpc_tcp_delta":,"dns_tcp":,"dns_tcp_delta":,"dcerpc_udp":,"dcerpc_udp_delta":,"dns_udp":,"dns_udp_delta":}},"flow_mgr":{"closed_pruned":,"closed_pruned_delta":,"new_pruned":,"new_pruned_delta":,"est_pruned":,"est_pruned_delta":,"bypassed_pruned":,"bypassed_pruned_delta":,"flows_checked":,"flows_checked_delta":-,"flows_notimeout":,"flows_notimeout_delta":-,"flows_timeout":,"flows_timeout_delta":,"flows_timeout_inuse":,"flows_timeout_inuse_delta":,"flows_removed":,"flows_removed_delta":,"rows_checked":,"rows_checked_delta":,"rows_skipped":,"rows_skipped_delta":,"rows_empty":,"rows_empty_delta":,"rows_busy":,"rows_busy_delta":,"rows_maxlen":,"rows_maxlen_delta":},"file_store":{"open_files":,"open_files_delta":},"dns":{"memuse":,"memuse_delta":-,"memcap_state":,"memcap_state_delta":,"memcap_global":,"memcap_global_delta":},"http":{"memuse":,"memuse_delta":,"memcap":,"memcap_delta":}}}
{"timestamp":"2017-08-17T16:32:08.006119+0800","flow_id":,"event_type":"flow","src_ip":"192.168.1.106","src_port":,"dest_ip":"119.29.29.29","dest_port":,"proto":"UDP","app_proto":"dns","flow":{"pkts_toserver":,"pkts_toclient":,"bytes_toserver":,"bytes_toclient":,"start":"2017-08-17T16:27:07.210960+0800","end":"2017-08-17T16:27:07.237152+0800","age":,"state":"established","reason":"timeout","alerted":false}}
{"timestamp":"2017-08-17T16:32:08.006255+0800","flow_id":,"event_type":"flow","src_ip":"192.168.1.106","src_port":,"dest_ip":"119.29.29.29","dest_port":,"proto":"UDP","app_proto":"dns","flow":{"pkts_toserver":,"pkts_toclient":,"bytes_toserver":,"bytes_toclient":,"start":"2017-08-17T16:27:07.210960+0800","end":"2017-08-17T16:27:07.237152+0800","age":,"state":"established","reason":"timeout","alerted":false}}

//-::00.188090  [**] [::] ET MALWARE Suspicious Mozilla User-Agent - Likely Fake (Mozilla/4.0) [**] [Classification: A Network Trojan was Detected] [Priority: ] {TCP} 192.168.1.106: -> 211.159.130.105:
//-::00.312554 [**] [::] ET MALWARE Suspicious Mozilla User-Agent - Likely Fake (Mozilla/4.0) [**] [Classification: A Network Trojan was Detected] [Priority: ] {TCP} 192.168.1.106: -> 211.159.130.105:
//-::35.606046 [**] [::] ET POLICY Outdated Flash Version M1 [**] [Classification: Potential Corporate Privacy Violation] [Priority: ] {TCP} 192.168.1.106: -> 14.18.245.211:
//-::26.198737 [**] [::] ET POLICY HTTP traffic on port (POST) [**] [Classification: Potentially Bad Traffic] [Priority: ] {TCP} 192.168.1.106: -> 183.3.235.188:
//-::01.181590 [**] [::] ET POLICY Outdated Flash Version M1 [**] [Classification: Potential Corporate Privacy Violation] [Priority: ] {TCP} 192.168.1.106: -> 14.18.245.211:
//-::51.709411 [**] [::] ET POLICY HTTP traffic on port (POST) [**] [Classification: Potentially Bad Traffic] [Priority: ] {TCP} 192.168.1.106: -> 183.3.235.188:
//-::53.182341 [**] [::] ET POLICY Outdated Flash Version M1 [**] [Classification: Potential Corporate Privacy Violation] [Priority: ] {TCP} 192.168.1.106: -> 14.18.245.211:
//-::34.097124 [**] [::] ET POLICY HTTP traffic on port (POST) [**] [Classification: Potentially Bad Traffic] [Priority: ] {TCP} 192.168.1.106: -> 183.3.235.188:
//-::41.476584 [**] [::] ET POLICY Outdated Flash Version M1 [**] [Classification: Potential Corporate Privacy Violation] [Priority: ] {TCP} 192.168.1.106: -> 14.18.245.211:
//-::41.476584 [**] [::] ET POLICY Outdated Flash Version M1 [**] [Classification: Potential Corporate Privacy Violation] [Priority: ] {TCP} 192.168.1.106: -> 14.18.245.211:
//-::25.114492 [**] [::] ET POLICY HTTP traffic on port (POST) [**] [Classification: Potentially Bad Traffic] [Priority: ] {TCP} 192.168.1.106: -> 183.3.235.188:
//-::25.114492 [**] [::] ET POLICY HTTP traffic on port (POST) [**] [Classification: Potentially Bad Traffic] [Priority: ] {TCP} 192.168.1.106: -> 183.3.235.188:

------------------------------------------------------------------------------------
Date: // -- :: (uptime: 0d, 00h 00m 08s)
------------------------------------------------------------------------------------
Counter | TM Name | Value
------------------------------------------------------------------------------------
capture.kernel_packets | Total |
decoder.pkts | Total |
decoder.bytes | Total |
decoder.ipv4 | Total |
decoder.ethernet | Total |
decoder.tcp | Total |
decoder.udp | Total |
decoder.avg_pkt_size | Total |
decoder.max_pkt_size | Total |
flow.tcp | Total |
flow.udp | Total |
tcp.sessions | Total |
tcp.syn | Total |
tcp.synack | Total |
tcp.rst | Total |
app_layer.flow.tls | Total |
app_layer.flow.failed_udp | Total |
flow.spare | Total |
flow_mgr.rows_checked | Total |
flow_mgr.rows_skipped | Total |
tcp.memuse | Total |
tcp.reassembly_memuse | Total |
dns.memuse | Total |
flow.memuse | Total |
------------------------------------------------------------------------------------
Date: // -- :: (uptime: 0d, 00h 00m 15s)
------------------------------------------------------------------------------------
Counter | TM Name | Value
------------------------------------------------------------------------------------
capture.kernel_packets | Total |
decoder.pkts | Total |
decoder.bytes | Total |
decoder.ipv4 | Total |
decoder.ipv6 | Total |
decoder.ethernet | Total |
decoder.tcp | Total |
decoder.udp | Total |
decoder.icmpv6 | Total |
decoder.avg_pkt_size | Total |
decoder.max_pkt_size | Total |
flow.tcp | Total |
flow.udp | Total |
flow.icmpv6 | Total |
tcp.sessions | Total |
tcp.syn | Total |
tcp.synack | Total |
tcp.rst | Total |
app_layer.flow.http | Total |
app_layer.tx.http | Total |
app_layer.flow.tls | Total |
app_layer.flow.dns_udp | Total |
app_layer.tx.dns_udp | Total |
app_layer.flow.failed_udp | Total |
flow.spare | Total |
flow_mgr.flows_checked | Total |
flow_mgr.flows_notimeout | Total |
flow_mgr.rows_checked | Total |
flow_mgr.rows_skipped | Total |
flow_mgr.rows_maxlen | Total |
tcp.memuse | Total |
tcp.reassembly_memuse | Total |
dns.memuse | Total |
http.memuse | Total |
flow.memuse | Total |
------------------------------------------------------------------------------------
Date: // -- :: (uptime: 0d, 00h 00m 22s)
------------------------------------------------------------------------------------
Counter | TM Name | Value
------------------------------------------------------------------------------------
capture.kernel_packets | Total |
decoder.pkts | Total |
decoder.bytes | Total |
decoder.ipv4 | Total |
decoder.ipv6 | Total |
decoder.ethernet | Total |
decoder.tcp | Total |
decoder.udp | Total |
decoder.icmpv6 | Total |
decoder.avg_pkt_size | Total |
decoder.max_pkt_size | Total |
flow.tcp | Total |
flow.udp | Total |
flow.icmpv6 | Total |
tcp.sessions | Total |
tcp.syn | Total |
tcp.synack | Total |
tcp.rst | Total |
app_layer.flow.http | Total |
app_layer.tx.http | Total |
app_layer.flow.tls | Total |
app_layer.flow.dns_udp | Total |
app_layer.tx.dns_udp | Total |
app_layer.flow.failed_udp | Total |
flow.spare | Total |
flow_mgr.flows_checked | Total |
flow_mgr.flows_notimeout | Total |
flow_mgr.rows_checked | Total |
flow_mgr.rows_skipped | Total |
flow_mgr.rows_maxlen | Total |
tcp.memuse | Total |
tcp.reassembly_memuse | Total |
dns.memuse | Total |
http.memuse | Total |
flow.memuse | Total |
------------------------------------------------------------------------------------

  对于其他的,大家自己去看吧!

  我这里主要讲的是eve.json和fast.log的区别

  在2281行。

  eve.json(即包括所有类型的数据)

  2017年8月16日的上午8点54分07秒

  fast.log(即只是报警数据)

  

Suricata产生的数据存储目录的更多相关文章

  1. MySQL更改数据库数据存储目录

    MySQL数据库默认的数据库文件位于/var/lib/mysql下,有时候由于存储规划等原因,需要更改MySQL数据库的数据存储目录.下文总结整理了实践过程的操作步骤. 1:确认MySQL数据库存储目 ...

  2. mysql更改数据存储目录

    具体操作请参考文章 1.http://blog.csdn.net/aaronbai/article/details/1431190 更改数据存储目录时候会出现 ERROR 2002 (HY000): ...

  3. Ubuntu上更改MySQL数据库数据存储目录

    之前写过一篇博客"MySQL更改数据库数据存储目录",当时的测试环境是RHEL和CentOS,谁想最近在Ubuntu下面更改MySQL数据库数据存储目录时遇到了之前未遇到的问题,之 ...

  4. MySQL 更改数据库数据存储目录

    MySQL数据库默认的数据库文件位于 /var/lib/mysql 下,有时候由于存储规划等原因,需要更改 MySQL 数据库的数据存储目录. 下文总结整理了实践过程的操作步骤.   1 确认MySQ ...

  5. Ubuntu 安装mysql & 自定义数据存储目录

    一.安装 apt-get install mysql-server 执行过程如下: root@duke:~# apt-get install mysql-server 正在读取软件包列表... 完成 ...

  6. Windows安装RabbitMQ并设置数据存储目录

    一.安装Elang 下载otp_win64_xx.x.exe,当前使用otp_win64_21.3.exe版本,按步骤完成安装. 下载地址:http://www.erlang.org/download ...

  7. centos mysql 数据存储目录安装位置

    rpm -ql mysql查看安装位置 MYSQL默认的数据文件存储目录为/var/lib/mysql.假如要把目录移到/home/data下需要进行下面几步: 1.home目录下建立data目录 c ...

  8. mysql5.6更改datadir数据存储目录

    环境需求: 有些数据存储场景可能需要将数据放到指定的挂载路径或目录,mysql默认存放数据路径在:/var/lib/mysql下. 测试环境: 操作步骤: 1. 查看当前存储目录 [root@mysq ...

  9. linux 更改mysql 数据存储目录

    https://www.cnblogs.com/hellangels333/p/8376177.html  参考位博主的文章,稍做改动 1.检查mysql数据库存放目录 mysql -u root - ...

随机推荐

  1. shell mv

    mv $a"/"$b"/"* $a"/"$b"/preview" 移动某个文件夹下的所有文件 使用* 但*不用双引号

  2. Jmeter代理服务器录制请求

    1.文档前提说明 1)本文使用jmeter的版本为 apache-jmeter-2.13 及以上版本 2)java版本要求在 1.8.0 以上 注:jmeter版本一般和java相应的版本一起使用,如 ...

  3. bzoj5483: [Usaco2018 Dec]Balance Beam

    又又又又又又又被踩爆了 首先容易写出这样的期望方程:f(1)=max(d(1),f(2)/2),f(n)=max(d(n),f(n-1)/2), f(i)=max(d(i),(f(i-1)+f(i+1 ...

  4. .Net线程池ThreadPool导致内存高的问题分析

    最近写了一个WinFrom程序.此程序侦听TCP端口,接受消息处理,然后再把处理后的消息,利用线程池通过WebService发送出去(即一进一出). 在程序编写完成后,进行压力测试.用Fiddler提 ...

  5. IDEA maven dependency自动提示

    通过File->setting->maven->repositories,选择本地仓库,点击右上角更新,更新maven仓库索引 在pom.xml编写引入依赖的jar包时,已经下载到本 ...

  6. 阿里云短信服务发送短信验证码(JAVA开发此功能)

    开发此功能需注册阿里云账号,并开通短信服务(免费开通) 充值后,不会影响业务的正常使用!(因为发送验证类短信:1-10万范围的短信是0.045元/条).开发测试使用,充2块钱测试足够了 可参考阿里云官 ...

  7. CentOS 7中ip命令将逐渐取代 ifconfig

    首先看下图: 要安装ip,请点击这里下载iproute2套装工具 .不过,大多数Linux发行版已经预装了iproute2工具. 你也可以使用git命令来下载最新源代码来编译: $ git clone ...

  8. SPFA 最短路 带负权边的---- 粗了解

    SPFA(Shortest Path Faster Algorithm)是Bellman-Ford算法的一种队列实现,减少了不必要的冗余计算. 算法大致流程是用一个队列来进行维护. 初始时将源加入队列 ...

  9. I.MX6 eMMC分区挂载

    /********************************************************************* * I.MX6 eMMC分区挂载 * 说明: * 如果想要 ...

  10. Dijkstra再理解+最短路计数

    众所周知,Dijkstra算法是跑单源最短路的一种优秀算法,不过他的缺点在于难以处理负权边. 但是由于在今年的NOI赛场上SPFA那啥了(嗯就是那啥了),所以我们还是好好研究一下Dij的原理和它的优化 ...