摘要: 进程 1. fork , waitpid 测试: 2. 守护进程: 阅读全文
posted @ 2019-06-20 17:39 panda_w 阅读(287) 评论(0) 推荐(0)
摘要: 线程 1.线程自动分离,常用方法: 2.线程手动分离,用来了解: 测试: success ! <笔记> 1. 阅读全文
posted @ 2019-06-20 16:33 panda_w 阅读(315) 评论(0) 推荐(0)
摘要: 信号量_实现共享内存 1.sem.h #ifndef __SEM_H__ #define __SEM_H__ #include <stdio.h> #include <sys/types.h> #include <sys/ipc.h> #include <sys/sem.h> #include <s 阅读全文
posted @ 2019-06-20 12:04 panda_w 阅读(295) 评论(0) 推荐(0)
摘要: 有名管道 1.client 2.server success ! 阅读全文
posted @ 2019-06-19 16:18 panda_w 阅读(461) 评论(0) 推荐(0)
摘要: 无名管道 success ! 阅读全文
posted @ 2019-06-19 15:17 panda_w 阅读(369) 评论(0) 推荐(0)
摘要: 消息队列 1.头文件 #ifndef __MSG_H__ #define __MSG_H__ #include <sys/types.h> #include <sys/ipc.h> #include <sys/msg.h> #include <stdio.h> #include <stdlib.h> 阅读全文
posted @ 2019-06-19 14:23 panda_w 阅读(340) 评论(0) 推荐(0)
摘要: 共享内存 1.头文件 #ifndef __SHM_H__ #define __SHM_H__ #include <sys/types.h> #include <sys/stat.h> #include <fcntl.h> #include <sys/ipc.h> #include <sys/shm. 阅读全文
posted @ 2019-06-19 09:26 panda_w 阅读(484) 评论(0) 推荐(0)
摘要: ubunt 配置vim 添加行号 set nu 自动换行 set autoindent 设置Tab set tabstop=4 突出显示当前行 set cursorline 在右下角显示光标位置的状态行 set ruler 阅读全文
posted @ 2019-06-18 09:38 panda_w 阅读(239) 评论(0) 推荐(0)
摘要: 修改ubunt主机名和用户名 修改主机名: 1.修改hostname文件 2.修改hosts文件 (问题:如果主机名错误将会打印:无法解析主机*****) 3. 重启: 修改用户名: 1. 修改sudoer文件(一定要写,不然后悔!) 名字赋予较高的权限,防止修改下面文件的过程中出现权限不足 2.修 阅读全文
posted @ 2019-06-17 15:03 panda_w 阅读(554) 评论(0) 推荐(0)
摘要: TCP 代码示例:https://www.cnblogs.com/panda-w/p/11063829.html UDP 代码示例:https://www.cnblogs.com/panda-w/p/11063834.html UDP : 1.点对点,无连接,无应答,不根据网络好还调整分组数据大小 阅读全文
posted @ 2019-06-16 11:17 panda_w 阅读(305) 评论(0) 推荐(0)