Access your server via. online https SSH Client: https://c9.io
Btw, C9’s online IED is awesome, take a look it’s html editor:
Need to catch the exit code, handle the Error based on the exit code.
Use %ErrorLevel% – Almost all applications will set an exit code when complete (by conversion, 0 means successful).
Example 1:
copy file1.txt file3.txt
ECHO ...%ErrorLevel%
copy fileNotExisting.txt f.txt
ECHO %ErrorLevel%
Output:
“1 file(s) copied”
0
“The system cannot find the file specified.”
1
Example 2:
SET SSIS_EXIT_CODE=%ErrorLevel%
copy "%PKG_PATH%\Logs\….dtsx.log" ..
IF %SSIS_EXIT_CODE% NEQ 0 (
EXIT /B %SSIS_EXIT_CODE%
)
Links:
http://ss64.com/nt/errorlevel.html
http://ss64.com/nt/exit.html
How to check the exit code of the last command in batch file?
svnadmin dump ./repository/project > /home/backup/project_backup.svn.dump
manual: http://svnbook.red-bean.com/en/1.7/svn.ref.svnadmin.c.dump.html
PHP has a shell_exec command: “Execute command via shell and return the complete output as a string ” http://php.net/manual/en/function.shell-exec.php
And here is a project: http://phpshell.sourceforge.net/
PHP Shell is a shell wrapped in a PHP script. It’s a tool you can use to execute arbitrary shell-commands or browse the filesystem on your remote webserver. This replaces, to a degree, a normal telnet connection, and to a lesser degree a SSH connection.
You use it for administration and maintenance of your website, which is often much easier to do if you can work directly on the server. For example, you could use PHP Shell to unpack and move big files around. All the normal command line programs like ps, free, du, df, etc… can be used.
Download and config phpShell,, and then upload to your server, then you can run shell!
http://phpshell.sourceforge.net/
查看当前时区:
date –R
修改时区: 调整时区到东八区 – 北京时间
[root@localhost ~]# cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
cp: overwrite `/etc/localtime’? y
// Proudly powered by Apache, PHP, MySQL, WordPress, Bootstrap, etc,.