, the line break is/r/n and for Unix ".% X: NDC associated with the current thread (nested Diagnostic Environment), especially used in applications with multiple clients and multithreading such as java servlets.%: Output A "%" character.Additionally, you can add modifiers between % and formatted characters to control the minimum length, maximum length, and text alignment. For example:1) % 20c: specify the name of the output category. The minimum lengt
), including the class name, the thread that occurred, and the number of rows in the code. Example: Testlog4.main (testlog4.java:10)%x: The NDC (nested diagnostic environment) associated with the output and current line threads, especially for multi-client multithreaded applications such as Java Servlets.Percent: Output a "%" character%F: The name of the file where the output log message was generated%l: Line numbers in the output code%M: The specified message in the output code, resulting in th
1. on Linux, set the IP address and other information on the ifcfg-eth0
The detailed configuration information is as follows:
[Root @ rac01 Desktop] # more/etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE = eth0BOOTPROTO = noneNM_CONTROLLED = yesONBOOT = noTYPE = EthernetUUID = 3d5f18d5-73e0-48db-acbb-67d3ee8b332fIPADDR = 192.168.171.150PREFIX = 24
2. invalid IP Address
(1) ifconfig: View eth0 Nic information and find that the IP address does not take effect
[Root @ rac0
the VIP is already bound to the network card.Lvs01 ~]# IP Ainet 192.168.137.150/24 BRD 192.168.137.255 Scope Global ENS33Valid_lft Forever Preferred_lft Foreverinet 192.168.137.80/32 Scope Global ENS33Valid_lft Forever Preferred_lft ForeverLVS02 ~]# IP A # #介意可以看到vip不在lvs02上2:eth0: Link/ether 00:0c:29:a5:b4:85 BRD FF:FF:FF:FF:FF:FFinet 192.168.137.130/24 BRD 192.168.137.255 Scope Global eth0Inet6 FE80::20C:29FF:FEA5:B485/64 Scope linkValid_lft Foreve
The preface is important:1) If you seem to have a lot of Internet settings fixed IP data, still no success;2) If your virtual machine is cloned, if you restart the network error: Bringing up interface Eth0:Error:No suitable device found:no device found for connection ' Syste M eth0 '.3) If you don't have eth0, then you're probably in the right place.Resolution: 1) Set up a fixed ip,2) cloned virtual machine Restart Network Service restart errorSteps:1. Ifconfig-a View your network configuration
The following command environment is the centos6.6 system;
1234567891011121314151617181920212223
[[emailprotected]~]#ifconfigeth0eth0Linkencap:EthernetHWaddr00:0C:29:2A:03:61inetaddr:192.168.20.50Bcast:192.168.20.255Mask:255.255.255.0inet6addr:fe80::20c:29ff:fe2a:361/64Scope:LinkUPBROADCASTRUNNINGMULTICASTMTU:1500Metric:1RXpackets:339errors:0dropped:0overruns:0frame:0TXpackets:270errors:0dropped:0overruns:0carrier:0collisions:0txqueue
[[email protected] ~]# uname //view current systemLinux[[email protected] ~]# uname-r//view kernel version2.6.18-348.el5[[email protected] ~]# uname-a//View details of the kernelLinux localhost.localdomain 2.6.18-348.el5 #1 SMP Wed Nov 21:22:00 EST. x86_64 x86_64 x86_64 Gnu/linux[Email protected] ~]# lsb_release-ddescription:red Hat Enterprise Linux Server release 5.9 (Tikanga)[[email protected] ~]# cat/etc/redhat-release//Display the first page information of the documentRed Hat Enterprise Lin
202.100.2.2/32 Dev tunnel0chmod +x/etc/init.d/gre.shecho "/etc/init.d/gre.sh" >>/etc/rc.d/rc.locallinux2: vi/etc/init.d/gre.sh # #内容如下:Insmod/lib/modules/2.6.18-164.el5/kernel/net/ipv4/ip_gre.koIP tunnel Add tunnel0 mode GRE remote 192.168.10.1 local 192.168.20.2 TTL 255IP link set tunnel0 up MTU 1400IP addr Add 172.16.1.2/30 dev tunnel0IP Addr del 172.16.1.2/30 peer 172.16.1.1/30 Dev tunnel0IP addr Add 172.16.1.2/30 peer 172.16.1.1/30 Dev tunnel0chmod +x/etc/init.d/gre.shecho "/etc/init.d/gre.
tunnel0chmod +x/etc/init.d/gre.shecho "/etc/init.d/gre.sh" >>/etc/rc.d/rc.locallinux2:vi/etc/init.d/gre.sh # #内容如下:Insmod/lib/modules/2.6.18-164.el5/kernel/net/ipv4/ip_gre.koIP tunnel Add tunnel0 mode GRE remote 192.168.10.1 local 192.168.20.2 TTL 255IP link set tunnel0 up MTU 1400IP addr Add 172.16.1.2/30 dev tunnel0IP Addr del 172.16.1.2/30 peer 172.16.1.1/30 Dev tunnel0IP addr Add 172.16.1.2/30 peer 172.16.1.1/30 Dev tunnel0chmod +x/etc/init.d/gre.shecho "/etc/init.d/gre.sh" >>/etc/rc.d/rc.l
} '192.168.116.255[Email protected] ~]# ifconfig eth0|grep "inet addr" |awk-f "[:]+" ' {print $7} 'Mask[Email protected] ~]# ifconfig eth0|grep "inet addr" |awk-f "[:]+" ' {Print $8} '255.255.255.0Sed and regular Expressions mate IP addresses:[Email protected] ~]# ifconfig eth0|sed-n ' s#^.*addr:\ (. *\) BCA.*$#\1#GP '192.168.116.128Note: ^.*addr (is the beginning addr end of any character) \ Escape (), the content of the () example is the end of the addr. bca.*$ (the end of any character starti
corresponding values, you can normally commitQuerydict Object
Defined in Django.http.QueryDict
HttpRequest object's properties Get, post are objects of type querydict
Unlike a Python dictionary, an object of type querydict is used to handle a condition with multiple values for the same key
Method Get (): Gets the value based on the key
If a key has more than one value at a time, it gets the last value
Returns a value of None if the key does not exist, you can set th
In Windows to set up a network card multiple IP, it is easier, today I write about in the Linux system, to a network card set multiple IP address, under the Linux system, the first card is called Eth0, the second network card is called eth1, Here we give the first network card set multiple IP, under Linux, configure the network card configuration file in the directory/etc/sysconfig/network-script/, the original network card configuration file named Ifcfg-eth0, We give a network card configuratio
in the log specific information%n: Output a carriage return line break, Windows platform is "\ r \ n", Unix platform for "\ n" Output log information wrapping can be in%a modifier is added to the pattern character to control its minimum width, maximum width, and text alignment. such as:1)%20c: Specifies the name of the output category, the minimum width is 20, if the category name is less than 20, the default is the right alignment. 2%-
message was generated
%l: line number in output code
%M: The message specified in the output code, the resulting log specific information
%n: Output a carriage return line feed
You can control the minimum width, the maximum width, and the alignment of text by adding modifiers between% and pattern characters. Such as:
1)%20c: Specifies the name of the output category, the minimum width is 20, and if the category name is less than 20, th
Do the project is log4j output format parameters annoying, simply put the relevant parts of the API roughly translated, the original see http://logging.apache.org/log4j/docs/api/org/apache/log4j/PatternLayout.html
Parameters
Description
Example
%c
Lists the full name of the logger namespace, and if you add the {
log4j configuration File Parameters Example
Output Display Media
Suppose the current logger namespace is "A.B.C"
%c
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.