Linux如何添加可用空间到一个分区
df -k
显示所有分区的可用空间和已用空间
找到分区使用率将近100%的分区
sudo vgdisplay
这个命令显示的是有多少空间还没有被分配,如果显示vgdisplay: command not found 则需要安装lvm2, ubuntu下可以执行sudo apt-get install lvm2来进行安装
(Free PE / Size 19183 / 74.93 GB 表示你可以添加74.93G)
sudo lvextend -L+20G /dev/vg/home
这个命令会添加20G空间到home分区,这20G空间是从上面的74.93G未分配空间中取得的
相关文档:
1. HCI层协议概述:
HCI提供一套统一的方法来访问Bluetooth底层。如图所示:
从图上可以看出,Host Controller Interface(HCI) 就是用来沟通Host和Module。Host通常就是PC, Module则是以各种物理连接形式(USB,serial,pc-card等)连接到PC上的bluetooth Dongle。
在Host这一端:application,SDP,L2cap等协议 ......
#include <errno.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <stdlib.h>
#include <string.h>
#include <netinet/in.h>
#include <stdio.h>
#include <unistd.h>
#include <sys/types.h>
#include <s ......
/******************************
*
* server.c
*
******************************/
#include<stdio.h>
#include<stdlib.h>
#include<sys/socket.h>
#include<sys/types.h>
#include<errno.h>
#include<string.h>
#include<netinet/in.h>
#include<sys/wait.h> ......
1. 创建目录
mkdir –p test/sub
2. 在子目录sub/下编写hello.c和hello.h
/*****hello.c*****/
#include <stdio.h>
#include “hello.h”
void hello()
{
printf(“Hello!\n”);
}
/*****hello.h**** ......
存储管理
MMU与内核内存管理的关系
从线性地址到物理地址的映射,通过页目录表和页表来实现的。
内核为存储管理维护了一套复杂的数据结构,页目录表和页表是主要的结构之一。这些表也是存储在物理内存页面中的,因此,也是以4K为单位。
表中的每个表项都记录了一个32位的地址,为4个字节,因此,一个表中最多可以有1K项 ......