Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

custom kernel can't boot to init 3

Linux Kernel, Network, and Services configuration.
Post Reply
Message
Author
manmath
Posts: 137
Joined: 2009-11-26 07:16
Location: Odisha, India

custom kernel can't boot to init 3

#1 Post by manmath »

Hi All, with my custom build kernel I can't boot into init 3 (text console) though there's no problem booting into plasma desktop. Does framebuffer config have anything to do with it? Here's config file lines about framebuffer:

# Frame buffer Devices
#
CONFIG_FB_CMDLINE=y
# CONFIG_FB is not set
# end of Frame buffer Devices

User avatar
wizard10000
Global Moderator
Global Moderator
Posts: 551
Joined: 2019-04-16 23:15
Location: southeastern us
Has thanked: 75 times
Been thanked: 85 times

Re: custom kernel can't boot to init 3

#2 Post by wizard10000 »

Unless you've customized the runlevel there's no difference between runlevels 2-5 in Debian.

https://wiki.debian.org/RunLevel
we see things not as they are, but as we are.
-- anais nin

User avatar
NorthEast
Posts: 348
Joined: 2018-11-18 04:35
Has thanked: 12 times
Been thanked: 30 times

Re: custom kernel can't boot to init 3

#3 Post by NorthEast »

There's not a lot of info from OP, but these observations may be of interest.
A display manager needs to be enabled to boot into graphical, so you presumably are running one. Systemd can bypass it by making the default target: multi-user.target instead of graphical.target. That can be set thus:

Code: Select all

systemctl set-default multi-user.target
These commands show systemd settings on a machine that boots into a text prompt though a graphical display manager is installed:

Code: Select all

[tom@deb ~] $ systemctl show default.target |grep -e Id -e Names
Id=multi-user.target
Names=multi-user.target default.target runlevel4.target runlevel3.target runlevel2.target

[tom@deb ~] $ systemctl status default.target
● multi-user.target - Multi-User System
     Loaded: loaded (/lib/systemd/system/multi-user.target; indirect; vendor preset: enabled)
     Active: active since Wed 2022-06-22 07:53:51 AEST; 1h 30min ago
      Until: Wed 2022-06-22 07:53:51 AEST; 1h 30min ago
       Docs: man:systemd.special(7)
Jun 22 07:53:51 owl systemd[1]: Reached target Multi-User System.

[tom@deb ~]$ systemctl status graphical.target
○ graphical.target - Graphical Interface
     Loaded: loaded (/lib/systemd/system/graphical.target; static)
     Active: inactive (dead)
       Docs: man:systemd.special(7)
As for the kernel config # CONFIG_FB is not set, all kernels on the machine here that boots to text actually have: CONFIG_FB=y.
I think that without the framebuffer config, the bootup text would just be in the default 80x25 text character by line display, but I speculate that booting would not be affected.

Another means of booting to text prompt which used to work was adding a 3 to the end of the kernel parameters. That's doable by writing it to the "linux ..." line by hitting e when the grub menu appears, navigating down to the linux line, adding the 3 after a space and hitting cntl+x to boot. If that works it can be made permanent by adding it in /etc/default/grub and running update-grub.

manmath
Posts: 137
Joined: 2009-11-26 07:16
Location: Odisha, India

Re: custom kernel can't boot to init 3

#4 Post by manmath »

Yeah, thanks for your suggestion. I can boot into "init 3" with "vga=normal nomodeset" option in the kernel line, but the resulting console is of very low resolution. Any other options land me on a blank screen.
Last edited by manmath on 2022-06-22 08:08, edited 1 time in total.

User avatar
NorthEast
Posts: 348
Joined: 2018-11-18 04:35
Has thanked: 12 times
Been thanked: 30 times

Re: custom kernel can't boot to init 3

#5 Post by NorthEast »

Debian uses a framebuffer to increase the resolution of the console while still showing only the text console. It's the framebuffer that's going to allow for a higher resolution and smaller characters in the text console. The console font can be configured in /etc/default/console-setup. So if you want to have more options for console fonts, you might have to consider enabling the framebuffer. In the olden days one could use: vga=ask as a kernel parameter to get a list of resolutions available, so you could look into that possibility which depends on the VGA/VESA resolutions, but I believe it's been deprecated in debian for some time.

manmath
Posts: 137
Joined: 2009-11-26 07:16
Location: Odisha, India

Re: custom kernel can't boot to init 3

#6 Post by manmath »

"vga=ask" also leads to a blank terminal. well, let me manage with "vga=normal nomodeset" option, maybe I'll get used to after some days.

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: custom kernel can't boot to init 3

#7 Post by p.H »

Blank screen does not mean that the kernel cannot boot.
High resolution console with KMS requires the framebuffer.
wizard10000 wrote: 2022-06-21 14:03 Unless you've customized the runlevel there's no difference between runlevels 2-5 in Debian.
This information is obsolete with systemd : runlevels 2-4 are multi-user.target (text), runlevel 5 is graphical.target.

manmath
Posts: 137
Joined: 2009-11-26 07:16
Location: Odisha, India

Re: custom kernel can't boot to init 3

#8 Post by manmath »

Thanks! I recompiled the kernel with framebuffer, and it's all good now.

User avatar
wizard10000
Global Moderator
Global Moderator
Posts: 551
Joined: 2019-04-16 23:15
Location: southeastern us
Has thanked: 75 times
Been thanked: 85 times

Re: custom kernel can't boot to init 3

#9 Post by wizard10000 »

p.H wrote: 2022-06-25 06:59This information is obsolete with systemd : runlevels 2-4 are multi-user.target (text), runlevel 5 is graphical.target.
Old habits die hard :)

cheers -
we see things not as they are, but as we are.
-- anais nin

Post Reply