LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Desktop (https://www.linuxquestions.org/questions/linux-desktop-74/)
-   -   CentOS: How to set font size/ resolution on main console (https://www.linuxquestions.org/questions/linux-desktop-74/centos-how-to-set-font-size-resolution-on-main-console-768365/)

kumars.nitin123 11-11-2009 04:10 AM

CentOS: How to set font size/ resolution on main console
 
Hi All,
I use CentOS and i need to set resolution or font size so that i can see more lines of logs at a time on the main console of my CentOS box.

Thanks,

arizonagroovejet 11-11-2009 08:02 AM

What do you mean by 'main console'? Are you talk about a screen where you just see some white text on back with something like

Code:

CentOS blah blah

mymachine login:

If so you need to play around with the vga option passed to the kernel in the grub config. The grub config is probably at /boot/grub/menu.lst I use vga=0x31a. For a list of available modes use

Code:

$ hwinfo --framebuffer

kumars.nitin123 11-11-2009 11:47 PM

Yes, i meant by the same thing u replied for.

cat /boot/grub/menu.lst shows :

# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd0,0)
# kernel /vmlinuz-version ro root=/dev/hda2
# initrd /initrd-version.img
#boot=/dev/hda1
default=0
timeout=5
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
title CentOS (2.6.18-8.el5)
root (hd0,0)
kernel /vmlinuz-2.6.18-8.el5 ro root=LABEL=/
initrd /initrd-2.6.18-8.el5.img

And,
hwinfo --framebuffer shows:
-bash: hwinfo: command not found

arizonagroovejet 11-12-2009 07:02 AM

hwinfo is probably available in your repositories but it's not essential, it just gives you a list of what modes your card supports. You can just try codes to see if they work.


You need to modify the kernel line like so
Code:

kernel /vmlinuz-2.6.18-8.el5 ro root=LABEL=/ vga=0x31A
That will set the resolution to 1280x1024. For a list of possible vga codes see http://wiki.antlinux.com/pmwiki.php?n=HowTos.VgaModes


All times are GMT -5. The time now is 01:31 PM.