苦于备份网站数据库相当麻烦,还要去ftp导出,所以问问
谁做过什么程序,可以一键导出某网站的数据库的数据,,弄成压缩文件,下载
回复讨论(解决方案)
win 下的嘛? 自己写个bat 文件.来处理. 备份 压缩 复制文件到FTP目录
怎么写???
::……………………………………………………………………………………………………………………………………………………………………………………………………………………………
:: 版本:BACKDATESYSTEM V1.0
:: 功能:用于系统平台备份程序及数据
:: 特点:按当前日期生成文件名
:: pathback、pathSource、pathdatabase、filename、password、letter(接下行)
:: (接上行)baklogPath、bakdatabase、bakdatatime、baktimeStart分别为(接下行)
:: (接上行)备份路径、源路径、数据库路径、备份文件前缀名、密码 (接下行)
:: (接上行)WinRAR安装盘符、日志路径、数据库名、SQL自动备份时间、文档时间
:: bak_ftpServer、bak_ftpUserName、bak_ftpUserPass为FTP地址、用户及密码
::……………………………………………………………………………………………………………………………………………………………………………………………………………………………
set pathback=F:\WebSiteBack\
set PathSource=E:\WebSite\GjWebSite
:: set pathdatabase=E:\Project\WebSite_AspNet\AspNet_Test008\DB_2005
set filename=Andy_WebSite_
set password=wuyi
set letter=d:
set baklogPath=F:\WebSiteBack\Log\
set baktimeStart=%time:~0,2%%time:~3,2%%time:~6,2%%time:~9,2%
set bakdate=%date:~0,4%%date:~5,2%%date:~8,2%
:: set bakdatabase=dg_gongjiao
:: set bakdatatime=1126
:: ftp 相关参数
:: set bak_ftpServer=200.0.0.0
:: set bak_ftpUserName=test
:: set bak_ftpUserPass=test123456
:: del %pathback%%filename%*.rar
%letter%\Progra~1\WinRAR\WinRAR.exe a -inul -p%password% %pathback%%filename%%bakdate%%baktimeStart% %pathSource%
echo -- 压缩完成,生成%filename%%bakdate%%baktimeStart%.rar …… [%date% %time%] >%baklogPath%log_%bakdate%.txt
:: echo -- 开始上传 …… [%date% %time%] >>%baklogPath%log_%bakdate%.txt
:: echo open %bak_ftpServer% >ftp.andy
:: echo %bak_ftpUserName%>>ftp.andy
:: echo %bak_ftpUserPass%>>ftp.andy
:: echo bin >>ftp.andy
:: 是否以天创建文件夹
:: echo mkdir %bakdate% >>ftp.andy
:: echo cd %bakdate% >>ftp.andy
:: echo mput %pathback%%filename%*.rar >>ftp.andy
:: echo bye >>ftp.andy
:: FTP -s:ftp.andy -i >>%baklogPath%log_%bakdate%.txt
:: del ftp.andy /q
:: rem Xcopy %bak_tmpFile%* %pathback%%filename% /y
:: del %pathback%%filename%*.rar /q /s
:: rd %pathback% /q
:: echo -- 上传完成 [%date% %time%]-- >>%baklogPath%log_%bakdate%.txt
四五年前备份net时的bat,参考!
这么深奥。。能不能太浅显点。。。
没做过,ftp不是自带下载吗?何必呢?

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

Alipay PHP...

JWT is an open standard based on JSON, used to securely transmit information between parties, mainly for identity authentication and information exchange. 1. JWT consists of three parts: Header, Payload and Signature. 2. The working principle of JWT includes three steps: generating JWT, verifying JWT and parsing Payload. 3. When using JWT for authentication in PHP, JWT can be generated and verified, and user role and permission information can be included in advanced usage. 4. Common errors include signature verification failure, token expiration, and payload oversized. Debugging skills include using debugging tools and logging. 5. Performance optimization and best practices include using appropriate signature algorithms, setting validity periods reasonably,

Session hijacking can be achieved through the following steps: 1. Obtain the session ID, 2. Use the session ID, 3. Keep the session active. The methods to prevent session hijacking in PHP include: 1. Use the session_regenerate_id() function to regenerate the session ID, 2. Store session data through the database, 3. Ensure that all session data is transmitted through HTTPS.

The application of SOLID principle in PHP development includes: 1. Single responsibility principle (SRP): Each class is responsible for only one function. 2. Open and close principle (OCP): Changes are achieved through extension rather than modification. 3. Lisch's Substitution Principle (LSP): Subclasses can replace base classes without affecting program accuracy. 4. Interface isolation principle (ISP): Use fine-grained interfaces to avoid dependencies and unused methods. 5. Dependency inversion principle (DIP): High and low-level modules rely on abstraction and are implemented through dependency injection.

How to debug CLI mode in PHPStorm? When developing with PHPStorm, sometimes we need to debug PHP in command line interface (CLI) mode...

How to automatically set the permissions of unixsocket after the system restarts. Every time the system restarts, we need to execute the following command to modify the permissions of unixsocket: sudo...

Static binding (static::) implements late static binding (LSB) in PHP, allowing calling classes to be referenced in static contexts rather than defining classes. 1) The parsing process is performed at runtime, 2) Look up the call class in the inheritance relationship, 3) It may bring performance overhead.

Sending JSON data using PHP's cURL library In PHP development, it is often necessary to interact with external APIs. One of the common ways is to use cURL library to send POST�...
