Announcement

Collapse
No announcement yet.

Konsole how to see ALL the output?

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

    #16
    I don't understand why your output to a file is being truncated. It should not be. The size of the output piped to a file has nothing to do with the history size of bash. At here, my output is only 427 lines (my HP laptop).
    Windows no longer obstructs my view.
    Using Kubuntu Linux since March 23, 2007.
    "It is a capital mistake to theorize before one has data." - Sherlock Holmes

    Comment


      #17
      The default for Konsole is, I think, 1000 lines. Did you run that command dmidecode? I got 2472 lines of output from it!
      An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

      Comment


        #18
        Originally posted by Qqmike View Post
        Did you run that command dmidecode?
        Yes: sudo dmidecode As stated, on my HP laptop, the resultant output is 427 lines, the same number of lines if I pipe the output to a file.
        Windows no longer obstructs my view.
        Using Kubuntu Linux since March 23, 2007.
        "It is a capital mistake to theorize before one has data." - Sherlock Holmes

        Comment


          #19
          So, in your case, you are way under the "limit" anyway, where the default limit is 1000 lines. You should have no problem at all.
          The problem arises at (or just after exceeding) the 1000 line default limit.
          An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

          Comment


            #20
            Post 8 from Schwarzer Kater solves this problem: right-click on Konsole and adjust the scroll limit. Gonna mark this Solved for now.
            An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

            Comment


              #21
              Sorry if I missed this in an earlier post, but did you change the bash history size in your ~/.bashrc file?

              Code:
              # for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
              HISTSIZE=1000
              HISTFILESIZE=2000
              ​
              I always add a zero to mine.
              Code:
              # for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
              HISTSIZE=10000
              HISTFILESIZE=20000

              Please Read Me

              Comment


                #22
                The strange thing for me is that the OP could not set this in Konsole's preferences but only temporarily with a right click. *shrug*
                Last edited by Schwarzer Kater; Mar 25, 2023, 03:52 AM.
                Debian KDE & LXQt • Kubuntu & Lubuntu • openSUSE KDE • Windows • macOS X
                Desktop: Lenovo ThinkCentre M75s • Laptop: Apple MacBook Pro 13" • and others

                get rid of Snap script (20.04 +)reinstall Snap for release-upgrade script (20.04 +)
                install traditional Firefox script (22.04 +)​ • install traditional Thunderbird script (24.04)

                Comment


                  #23
                  Yeah, I don't see any menus where an option exists to set that limit, except only temporarily for the current session.
                  And, as I said above, the strange thing is, Why am I now dealing with this?!
                  I have never seen an issue in the past. Even for, specifically, dmidecode.
                  An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

                  Comment


                    #24
                    did you change the bash history size in your ~/.bashrc file?
                    I just saw oshunluvr's post. I tried that just now -- no change. I ran dmidecode and got just 1032 lines of output that I can see (the LAST 1032 lines of the result from running dmidecode). IOW, same result as before.

                    What is even stranger is that you guys don't seem to have this problem on 22.04.

                    I read about trying page up, ****+page up, control+page up, alt+page up, I've tried everything from the menus and from my keyboard. Can't go "up" off the top of the Konsole screen.
                    An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

                    Comment


                      #25
                      Originally posted by oshunluvr View Post
                      ,,, did you change the bash history size in your ~/.bashrc file?
                      That's the bash command history, and Qqmike wants to see one command's output, and has been trying to get it using konsole's scrollback.

                      Something's not right here. Maybe it's dmidecode; the man page has a section
                      BUGS

                      More often than not, information contained in the DMI tables is inaccurate, incomplete or simply wrong.
                      Saving to a text file doesn't work -- I just get a partial file, like what I see on my Konsole screen.
                      Saving to a text file with something like sudo dmidecode > dmi.txt has got nothing at all to do with konsole, unless you're viewing the text file in a konsole. Do you still see the truncated output if you open the text file with kate? Maybe you're using konsole's "Save Output As"?

                      Another approach would be
                      Code:
                      sudo dmidecode | less
                      less has many commands for moving around the output, and the PgUp/PgDn/Home/End keys work. That will work even in a Linux console, with a "c".
                      , which you get to with ctrl-alt-f2.
                      Regards, John Little

                      Comment


                        #26
                        Do you still see the truncated output if you open the text file with kate?
                        Yes.

                        More often than not, information contained in the DMI tables is inaccurate, incomplete or simply wrong.
                        Possibly so. I was only using it as a test or goofing around. Probably inxi -Fxxx gives most of what people look for.

                        ctrl-alt-f2: I've forgotten/hardly ever needed that; got stuck in that console! how do you return to GUI?! besides a hard reboot!

                        Code:
                        sudo dmidecode | less
                        Now that does work to see all the output, moving around with PgUp/etc.
                        It does not show the command I entered at Konsole, the 'sudo dmidecode | les's command, but it appears to show all the output from that command.
                        How do you exit from it? Ctrl+c didn't work. I didn't try "q".

                        man less ... should tell, I suppose ... Boy, I opened a can of worms.
                        Looking at man less, one must learn 'another language' to understand and fluidly use "less" IMO.

                        ​The more I think about it, the problem should have a better solution.
                        If I think about it beforehand, before issuing a command, then the solution in post 8 would work: rt-click in Konsole and change the scrollback setting.
                        But who works that way?
                        You usually want to maintain the flow of your work, not stop and re-do it in the middle of it.
                        There must be a way to see all your output from the start to any point in your work, your flow of commands and output.

                        Something wrong with DMI? what is another safe command to try that would generate, say, 2000 lines of output? to use as a test.

                        How exactly should I capture ALL the output to a text file (to be opened by Kate)?
                        Last edited by Qqmike; Mar 25, 2023, 01:40 PM.
                        An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

                        Comment


                          #27
                          Originally posted by Qqmike View Post
                          ctrl-alt-f2: I've forgotten/hardly ever needed that; got stuck in that console! how do you return to GUI?! besides a hard reboot!
                          Usually, ctrl-alt-f1 or possibly ctrl-alt-f7.
                          Windows no longer obstructs my view.
                          Using Kubuntu Linux since March 23, 2007.
                          "It is a capital mistake to theorize before one has data." - Sherlock Holmes

                          Comment


                          • Qqmike
                            Qqmike commented
                            Editing a comment
                            You were right, Paul, about this command working. I must have misread it on the first go-around, or something or other. Thanks.

                          #28
                          Thanks Snowhog. I recall f7 now ... Shows you how good Kubuntu is: I rarely need the Konsole these past several years.
                          An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

                          Comment


                            #29
                            Originally posted by Qqmike View Post
                            ctrl-alt-f2: how do you return to GUI?
                            ctrl-alt-f1 (since about 16.04, it was ctrl-alt-f7 before then)
                            Code:
                            sudo dmidecode | less
                            How do you exit from it? Ctrl+c didn't work. I didn't try "q".
                            q is the command indeed.
                            (less's commands are natural for vi or vim users.)
                            (I use less with the -e option, set by the environment variable LESS in by .bashrc, which allows one to exit with just the space bar. I use less a great deal, via an alias from more.)

                            ...the more i think about it ...
                            There must be a way to see all your output from the start to any point in your work, your flow of commands and output.
                            That's what the konsole scrollback is for. Before functions like that, using simple terminals, once the output scrolled off the top, it was gone. (Ironically, the way terminal emulators work, with output scrolling up, originated with teleprinters in the 19th century, which printed on paper and to see the old output one could just look through the pile of paper.)
                            Something wrong with DMI?
                            That was just speculation on my part, because I can't understand your reports. The fact that you've seen all the output and paged through it with less means dmidecode is working.
                            what is another safe command to try that would generate, say, 2000 lines of output?
                            Code:
                            seq 2000
                            How exactly should I capture ALL the output to a text file (to be opened by Kate)?
                            As Snowhog suggested in post #10,
                            Code:
                            sudo dmidecode >> dmidecode.txt
                            You can use ">" or ">>", the difference is that the latter adds on the end of any existing file. Also, there are utilities such as script or tmux; but I find with the 3000-line man "page" for tmux "one must learn another language".
                            Regards, John Little

                            Comment


                              #30
                              Thanks.

                              Yes on ctrl+alt+f1 returning to GUI after ctrl+alt+f2.
                              Also sudo dmidecode > dmidecode.txt did, in fact, work to capture all the output.

                              So it does sound like remembering to rt-click on Konsole and setting the scrollback limit BEFORE starting work is the way to go.

                              However, if you already started work without changing the scrollback limit above 1000, and the output 'scrolled off the top,' writing it to text does not seem to capture it all - it's gone.

                              Many thanks, jlittle, for all the explanation! It's always interesting.

                              An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

                              Comment

                              Working...
                              X