One solution for Failed to get size of gamma for output default

One solution is to make an /etc/X11/xorg.conf file which uses a vesa driver.

An example about workable /etc/X11/xorg.conf

Section "Monitor"
Identifier "Monitor0"
VendorName "Monitor Vendor"
ModelName "Monitor Model"
HorizSync 31.5-67
VertRefresh 50-75
#UseModes "Modes0" #monitor0usemodes
Option "PreferredMode" "1280x1024"
EndSection

Section "Modes"
Identifier "Modes0"
#modes0modeline0
EndSection

Section "Device"
### Available Driver options are:-
### Values: : integer, : float, : "True"/"False",
### : "String", : " Hz/kHz/MHz"
### [arg]: arg optional
#Option "ShadowFB" # []
#Option "DefaultRefresh" # [
]
#Option "ModeSetClearScreen" # [
]
Identifier "Card0"
Driver "vesa" #card0driver
VendorName "Silicon Integrated Systems [SiS]"
BoardName "661/741/760 PCI/AGP or 662/761Gx PCIE VGA Display Adapter"
BusID "PCI:1:0:0"
EndSection

Section "Screen"
Identifier "Screen0"
Device "Card0"
Monitor "Monitor0"
DefaultDepth 16
#Option "metamodes" "1280x1024_60 +0+0" #METAMODES_0
Subsection "Display"
Depth 16
Modes "1280x1024"
EndSubsection
EndSection

If that does not work, delete that file as root or use sudo via tty, where you get pressing ctrl alt f1

sudo rm /etc/X11/xorg.conf

sudo reboot