Download and install VirtualBox. Note: it is safe to keep all of the defaults for installation. If you are having trouble, there are more detailed instructions on the site.
Download the virtual machine image. If your browser asks you what you want to do with the file, just save it – don’t try to open it yet. NOTE: The file is large; this may go faster if download it from NAC rather than from home.
To install the virtual machine, use the File..Import appliance menu, or just hit Ctrl-I. The steps are simple, and it is safe to keep all of the defaults.
Make sure the virtual machine is working: select it from the list on the left and hit “start” from the menu, or just hit enter, or double-click it. This should start the OS in a new window.
You should soon be greeted by a picture of some bamboo or something. If so, rejoice :D Otherwise, you might want to check that the download completed properly. To do this (on a *nix system, including mac), check the SHA-1 hash by running sha1sum arch-103-S17.ova
1 and making sure that the output is:
8191a0143f43e5b173cd62bdb0b742fd03703253
The virtual machine uses a tiling window manager which may take a moment to get used to. Below, I’ve summarized some of the basic commands you’ll need to know to make good use of it. You might also check out this reference card for i3.
alt+d
and then type the name. Use the tab
key to auto-complete. Try opening firefox this way.shift+alt+q
.alt+enter
. From the command line, you can use the command $ open [filename]
and it will usually figure out the right program to open filename
with.alt+1,alt+2,alt+3
, etc. Try opening firefox in a new workspace (switch to workspace 2, and then open firefox).alt+j
to focus a window to the left, alt+;
to focus the right. alt+k
and alt+l
move up and down.alt+f
, or move it to another workspace with say, shift+alt+2
(this moves it to workspace 2).alt+h
before running the next program. To go back to a vertical split, use alt+v
.$ vimtutor
to get started. There are also some links to tutorials on the course information page.cd
, ls
, cp
, mv
, rm
and such instead of a file manager, but if you long for that windows explorer feel, try running thunar
.shift+alt+e
, and then press w
. Do not just close the virtual machine window! (Closing the window is the equivalent of pulling the plug on a real machine, and may leave the disk in an inconsistent state.) Note also that there is a menu in virtual box (file->close->power off the machine
) which sounds good, but should not be used! Use shift+alt+e
and then w
and you should not have any trouble.f
.) If this doesn’t work, see below.alt-tab
). If a key does get stuck, random button mashing might actually be the answer. Just do it somewhere safe!Shift+Insert
, or middle click the mouse (if you only have two buttons, try tapping them both at the same time to get a middle click). However, pasting stuff into your terminal can be dangerous as you may end up running an unintended command. As an alternative, you can try using tmux, which lets you do all this (and much more) with the keyboard.You can put VirtualBox in full screen mode from the menus, or by hitting ctrl-f
(using the right control key by default). Normally the resolution will expand to fill the entire screen, leaving no black regions on the sides, top, or bottom. However, in some cases this does not work, and the screen does not fill the entire space. I’ve left a workaround for this already. Here are the steps:
First, you need to figure out what screen resolution is right. To get a list of candidates, you can either lift it from your normal OS, or run this command in the virtual machine, first making sure full screen mode (with the black borders) is active:
Look for a mode with a +
next to it. This is supposed to be the “preferred” mode for your screen. The current mode will be marked with an asterisk *
. For my laptop, 1366x768
is preferred. In what follows, replace that with your choice, of course. Important: you should test out the mode before setting it! Do it like this:
Hit ctrl-c
if the new resolution looks right (it will be restored automatically in a few seconds otherwise).2 Once you have the right mode, do the following to make the changes permanent, again replacing “1366x768” with your choice.
$ cd ~/packages/dotfiles-103/
$ git pull
$ ln -s ~/packages/dotfiles-103/start-i3.sh ~/.config/
$ echo "1366x768" > ~/.config/x11mode
It may be desirable to share data between your operating system and the virtual machine. This is easily accomplished by any of the following, in descending order of preference.
If you just want to backup and transfer your source code for the projects and such, I’d recommend pushing your repository to a remote server. Bitbucket or github are a good choices for repository hosting.
Use ssh
and scp
.
Make a shared folder using virtual box. There are instructions online, but it is very simple. In the main virtual box window (the one that shows before you boot the guest OS), go to settings..shared folders, and add a folder from your hard drive. Then boot the VM, and run
$ mkdir -p ~/host && sudo mount -t vboxsf -o uid=csc103 shared ~/host
where shared
is the name of the shared folder you set up (the name you supplied to virtual box). Then ~/host
will be the folder on the VM that serves as the mount point. If the command is successful, then ~/host/ will point to the folder you’re sharing from your own OS.
Make backups and transfers using a USB device.
Email yourself.
You can in fact export the entire virtual machine; see the menu “File..export appliance” from the main virtual box window.
Here are a few references you might find useful if you haven’t used linux / unix much.
sed -i -e 's/\(^compton\)/# \1/' ~/.xinitrc
sed -i -e 's/^# \(compton\)/\1/' ~/.xinitrc
csc103
if you ever need them. This is also the root password.On windows, sadly you must resort to 3rd party software. You can try this, but I can’t vouch for it. Hopefully it just works in the first place!↩︎
The modetest
is a simple thing I left in your .bashrc
. It is more or less just xrandr --output VGA-1 --mode 1366x768 && sleep 7 && xrandr --output VGA-1 --auto
.↩︎