size[Root @ rehat root] # du-shNO2.View the size of subfolders in the current file and file[Root @ rehat root] # du-chNO3.View the file size[Root @ rehat root] # du-h test1.txtNO4.View the size of multiple files at the same time[Root @ rehat root] # du-h test1.txt test2.txt9. disk fragmentationIn linux, there is basically no need for fragment. it will be automatically organized at intervals.10. create/change a file systemNO1. create a file system type[Root @ rehat root] # umount/dev/sdb1[Root @
After redhatssh password-free logon settings, the system prompts you to enter the password. after several days, you cannot figure out why you set the password. ssh Directory. after the key is set in authorized_keys, you are prompted to enter the password. Find out what to do, and pay attention to the permissions. after setting password-free logon for... redhat ssh, you are prompted to enter the password.
This is the case. after several days, I cannot figure out why I set the. ssh directory and
However, MySQL has 700 permissions on the newly created database directory and 660 permissions on the data table file, which makes us confused. Does MySQL depend on the value set by the system? Reference
However, MySQL has 700 permissions on the newly created database directory and 660 permissions on the data table file, which makes us confused. Does MySQL depend on the value set by the system? Reference
transfer the content of pub to authorized_key. Pub files are useless.1. Use CRT to generate a key pair and upload the public key to linuxA. After successful login, the Public Key in the cpoyA machine is sent to machine B, so that the CRT can automatically log on to machine B and verify that the public key is universal.First, use CRT to generate the key:1. Use SecureCRT to create the private key and Public Key (Set Passphrase can be Set to an empty password for comparison verification)SecureCRT:
Create an automatic backup scriptHere, in order to make the database tutorial backup and recovery meet our actual requirements, use a Shell script that meets the requirements to automate the entire backup process.[Root @ CentOS ~] # Vi mysql tutorial-backup. sh scripts:
#! /Bin/bash
PATH =/usr/local/sbin:/usr/bin:/bin
# The Directory of BackupBACKDIR =/backup/mysql
# The Password of MySQLROOTPASS = ********* Replace the star number with the MySQL root Password.
# Remake the Directory of BackupRm
Directory of BackupRm-rf $ BACKDIRMkdir-p $ BACKDIR# Get the Name of DatabaseDBLIST = 'LS-p/var/lib/mysql | grep/| tr-d /'# Backup with DatabaseFor dbname in $ DBLISTDoMysqlhotcopy $ dbname-u root-p $ ROOTPASS $ BACKDIR | logger-t mysqlhotcopyDone
[2] Run the automatic database backup script
The Code is as follows:
[Root @ CentOS ~] # Chmod 700 mysql-backup.sh changes the script properties so that it can only be execu
After several days of hard work, I finally completed the Linux Enterprise Application-Linux server application information. The following is a detailed description. Customer requirements:
1. Provide the file server,
2. The windows system is required to be able to access the service.
3. Each department can only view its own folder, but not the folders of other departments.
4. Employees of each department have the permission to read and write Department folders.
5. disk quotas are required for fol
}
Collect:
= 700) window. open ('/upload/200743213556612.gif'); "src =" http://files.jb51.net/upload/200743213556612.gif "onload =" if (this. width> '200') this. width = '000000'; "border = 0>
Paging is successful, but there are too many waste codes. you have to change them!
Looking at the redundant code features, it seems that the filtering scope is not enough, and many of the following content should be filtered out. Well, move the filtering area
This article introduces the PHP concurrency lock example, to lock the data, only allow a user to operate within a time, this time need to use the lock, the need for friends to understand.
In the work project, you will encounter some PHP concurrent access to modify a data problem, if the data is not locked, it will cause data errors. Below I will analyze a financial payment lock problem. We hope to help you.
1 NO lock mechanism applied
1.1 Financial Payment Simplified version code
1.2 Problem
Read only = false
List = false
Hosts allow = 192.168.0.101/24
Hosts deny = 0.0.0.0/32
Auth users = backup
Secrets file =/etc/rsyncd. pwd
In a configuration file, uid and gid indicate the running identity. chroot indicates that the directory is automatically switched after the connection, and read only = false indicates that other clients are allowed to upload data to the server on the local machine. Host allow and deny are restricted connection addresses. Auth user is the authenti
security mode.
Disable php functions. For example, system, passthru, dl, exec, shell_exec, popen, phpinfo, proc_open, chmod, chown, chroot, dir, opendir, readdir, and scandir. I think it is very important. Even if you get the webshell permission, it is hard to mention it. The file listing function should also be disabled. dl is quite interesting.
5. apache Security
The uid user of the apache program. login is prohibited.
Disable some directories from executing php programs.
Php web application,
named vbird1 Based on the preset values.
[Root @ linux ~] # Useradd vbird1
[Root @ linux ~] # Ls-l/home
Drwxr-xr-x 3 vbird1 vbird1 4096 Aug 30 vbird1
[Root @ linux ~] # Grep vbird1/etc/passwd/etc/shadow/etc/group
/Etc/passwd: vbird1: x: 502: 502:/home/vbird1:/bin/bash
/Etc/shadow: vbird1 :!! : 13025: 0: 99999: 7 :::
/Etc/group: vbird1: x: 502:
# This example is just for you to understand. In fact, the system has standardized some parameters for new users!
# Therefore, when we use useradd, the s
1. Create a fruit sales report by color using Jfreechart1 PackageCom.wcy.chart.bar;2 3 Importjavax.servlet.http.HttpSession;4 5 Importorg.jfree.chart.ChartFactory;6 ImportOrg.jfree.chart.JFreeChart;7 Importorg.jfree.chart.plot.PlotOrientation;8 Importorg.jfree.chart.servlet.ServletUtilities;9 ImportOrg.jfree.data.category.CategoryDataset;Ten Importorg.jfree.data.general.DatasetUtilities; One A Public classBarChart3 { - - Public StaticString Genbarchart (HttpSession session)throwsexcepti
This.width=700;if (this.offsetheight>700) this.height=700; "border=" 0 "alt=" 鷌 N-Buckle m po m 譵? ' Island po m bencha confused Zhe 譣 v gamma-傔 楗? 栚 aズj 隺 ⒔ 湺? Controller KY "http://bbs.2cto.com" target= "_blank" class= "keylink" > Forum Nicholas_ng
*/
Function page ($page, $total, $phpfile, $pagesize =3, $pagelen =3) {
$pagecode =;//define variables to store pa
... into statement, insert... into statement, delete statement, or update statement, or nested in another subquery.
EM:
Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->
--
Group by, having,
Where
Select top
10
Userid, count (
*
)
As
Psize from produce group by userid order by psize DESC
--
Query the product table from large to small
>
Companies with the largest number of products releasedSelect
*
From produce
Wh
1. Use the number of subnets for Calculation
Before obtaining the subnet mask, you must first understand the number of subnets to be divided and the number of hosts required in each subnet.
1) convert the number of subnets to binary representation.2) The number of digits to obtain the binary value is N.3) obtain the subnet mask of the IP address, and obtain the subnet mask of the IP address.
To divide Class B IP address 168.195.0.0 into 27 subnets:1) 27 = 110112) the binary is five digits, n
[30253: 10b] duck init
We can see that although we have created three duck instances, initialize is called only once. We can also see that initialize is not called until we create a duck instance.
However, if duck has a sub-class, for example, we create a sub-class named Chicken (so weird ......) :
# Import
Note that the class chicken does not implement the initialize method.
If we run this program, but add a chicken instance:
Nslog (@ "Hello, world! "); Duck * duck1 = [[Du
The default Tomcat parameters are set for the development environment, rather than suitable for the production environment, especially the memory and thread configurations. The default values are very low and may become a performance bottleneck.
Tomcat Memory Optimization
Modify tomcat_home/bin/Catalina. Sh in Linux and add
Java_opts ="-XX: permsize = 64 m-XX: maxpermsize = 128 M-xms512m-xmx1024m-duser. timezone = Asia/Shanghai"
Modify tomcat_home/bin/Catalina. BAT in windows and add
, Cloud, wild goose door attack, attack the Huns.This is the horse Yi, after the first time, the emperor's initiative to attack the Huns.This troop, Gongsun he no income, Gongsun loss 7,000 cavalry, Li Guang soldiers defeated captured, fortunately finally fled back. Emperor Wu should both lose Gongsun, Li Guang into prison. According to the Chinese law, they trilogy centered beheaded, after two people pay ransom, was abolished as commoners.Four road men only Wei Green meritorious, was sealed as
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.