How do I have all of the lines from an update done in a terminal to a log file? Ubuntu Mate doesn't and I need the text
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
How do I have all of the lines from an update done in a terminal to a log file? Ubuntu Mate doesn't and I need the text
Screengrabs do not fit my purpose.
I know about /var/log/apt and history.log and term.log in there but it doesn't get logged in there in Ubuntu MATE 20.04.3. In fact it gets logged nowhere, since UM comes with the handy Log File Viewer, I've been able to verify that,I could copypaste lines as it happens but I then would likely be told that the log is not complete, there's a certain limit to how many lines the screen will show. I need to be able to copy paste lines from an updating process, it's not as simple as "command > result.txt" with sudo apt update then sudo apt upgrade. I'm not really a newbie but I guess I never had to do this, I could always find logs for anything before, but I never needed to get update lines from an update to catch an error I cannot show otherwise (screengrabs are not good enough apparently).
Thank you very much, I hope it is possible at all, this one error I have figured everything about except for one last step to fix, I can't find how or get help to fix it without update logs I can copypaste and put in bbcode tags.
Last edited by HannemanThrashKing; 02-02-2022 at 10:09 AM.
Nope, it's on the options right on the left in the Log-File Viewer in MATE. The updates do not get logged at all, we have to get past that. Maybe there is a way to create a log file when one does sudo apt-update && sudo apt-upgrade , some parameters added to it or something maybe?
To be clear, DPKG will show some installations, but not the error message that is only shown during the install process I experience since a while, that I have a good idea how to get rid of, but I need a copypaste of the install process entirely.
Are you sure that error message is displayed on stdin and not on stderr?
You may have to redirect stderr.
Code:
sudo apt-get install <package-name> 2>&1 | tee Log.txt
This is good to know. I have been using tee to log the results for apt-get dist-upgrade for a while now and didn't realize that the stderr wasn't getting logged. Luckily I didn't need to but going forward I can ensure all errors are also logged.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.