No terminal output available in gnome updater

Post your bugs here.
User avatar
ilu
Posts: 1602
Joined: 09 Oct 2013 12:45

No terminal output available in gnome updater

Postby ilu » 29 Sep 2017 21:11

gpk-update-viewer doesn't show any terminal output, not even in case anything went wrong. You can see a notice fly by but that's it. This makes debugging extremly painful. gpk-log keeps only the names of installed packages.

Did I overlook something? Is there a way to call the program with parameters that print apt terminal output into a log file? I could not find anything.

kurotsugi
Posts: 1920
Joined: 09 Jan 2014 00:17

Re: No terminal output available in gnome updater

Postby kurotsugi » 02 Oct 2017 00:32

we could use many front-end but at the end it still using apt in the back. debugging could be done by using apt's log. I think it's the correct way to do it. the front-end log should only contain front-end related information. otherwise, there would be lot of duplicated information.

User avatar
ilu
Posts: 1602
Joined: 09 Oct 2013 12:45

Re: No terminal output available in gnome updater

Postby ilu » 02 Oct 2017 17:12

Apt's logs seem to just list the installed packages. I'm looking for the terminal output during install. That could be covered by dpkg's log but isn't, at least not in detail. I'm looking for a way to see how postinstall scripts went, maybe by

Code: Select all

gksu gnome-updater-whatever-start-command >> some-log-file
Schoeljes updater had a terminal window that showed the output so you could check what went wrong. Gnome updater just goes on, without even an error message. This is fatal if things go downhill later, especially with our standard conf that sends /var/log/ into nirwana after reboot.

Please correct me if I overlooked any available debugging tool.

I think I will move this into the bug section because of this combination. On itself everything is fine, but the combination can be fatal.

kurotsugi
Posts: 1920
Joined: 09 Jan 2014 00:17

Re: No terminal output available in gnome updater

Postby kurotsugi » 03 Oct 2017 01:44

apt has two logs. what you're looking for is /var/log/apt/term.log. it contain all the terminal output. btw,
especially with our standard conf that sends /var/log/ into nirwana after reboot.

I didn't recall we made a decision to discard /var/log at every boot. do we really do that? IIRC there was a proposal to move /var/tmp into ramdisk but the other directory under /var should be intact.

User avatar
ilu
Posts: 1602
Joined: 09 Oct 2013 12:45

Re: No terminal output available in gnome updater

Postby ilu » 03 Oct 2017 02:17

Thank you for the hint at term.log, I did not know that. Anyway, /var/log and /var/log/apt specifically is configured for tmpfs.

kurotsugi
Posts: 1920
Joined: 09 Jan 2014 00:17

Re: No terminal output available in gnome updater

Postby kurotsugi » 03 Oct 2017 05:16

well...that's a serious issue :3

User avatar
grizzler
Posts: 1882
Joined: 04 Mar 2013 15:45
Location: The Hague, NL

Re: No terminal output available in gnome updater

Postby grizzler » 06 Oct 2017 14:58

ilu wrote:Anyway, /var/log and /var/log/apt specifically is configured for tmpfs.

Is that by default on all new installations or just on SSD? If not the latter, this needs to change.

