- 博客(43)
- 收藏
- 关注
转载 Linux重启网卡出现“failed to start lsb:bring up/down networking”
查找原因发现是IP地址被占用所导致的错误。系统设置的是静态IP,该IP被其他设备使用,所以修改一下IP地址就解决了;
2020-11-10 23:03:05
1282
原创 VMware安装的Linux系统ping不通主机和网络
1.在VMware上安装好Linux系统后,发现ping不通主机。在“桥接模式”和“仅主机模式”下,无论是静态IP还是dhcp都ping不通。偶然发现ping局域网内的其他主机可以ping通。问题发现,关闭电脑上的防火墙,再试ping,成功;2.主机能ping通了,但网络ping不通,ping www.baidu.com,8.8.8.8出现[root@localhost ~]# ping www.baidu.comconnect: Network is unreachable[r.
2020-06-03 10:20:09
2171
原创 使用MySQL数据库时出现“Reading table information for completion of table and column names...”
mysql> show databases;+--------------------+| Database |+--------------------+| information_schema || mysql || performance_schema || sys || test_db_tw...
2020-04-07 12:01:01
1808
原创 Linux中使用ctrl+z停止任务后如何恢复任务
ctrl+z的作用是停止任务,要恢复停止的任务要使用fg命令[root@localhost ~]# jobs[1]+ 已停止 top[root@localhost ~]# fg 1fg [任务序号],直接用fg命令,恢复的是最新停止的一条任务...
2020-03-20 15:08:28
11996
原创 centOS7安装asterisk
1.下载asterisk,asterisk-1.8.7.1.tar.gz;2.安装所依赖的包:yum -y install libxml2-devel ncurses-devel libtermcap kernel-devel kernel-smp-devel gcc-c++ openssl-devel newt-devel zlib-devel unixODBC-devel libtool ...
2020-03-20 10:42:35
2287
转载 使用userdel删除用户时出现“userdel: user XXX is currently used by process XXX”
[root@localhost ~]# userdel sgtwyuserdel: user sgtwy is currently used by process 3703[root@localhost ~]# 原因是使用了su频繁转换用户解决方法:直接退出后重新登录root,然后userdel -r 用户名;或者Ctr+d退回到初始用户再使用userdel;...
2020-03-17 15:56:18
6723
原创 使用ssh远程登陆Parrot Sec
1.启用ssh服务:systemctl start ssh2.使用Xshell连接Parrot,出现“SSH服务器拒绝了密码,请再试一次”的vi /etc/ssh/sshd_config#LoginGraceTime 2m#PermitRootLogin prohibit-password#StrictModes yes#MaxAuthTries 6#MaxSessions 1...
2020-01-01 00:56:02
1005
原创 CentOS下IPv6的使用
1.查看是否支持IPv62.安装Apache后使用IPv6访问web,[fe80::4e36:ce45:a44d:4712]3.使用ping6来ping本地电脑本地电脑的IPv6为:fe80::4c23:f8ca:f5cb:1410ping6 fe80::4c23:f8ca:f5cb:1410%ens33(通过网卡ens33与本地电脑相连)4.ssh使用IPv6(1)用xshel...
2019-11-27 10:56:38
1459
原创 centOS7安装apache
1.安装httpdyum -y install httpd2. 启动httpdsystemctl start httpd3.设置httpd开机启动[root@localhost ~]# systemctl enable httpdCreated symlink from /etc/systemd/system/multi-user.target.wants/httpd...
2019-11-23 00:41:33
132
转载 python出现no module named 'win32api'
在控制台输入命令:pip install pypiwin32安装成功,问题解决
2019-06-18 09:17:42
1591
转载 SIP协议出现488 Not acceptable here
错误报文如下: SIP/2.0 488 Not acceptable here Via: SIP/2.0/UDP 192.168.100.3:5060;branch=z9hG4bK3c832484e202e1e6c7d6cfd4e60f8;received=192.168.100.3;rport=20000 From: "WinSIP 1" <sip:6008@192.16...
2019-06-05 13:30:41
24047
9
原创 linux下C语言编程
1.编译单个源文件test.cvi test.c #include<stdio.h> int main(){ printf("%s\n","tdfs"); }gcc -o test test.c 编译生成执行文件test; [root@localhost tests]# gcc -o test test.c [root@localhost tests]# ls te...
2019-05-06 14:17:52
517
原创 win10的MySQL8忘记密码
以管理员身份运行cmd(mysql目录下的文件夹bin已加入到环境变量中);先关闭MySQL服务:net stop mysql;再执行:mysqld --console --skip-grant-tables --shared-memory不要关闭该界面,重新以管理员身份运行cmd;更改密码退出重启MySQL服务:net start mysql;...
2019-05-05 23:10:01
1444
3
转载 SIP消息类型简介
1.请求消息:用于客户端为了激活按特定操作而发给服务器的SIP消息,包括INVITE,ACK,OPTIONS,BYE,CANCEL和REGISTER消息等。请求消息 消息含义 INVITE 发起会话请求 ACK 证实已收到对于INVITE请求的最终响应。该消息仅和INVITE消息配套使用 BYE 结束会话。 CANCEL 取消未完成的请求,对于已...
2019-04-30 17:20:19
5694
转载 SIP注册流程
SIP Phone的地址为:192.168.0.111;SoftX3000的地址为:192.168.0.122;基本流程如图所示:(1)SIP Phone发送一条不带认证信息的REGISTER;(2)服务器返回401(未授权);(3)SIP Phone客户端发送带有认证信息的REGISTER;(4)服务器进行验证, 合格返回200OK;SIP报文分析:(1)SIP Phone发...
2019-04-30 13:47:01
7186
转载 CentoS7安装MySQL
下载MySQL8复制链接[root@localhost /]# wget https://dev.mysql.com/get/mysql80-community-release-el7-2.noarch.rpm[root@localhost /]# yum -y localinstall mysql80-community-release-el7-2.noarch.rpm[root@l...
2019-04-11 21:59:16
377
转载 jsp页面引入外部js、CSS的方法
(1)NewFile.jsp与d.css、s.js在同一目录下<script type="text/javascript" src="s.js"></script><link id="css" rel="stylesheet" type="text/css" href="d.css" />(2)
2019-03-07 14:57:51
5774
转载 能使用firebug的火狐浏览器下载地址
https://archive.mozilla.org/pub/firefox/releases/39.0b2/win32/zh-CN/
2019-03-04 15:09:57
235
转载 jsp中引入js、css时出现net::ERR_ABORTED 404 (Not Found)错误
GET http://localhost:8080/static/My/Sub.js net::ERR_ABORTED 404 (Not Found)出现此问题主要是引入的js、css不起作用。相对路径引入&amp;lt;%@ page language=&quot;java&quot; contentType=&quot;text/html; charset=utf-8&quot; pageEncoding=&
2019-03-01 11:50:39
63545
5
转载 The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
鼠标右键项目-&gt;Build Path-&gt;Configure Build Path…-&gt;Libraries-&gt;Add Library…
2019-03-01 10:38:08
99
转载 centoS安装sipp出现的错误
1. configure: error: no acceptable C compiler found in $PATH主要是缺少C编译器[root@localhost sipp-3.5.1]# yum -y install gcc2.configure: error: ncurses library missing主要缺少ncurses库yum list|grep ncurses...
2019-02-26 13:38:32
942
转载 linux安装文件出现configure: error: no acceptable C compiler found in $PATH错误
configure: error: no acceptable C compiler found in $PATH错误主要是没有C编译器.安装C编译器:[root@localhost sipp-3.5.1]# yum -y install gcc重新安装文件,问题解决
2019-02-26 13:27:42
79485
6
转载 centoS7中,ens33没有显示ip
[root@localhost /]# cd /etc/sysconfig/network-scripts[root@localhost network-scripts]# lsifcfg-ens33 ifdown-eth ifdown-post ifdown-Team ifup-aliases ifup-ipv6 ifup-post ifup-Team ...
2019-02-26 11:54:31
2736
4
转载 QT:鼠标移动无外框窗口
mainwindow.h中:private: void mousePressEvent(QMouseEvent *event); void mouseMoveEvent(QMouseEvent *event);private: QPoint windowPos,mousePos,dPos;mainwindow.cpp中:void MainWindow::mo...
2019-01-14 23:59:50
187
转载 Linux(centos7)下忘记MySQL8密码
先关闭MySQL服务# systemctl stop mysqld进入my.cnf# vi /etc/my.cnf在[mysql] 下添加 skip-grant-table重启MySQL:# systemctl restart mysqld进入MySQL,修改密码# mysql -u root -pEnter password: //回车进入mysql&amp;amp;gt;use m...
2019-01-07 14:47:49
1265
转载 centos7安装MySQL后没有生成临时密码
在centos7安装MySQL后,/var/log/mysqld.log中没有生成临时密码# rm -rf /var/lib/mysqld# systemctl start mysqld# grep 'temporary password' /var/log/mysqld.log2019-01-07T10:38:33.469921Z 5 [Note] [MY-010454] [Server...
2019-01-07 12:09:35
7307
3
转载 SQLyog连接Linux中的MySQL8出现2058错误
# mysql -u root -pEnter password:mysql&gt;ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';'password’为MySQL的登录密码。
2019-01-07 12:01:57
1785
3
转载 SQLyog连接Linux中的数据库出现2003错误
出现2003错误是因为Linux没有开放3306端口。# iptables -L -n //查看开放的端口# iptables -A INPUT -p tcp --dport 3306 -j ACCEPT
2019-01-07 11:55:53
3594
转载 SQLyog连接数据库出现1130错误
修改root的连接限制,host=’%'为允许所有IP都有连接权限# mysql -u root -pEnter password:mysql&gt; use mysql;mysql&gt; select host from user where user='root';mysql&gt;update user set host='%' where user='root';mysql&...
2019-01-07 11:51:40
3027
转载 centos7安装MySQL8
1.下载地址:MySQL# wget https://dev.mysql.com/get/mysql80-community-release-el7-1.noarch.rpm如果没有wget命令,则需要安装:yum -y install wget2.安装mysql8:# yum -y localinstall mysql80-community-release-el7-1.noarc...
2019-01-07 11:38:57
143
原创 C语言函数--fread()、fwrite()的基本用法
fread():size_t fread(void *str,size_t size,size_t num,FILE stream);从文件中读取sizenum字节数据到str中.fwrite():size_t fwrite(void *str,size_t size,size_t num,FILE *stream);把str中的数据写入文件stream内;#include &lt;s...
2018-12-21 13:11:03
700
原创 C语言如何获取文件的长度?
#include <stdio.h>int main(){ FILE *fp = fopen("test.txt","w+"); int len ; char *p = "1234567"; fputs(p,fp);//向文件test.txt写入数据; rewind(fp);//将文件指针指向文件开头 fseek(fp,0,SEEK_END);//将文件指针指向文件的结尾...
2018-12-20 17:12:41
3667
原创 C语言函数--fscanf()、scanf()、sscanf()基本用法
fscanf()、scanf()、sscanf()都包含在<stdio.h>中fscanf():int fscanf(FILE *stream,const char *format,…);从流stream读取格式化输入。scanf():int scanf(const char *format,…);从标准输入stdin读取格式化输入。sscanf():int sscan...
2018-12-19 13:48:36
1722
原创 C语言函数--fprintf、printf、sprintf的基本用法
fprintf()、printf()、sprintf()都包含在&lt;stdio.h&gt;内fprintf():int fprintf(FILE *stream,const char *format,…);发送格式化输出到stream中。print():int printf(const char *format,…);发送格式化输出到标准输出stdout中。sprintf():...
2018-12-18 10:40:43
579
原创 Linux命令--systemctl
systemctl命令是系统服务管理器指令,它实际上将 service 和 chkconfig 这两个命令组合到一起。1.查看服务当前状态:systemctl status (serviceName),如:# systemctl status firewalld.service//查看防火墙是否已启动2.启动服务:systemctl start (serviceName),如:# sys...
2018-12-17 17:05:44
520
转载 eclipse突然出现启动闪退、打不开等问题
重启了一下电脑,eclipse突然打不开了,百度了一下解决了。打开eclipse安装目录下的eclipse.ini,将以下参数减小,-Xms512m-Xmx1024m修改为-Xms256m-Xmx512m
2018-12-11 14:52:00
498
转载 java图形界面swing:如何让窗口显示在显示屏中间
setLocationRelativeTo(Component c);这个函数可以将打开的窗口设置为居中显示,代码如下:public class f extends JFrame { /** * */ private static final long serialVersionUID = 1L; private JPanel contentPane; /** * La...
2018-11-30 13:34:38
3195
原创 Linux查询系统信息命令--uname
用法:uname [选项]…作用:输出系统的信息;-a 或 --all 显示全部的信息。-s 或 --sysname 显示操作系统名称。-n 或 --nodename 输出网络节点上的主机名-o 或 --operating-system 输出操作系统名称-r 或 --release 显示操作系统的发行编号。-v 或 --kernel-version 显示操作系统的版本。...
2018-11-30 09:38:33
292
原创 Linux中的文件含义和属性简介
Linux中文件的含义[root@localhost ~]# cd /[root@localhost /]# pwd/[root@localhost /]# cd ~[root@localhost ~]# pwd/rootroot为用户名,localhost为主机名,~为家目录(相当于/root/),/为根目录;[root@localhost /]# lsbin etc ...
2018-11-29 16:56:13
708
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人