共 24 篇文章 |
|
find ./ -name "*.html" -exec grep "www.ununu.cn" {} \; -exec sed -i ''s/www.ununu.cn/ununu.cn/g'' {} \;结合find 和sed可以实现,下面写一个:递归查找目录下所有的html文件,并把文件中的“www.ununu.cn”字符串替换成"ununu.cn":find ./ -type f -name ''*.html''|xarg... 阅1541 转9 评0 公众公开 18-02-10 11:28 |
第一步 mysql的安装配置,使用Navicat访问。yum install mysql-server //安装mysql服务端。yum install mysql //安装mysql客户端。使用 mysql -uroot -hyourserverhost 登陆mysql 假如说我的server host是192.168.1.1 那么我使用。安装mysql的时候 已经默认建立了一个叫mysql的数据库 我们进入这个数据库。需要安装 php-mysql 客户端 yum -y in... 阅250 转1 评0 公众公开 17-05-22 11:51 |
第二步 使用mysqldump 和 crontab定时任务定时备份数据库。解释下这句命令 使用username:root,password:123456 登陆数据库 mysql 将mysql数据库中的host 和user表备份到/home/1.sql 这个文件。在/home/下新建一个脚本 vim 2.sh 然后保存退出 ,将脚本权限改成可执行 chrom 777 2.sh 然后编辑2.sh 在里边写入。 阅79 转0 评0 公众公开 17-05-22 11:46 |
Linux下Mysql数据库忘记root密码的解决办法。[root@Server mufan]# mysql -u root.mysql> use mysql.更新mysql数据库中的user表的root的password字段。mysql> update user set password=PASSWORD("new_password") where User="root";刷新权限,使其立即生效,之后退出mysql,并重新启动mysql.# mysql -uroot -penter... 阅135 转0 评0 公众公开 15-12-19 01:54 |
linux git clone权限被拒绝2 检查SSH公钥cd ~/.ssh。不存在的请看下一步3 生成SSH公钥$ ssh-keygen -t rsa -C "your_email@youremail.com" # Creates a new ssh key using the provided email Generating public/private rsa key pair. Enter file in which to save the key (/home/you/.ssh/id_rsa):打开github,找到账户里面添加SS... 阅3029 转3 评0 公众公开 15-12-17 15:11 |
阅121 转1 评0 公众公开 15-12-17 14:14 |
网页转图片,html生成图片,网页生成图片(基于linnux+phantomjs)安装扩展: (1)下面是我在linux上的安装过程,如果没有安装git请先yum install git 安装casperjs cd / git clone git://github.com/n1k0/casperjs.git cd casperjs ln -sf /casperjs/bin/casperjs /usr/local/bin/casperjs //可以忽略 实际执行中php是执行 /casper... 阅636 转1 评0 公众公开 15-12-17 14:10 |
linux centos安装编译phantomjs 2.0的方法。linux centos 安装编译phantomjs 2.0的步骤:1、 先安装这些支持:sudo yum -y install gcc gcc-c++ make flex bison gperfruby openssl-devel freetype-devel fontconfig-devel libicu-devel sqlite-devel libpng-devel libjpeg-devel2、 装好了上面的支持服务再在服务器上编译:git clone git://gi... 阅122 转0 评0 公众公开 15-12-17 14:10 |
阅41 转0 评0 公众公开 15-12-08 09:57 |
Linux中重启的两个命令:reboot和init 6之间的区别init命令用于改变操作系统的运行级别。我们应该在通常情况下使用 init 6.reboot - reboot performs a sync(1M) operation on the disks, and then amulti- user reboot is initiated. See init(1M) for details.init 6 Stop the operating system and reboot to thestate defined by the initd... 阅279 转0 评0 公众公开 15-12-04 16:06 |