Apress / low-level-programming

Source code for 'Low-Level Programming' by Igor Zhirkov
http://www.apress.com/9781484224021
Other
768 stars 200 forks source link

VirtualBox display resolution #60

Closed Anding closed 6 years ago

Anding commented 6 years ago

Hello,

I am new to Linux, Debian and VirtualBox. Is there anyway to increase the screen resolution beyond 1024*768? Yes, there are forum threads out there that are not easy to understand, but I'd like to spend time on Low Level Programming instead and would appreciate simple instructions. Thank you!

display

sayon commented 6 years ago

Hello and thank you for pointing the problem out! Unfortunately I am cut off the fast Internet connection until Monday, I will try to upload another VM which does not have that problem in a couple of days.

For now, here is the solution that worked for me:

Long story short

You need to install packages build-essential, module-assistant and run m-a prepare, then install VirtualBox guest additions.

Detailed description

.

  1. In guest Debian: Open terminal and run these commands:
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install -y build-essential module-assistant
sudo m-a prepare

When asked for password, type your user password ('user' by default)

This will prepare your guest OS.

  1. In VirtualBox: Click on 'Install Guest Additions' in 'Devices' menu. Follow instructions to download, install and mount a virtual CD.

  2. Restart guest Debian (might be unnecessary). Check if the virtual CD is mounted correctly, if in doubt click on 'Devices'->'Insert Guest Additions CD image'

  3. Again in guest: Open terminal and run:

sudo sh /media/cdrom/VBoxLinuxAdditions.run

You might need to replace cdrom with cdrom0 or cdrom1.

  1. Restart guest Debian. Your screen should now behave as you expect it to. It even resizes following the size of the VirtualBox's window!

A useful video

https://www.youtube.com/watch?v=KJ5pObje1Dk

Anding commented 6 years ago

Thank you very much indeed. I can also confirm that setting up the tools in another Linux distribution (which I did in the interim) was straightforward.

sayon commented 6 years ago

I have uploaded a default Ubuntu VM with desktop environment and all necessary tools installed. It does not have that resolution problem so I assume it will be more convenient, albeit a little bulkier.