The idea of putting my logs in tmpfs would make me scream (and move to another distro - and I'm not even joking here...).
Frank

SolydX EE 64 - tracking Debian Testing

User avatar
Schoelje
Site Admin
Posts: 8422
Joined: 26 Jan 2013 19:36
Location: Netherlands
Contact:

Re: No terminal output available in gnome updater

Postby Schoelje » 06 Oct 2017 18:23

Only on SSD.
The discussion started way back in 2015: viewtopic.php?t=5536
It has been part of the live installer since.

A setup with SSD will have these entries added in fstab:

Code: Select all

tmpfs   /tmp                    tmpfs   defaults,noatime,mode=1777              0       0
tmpfs   /var/tmp                tmpfs   defaults,noatime                        0       0
tmpfs   /var/backups            tmpfs   defaults,noatime                        0       0
tmpfs   /var/log                tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/apt            tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/samba          tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/cups           tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/lightdm        tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/ConsoleKit     tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/clamav         tmpfs   defaults,noatime                        0       0
tmpfs   /var/cache/apt/archives tmpfs   defaults,noexec,nosuid,nodev,mode=0755  0       0


SolydXK needs you!
Development | Testing | Translations

User avatar
ilu
Posts: 1602
Joined: 09 Oct 2013 12:45

Re: No terminal output available in gnome updater

Postby ilu » 06 Oct 2017 19:40

I haven't forgotten about the old discussion. But the situation changed since we don't have the good SolidXK updater anymore. The new software is lacking output if something goes wrong.

Also it can't hurt to rethink decisions. Nearly everyone has a SSD nowadays, they got much cheaper and I've heard that wear is not so much an issue nowadays. This means that nearly everyone with a new computer is without logs. And it's not trivial to explain to somebody inexperienced how to get the logs back. Also its probably too late to save an installation at that point. It's easier to explain how to put it from drive to tmpfs (especially if the commented # entrys are already there) than the other way round.

My starting issue was with the updater. But we probably can't do anything about it, if I did not miss something. So that lead back to the logs.

User avatar
grizzler
Posts: 1882
Joined: 04 Mar 2013 15:45
Location: The Hague, NL

Re: No terminal output available in gnome updater

Postby grizzler » 07 Oct 2017 07:59

Schoelje wrote:Only on SSD.

Ah. OK. I sincerely hope anyone with an SSD who also has a spinning drive has the sense to move /var/log there.

ilu wrote:Nearly everyone has a SSD nowadays, they got much cheaper and I've heard that wear is not so much an issue nowadays.

Generally, yes. However, I seem to remember reading about some application that started logging errors at a ridiculous rate and still managed to destroy people's SSDs. I know I certainly wouldn't put my /var/log there.

We should think of a solution for apt and dpkg logs though. Losing them is a pain, if the current updater doesn't produce any useful output.
Frank

SolydX EE 64 - tracking Debian Testing

User avatar
ilu
Posts: 1602
Joined: 09 Oct 2013 12:45

Re: No terminal output available in gnome updater

Postby ilu » 07 Oct 2017 22:36

I vote for keeping at least everything in /var/log/apt. I really need them now after encountering the already known samba daemon failure. Glad I changed fstab 5 days ago, I hope I can get to the source of the problem now.

My son saw the error message fly by but the updater terminated without any feedback. gpk-log shows a list of packages, nothing useful. Details: https://forums.solydxk.com/viewtopic.php?f=7&t=7037&start=40#p66631

Edit: Thanks to the apt and samba logs resolved.

kurotsugi
Posts: 1920
Joined: 09 Jan 2014 00:17

Re: No terminal output available in gnome updater

Postby kurotsugi » 09 Oct 2017 00:02

Code: Select all

tmpfs   /tmp                    tmpfs   defaults,noatime,mode=1777              0       0
tmpfs   /var/tmp                tmpfs   defaults,noatime                        0       0
tmpfs   /var/backups            tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/samba          tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/cups           tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/ConsoleKit     tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/clamav         tmpfs   defaults,noatime                        0       0

some of the logs are critical so perhaps we should consider to remove some of items from the list. my suggestion is above.

User avatar
Schoelje
Site Admin
Posts: 8422
Joined: 26 Jan 2013 19:36
Location: Netherlands
Contact:

Re: No terminal output available in gnome updater

Postby Schoelje » 09 Oct 2017 05:29

Just to complete your list, kurotsugi, here are the entries that you want to drop from fstab:

Code: Select all

/var/log
/var/log/apt
/var/log/lightdm
/var/cache/apt/archives

Could you also explain why you consider these critical?


SolydXK needs you!
Development | Testing | Translations

kurotsugi
Posts: 1920
Joined: 09 Jan 2014 00:17

Re: No terminal output available in gnome updater

Postby kurotsugi » 09 Oct 2017 06:32

sure :3
- /var/log is the main directory so if you put it into tmpfs, all log will be disapear on reboot.
- /var/log/apt is important as ilu have described above.
- /var/log/lightdm contain information which will be required if you either can't properly boot or can't login.
- /var/cache/apt is oftenly used to restore system to prior condition. for an example, if package A broke, I can downgrade it to restore my system. without apt cache, I'll have to dig into debian's archive repo...which as you know...it's quite a pain since not even google tell you how to use on the first page

these are what I considered critical. though, personally I'm agree with grizzler. in general, the content of /var/log should be left untouched.

User avatar
ilu
Posts: 1602
Joined: 09 Oct 2013 12:45

Re: No terminal output available in gnome updater

Postby ilu » 09 Oct 2017 15:46

After recent experiences I would also consider /var/log/samba important. Or, even better, the whole /var/log

I think it would be good to have that tmpfs configuration in fstab but "out-commented" with the leading "#". That way it would be really easy for anybody who wants to put /var/log in tmpfs to do so - just remove the # from the line you want to put onto tmpfs. If any app runs wild with logs its easy for the user to just copy-paste and edit one of those fstab lines.

This is better than the other way round because I'm still looking for an easy way to get the logs back from tmpfs onto disk.

User avatar
Schoelje
Site Admin
Posts: 8422
Joined: 26 Jan 2013 19:36
Location: Netherlands
Contact:

Re: No terminal output available in gnome updater

Postby Schoelje » 10 Oct 2017 13:32

Then the entries would look like this after a clean install on SSD:

Code: Select all

tmpfs   /tmp                    tmpfs   defaults,noatime,mode=1777              0       0
tmpfs   /var/tmp                tmpfs   defaults,noatime                        0       0
tmpfs   /var/backups            tmpfs   defaults,noatime                        0       0
# Disable /var/log/* tmpfs dirs when enabling tmpfs on /var/log
#tmpfs   /var/log                tmpfs   defaults,noatime                        0       0
#tmpfs   /var/log/apt            tmpfs   defaults,noatime                        0       0
#tmpfs   /var/log/lightdm        tmpfs   defaults,noatime                        0       0
#tmpfs   /var/log/samba          tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/cups           tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/ConsoleKit     tmpfs   defaults,noatime                        0       0
tmpfs   /var/log/clamav         tmpfs   defaults,noatime                        0       0
#tmpfs   /var/cache/apt/archives tmpfs   defaults,noexec,nosuid,nodev,mode=0755  0       0

I can change that in the live installer.

Is everybody alright with this?

[Edit]
I'm still in doubt about /var/cache/apt/archives. Is it usual to use this for what kurotsugi described above? I personally haven't since we're on stable.


SolydXK needs you!
Development | Testing | Translations

User avatar
ilu
Posts: 1602
Joined: 09 Oct 2013 12:45

Re: No terminal output available in gnome updater

Postby ilu » 10 Oct 2017 23:25

Just another reason why this change is necessary: At the moment we can't purge samba because /var/log/samba is a mount point. Took me 2 pages of samba troubleshooting to figure that out :oops:
Come to think of it: That guys samba trouble started shortly after he "deleted/reinstalled the pdf printer" - also /var/log/cups is a tmpfs mount point. So maybe don't mount anything with tmpfs that somebody would like to purge?
At least we have to remember that these mount points could cause all kind of trouble. If somebody wanted to put logs into memory the safest way would be the option to mount the whole /var/log with tmpfs. No mount point trouble when purging. Or do the subdirectories need to be mounted separately?

Regarding /var/cache/apt/archives: does the apt-cache command use these? I use apt-cache quite often but it seems to work ok with the present fstab.

kurotsugi
Posts: 1920
Joined: 09 Jan 2014 00:17

Re: No terminal output available in gnome updater

Postby kurotsugi » 11 Oct 2017 00:22

I'm still in doubt about /var/cache/apt/archives. Is it usual to use this for what kurotsugi described above? I personally haven't since we're on stable.
it is what /var/apt/cache designed to (i.e: avoid downloading large number and packages and ease to fix breakage). though, yes, stable user rarely got these kind of issue so they rarely use it. apt store every downloaded package there and kept them until user manually clean them so it doesn't affect ssd's read/write frequency much.
does the apt-cache command use these? I use apt-cache quite often but it seems to work ok with the present fstab.
apt-cache command and this cache is different. apt has two caches. packages cache, which we discussed above, and package list cache which stored somewhere else. apt-cache reads package list cache. remember when you do "apt-get update" and you downloaded many files? those are the package list. apt stored those files apt's package list cache.


Return to “Bug control”

Who is online

Users browsing this forum: No registered users and 1 guest