ICode9

精准搜索请尝试: 精确搜索
  • apache如何开启反向代理?这篇完整教你如何配置2022-05-06 19:34:47

       什么是反向代理?     服务器根据客户端的请求,从其关联的一组或多组后端服务器(如Web服务器)上获取资源,然后再将这些资源返回给客户端,客户端只会得知反向代理的IP地址,而不知道在代理服务器后面的服务器簇的存在。     反向代理的特点:反向代理是供很多客户端都通过它间接

  • linux 系统中如何匹配指定数目的连续多个字符2022-05-05 17:34:33

      1、测试数据 root@PC1:/home/test2# ls test.txt root@PC1:/home/test2# cat test.txt attatgcccagggtttgttacttcagatgtgtccagagtttctcccttct ggcaggttcatggtcttgctcacttcaagaatgaagctgcagacatttac ggtgagtgttacagcacttatatttgttgtatccagagtttgttccttca gatgtgtccagaatttcttcc

  • linux 中 常用的条件判断语句2022-05-05 10:00:09

      测试文件 root@PC1:/home/test2# touch file.txt root@PC1:/home/test2# mkdir data root@PC1:/home/test2# ls data file.txt root@PC1:/home/test2# ll -h total 12K drwxr-xr-x 3 root root 4.0K 5月 5 08:54 ./ drwxr-xr-x 10 root root 4.0K 5月 1 20:56 ../ drwxr

  • test22022-05-03 11:33:23

    <?xml version="1.0" encoding="UTF-8"?> <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee htt

  • linux 中awk中数组实现逆向输出文件2022-05-01 13:04:14

      1、 root@PC1:/home/test2# ls a.txt root@PC1:/home/test2# cat a.txt a b c d a b e f c d c d m n root@PC1:/home/test2# awk '{a[i++]=$0} END {for(j = i - 1; j >= 0; j--) print a[j]}' a.txt m n c d c d e f a b c d a b   tac不香吗?  不过awk数组是真强大。

  • R语言中利用optparse包给函数传递参数2022-04-28 23:34:11

      1、 root@DESKTOP-1N42TVH:/home/test2# ls a.txt test.r root@DESKTOP-1N42TVH:/home/test2# cat test.r #!/usr/bin/Rscript library(optparse) option_list <- list( make_option(c("-a", "--aa"), type = "character"), make_op

  • eleastcsearch01-操作mapping2022-04-28 08:35:41

    # ElasticSearch version "number": "7.14.1" # 获取健康值 GET _cat/health?v # 获取所有的信息 GET _cat/indices?v # mappings信息======================================= # 创建test3索引 # mapping number_of_shards分片数 # number_of_replicas版本数 PUT /test3 {

  • QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'2022-04-27 01:01:51

      1、问题     2、解决方法 root@DESKTOP-1N42TVH:/home/test2# vim /etc/profile ## 在配置文件末尾追加如下两句 export XDG_RUNTIME_DIR=/usr/lib/ export RUNLEVEL=3   source一下: root@DESKTOP-1N42TVH:/home/test2# source /etc/profile    3、测试(刚才的问

  • linux 中调用shell脚本时指定工作目录为shell脚本所在的目录2022-04-26 23:34:22

      1、 root@DESKTOP-1N42TVH:/home/test# ls root@DESKTOP-1N42TVH:/home/test# ls /home/test2/* /home/test2/a.txt /home/test2/test.sh root@DESKTOP-1N42TVH:/home/test# cat /home/test2/test.sh ## shell脚本所在目录及内容 #!/bin/bash wc -l ./a.txt root@DESKTOP

  • linux 中 grep -q选项2022-04-24 18:01:18

      1、linux 中 grep -q选项表示静默输出, 即不显式匹配结果 root@DESKTOP-1N42TVH:/home/test2# ls a.txt root@DESKTOP-1N42TVH:/home/test2# cat a.txt ## 测试数据 d e j s q u z c b root@DESKTOP-1N42TVH:/home/test2# grep "s" a.txt ## 直接输出匹配结果

  • 玩转Mysql系列 - 第5天:DML操作汇总,确定你都会?2022-04-23 22:04:12

    对mysql感兴趣的,加一下我的微信itsoku,拉你入群交流技术。 这是Mysql系列第5篇。 环境:mysql5.7.25,cmd命令中进行演示。 DML(Data Manipulation Language)数据操作语言,以INSERT、UPDATE、DELETE三种指令为核心,分别代表插入、更新与删除,是必须要掌握的指令,DML和SQL中的select熟

  • Python基础语法(二十一)--闭包之装饰器2022-04-16 21:35:16

    装饰器 装饰器的原理就是闭包,调用方式不变 def test(func): print('----func----') def test2(): print('----test2这里是扩展功能----') func() return test2 @test def test1(): print('----test1----') test1() 执行流程图

  • 1143. 最长公共子序列2022-04-08 18:31:22

    ✅做题思路or感想 经典子序列问题,都适合用动态规划来解 子序列默认不连续,子数组默认连续! dp数组含义 子序列的题一般都这样子定义dp数组:dp[i][j]表示在test1的[0, i - 1]和test2的[0, j - 1]上最长的子序列长度(注意这里是范围里的最长子序列长度!) 为什么要这样子定义呢,因为这样子

  • linux中一次性计划任务服务at命令2022-04-06 09:31:26

      1、创建计划任务服务 [root@centos7pc1 test2]# ls [root@centos7pc1 test2]# date Wed Apr 6 17:16:12 CST 2022 [root@centos7pc1 test2]# at now+2 min ## 设置任务时间, 2分钟后 at> touch a.txt ## 设置执行的命令 at> <EOT> ## ctrl + D job

  • linux 中 case条件测试语句2022-04-06 09:01:38

      1、 [root@centos7pc1 test2]# ls test.sh [root@centos7pc1 test2]# cat test.sh ## 测试脚本 #!/bin/bash read -p "please input an number or an letter: " KEY case $KEY in [a-z]|[A-Z]) echo "You had entered an letter!" ;; [0-9]) echo "Y

  • linux 中awk命令计算每行数据的和、平均数、最大值、最小值2022-04-04 01:01:14

      1、测试数据 root@DESKTOP-1N42TVH:/home/test2# ls a.txt root@DESKTOP-1N42TVH:/home/test2# cat a.txt 3 1 4 2 1 2 6 3 2 1 3 3   2、计算每行数据的和 root@DESKTOP-1N42TVH:/home/test2# cat a.txt 3 1 4 2 1 2 6 3 2 1 3 3 root@DESKTOP-1N42TVH:/home/test2# awk '

  • linux 中 awk NF的作用2022-04-04 00:39:49

      1、删除空行 root@DESKTOP-1N42TVH:/home/test2# ls a.txt root@DESKTOP-1N42TVH:/home/test2# cat a.txt df gfdg df gg er fd gg ww kkkk jjjj root@DESKTOP-1N42TVH:/home/test2# cat -A a.txt df gfdg$ $ df gg er$ ^I^I$ fd gg ww$ ^I^I$ kkkk jjjj$ root@DESKTOP-

  • koa test22022-03-27 20:31:27

    async function run(){ const koa = require('koa') const Router = require('koa-router') const Static = require('koa-static-cache') const mysql=require('mysql2/promise') const bodyparser=require(�

  • 使用uniq命令求并集交集差集2022-03-26 19:00:42

    原创:打码日记(微信公众号ID:codelogs),欢迎分享,转载请保留出处。 uniq uniq是linux上非常有用的一个命令,从字面意思上就能看出来,它可以用来去重。  但使用uniq的前提是文件是排好序的,所以我们经常会搭配sort排序命令来一起使用uniq,如下: $ cat test.txt c a a b $ sort test.txt

  • While控制器2022-03-20 21:35:42

    Condition (function or variable) :条件(函数或变量)。条件为 Flase 的时候,才会跳出 While 循环,否则一直执行 While 控制器下的样例。         1、不填(空):当 While 控制器下最后一个样例执行失败后 跳出循环 test1、test2、test3,都能运行成功,会一直运行下去,陷入死循环    te

  • ElasticSearch的基操和进阶查询2022-03-18 22:58:04

    一,ElactisSearch简介 1. 定义 ElasticSearch是一个基于Lucene的搜索服务器。它提供了一个分布式多用户能力的全文搜索引擎,基于RESTful web接口。Elasticsearch是用Java开发的,并作为Apache许可条款下的开放源码发布,是当前流行的企业级搜索引擎。设计用于云计算中,能够达到实时搜索

  • test22022-03-10 11:01:39

    @Override public String getStatSql() { StringBuilder sqlAppender = new StringBuilder("SELECT STATUS as status, count( * ) as value" + " FROM (SELECT a.prodcode, b.expiredtime," + " CASE

  • vue项目添加html页面 并跳转2022-03-06 07:00:06

    vue项目中,把已经写好的html直接放进去,而不经过编译,直接跳转html页面 项目根目录里,如果有public文件夹,则直接放进public文件夹里,与index.html 同级开始,按照项目路径访问。 例如:在public新建pages/test.html, 则: 浏览器访问路径是: http://host:port/pages/test.html 注意,此时tes

  • nginx: [emerg] duplicate upstream "test2" in /usr/local/nginx/conf/sites-enabled/test2.con2022-02-21 15:04:08

    使用/usr/local/nginx/sbin/nginx -t 检查nginx配置文件时报错: nginx: [emerg] duplicate upstream "test2" in /usr/local/nginx/sites-enabled/test2.conf:1 nginx: configuration file /usr/local/nginx/conf/nginx.conf test failed   原因:有相同名称的upstream,可以grep查

  • @Transactional同类方法调用不生效及解决方法2022-02-21 01:01:24

    同一个类中方法调用会可能导致@Transactional失效 同类中方法test1调用方法test2,test1没有声明注解事务,而test2方法有。则外部调用test1之后,方法test2的事务是不会起作用的。 转载:https://blog.csdn.net/weixin_38898423/article/details/113835501?utm_medium=distribute.pc_

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有