The installation of Ubuntu Server is similar to the desktop edition, with two exceptions. First, it does not automatically add the second (host-only) networking interface to the Linux configuration and the apt-sources for Java are missing. This can be fixed easily:
Adding the second networking interface
Ubuntu Server 16.04:
Modify /etc/network/interfaces. and add the following code to it:
auto enp0s8
iface enp0s8 inet dhcp
Older Ubuntu Versions:
Modify /etc/network/interfaces. You should have two network interfaces (eth0 and eth1 where one is the NAT interface and the other one the vboxnet0 interface), but only one has been configured by the Ubuntu installer. Assuming eth1 is the vboxnet0 interface, the file should contain these contents:
...
auto eth0
auto eth1
iface eth0 inet dhcp
iface eth1 inet static
address 192.168.56.101
netmask 255.255.255.0
Replace 192.168.56.101 with your desired (static) IP address. After the modification, run "ifup eth1" to get the interface working.
Adding an apt repository for Sun Java
Add the following line to /etc/apt/sources.list:
deb http://archive.canonical.com/ubuntu lucid partner
After this run apt-get update.