[Gta04-owner] ***UNCHECKED*** Re: suggestions for rootfs

H. Nikolaus Schaller hns at goldelico.com
Wed Feb 1 07:13:17 CET 2017

Hi Jonas,

> Am 31.01.2017 um 23:02 schrieb Jonas Smedegaard <jonas at jones.dk>:
> Quoting H. Nikolaus Schaller (2017-01-31 19:57:24)
>> Hi Jonas,
>>> Am 31.01.2017 um 19:41 schrieb Jonas Smedegaard <jonas at jones.dk>:
>>> Quoting Andreas Kemnade (2017-01-31 17:22:46)
>>>> here are some ideas for rootfs.
>>>> 1. /etc/default/rcS
>>>> FSCKFIX=yes
>>>> Well, no chance to press an y key on the gta04, so this at least
>>>> give some chances to have it booted.
>> When is this needed? I could so far use the RS232 console to type the
>> y if needed.
> It is needed when pre-mount routines detect disk corruption that is
> risky to repair, i.e. where you might want to make a backup before
> aggressively trying to fix the errors.  If you are at a terminal, it
> will prompt you if you wanna proceed, but just hangs if you are not at a
> terminal - e.g. a remote server or an embedded device like a phone (not
> in debug mode).

Yes, I know what it does. It is more the question when and how often
we really need it. I.e. how often is disk corruption. I remember it
every 2 years or so after removing the boot-SD card during operation.

So what is better - hang with a rootfs that can be potentially fixed
by hand or trying automatic fsck -y which still may fail and damage the
card even further.

>>> Only relevant when the package sysvinit-core is installed.  By
>>> default with both current and upcoming stable debian, systemd-sysv
>>> is installed instead, which does not use that hint - and in upcoming
>>> stable release the file is not installed at all by default (so
>>> ensure that automated tweaking scripts check existence of the file
>>> before editing!).
>>> Beware that "not default" implies "less tested"!  It is close to
>>> impossible to avoid systemd on Debian nowadays: If you try, you will
>>> quite likely end up with a system running poorly tested code as init
>>> and _still_ load systemd code indirectly through e.g. the SSH daemon
>>> (unless you aggressively avoid well-tested tools and e.g. use
>>> dropbear for ssh).
>> Basically we have a rootfs that must fit into the 512MB NAND flash
>> limitation (which is more like 450MB) and have something useable in
>> NAND flash for demos or as a fallback if there is no woking µSD
>> installed (which has none of these limitations).
>> With stripping languages and manuals I was able to get a working NAND
>> partition filled by just 99% (incl. kernel modules) where you still
>> can run apt-get upgrade (IMHO the package list cache has grown very
>> much). With Debian 7 it was never a problem to fit it into NAND.
>> So some questions related to Debian 9 to make the right decisions: how
>> much space does it need on a rootfs compared to Debian 8.7? Has it
>> grown or did it shrink? Which one needs more space in rootfs: systemd
>> or sysvinit?
> That obviously depends quite a lot on what you consider a "need".

Let's assume you have exactly the same packages for an LXDE system.

> At the work session I attended, I tried to trim your bootstrapping
> script, but you reverted that with the argument that e.g. development
> tools was quite handy to have available...

Those do not seem to need much space. /var/lib/apt/lists alone is 75 MB.
A bigger problem is also that perl and python are fully installed.

> You can also remove /usr/share/doc - for a personally built system.  For
> a system distributed to others, all /usr/share/doc/*/copyright files
> must be preserved.

AH, good hint. I even had removed those to get down to the 99%...

>  It is possible to instruct dpkg to automatically
> skip installing parts of the system, instead of installing fully and
> then removing again afterwards. I believe the package localepurge
> optionally trains dpkg, and I suspect it can be configured to also strip
> additional non-locale-related stuff.

Already done.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.goldelico.com/pipermail/gta04-owner/attachments/20170201/21c9298c/attachment-0001.asc>

More information about the Gta04-owner mailing list