Buy Percona ServicesBuy Now!

Wide character in print at /usr/bin/pt-archiver line 6700.

  • Filter
  • Time
  • Show
Clear All
new posts

  • Wide character in print at /usr/bin/pt-archiver line 6700.

    Hi all,

    I'm trying to archive some parts of our production DB but pt-archiver don't want to run properly, it fails with "Wide character in print at /usr/bin/pt-archiver line 6700."
    Our DB has some data encoded in different than UTF8 encodings.

    I tried to use "--[no]check-charset" flag but then it's only getting 20 first rows and stopping to work.

    Is there any way to overcome that?

    Thank you in advance,

  • #2
    Hi Denis thanks for your question.
    Can I just check what version of Percona Toolkit you are running please? I found reference to a bug here which suggests the issue is fixed. It seems to be something that occurs intermittently.
    There are a couple of suggestions in the bug post too. If you have a test environment though, would be best to check those out there first.
    Anyway, let me know about the version, Percona Server or MySQL versions, environment etc and I'll see if I can get someone to check that for you.
    Is this an emergency? Get assistance from Percona Support. Click here.


    • #3

      And thank you for prompt feedback!

      pt-archiver I'm using is 3.0.10, MySQL server has 5.6.34 version.

      The environment is Ubuntu 16.04.03 LTS 64 bit.

      I'm running the "pt-archiver" command using "--charset" flag with type of "utf8" but in its short form: "-A; type: string", below is command example (sensitive data has been removed):

      nohup pt-archiver --source u=<username>,p='<password>',h=<host>,D=<database>, t=<table>,A=utf8 --file <output_file> --where "<where clause>'" --progress 10000 --statistics --limit 1000 --txn-size 500 > <log_file>.log 2>&1

      I haven't tried yet one of the following (taken from the link you've shared above):

      For the time being, anyone getting this should probably be running the tool with --charset utf8, or setting 'PERL_UNICODE=SAD' in their environment, or failing that as
      $ perl -CSAD pt-archiver ...
      $ perl -Mopen=:utf8 pt-archiver ...
      If you have a test environment though, would be best to check those out there first.
      I'll do.

      Thank you once again.


      • #4
        You're welcome. If you possibly can, if you could download PT 3.0.11 (the latest version) and try that "just in case".
        Meanwhile, I will bring this to the attention of the tech team here in case anyone has an alternative suggestion.


        • #5
          Hi Lorraine,

          I installed the latest version of PT and seems it's running now without any issue.

          I'll post back here if this issue occurs again.

          Thank you for your help, it's much appreciated.


          • #6
            You're welcome, I'm glad it's sorted.
            Please do post back if it recurs, but from the bug database it appears that we're satisfied we've fixed that one.


            • #7
              Hello Lorraine,

              I'm still facing the same issue even when using recent PT version which is 3.0.11. It's failing when trying to get data with text like 讠m㸋> and ⱳ⬘ᦢ

              Is there anyway to overcome that?

              Thank you in advance.


              • #8
                Hello le_den, thanks for the update. OK it sounds as though the original bug is not quite fixed in all cases. Are you able to create a small reproducible case by any chance? I feel that we probably need to update our bug database with a test case. Let me know? As it appears to be intermittent that's always one of the trickiest things to track, but a test case could help a great deal.


                • #9
                  Hello Lorraine,

                  There is the .csv file with 4 examples, two first are those where the PT is failing on while the last two are being processed without any issue.

                  Hope you will find this useful.
                  Thank you.


                  • #10
                    Thank you le_den, I will get this to the relevant techs and see if they can reproduce. Appreciated.


                    • #11

                      Could you share the output of SHOW CREATE TABLE please?



                      • #12

                        Originally posted by carlos.salguero View Post

                        Could you share the output of SHOW CREATE TABLE please?

                        There you go:

                        CREATE TABLE `log` (
                        `UID` varchar(255) COLLATE utf8_bin DEFAULT NULL,
                        `numb1` varchar(255) COLLATE utf8_bin DEFAULT NULL,
                        `numb2` varchar(255) COLLATE utf8_bin DEFAULT NULL,
                        `created_at` datetime NOT NULL,
                        `updated_at` datetime NOT NULL,
                        `state` varchar(40) COLLATE utf8_bin DEFAULT NULL,
                        `field1` varchar(50) COLLATE utf8_bin DEFAULT NULL,
                        `content` varchar(1000) COLLATE utf8_bin DEFAULT NULL,
                        `id` bigint(20) NOT NULL AUTO_INCREMENT,

                        PRIMARY KEY (`id`),
                        UNIQUE KEY `index_log_on_uid` (`uid`),
                        KEY `index_log_on_created_at` (`created_at`),
                        KEY `index_log_on_state` (`state`),
                        KEY `field1_idx` (`field1`),
                        ) ENGINE=InnoDB AUTO_INCREMENT=1876946846 DEFAULT CHARSET=utf8 COLLATE=utf8_bin

                        Best Regards,


                        • #13
                          Hello Percona team,

                          Do you have any update?

                          Thank you.


                          • #14

                            Can you use mysqldump to send us the data examples?
                            I am not being able to import your data.


                            • #15
                              Hi Carlos,

                              Attached is a mysql dump file example.txt . please try to import it and let me know how that goes.

                              Last edited by le_den; 08-23-2018, 05:20 AM.