Archive for the ‘IT technology’ category

Do cdn china telecommunications Netcom ip address allocation table to download.

January 16th, 2010

ScanMon of its Web site because the server is located in California, the china users to access very slow, the network delay in the 200ms or so has come to the ideal state (the United States to China, long distance cross-sea fiber optic cable).

General Telecom / Netcom users to access the U.S. site, the network data transmission, following the route first, the local ISP network, then the metro, followed by provincial and municipal network node, and then the backbone network, the final exit from Shanghai and other out across more than 10,000 kilometers the vast Pacific Ocean, in the United States, California / Oregon landing. Network delay (latency) in more than 200ms. Many people mistakenly believe that GFW’s network filter will affect the speed, but in fact this effect is negligible, the network for more than 200ms delay is mainly because the transmission distance is too long, the Japanese / Australian Internet users against the United States and mainland China network delay the user about the same, while European customers in general across the Atlantic Ocean for more than 100ms. If you are a mobile user, then the two giants for bandwidth resources to be pitiful, mobile users are generally the first south to Hong Kong to connect NTT nodes, and then detour to reach the United States, Japan, Network latency reached a staggering Qi Babai cents seconds.

The help of friends in the test in Beijing, Shanghai and Guangzhou, the speed of access to the site can also be acceptable, but some users have reported speed is still very slow. Because of this issue and therefore lost a lot of customers.

Taking into account these problems, I decided in the domestic planted two nodes, by cdn ways to solve this problem. Cdn need to do a detailed ip address allocation table, to facilitate separation of (Telecom / Netcom); (domestic / foreign), to speed up web site access speeds, allowing users to have better access to results. At a friend’s help, organize A Chinese telecommunications operator (ISP) IP address allocation table.

At present, China mainly domestic ISP Telecom, China Netcom (now merged with China Netcom), mobile (have been consolidated CRC) 3, the largest telecommunications and China Unicom (China Netcom). The north and south of the ISP due to the different, ISP restrictions between the North and the South led to a user’s visit to the site that excruciatingly slow. To solve this problem, the current common practice is to obtain IP addresses operator, by setting the two-wire (multi-line) DNS access to achieving a “Telecommunication walk Telecom, Netcom, Netcom to go” to solve the problem.

» Read more: Do cdn china telecommunications Netcom ip address allocation table to download.

Jacky‘s blog keyword tag cloud

January 11th, 2010

Jacky‘s blog keyword tag cloud

花时间在我的宝贝葫芦上做到标签云:

scanmon.com jk.scanmon.com , bebian , nginx ,moon52.com ,linux , mysql, 快乐生活 ,apache , jacky ,月影鹏鹏php

schroot – chroot for any users

January 7th, 2010

From manpages: schroot allows the user to run a command or a login shell in a chroot environment. If no command is specified, a login shell will be started in the user current working directory inside the chroot.

I’ve been trying some virtual machines solutions to execute some programs 32bits in my machine. But it’s take very time, start a xen VM or virtualbox. Often this solutions needs some maintain additional costs to setup a X server to run any X-based program.

» Read more: schroot – chroot for any users

OpenSSH logging with ChrootDirectory

January 7th, 2010

Finally following up on the previous article on the subject, I found some time to investigate logging what happens in an internal-sftp session using rsyslog.

Making syslog available in the chroot

Simply create a dev directory in each one of the chosen user chroot directories.

# mkdir /home/user/dev

Configuring rsyslog to probe the new logging source

Simply drop the following contents in /etc/rsyslog.d/sshd.conf :

# Create an additional socket for some of the sshd chrooted users.
$AddUnixListenSocket /var/fileserv/dev/log

# Log internal-sftp in a separate file
:programname, isequal, "internal-sftp" -/var/log/sftp.log
:programname, isequal, "internal-sftp" ~

 » Read more: OpenSSH logging with ChrootDirectory

inux: rm and the ‘Argument list too long’ error message.

January 6th, 2010

Linux: rm and the ‘Argument list too long’ error message.

Linux: rm and the ‘Argument list too long’ error message.


Let’s say you wanted to delete all the files in a directory that begins with the word ’spam’:

[root@yoursite filter]# rm spam*

bash: /bin/rm: Argument list too long

ERROR!

This happens when you are trying to delete too many files in a directory at the same time – it seems rm has limits ….

To solve the problem:

Use ‘find’ to pipe all the matching files to ‘rm’, one at a time.

[root@yoursite filter]# find . -name ’spam*’ | xargs rm

» Read more: inux: rm and the ‘Argument list too long’ error message.