1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

【CentOS7】画面の解像度の変更

Last updated at Posted at 2021-06-07

環境

  • 仮想マシンでCentOS7

手順

1./etc/default/grubの変更

vi /etc/default/grubで編集する
7行目のquietの後ろにvga=数値を入れる(例として792を入れいている)

変更前
1 GRUB_TIMEOUT=5
2 GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
3 GRUB_DEFAULT=saved
4 GRUB_DISABLE_SUBMENU=true
5 GRUB_TERMINAL_OUTPUT="console"
6 GRUB_CMDLINE_LINUX="spectre_v2=retpoline rd.lvm.lv=centos/root rd.lvm.lv=centos/swap rhgb quiet"
7 GRUB_DISABLE_RECOVERY="true"
変更後
1 GRUB_TIMEOUT=5
2 GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
3 GRUB_DEFAULT=saved
4 GRUB_DISABLE_SUBMENU=true
5 GRUB_TERMINAL_OUTPUT="console"
6 GRUB_CMDLINE_LINUX="spectre_v2=retpoline rd.lvm.lv=centos/root rd.lvm.lv=centos/swap rhgb quiet vga=792"
7 GRUB_DISABLE_RECOVERY="true"

※行数は:set numberで表示可能

数値の決め方

bit 640 x480 800 x600 1024 x768 1280 x1024 1400 x1050 1600 x1200
8 769 771 773 775 835 796
15 784 787 790 793 - 797
16 785 788 791 794 837 798
24 786 789 792 795 838 799
32 809 814 824 829 - 834

2.変更後に以下を実行する

# grub2-mkconfig -o /boot/grub2/grub.cfg
# reboot

参考サイト

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?