WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: [Solved] How to enable busybox terminal on F8 to F12 keys in Core Linux 13.0?  (Read 2252 times)

Tiago Araujo da Costa

  • Guest
« Last Edit: July 22, 2022, 06:01:55 AM by Rich »

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11178
Re: How to enable busybox terminal on F8 to F12 keys in Core Linux 13.0?
« Reply #1 on: March 01, 2022, 05:18:37 PM »
Hi Tiago Araujo da Costa
Try adding this boot code:
Code: [Select]
multivt
Found here:
http://forum.tinycorelinux.net/index.php/topic,21866.msg136816.html#msg136816
« Last Edit: March 04, 2022, 05:20:21 PM by Rich »

Tiago Araujo da Costa

  • Guest
Re: How to enable busybox terminal on F8 to F12 keys in Core Linux 13.0?
« Reply #2 on: March 04, 2022, 04:20:55 PM »
multivt already exists in boot code.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11178
Re: How to enable busybox terminal on F8 to F12 keys in Core Linux 13.0?
« Reply #3 on: March 04, 2022, 05:17:13 PM »
Hi Tiago Araujo da Costa
That boot code should give you F1 to F6. Does it have to be F8 to F12? Or do you need more terminals?

Tiago Araujo da Costa

  • Guest
Re: How to enable busybox terminal on F8 to F12 keys in Core Linux 13.0?
« Reply #4 on: March 14, 2022, 03:55:52 AM »
I need to run Ash terminal on F8 to F12 keys too.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11178
Re: How to enable busybox terminal on F8 to F12 keys in Core Linux 13.0?
« Reply #5 on: March 14, 2022, 07:59:51 AM »
Hi Tiago Araujo da Costa
I think you need to edit the  etc/inittab  file in your  initrd  for that. The general procedure for that is:
Create a temporary worlspace:
Code: [Select]
mkdir tempdir
cd tempdir

Unpack the initrd:
Code: [Select]
zcat /path/to/boot/files/core.gz  PIPE  sudo cpio -i
Add entries for tty8 through tty12:
Code: [Select]
editor etc/inittab
Repack the initrd to a new name:
Code: [Select]
sudo find .  PIPE  sudo cpio -o -H newc  PIPE  gzip > /path/to/boot/files/coretty12.gz
Notes:
1. Where you see the word  PIPE , replace it with the pipe symbol (|). It's on the backslash (\) key.
2. Add another entry to your bootloaders config file and point it at  coretty12.gz.
3. If you are running a GUI, I think F7 will return you to your desktop with these settings.
4. Don't forget that period between  find  and  PIPE.

Tiago Araujo da Costa

  • Guest
Re: How to enable busybox terminal on F8 to F12 keys in Core Linux 13.0?
« Reply #6 on: July 22, 2022, 05:48:06 AM »
Success.

Content of /etc/inittab

Code: [Select]
# /etc/inittab: init configuration for busybox init.
# Boot-time system configuration/initialization script.
#
::sysinit:/etc/init.d/rcS

# /sbin/getty respawn shell invocations for selected ttys.
tty1::respawn:/sbin/getty -nl /sbin/autologin 38400 tty1
#tty2::respawn:/sbin/getty -nl /sbin/autologin 38400 tty2
#tty3::respawn:/sbin/getty -nl /sbin/autologin 38400 tty3
#tty4::respawn:/sbin/getty -nl /sbin/autologin 38400 tty4
#tty5::respawn:/sbin/getty -nl /sbin/autologin 38400 tty5
#tty6::respawn:/sbin/getty -nl /sbin/autologin 38400 tty6
#tty8::respawn:/sbin/getty -nl /sbin/autologin 38400 tty8
#tty9::respawn:/sbin/getty -nl /sbin/autologin 38400 tty9
#tty10::respawn:/sbin/getty -nl /sbin/autologin 38400 tty10
#tty11::respawn:/sbin/getty -nl /sbin/autologin 38400 tty11
#tty12::respawn:/sbin/getty -nl /sbin/autologin 38400 tty12

# Stuff to do when restarting the init
# process, or before rebooting.
::restart:/etc/init.d/rc.shutdown
::restart:/sbin/init
::ctrlaltdel:/sbin/reboot
::shutdown:/etc/init.d/rc.shutdown

Content of /sbin/autologin

Code: [Select]
#!/bin/busybox ash
. /etc/init.d/tc-functions
useBusybox
if [ "$1" = "tty1" ]; then
if [ -f /var/log/autologin ] ; then
    exec /sbin/getty 38400 tty1
else
    touch /var/log/autologin
    exec login -f root
fi
else
exec login -f tc
fi

    [EDIT]:  Added code tags.  Rich
« Last Edit: July 22, 2022, 06:01:00 AM by Rich »

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11178
Hi Tiago Araujo da Costa
Please use  Code Tags  when posting commands and responses seen in a terminal. To use  Code Tags  click on the  #  icon
above the reply box and paste your text between the  Code Tags  as shown in this example:

Quote
[code][   36.176529] pcm512x 1-004d: Failed to get supply 'AVDD': -517
[   36.176536] pcm512x 1-004d: Failed to get supplies: -517
[   36.191753] pcm512x 1-004d: Failed to get supply 'AVDD': -517[/code]

It will appear like this in your post:
Code: [Select]
[   36.176529] pcm512x 1-004d: Failed to get supply 'AVDD': -517
[   36.176536] pcm512x 1-004d: Failed to get supplies: -517
[   36.191753] pcm512x 1-004d: Failed to get supply 'AVDD': -517

Code Tags  serve as visual markers between what you are trying to say and the information you are posting. They also preserve
spacing so column aligned data displays properly. Code tags also automatically add horizontal and or vertical scrollbars
to accommodate long lines and listings.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11178
Hi Tiago Araujo da Costa
Thank you for confirming it worked.

There is no need to lock the topic, I have marked it as solved. :)