Tag Archives: Configuration management

How to Solve Error: Cannot find the declaration of element ‘beans’.

Question: org.xml.sax .SAXParseException: cvc-elt.1: Cannot find the declaration of element ‘beans’.

Solution: first, if the exception is encountered in the project, it is usually the problem that the project cannot download to the spring-beans-2.5.xsd file. The version number here varies with the project version.

Here you need to configure the local XSD file as follows:

Find the core package of spring referenced in your project, spring.jar

Open it with a compressed file and find the path

org/springframework/beans/factory/xml/

And configure the XSD file in this path to applicationContext.xml If there are more than one configuration file, all of them will be replaced

That is to say,
is the best choice

classpath:/org/springframework/beans/factory/xml/spring-beans-2.5.xsd

Instead of

http://www.springframework.org/schema/beans/spring-beans-2.5.xsd

Enables the configuration file to be read directly from the local

Reprint address: http://blog.csdn.net/wengang285/article/details/7587264

Method 2:

Modify spring applicationContext.xml Change the name space of the XML file to the following code:

<?xml version=”1.0″ encoding=”utf-8″?>
<!DOCTYPE beans PUBLIC “-//SPRING//DTD BEAN 2.0//EN” ” http://www.springframework.org/dtd/spring-beans-2.0.dtd “>
<beans>

Problem solving address: http://www.myexception.cn/vc-mfc/627052.html

 

The first method seems to have no effect, so I use the second method to solve the problem

MySQL forgot the root password

MySQL forgot the root password

1. Start the task manager and end the MySQL process

2. Enter the command line, enter the bin directory of MySQL (& lt; environment change & gt; path, you can find the bin directory) and start the MySQL service

mysqld -nt –skip-grant-tables  

(start without checking permissions);

(it may appear: 120705 17:41:14 [warning] option ‘new’: Boolean value’t ‘wasn’t recognized. Set to off. )

3. Reopen a command prompt window

 

  

Input: MySQL – uroot

4. Change the root password:

 

  

update mysql.user set password=PASSWORD(‘newpass’) where User=’root’;

5, flush privileges;

6, quit

Reconnecting MySQL

Reprint address:

http://blog.sina.com.cn/s/blog_ a3695da601010 mrs.html

MySQL modify character set

First of all, there are two main concepts about MySQL character set, one is character sets, the other is collations, the former is character content
and encoding, and the latter is some rules for comparing the former. These two parameter sets can be specified at four levels: database instance, single database, table and column.

For users, utf8 encoding is generally recommended to store data. To solve the problem of garbled code, it is not only the storage of MySQL data, but also related to the coding mode of user program files and the connection mode between user program and MySQL database.

first of all, MySQL has a default character set, which is determined during installation. When compiling mysql, you can use default_ Charset =
utf8 and default_ COLLATION=utf8_ general_ CI (MySQL version 5.5, version 5.1 uses — with charset =
utf8 — with collation = utf8)_ general_ The default character set is utf8, which is also the most once and for all method. After this is specified,
the coding mode of client connecting to database is utf8 by default, and the application does not need any processing.

unfortunately, many people don’t specify these two parameters when compiling and installing mysql, and most people install it through binary programs.
at this time, the default character set of MySQL is Latin1. At this time, we can still specify the default character set of MySQL by my.cnf Add two parameters to the file:
1. Add
default character set = utf8 under [mysqld]
2. Add
default character set = utf8 under [Client]
2 In this way, we don’t need to specify utf8 character set when we build database and table. This writing method in the configuration file solves the problem of data storage and comparison
, but it has no effect on the connection of the client. At this time, the client usually needs to specify utf8 connection to avoid garbled code. This is the general set
Names command. In fact, the set names utf8 command corresponds to the following server-side commands:
set character_ set_ client = utf8;
SET character_ set_ results = utf8;
SET character_ set_ Connection = xutf8;
but these three parameters cannot be written in the configuration file my.cnf It’s in the library. It can only be modified dynamically by the set command. What we need is to write a way to
Yongyi in the configuration file. At this time, is there a way to solve the problem on the server?The feasible idea is in init_ Set in connect. This command will be triggered every time an ordinary user connects. You can add the following line in the [mysqld] section to set the connection character set:
Add under [mysqld]:
init_ Connect =’set names utf8 ‘
summary:
1. It is preferred to specify two parameters to use utf8 encoding when compiling and installing mysql.
2. Select in the configuration file my.cnf or my.ini Set two parameters and init at the same time_ Connect parameter.
3. The third is in the configuration file my.cnf or my.ini Set two parameters, and specify the set names command for the client connection.
4. In the configuration file my.cnf The default character set parameter is added to the client and server in to facilitate management.

SSL handshake failed: SSL error: illegal key usage detected in the certificate

SVN under Linux cannot connect to the Windows server: SSL failure: SSL error: Illegal key usage detected in the certificate.
The SVN server has been configured with visualSVN on Windows 2003 and is available on the Windows virtual machine client side.
Today, however, trying to run SVN on Ubuntu 11.10 installed Subversion. But use times similar to the following error:
SVN: method OPTIONS fail in “https://1.0.0.2:8443/svn/xxx” : the SSL handshake failed: SSL error: key usage of detected irregularities in the certificate.
 
Reason for error: This is because Virtual SVN USES a plug-in when generating authentication data that is supported by OpenSSL but not by GnuTls.
The
correction is to modify the certificate source sky generated for third-party certificates used by visualsvn on the server so that both Windows and Linux can recognize it.
Process:

1.Add the following registry value to the Windows registry :(mine is 32 bits)
for 32-bit system :(run regedit-> Find the following registry key -& GT; Add a value of type DWORD)
[HKEY_LOCAL_MACHINESOFTWAREVisualSVNVisualSVN Server]
“CreateGnuTLSCompatibleCertificate” = dword: 00000001
for 64 – bit system:
[HKEY_LOCAL_MACHINESOFTWAREWow6432NodeVisualSVNVisualSVN Server]
“CreateGnuTLSCompatibleCertificate” = dword: 00000001
Start VisualSVN Server Manager. (open virsualSVN Server)
2. Go to Action | Properties | Certificate.
3.Click Change certificate…
execute SVN again, it will prompt the certificate generator to be warned that it is not trusted, choose to accept it permanently.

and that solves the problem.
 
Another solution (without testing) is to make SVN clients on LINUX support OPENSSL.
The methods are as follows:

wget wget http://subversion.tigris.org/downloads/subversion-1.6.3.tar.gz

http://subversion.tigris.org/downloads/subversion-deps-1.6.3.tar.gz tar XVFZ subversion – 1.6.3. Tar. Gz
the tar XVFZ subversion-deps-1.6.3.tar.gz
CD subversion-1.6.3/neon/

sudo apt-get install libssl-dev libxml2-dev
./configure –with-ssl –with-pic
make
make install

CD.
rm -rf neon
edit /etc/ld.so.conf and add /usr/local/lib
ldconfig

./configure –with-ssl –with-neon=/usr/local
make
make install

dpkg –purge subversion

JIRA start error: the jira.home directory ‘/opt/jira_ home’ is already locked. JIRA startup failed, JIRA has been locked.

start JIRA, log appear the following error:

jira startup failed, jira has been locked.

error because there is a.jira-home.lock file under ‘/opt/jira_home’, delete and restart it. The.jira-home.lock file is designed to prevent multiple jira sites from running on the same machine and having the same jira.home set

How do I unlock my JIRA home directory?

The


The