Posts: 91
dirkd
Joined: 30 May 2014
#1
When transferring an iso-snapshot to USB I can choose a language to be used when booting up the system. However, the offered list of languages is very incomplete. When I choose 'Dutch', the boot-option lang=nl_NL is added to the live system. However, in Belgium we use another default keyboard layout than in the Netherlands, so nl_BE would be better. Again, one can change the keyboard layout for the live system at boot time, but I want to give these USB keys to young, inexperienced students. A wrong keyboard layout can be very confusing for them. So having the correct one as default would be preferable.

Another issue to consider: when adding the language option I not only change the keyboard layout, but the interface too (menu's especially, help files too maybe) gets translated. These translations have very bad quality: they are incomplete, non-standard (compared to what one is used to under Windows) and generally confusing. They are also not necessary: every student that is going to use this system has learned English sufficiently well. So it would be better to keep the English interface, and ONLY change the default keyboard layout.

Can such a thing more or less easily be done?

(When making the ISO snapshot, I keep the existing user. Nevertheless, my keyboard customizations seem to get lost).
Posts: 1,445
skidoo
Joined: 09 Feb 2012
#2
translations-t5617.html
It's possible that, at the moment, no one other than _you_ is available to contribute"better Dutch translations" for the antix-authored packages (ControlCentre, etc.)

After skimming a couple pages

========= SCRAPER REMOVED AN EMBEDDED LINK HERE ===========
url was:"https://bbs.archlinux.org/viewtopic.php?id=153137"
linktext was:"https://bbs.archlinux.org/viewtopic.php?id=153137"
====================================


========= SCRAPER REMOVED AN EMBEDDED LINK HERE ===========
url was:"http://www.tldp.org/HOWTO/Belgian-HOWTO/configuration.html"
linktext was:"http://www.tldp.org/HOWTO/Belgian-HOWTO ... ation.html"
====================================


========= SCRAPER REMOVED AN EMBEDDED LINK HERE ===========
url was:"https://www.linux.com/learn/docs/ldp/446-belgian-howto"
linktext was:"https://www.linux.com/learn/docs/ldp/446-belgian-howto"
====================================


========= SCRAPER REMOVED AN EMBEDDED LINK HERE ===========
url was:"http://www.unix.com/man-page/osf1/5/dutch/"
linktext was:"http://www.unix.com/man-page/osf1/5/dutch/"
====================================

I'll suggest (if you haven't already done so) prior to creating a snapshot, perform this terminal operation:
sudo dpkg-reconfigure locales
It will present you with an opportunity to set the EXACT locale (NL_be.UTF-8 or NL_be.ISO-KAMASUTRA or whatever)
and it provides an opportunity to DEselect the many preinstalled locales which are"not useful on your particular system".
Afterward (again, PRIOR to performing snapshot), run the"bleachbit" program, AsRoot.
Doing so will eliminate 8,000-10,000 unneeded language-related files (YMMV, depending on which, and how many, apps have been installed).

Specific to NL_be keyboard setup, reviewing these past discussions may be helpful to you:
problem-with-antix-installer-itself-t3606.html
antix-system-t2970-15.html
Posts: 91
dirkd
Joined: 30 May 2014
#3
Just to be clear: I have no problems anymore configuring keyboards and locale on an installed system. It's just that that the live system resulting from an iso-snapshot seems to use its own keyboard configuration, in stead of the one I configured before taking the snapshot. Antix 13.3 gave me a live system with a belgian keyboard. So if not too much has changed, I should manage to do so again. Thanks for the links: dpkg-reconfigure locales, and the discussion by AC about antix-system look promising. I'll report back.

I don't blame anyone for incomplete translations. I fully realise the task is humongous. Even Microsoft, not exactly short on resources, fails in some ways. For me the solution lies in sticking with the English interface language as much as possible. Provided one has a reasonable grasp of the language, that is.
Posts: 1,445
skidoo
Joined: 09 Feb 2012
#4
(this is my"best guess", perhaps not a definitive solution)

