Announcement

Collapse
No announcement yet.

kwrite on big files -- 14.04 was fine, 16.04 sucks

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [DESKTOP] kwrite on big files -- 14.04 was fine, 16.04 sucks

    I am maintaining a huge -- 25 mb -- text file using kwrite.

    On kubuntu 14.04, kwrite worked great.

    When I first tried 16.04 in early 2016, kwrite was clearly not the same:

    1. For the arrow keys, keyboard repeat works at the top of the file, but not further down. In 16.04, the display does not update -- you cannot see where the cursor is. If you hold an arrow key down for a while and release, after some seconds, the cursor reappears somewhere. In 14.04, anywhere in the file, you see exactly where the cursor is at every instant, you can release the arrow key when you want, and the cursor is where you expect it to be.

    2. Pasting text into the file, 16.04 takes several seconds for the text to appear. in kwrite 14.04, the text appeared instantly.

    After evaluating 16.04 in early 2016, the kwrite problem was a show stopper -- I declined to upgrade, and I have been on 14.04 until recently. But then in March, a more pressing consideration made me upgrade to 16.04, and kwrite is still a problem on my big file.

    In 2016, I tried tweaking settings in hope of fixing the problem, but I did not find a solution.

    Is there any solution to my kwrite problem? Thanks,

    #2
    Do you have a large swap file? If not, change from swap to a local directory. That *might* help.
    "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
    – John F. Kennedy, February 26, 1962.

    Comment


      #3
      Move tmpfs to RAM, use Kate instead, launch kwrite in terminal and observe any messages, open "top" in a terminal and observe how much RAM kwrite is using to indicate a memory leak,

      Please Read Me

      Comment


        #4
        Originally posted by likes2skate View Post
        I am maintaining a huge -- 25 mb -- text file using kwrite.
        Is that a typo? 25 MB is not huge for text files; a bit big I'd say. Any size up to your system's free memory should be easily handled; admins often deal with GB log files.

        If it really is only 25 MB I suspect there's something else going on. Such as, syntax highlighting struggling with deep structures.

        John Little
        Regards, John Little

        Comment


          #5
          I just created a 25Mb text file and opened it with KWrite. Navigating and making changes was lightening fast. KWrite is a default install. No config editing. I've got 8GB RAM and an 8GB swap file. I'm running Neon with an NVidia GT650M GPU.
          "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
          – John F. Kennedy, February 26, 1962.

          Comment


            #6
            This desktop has 16GB of RAM and a 10.8 GB swap partition. At this moment, kinfocenter shows the swap is not used.

            Yes the file size is 25 MB. I opened it using kate, see the screen shot -- kate says it is a big file!

            At the bottom, using kate, the cursor movement is as described above -- 14.04 was OK, 16.04 sucks.

            For me, navigating and making changes is fast at the top of the file only.

            I launched kwrite in a terminal, and there were no messages.

            There are no structures, just lines.

            The video card is an NVIDIA GT218 [GeForce 210].

            I do not know how to move tmpfs to RAM. I tried top, but kwrite jumps around then disappears.

            Would it help if I installed neon?
            Attached Files

            Comment


              #7
              Originally posted by likes2skate View Post
              This desktop has 16GB of RAM and a 10.8 GB swap partition. At this moment, kinfocenter shows the swap is not used.

              Yes the file size is 25 MB. I opened it using kate, see the screen shot -- kate says it is a big file!

              At the bottom, using kate, the cursor movement is as described above -- 14.04 was OK, 16.04 sucks.

              For me, navigating and making changes is fast at the top of the file only.

              I launched kwrite in a terminal, and there were no messages.

              There are no structures, just lines.

              The video card is an NVIDIA GT218 [GeForce 210].

              I do not know how to move tmpfs to RAM. I tried top, but kwrite jumps around then disappears.

              Would it help if I installed neon?
              The error msg says "i18n" missing. That stands for "Internationalization", there being 18 letters between the first "i" and the last "n" in that word.

              There should be as default installations on your machine the following libraries which will give you i18n capability:
              debconf-i18n
              libkf5declarative5
              libkf5declarative-data

              Also, make sure that the following are also installed on your system.
              language-pack-en
              language-pack-en-base

              Also, for text files, make sure that Tools --> Encoding --> Unicode --> UTF8 is set, unless you are not using English. Then UTF-16.
              Last edited by GreyGeek; Apr 02, 2017, 09:28 AM.
              "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
              – John F. Kennedy, February 26, 1962.

              Comment


                #8
                You are attempting to open one or more large files:
                I've provoked kate into seriously slow running, maxing a CPU core, opening a 1.2 GB text file, made up of many copies of about 12 MB of C source, but I still didn't get that message.

                I wonder if it would be ok for you to pastebin the file, so that we could look at it? Or maybe create a 25 MB file with
                Code:
                seq 3300000 > x
                and see if the problem is reproduced.

                A couple of wacky ideas. Maybe it's a sparse file, or is some weird file system thing, like a magnet link.
                Regards, John Little

                Comment


                  #9
                  what error message?

                  copied from the konsole:

                  Reading package lists... Done
                  Building dependency tree
                  Reading state information... Done
                  debconf-i18n is already the newest version (1.5.58ubuntu1).
                  libkf5declarative-data is already the newest version (5.18.0-0ubuntu1).
                  libkf5declarative-data set to manually installed.
                  libkf5declarative5 is already the newest version (5.18.0-0ubuntu1).
                  libkf5declarative5 set to manually installed.
                  language-pack-en is already the newest version (1:16.04+20161009).
                  language-pack-en-base is already the newest version (1:16.04+20160627).
                  0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

                  > Also, for text files, make sure that Tools --> Encoding --> Unicode --> UTF8 is set

                  Yes.

                  I still have 14.04 on some laptops and on a remote office desktop. Today, I am happy with kwrite on 14.04, and I am annoyed with kwrite on 16.04. It is exactly this simple.

                  I used to use Dropbox, but I switched to MEGAsync (similar to Dropbox, but as a "me to" product, it has to be "better"), so at different times, I am editing the same big file on different computers. I NOTICE A BIG DIFFERENCE!

                  Today, I will travel, and I will be away from my residence and office for more than 3 weeks. For most of that time, I will be using a laptop on which 14.04 is currently installed. (I may upgrade it to 16.04 despite the kwrite issue that is annoying me.)

                  To me, the difference is not subtle, but painfully obvious. I can imagine that for people who do not ever use kwrite to EDIT "big" files, what bothers me would be subtle. But when you spend hours editing a file, frequently pasting in text and wanting to move the cursor using arrow keys, comparing ZERO delay to a delay of several seconds is a big deal -- to someone who does it a lot on an almost daily basis. For this reason, maybe I need to post on bugs.kde.org, not here.

                  OK I will create a new 25 mb file of random text, and see whether the problem is duplicated.

                  Comment


                    #10
                    I reproduced the problem, maybe someone would like to try it.

                    I googled "Richard Stallman", went to some hit pages, and copied some text by or about him. I pasted into a file and duplicated. I used the fmt utility to break the long lines into shorter lines (the file I edit in real live has mostly short lines). The file is almost 27 mb. I gzipped it, and uploaded it here:

                    http://www.advanced-app.com.hk/MiscJ...d_short.txt.gz

                    For both the following tests, I used wget to download the file and gzip -d to extract it.

                    On the 16 gb desktop running kubuntu 16.04:
                    I went to the bottom of the file, and from the bottom I selected up to and including the line "The consequences:". I copied the selected text. I used PgUp several times until I came to the heading "The GNU Manifesto". Above that heading, I hit Paste (Ctrl-V), and counted "one thousand one, one thousand two, one thousand three, ..." The inserted text appeared between one thousand five and one thousand six. I hit Ctrl-Z. I held down the up arrow key, and kept holding it down while I counted ""one thousand one, one thousand two, one thousand three, one thousand four, one thousand five" then I released the up arrow key, and started counting again. The cursor did not come back after I counted up to one thousand eight.

                    On the 8 gb laptop running kubuntu 14.04:
                    I went to the bottom of the file, and from the bottom I selected up to and including the line "The consequences:". I copied the selected text. I used PgUp several times until I came to the heading "The GNU Manifesto". Above that heading, I hit Paste (Ctrl-V). There was no need to count, as the inserted text appeared instantaneously (to my human perception). I hit Ctrl-Z. I held down the up arrow key, and kept holding it down while I counted ""one thousand one, one thousand two, one thousand three, one thousand four, one thousand five" then I released the up arrow key. There was no need to count again, as cursor came to a stop instantaneously. While I was holding down the up arrow key, the cursor never disappeared, but moved up smoothly and continuously.

                    Feel free to try it yourself!
                    Last edited by likes2skate; Apr 04, 2017, 09:31 PM.

                    Comment


                      #11
                      BTW, I first noticed this issue in 2016, WITH NO HARDWARE CHANGE. That is, I had been using 14.04 on a desktop. I removed that hard drive, and on the same desktop, on fresh hard drive, I installed 16.04 and copied on all my files. After trying 16.04 for a day or so, because of this kwrite issue, I said "NO WAY", took out the 16.04 hard drive, put in a fresh hard drive, installed 14.04, then copied all my files to the fresh 14.04 installation. This entire process was on one desktop -- no change of hardware, this issue seems to have nothing to do with the hardware and everything to do with 14.04 vs 16.04.

                      Comment


                        #12
                        I'm on 16.10, but FWIW, I downloaded the file, decompressed it, and do not reproduce your problem, with kate or kwrite. On an intel i7-6700 and a SATA SSD,

                        Google says kate can be slow if it's using a swap file over NFS; when I use kate it puts the swap file in the same directory as the file. Is NFS involved anywhere?
                        Regards, John Little

                        Comment


                          #13
                          > Google says kate can be slow if it's using a swap file over NFS; when I use kate it puts the swap file in the same directory as the file. Is NFS involved anywhere?

                          I have never tweaked kwrite and/or kate at that level. No, I do not put the swap file on an NFS drive, my 16.04 desktops do not connect to any NFS drive.

                          In 14.04, the Kate part of kwrite is Kate Part Version 3.7 (on the kwrite Help pull down, there are separate Abouts for kwrite and editor component, the editor component of kwrite is kate).

                          In 16.10, what is the kate version? Maybe they fixed the problem in your version.

                          I changed offices, I do not have access to a 16.04 install at this moment. It will be a day or two.

                          Comment


                            #14
                            I am not having the issues you describe with the file in KWrite on my 16.04.1 installation. I downloaded your file and opened it with KWrite and repeated your steps. No problems.

                            I'm going to suggest that the issue is with the KWrite configuration settings in your users /home directory from 14.04 and the installation of KWrite after you installed 16.04.

                            You said:
                            In 14.04, the Kate part of kwrite is Kate Part Version 3.7 (on the kwrite Help pull down, there are separate Abouts for kwrite and editor component, the editor component of kwrite is kate).
                            Kate Part Version is 5.28.0 when installed in 16.04.1.

                            I would suggest that you delete /home/$USER/.config/kwriterc and /home/$USER/.local/share/kwrite and then reinstall kwrite: sudo apt-get update && sudo apt-get install --reinstall kwrite and see if things improve.
                            Using Kubuntu Linux since March 23, 2007
                            "It is a capital mistake to theorize before one has data." - Sherlock Holmes

                            Comment


                              #15
                              @Here, kate had no problem but I was able to get kwrite to totally lockup and spike CPU to 100%. I never could get any error messages.

                              My test was to download the file above, open in with kwrite, use the scroll bar to move to the bottom of the file, hit the Page Up key several time, done.

                              Locked kwrite every time.
                              Last edited by oshunluvr; Apr 06, 2017, 06:30 AM.

                              Please Read Me

                              Comment

                              Working...
                              X