Hi,

I am getting this really weird output while printing out from "uemcli". The uemcli is EMC's command line tool to manage some of their storage arrays. Now they have mentioned in the documentation that the latest version of the uemcli does have issues with Perl only on Windows and might show strange characters. I checked on the EMC forum and found a thread where someone has given a way to overcome this, but it does not work for me. This is how the output appears on the command line. Note the "yth" output appears all by itself.

C:\>perl vnxe_1.pl ythS t o r a g e s y s t e m a d d r e s s : 1 9 2 . 1 6 8 . 1 +. 1 2 3 S t o r a g e s y s t e m p o r t : 4 4 3 H T T P S c o n n e c t i o n 1 : S y s t e m n a m e = C D R - +V N X e 1 M o d e l = V N X e +3 3 0 0 P l a t f o r m t y p e = E M C +S t o r a g e S y s t e m P r o d u c t s e r i a l n u m b e r = X Y Z 0 + 1 3 4 1 2 3 4 5 6 7 A u t o f a i l b a c k = o n H e a l t h s t a t e = O K ( +5 ) H e a l t h d e t a i l s = " T h e + s y s t e m i s o p e r a t i n g n o r m a l l y . "

If the output is captured in a file, a lot of japanese characters show up. If I use utf-8, it still prints to file like how it's shown above. I know this is not a Perl problem, and I have tried utf-8 and utf-16 encoding/decoding and tried using Text::Unidecode, but either I am not using it right, or it is having no effect on the issue. Any help would be greatly appreciated.

Here's a snippet of the code I am trying. The username and password is being read from a separate file. I've removed a lot of code and only kept the code that displays the output shown earlier.

use strict; use warnings; use Text::Unidecode; my @arrayhealth = `uemcli -d $vnxe_ip -u $username -p $password /sys/g +eneral show -detail`; my ($system_name, $model, $platform_type, $product_serial_number, $aut +o_failback, $health_state, $health_details) = @arrayhealth; my @unidecode_arrayhealth = unidecode(@arrayhealth); print "@unidecode_arrayhealth\n";


In reply to Unicode issues with emc uemcli by pritesh_ugrankar

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.