When booting from a snapshot you've created, try adding this to the bootline:
locale=nl_BE bootkbd=be-latin1 console-setup/layoutcode=be-latin1
(From what you've described, you may want to change the locale= portion)

If this achieves the desired result, to make it the permanent default, you could try adding those args to the bootmenu entries by editing
/boot/grub/grub.cfg
but that not will not be possible if you're booting the snapshot iso from CD, so, instead...

During the snapshot creation, in the workflow there's a prompt:
"The program will now pause to allow you to edit any files in the work directory.
Select Yes to edit the boot menu or select No to bypass this step and continue creating the snapshot."

Here you should be able to inject your custom bootline args by editing the $work_directory/.../grub.cfg

edit:
OOPS, that isosnapshot dialogbox offering to"pause while you edit the files" it isn't displayed unless you have edited
iso-snapshot.conf
and changed line57 (or so) so that it reads as:
edit_boot_menu=yes
Last edited by skidoo on 22 Aug 2015, 05:21, edited 1 time in total.
Posts: 91
dirkd
Joined: 30 May 2014
#5
Thank you, Skidoo. All those fancy bootline codes didn't work, but they put me on the right track. Simply adding kbd=be did the trick. I didn't understand what the <F8-SAVE> option on the boot screen (when booting live from USB) actually did, but now I do. After adding an additional bootcode and saving with the help of <F8>, the next bootcycle makes a new boot menu entry (CUSTOM) the default one. That entry boots AntiX, but with the additional boot code (kbd=be in my case) included.

As for me, this is a perfectly workable solution, even if not ideal. With workable I mean that I can distribute a live USB key to someone with no experience whatsoever with linux, and be confident that he/she can boot it without problems. The only information needed is the password (type antix whenever a password is required), on every other question, just <Enter>. For that to work, the keyboard must behave as expected. So, this topic can be marked as SOLVED (I can't do this myself, can I?).

I also found a hack, which I DO NOT RECOMMEND, but if someone is desperate: it works. In the script /usr/local/bin/antix2usb.py you will find a list of bootcodes of the form 'LANG=xy_XY'. When starting this script from the control center, there is a drop-down list (called Language), that lets you choose one of these language codes. Now, if you want another bootcode added at the end of the default boot entry on your live USB stick, you can easlily edit that list in the python script. Like this:

Code: Select all

LANGUAGES = [["bg_BG","Bulgarian"],
    ["kbd=be,us","=My own standard boot code="],
    ["lang=ca_ES","Catalan"],
    ["lang=cs_CZ","Czech"],
    ["lang=da_DK","Danish"],
....
Indeed, the problem of changing the keyboard layout during boot time seems to lie entirely in the Antix2usb script. The Iso-snapshot script allows for more configuration (including a custom keyboard layout), but part of that flexibility is lost when transferring the iso to USB. Of course, booting from USB itself is more flexible than from DVD. (One of my old laptops I use for testing wont boot from DVD - iso too large I guess - but boots happily from USB).

During my detective work, I also stumbled upon the configuration file for the Antix 13.2 snapshot script. I guess this file has no real purpose anymore? In the older setup everything that went into the iso was first copied to a temporary folder, and there was an option to edit everything in that folder before actually compiling the iso-file. This option has disappeared in Antix15. Maybe to save disk space? But the older scheme had its merits.

The following questions are purely asked in the hope of learning a bit more, so don't waste too much time on them:
  • you advised me to edit /boot/grub/grub.cfg, but actually, my USB stick uses extlinux in stead of grub. I can't even choose grub when running the antix2usb script (grub and syslinux options are greyed out).
  • in a previous post you proposed deleting all unneeded language files. Isn't that dangerous, when eg, you choose a language code in the antix2usb script that refers to files previously deleted from the system?
To round up this discussion: I can perfectly understand the logic of ALWAYS using a standard US keyboard on booting. When you distribute a live system world wide, you don't want users across the world to be confronted with a Belgian keyboard layout. But for purely local purposes, it can be handy to use a custom keyboard layout. And Antix boot codes make this possible (with a little effort). I don't know if other systems have these boot codes too (they may well be standard grub features for all I know), but I like them a lot. Very thoughtful design feature.
anticapitalista
Posts: 5,955
Site Admin
Joined: 11 Sep 2007
#6
dirkd - just a quick comment.

We have tried to improve localisation, especially for live usage, into the design of antiX. We probably still have a way to go and as you have noticed, what worked well enough in antiX-13 may not work as well or works in a different way to antiX-15. When I'm back in Greece to work on antiX, we'll aim to improve this feature further.