凉城旧巷
Python从入门到自闭,Java从自闭到放弃,数据库从删库到跑路,Linux从rm -rf到完犊子!!!
上一页 1 ··· 12 13 14 15 16 17 18 19 20 ··· 32 下一页
摘要: Dockerfile编写 一、基础语法 https://www.cnblogs.com/linagcheng/p/13440287.html#%E5%9B%9B%E3%80%81dockerfile%E7%BC%96%E5%86%99 FROM ubuntu:18.04 # 指定基础镜像,必须是第一 阅读全文
posted @ 2020-08-05 20:20 凉城旧巷 阅读(452) 评论(0) 推荐(0)
摘要: Docker 部署项目 一、安装docker(Ubuntu) 转自:https://blog.csdn.net/jinking01/article/details/82490688 由于apt官方库里的docker版本可能比较旧,所以先卸载可能存在的旧版本: $ sudo apt-get remov 阅读全文
posted @ 2020-08-05 15:40 凉城旧巷 阅读(1000) 评论(0) 推荐(0)
摘要: Django ORM级联不会在表中真正创建 案例 django models层 from django.db import models class Publish(models.Model): name = models.CharField('出版社名', max_length=50) addre 阅读全文
posted @ 2020-08-03 15:12 凉城旧巷 阅读(367) 评论(0) 推荐(0)
摘要: MySQL排序内存溢出 案例 MySQL中: Django项目中: 原因 SHOW VARIABLES LIKE '%sort_buffer_size%'; 图中的sort_buffer_size为256*1024,太小 解决方案 修改sort_buffer_size SET GLOBAL sort 阅读全文
posted @ 2020-08-03 10:06 凉城旧巷 阅读(309) 评论(0) 推荐(0)
摘要: 一、case 1 案例 # time datetime类型 def update_db(table_name,name,t): sql='update table {} set name={}, time={}'.format(table_name,name,t) 原因 当最外面引号被去掉后,第三个 阅读全文
posted @ 2020-07-22 11:15 凉城旧巷 阅读(493) 评论(0) 推荐(0)
摘要: xpath解析table 案例 使用xpath解析,结果可能是[]空列表 xpath('//table[@id="cvssscorestable"]/tbody/tr[2]/th/text()') 原因 在用xpath解析网页的时候,会遇到tbody标签。tbody标签有的时候可以解析,有的时候不可 阅读全文
posted @ 2020-07-20 17:33 凉城旧巷 阅读(5144) 评论(0) 推荐(2)
摘要: ubuntu自启动服务脚本 参考链接:https://blog.csdn.net/qq_29663071/article/details/80814081 1、创建一个service文件 进入/etc/systemd/system/,创建一个my.service文件,内容如下 [Unit] Desc 阅读全文
posted @ 2020-07-13 10:08 凉城旧巷 阅读(1389) 评论(0) 推荐(0)
摘要: 问题 数据库链接丢失异常 django.db.utils.OperationalError: (2013, 'Lost connection to MySQL server during query') 查询mysql全局变量SHOW GLOBAL VARIABLES;可以看到wait_timeou 阅读全文
posted @ 2020-07-10 16:34 凉城旧巷 阅读(5216) 评论(0) 推荐(1)
摘要: logging模块 import logging # 1.生成一个logger对象 logger = logging.getLogger() # 2.设置日志格式 formatter = logging.Formatter(fmt="%(asctime)s - %(levelname)s : %(m 阅读全文
posted @ 2020-06-08 19:45 凉城旧巷 阅读(768) 评论(0) 推荐(0)
摘要: nmap Ex: scanme.nmap.org, microsoft.com/24, 192.168.0.1; 10.0.0-255.1-254 TARGET SPECIFICATION: Can pass hostnames, IP addresses, networks, etc. Ex: s 阅读全文
posted @ 2020-06-02 21:01 凉城旧巷 阅读(2532) 评论(0) 推荐(0)
上一页 1 ··· 12 13 14 15 16 17 18 19 20 ··· 32 下一页