Over the past few years, students taking my Perl/CGI course continued to ask me when I would be graduating from CGI
to PHP, and whether I would offer a course or write a PHP “by Example” book. I didn’t really take the idea of a book
seriously until
服务器端安装
安装服务器端:在终端中输入如下命令,回车后,然后按照提示输入
sudo apt-get install mysql-server
服务器用于接收客户端的请求、执行sql语句、管理数据库
服务器端一般以服务方式管理,名称为mysql
启动服务
sudo service mysql start
查看进程中是否存在mysql服务
ps ajx|grep mysql
停止服务
sudo service nysql stop
重启服务
sudo service mysql resta
Linux 服务器上的程序每天都在更新 MySQL 数据库,于是就想起写一个 shell 脚本,结合 crontab,定时备份数据库。其实非常简单,主要就是使用 MySQL 自带的 mysqldump 命令。
#!/bin/bash
# Shell scr ipt to backup MySql database
# To backup Nysql databases file to /backup dir and later pick up by your
# scr ipt. You c