码迷,mamicode.com
首页 >  
搜索关键字:file system check    ( 106627个结果
PHP2014-5-12的总结
PHP上传文件1:上传文件的三步骤: (1):$_FILES("upload");//upload:他是一个二维数组 (2):判断是否有文件上传:$_upload(File) (3):将文件上传到服务器:move_uploaded_file();2:if(is_uploaded_fil...
分类:Web程序   时间:2014-05-14 02:57:10    阅读次数:389
读取文件
public String BufferedReaderDemo(String path) throws IOException...{File file=new File(path);if(!file.exists()||file.isDirectory())throw new FileNotFo...
分类:其他好文   时间:2014-05-14 02:16:11    阅读次数:199
Leetcode 树 Same Tree
本文为senlie原创,转载请保留此地址:http://blog.csdn.net/zhengsenlie Same Tree  Total Accepted: 15922 Total Submissions: 38418 Given two binary trees, write a function to check if they are equal o...
分类:其他好文   时间:2014-05-14 01:15:40    阅读次数:293
mysql主从检测脚本
#!/bin/bash #checkmysqlslavestatus USER="check" PSW="***" RUNTIME=3600 ADDR="192.168.*.*" declare-aslave_is forIPin$ADDR do slave_is=($(/usr/local/mysql/bin/mysql-h$IP-u${USER}-p${PSW}-e"showslavestatus\G"|grepRunning|awk‘{print$2}‘)) if["${slave_is[0]}"="Y..
分类:数据库   时间:2014-05-13 04:33:44    阅读次数:374
graphite,python监控网卡流量
#!/usr/bin/envpythonimportsys,timefromsocketimportsocketdefread_interface(in_file):withfile(in_file)asf:returnf.readlines()[2:]defset_interface(inter_msg):dic={}foriinxrange(len(inter_msg)):dic[inter_msg[i].split(":")[0].strip()]={"in":inter_msg[i].split(":..
分类:编程语言   时间:2014-05-13 04:01:55    阅读次数:432
python自定义查找文件内容
#!/usr/bin/envpython#coding:utf8#此脚本为查找递归目录下所有文件匹配的内容importos,sys,tabdefpaths(path):list_path=os.walk(path)all_file=[]forp,d,flinlist_path:forfinfl:pfile=os.path.join(p,f)ifos.path.isdir(pfile):paths(pfile)all_file.append(pfile)returnall..
分类:编程语言   时间:2014-05-13 03:49:34    阅读次数:426
python管理mysql,请叫我雷锋
#!/usr/bin/envpython#coding:utf8importos,sys,glob,time,MySQLdb,reDIRNAME=os.path.dirname(__file__)OPSTOOLS_DIR=os.path.abspath(os.path.join(DIRNAME,‘..‘))sys.path.append(OPSTOOLS_DIR)fromlibrary.mysqlconfigimportMySQLDConfig,getMyVariablesfromoptparseimport..
分类:数据库   时间:2014-05-13 02:46:59    阅读次数:809
微软私有云分享(R2)7-Linux虚拟机无DNS?
上一章我们说到一个悲剧,通过SCVMM2012R2(已知的2012SP1也有这个毛病)部署Linux虚拟机没有配网关,这在生产中会产生一些小问题。解决起来很简单,但是对Linux不熟的用户肯定不知道,另外这个毛病存在于中文版的SCVMM2012R2中,其他语言不明============小技巧解决大悲剧====..
分类:系统相关   时间:2014-05-13 02:41:50    阅读次数:366
微软私有云分享(R2)6-Linux的自动化部署
WindowsServer2012R2对Linux的支持变得越来越多了,用SCVMM2012R2部署Linux(如CentOS)显得更有价值,比如支持动态内存,运行效率更高等等。在SCVMM2012R2中部署Linux和Windows有很大差异,你以为"下一步"不停点下去就能搞定么?那是不可能的。=====前置条件========新手通过S..
分类:系统相关   时间:2014-05-13 02:22:24    阅读次数:462
python批量同步web服务器代码核心程序
#!/usr/bin/envpython#coding:utf8importos,sysimportmd5,tabfrommysql_co.my_dbimportset_mysqlfromssh_co.ssh_connectimportsshdfromssh_co.cfg.configimportssh_message,item_pathfromfileimportfindfiledefmy_mysql():db_file={}my_connect=set_mysql()f_file=findfile.mai..
分类:编程语言   时间:2014-05-13 01:44:22    阅读次数:449
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!