I've been trying to get this back all night but I've failed so I thought I'd come here and ask.
I was moving my machine (HP Z240 with standard Intel graphics) running Ubuntu Studio 21.10 that was running at 2K resolution. Had a mishap with the DisplayPort cable. Plugged another in and the highest resolution I'm offered is 1080p. Used another cable bought only a month ago, still 1080p.
I did some fiddling with xrandr and for a short while I had 4K running at a very low refresh rate (the original reason for choosing 2K), so at least i know the cable's not the problem. Where have the other resolutions gone? And how can I get them back?
HDMI-1 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 1872mm x 1053mm
1920x1080 60.00 50.00 59.94 30.00 25.00 24.00 29.97 23.98
1920x1080i 60.00* 50.00 59.94
1680x1050 59.88
1600x900 60.00
1280x1024 75.02 60.02
1440x900 59.90
1280x800 59.91
1152x864 75.00
1280x720 60.00 50.00 59.94
1024x768 75.03 70.07 60.00
832x624 74.55
800x600 72.19 75.00 60.32
720x576 50.00
720x576i 50.00
720x480 60.00 59.94
720x480i 60.00 59.94
640x480 75.00 72.81 66.67 60.00 59.94
720x400 70.08
EDIT:
After I did some searching I found a way to decode the display's EDID file using read-edid. This gave me all the modes available for the display. I still don't understand why these are not being read by the system.
Anyway, I found the mode:
"Mode 1" 241.50 2560 2608 2640 2720 1440 1443 1448 1481 +hsync -vsync
which looked very similar to what I had been using. I renamed this mode and then created it as a new one using xrandr. It appeared in settings and allowed me to switch to it.
To make these changes permanent the only suggestion i've found is to run my xrandr script as a batchfile at startup. Is this the only way? And I still have no idea why the original settings are no longer shown.