上一页 1 2 3 4 5 6 ··· 17 下一页
摘要: 1 elk是什么 pass 2 使用docker-compose搭建elk系统的链接 github使用人数很多的连接地址:https://github.com/deviantony/docker-elk/ 3 发送的日志在logstash接收到必须是json 发送时可以logger.info("he 阅读全文
posted @ 2019-06-19 12:01 Adamanter 阅读(243) 评论(0) 推荐(0) 编辑
摘要: 1.查看防火墙状态 systemctl status firewalld firewall-cmd --state #查看默认防火墙状态(关闭后显示notrunning,开启后显示running) 2.查看防火墙是否开机启动 systemctl is-enabled firewalld 3.关闭防火 阅读全文
posted @ 2019-06-11 17:57 Adamanter 阅读(95) 评论(0) 推荐(0) 编辑
摘要: 1 TCP端口的连通性 TC端口的连通性,一般通过telnet检测: TCP协议是面向连接的,可以直接通过telnet命令连接 yum install telnet -y telnet localhost 5001 或者有服务的curl curl -XGET localhost:5001 2 UDP 阅读全文
posted @ 2019-06-11 11:32 Adamanter 阅读(2402) 评论(0) 推荐(0) 编辑
摘要: cd /etc/ssh # 查看sshd_config中关于客户端活动状态的配置 grep ClientAlive sshd_config # 默认配置如下 # ---------------------------- #ClientAliveInterval 0 #ClientAliveCountMax 3 # ---------------------------- # ClientAliv... 阅读全文
posted @ 2019-06-04 18:03 Adamanter 阅读(232) 评论(0) 推荐(0) 编辑
摘要: from mongoengine.errors import NotUniqueError try: pass # 保存字段到数据库 result = formalReturn(201, 'upload success', data=None) return jsonify(result), 201 except No... 阅读全文
posted @ 2019-04-24 11:44 Adamanter 阅读(348) 评论(0) 推荐(0) 编辑
摘要: 官方镜像: docker pull docker.elastic.co/elasticsearch/elasticsearch:6.5.4 要设置/root/data/esdata可读写 docker run --name es_test_01 -p 9200:9200 -p 9300:9300 - 阅读全文
posted @ 2019-04-19 14:11 Adamanter 阅读(4726) 评论(0) 推荐(1) 编辑
摘要: 安装python以及包管理工具yum install python36yum install python36-pip 阅读全文
posted @ 2019-04-17 14:38 Adamanter 阅读(89) 评论(0) 推荐(0) 编辑
摘要: # coding=utf-8 # 僵尸标签显示次序: # 性别:女士/男士 # 人种:白人/亚洲人/黑人/阿拉伯人 # 季节:春秋/夏季/冬季 # 场景:街头/都市(其它不显示) # 风格:预留(暂时没有) # 年龄组:儿童/老人(成人不显示) # 眼镜:太阳镜/眼镜(无不显示) # 人物:刘诗诗 # 秀场:2019秋冬高级成衣 # 品牌:Topshop Unique # 影视:知否(暂时没有... 阅读全文
posted @ 2019-04-13 18:08 Adamanter 阅读(635) 评论(0) 推荐(0) 编辑
摘要: # coding=utf-8 import asyncio async def consumer(n, q): print('consumer {}: starting'.format(n)) while True: print('consumer {}: waiting for item'.format(n)) item = await ... 阅读全文
posted @ 2019-04-13 18:01 Adamanter 阅读(919) 评论(0) 推荐(0) 编辑
摘要: # coding=utf-8 import asyncio import aiohttp async def myfunc(url): async with aiohttp.ClientSession() as session: payload = {'image_url': url} async with session.post('http:/... 阅读全文
posted @ 2019-04-13 17:54 Adamanter 阅读(192) 评论(0) 推荐(0) 编辑
摘要: url = "https://app-s3.aifashion.com/sssdska45565646.jpg" def get_hash_from_url(upload_url): format = upload_url.rsplit(".")[-1] s1 = upload_url.rsplit(".")[-2] md5 = s1.rsplit('/')[-1]... 阅读全文
posted @ 2019-04-13 17:53 Adamanter 阅读(944) 评论(0) 推荐(0) 编辑
摘要: sensetive_words.txt 阅读全文
posted @ 2019-04-13 17:44 Adamanter 阅读(778) 评论(0) 推荐(0) 编辑
摘要: import time from multiprocessing import Pool from tqdm import tqdm # 简单多进程 def hello_world(name): time.sleep(1) sentence = "hello world " + name return '{}'.format(sentence) def main(... 阅读全文
posted @ 2019-04-13 17:38 Adamanter 阅读(156) 评论(0) 推荐(0) 编辑
摘要: from xpinyin import Pinyin pin = Pinyin() from collections import OrderedDict def deal_conversion(tags): """ 将标签中的值得中文名处理为拼音,英文名不变 :param tags: :return: """ _tags = [] ... 阅读全文
posted @ 2019-04-13 17:29 Adamanter 阅读(422) 评论(0) 推荐(0) 编辑
摘要: import random import json import datetime import time from pymongo import MongoClient from pymongo import MongoClient, ASCENDING, UpdateOne, InsertOne, DeleteOne, ReplaceOne from pymongo.errors impor... 阅读全文
posted @ 2019-04-13 16:32 Adamanter 阅读(3539) 评论(0) 推荐(0) 编辑
摘要: import time import datetime from bson.objectid import ObjectId from collections import Iterator class MyIter(Iterator): def __next__(self): return ObjectId() published_at = datetime.da... 阅读全文
posted @ 2019-04-13 16:23 Adamanter 阅读(279) 评论(0) 推荐(0) 编辑
摘要: from pymongo import MongoClientmdb = MongoClient('120.xxx.xxx.xxx:20002', username='xxx', password='xxx')# 数据240万# no_cursor_timeout=True代表连接不中断,连续取# 阅读全文
posted @ 2019-04-13 16:12 Adamanter 阅读(1262) 评论(0) 推荐(0) 编辑
摘要: es创建索引 es搜索 es类实现 阅读全文
posted @ 2019-04-13 15:52 Adamanter 阅读(626) 评论(0) 推荐(0) 编辑
摘要: import zlib post_id = "65fe4882de661f4a6e25391c790b6b86" post_id_crc32= zlib.crc32(post_id.encode("utf-8")) print(post_id_crc32) # 3217366125 阅读全文
posted @ 2019-04-13 15:42 Adamanter 阅读(3155) 评论(0) 推荐(0) 编辑
摘要: # coding=utf-8 import os import json import connexion from flask import jsonify app = connexion.FlaskApp(__name__, specification_dir='.') application = app.app # 测试配置 # application.config['SQLA... 阅读全文
posted @ 2019-04-13 15:27 Adamanter 阅读(349) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 ··· 17 下一页