file/filetype.c #include "apue.h"intmain(int argc, char *argv[]){ int i; struct stat buf; char *ptr; for (i = 1; i < argc; i++) { printf("%s: ", argv[...
分类:
其他好文 时间:
2014-07-18 23:38:27
阅读次数:
412
lib/setfl.c #include "apue.h"#include voidset_fl(int fd, int flags) /* flags are file status flags to turn on */{ int val; if ((val = fcntl(fd, F_GETF...
分类:
其他好文 时间:
2014-07-18 23:38:21
阅读次数:
333
file/hole.c #include "apue.h"#include char buf1[] = "abcdefghij";char buf2[] = "ABCDEFGHIJ";intmain(void){ int fd; if ((fd = creat("file.hole", FILE_M...
分类:
其他好文 时间:
2014-07-18 23:35:26
阅读次数:
193
file/fileflags.c #include "apue.h"#include intmain(int argc, char *argv[]){ int val; if (argc != 2) err_quit("usage: a.out "); if ((val = fcntl(atoi(a...
分类:
其他好文 时间:
2014-07-18 23:28:24
阅读次数:
203
file/seek.c#include "apue.h"intmain(void){ if (lseek(STDIN_FILENO, 0, SEEK_CUR) == -1) printf("cannot seek\n"); else printf("seek OK\n"); exit(0);}
分类:
其他好文 时间:
2014-07-18 23:27:20
阅读次数:
187
1.递归遍历所有文件 并在控制台输出
2.获取某个绝对地址文件目录下的以txt结尾的文件 递归遍历获取file存到list中 然后用用流写到自己创建的文件中
import java.io.*;
import java.util.ArrayList;
import java.util.List;
public class file {
/**
* @param args
*...
分类:
其他好文 时间:
2014-07-18 23:01:20
阅读次数:
246
用oracle账号登陆ORACLE数据库服务器
方法一:
查看表空间的名字及文件所在位置:
select tablespace_name, file_id, file_name,round(bytes/(1024*1024),0) total_space
from dba_data_files order by tablespace_name;
修改数据库dat...
分类:
数据库 时间:
2014-07-18 22:24:47
阅读次数:
435
Iceberg是Mac下比较好用的pkg生成工具。
在files中选择你想要存放(自己文件的文件夹),生成pkg后文件夹就会存储在设置的那个文件夹下。
点击scripts选择pkg安装各个阶段所要执行脚本路径。...
分类:
其他好文 时间:
2014-07-18 21:30:46
阅读次数:
898
获取SD卡的总空间和可用空间
File path = Environment.getExternalStorageDirectory();
StatFs stat = new StatFs(path.getPath());
long blockSize = stat.getBlockSize();
long totalBlocks = stat.getBlockCount();
long ava...
分类:
移动开发 时间:
2014-07-18 21:22:16
阅读次数:
247
nagios配置文件生成htpasswd/etc/nagios/passwdnagiosadminidentity资产唯一编号chmod444/etc/assetid接口要写的健壮接口判断值是否全面批量的生成ip,主机名,其它项都一致pipinstall‘ipython<2.0‘CURR_DIR=os.path.abspath(os.path.dirname(__file__))当前这个文件名所在..
分类:
移动开发 时间:
2014-07-17 08:14:03
阅读次数:
323