When I run a Perl script in centos6.6, the "Server Version unavailable ... line 545" issue appears,650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/6E/56/wKiom1V5QQqgUYmmAAE3u4RM610360.jpg "title=" Perl-sdk-545.png "alt="
1 #!/usr/bin/env Perl2 Usewarnings;3 UseStrict;4 Use Socket;5 6 my $HOST='localhost';7 my $PORT=8080;8 Socket(S,pf_inet,sock_stream,Getprotobyname("TCP"));9 if(Connect(S,sockaddr_in ($PORT, Inet_aton ($HOST)))){Ten Open(STDIN,">&s"); One
Perl Module Net::scp::expect Batch FileWrite deployment scripts with Net::ssh::P Erl and Net::scp::expectPerl scripts for SCP distribution filesPerl SCP Operations#!/usr/bin/PerlUse net::scp::expect;my $pc _ip="192.168.233.135"; my $pc _passwd="Test"
Implemented features:Fetch warn and its description and NUM numberFeatures not implemented:How to prioritize these warn to facilitate later report analysis usingIdea:1. Find a way to permanently save and read warn Level/advice data at the fastest
In BI report development, often need to calculate the year-end, need to use the month-end date, with the date function of the database system needs to be in each place to use the date to write the function, in some special cases, the function will
"Linux/unix" manual Installation and automatic installation manual Installation: The modules you need, manually compiled, installed assuming you want to install the Xml-simple module, download the DBI module version 2.20 from the cpan
The 12th chapter: Regular ExpressionsA regular expression is a sub-program. is the text matching subroutine. Yi Wu.Be sure to use the/X flag. Yi Lu.be sure to mark with/M. One restaurant Qi.use \a and \z as the string boundary anchor point (anchor).
1. Chop and chomp Functions
Both functions use strings as parameters and remove the last character from them. The difference is that, no matter what the last character is, chop will be removed and returned in the return value. Only when the last
Comparison of Perl use and require usage
Comparison (1) Description:Both functions mean loading and referencing Perl modules, or sub-functions.Program,
The difference is that Perl use is searched in the current default. Once the module is not in
I have a Perl script named A. pl, which contains a statement similar to the following to read the input value of the command line:
My $ device_name = ;
If I use the system or readpipe command in the B. pl script to bond the script a. pl, the
1. perldoc perllocal 2. We recommend pminst commands in pmtools.
Http://search.cpan.org/src/MLFISHER/pmtools-1.01/pminst 3. Prepare the following specimens
#! /Usr/bin/perluse strict; Use extutils: installed; my $ inst = extutils: installed-> New (
1. When chomp does not have a parameter, use the default parameter to operate on $.
2. array @ array .. can be referenced by $ array [number. $ # Array... indicates the number of indexes in the array.
3. $! Contains error information;
4. By default,
1. Replacement
S/pattern/replace/; # returns the Boolean value of whether the replacement is successful.
You can use capture variables, such as S/(\ W)/$1/
If the matching fails, no processing is performed.
2. delimiters
For delimiters without left
The normal subscript operations in the perl array must be familiar to everyone. I will not describe them here.This article describes the multi-digit values under the perl array, which greatly facilitates Array Operations.Note: These numbers are from
This module uses the perl array to represent a file. each row of the file corresponds to an element of the array. The first behavior element is 0, and the second response is 1 ,...The file itself is not actually loaded into the memory, and the
So that some characters (especially wide characters) cannot be correctly displayed, that is, they are no longer in UTF-8 format.
Solution:When the output file is opened, the encoding format is specified, so no garbled characters will occur after
The Perl script batchReplace. pl can be used to replace text/code in files in batches. You can search for files of the specified type in the specified directory and recursively check the subdirectories. Copy the directory structure of the input file
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.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service