上一页 1 2 3 4 5 6 7 8 9 10 ··· 16 下一页
摘要: 解决方法:(1)使用linux命令dos2unix filename,直接把文件转换为unix格式(2)使用sed命令sed -i "s/\r//" filename 或者 sed -i "s/^M//" filename直接替换结尾符为unix格式(3)vi filename打开文件,执行 : s 阅读全文
posted @ 2020-05-20 14:55 RoyFans 阅读(196) 评论(0) 推荐(0) 编辑
摘要: 使用ntpdate比较简单。格式如下: [root@linux ~]# ntpdate [-nv] [NTP IP/hostname][root@linux ~]# ntpdate 192.168.0.1[root@linux ~]# ntpdate pool.ntp.org 但这样的同步,只是强制 阅读全文
posted @ 2020-04-27 10:01 RoyFans 阅读(1621) 评论(0) 推荐(0) 编辑
摘要: 特征如下: CPU占用一直比较高,初步分析是挖矿程序: 系统的crontab –l显示调度列表如下: 20 * * * * /root/.aliyun.sh >/dev/null 2>&1 查看脚本内容: #!/bin/bash exec &>/dev/null echo ZXhlYyAmPi9kZ 阅读全文
posted @ 2020-04-17 22:05 RoyFans 阅读(7700) 评论(1) 推荐(0) 编辑
摘要: TigerVNC使用非加密的链接,默认会被firewalld blocked 掉,想要 vnc正常工作就需要让firewalld开放相应的端口才行。 vnc默认的端口号为5900,而每个vnc window的端口号是: 5900+window_number(or,display_number) 如: 阅读全文
posted @ 2020-03-22 20:30 RoyFans 阅读(409) 评论(0) 推荐(0) 编辑
摘要: 新建一个文本picture.bat,输入 start snippingtool保存,双击,就可以截图了 阅读全文
posted @ 2020-03-20 21:02 RoyFans 阅读(750) 评论(0) 推荐(0) 编辑
摘要: 在linux系统的环境下,不管是root用户还是其它的用户只有登陆系统后用进入操作我们都可以通过命令history来查看历史记录,可是假如一台服务器多人登陆,一天因为某人误操作了删除了重要的数据。这时候通过查看历史记录(命令:history)是没有什么意义了(因为history只针对登录用户下执行有 阅读全文
posted @ 2020-03-10 15:49 RoyFans 阅读(384) 评论(0) 推荐(0) 编辑
摘要: elasticsearch启动时遇到的错误 问题翻译过来就是:elasticsearch用户拥有的内存权限太小,至少需要262144; 解决: 切换到root用户 执行命令: sysctl -w vm.max_map_count=262144 查看结果: sysctl -a|grep vm.max_ 阅读全文
posted @ 2020-03-04 10:46 RoyFans 阅读(506) 评论(0) 推荐(0) 编辑
摘要: 配置站点使用 https,将tomcat、Apache等服务 http 重定向至 https 1. nginx 的 ssl 模块安装 查看 nginx 是否安装 http_ssl_module 模块。 $ /usr/local/nginx/sbin/nginx -V 如果出现 configure a 阅读全文
posted @ 2020-02-26 15:42 RoyFans 阅读(586) 评论(0) 推荐(0) 编辑
摘要: 可能原因:文件已经删除,但是并没有释放,用lsof命令查看那些删除了但是还打开着文件句柄的文件 lsof | grep deleted | sort -nr 用kill 命令删除查询出的进程 阅读全文
posted @ 2020-02-19 21:41 RoyFans 阅读(1962) 评论(0) 推荐(0) 编辑
摘要: 目录: 1、Nginx运行工作进程数量 Nginx运行工作进程个数一般设置CPU的核心或者核心数x2。如果不了解cpu的核数,可以top命令之后按1看出来,也可以查看/proc/cpuinfo文件 grep ^processor /proc/cpuinfo | wc -l [root@lx~]# v 阅读全文
posted @ 2020-01-10 15:26 RoyFans 阅读(249) 评论(0) 推荐(0) 编辑
摘要: 一:下载 nginx安装包 wget -c https://nginx.org/download/nginx-1.10.1.tar.gz 二:解压nginx 安装包 tar -zxvf nginx-1.10.1.tar.gz 三:编译 nginx # cd nginx-1.10.1 ./config 阅读全文
posted @ 2020-01-09 11:26 RoyFans 阅读(188) 评论(0) 推荐(0) 编辑
摘要: 执行如下命令: 阅读全文
posted @ 2020-01-03 14:49 RoyFans 阅读(466) 评论(0) 推荐(0) 编辑
摘要: es 中定义date类型 插入时区需制定时区 查询es数据 阅读全文
posted @ 2020-01-03 09:59 RoyFans 阅读(3157) 评论(0) 推荐(0) 编辑
摘要: 一、现象 最近发现Mysql服务器磁盘IO一直很高 发现3307和3306实例占用IO最高,进入3307实例,查看sync_binlog变量 发现设置的是1,也就是说每次事务提交都会将binlog的缓存写入磁盘,严重影响磁盘效率,将变量设置为1000, 再查看innodb_flush_log_at_ 阅读全文
posted @ 2019-12-26 15:47 RoyFans 阅读(1960) 评论(0) 推荐(0) 编辑
摘要: #!/bin/bash # 删除元数据 rm -rf /var/lib/rabbitmq/mnesia # 重启rabbitmq rabbitmqctl stop systemctl restart rabbitmq-server # 添加用户 rabbitmqctl add_user admin 123456 rabbitmqctl set_user_tags admin administrat 阅读全文
posted @ 2019-12-19 14:26 RoyFans 阅读(1583) 评论(0) 推荐(0) 编辑
摘要: 问题描述 解决办法 Apache 阅读全文
posted @ 2019-12-18 17:41 RoyFans 阅读(3190) 评论(0) 推荐(1) 编辑
摘要: 1.先用ps查询进程号 ps -aux|grep 进程名字 2.查看更详细的内存占比 cat /proc/3664/status 返回结果:(其中VmRSS为进程所占用的内存) 阅读全文
posted @ 2019-12-12 20:11 RoyFans 阅读(8790) 评论(0) 推荐(0) 编辑
摘要: shell 脚本 用 crontab 设定定时任务 查看 crontab 日志 阅读全文
posted @ 2019-12-10 18:41 RoyFans 阅读(663) 评论(0) 推荐(0) 编辑
摘要: #!/bin/bash #1.查看物理cpu个数 physical=`cat /proc/cpuinfo |grep 'physical id'|sort -u|wc -l` echo 物理cpu个数: "$physical" #2.查看核心数量 core=`grep 'core id' /proc/cpuinfo | sort -u | wc -l` echo 核心数: "$core" #3.查 阅读全文
posted @ 2019-12-09 15:14 RoyFans 阅读(447) 评论(0) 推荐(0) 编辑
摘要: rabbitmqctl start_app启动没有这个问题 阅读全文
posted @ 2019-12-02 15:29 RoyFans 阅读(3083) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 10 ··· 16 下一页