Start Ubuntu Without Starting The Gnome Desktop (text mode)

  • 0

Start Ubuntu Without Starting The Gnome Desktop (text mode)

Get Social!

If you’ve installed a desktop, such as Gnome, on Linux you may not need it all the time. Some of the time taken to boot your machine when you first turn it on is used by loading the GUI and everything that comes with it. In addition, once it’s loaded it will consume resources such as RAM.

Once you install a desktop such as Gnome, especially on Ubuntu/ Debian, the default is to boot your computer into the GUI.

You could set the desktop not to load by default so that you’re presented with a terminal login screen on boot.console-login

You can then load the desktop, such as Gnome, if you need to or just use the terminal if you don’t.

To disable the Desktop on boot you’ll need to edit the grub config file and edit the GRUB_CMDLINE_LINUX_DEFAULT parameter.

GRUB_CMDLINE_LINUX_DEFAULT will likely be quiet splash and you’ll need to change that to quiet splash text.

Save and close the file.

The last step is to run the update-grub command to update the grub bootloader config.

Your computer will now always boot in text mode, that is, without a desktop.

Start the Desktop

If you ever want to start the desktop, log in to the terminal session with your user name and password and run the following:


  • 0

Download Oracle Java From The Terminal With wget

Get Social!

java-logoOracle have a very restrictive license that applies to most of their software downloads which prohibits you from distributing the binaries yourself. What this means, for example, is that you could not download the Java binaries and upload them to your own APT repository for others to use.

There are a few workarounds that exist to help making this install easier, but here we’re going to look at downloading the Java runtime environment (JRE) binaries and installing them all from a command line.

Use wget to download the binaries, so make sure that’s available on your system. If it isn’t, simply apt-get install wget.

One of the important things to note is that the Java version changes over time and therefore the links and commands below may need to be changed to ensure you’re always getting the latest version. Check out the Java Download Page to make sure you have the latest.

I’m using an minimal version of Debian that doesn’t have the worlds Certificate Authorities installed and therefore wget gives me an error:

The fix is to either install the correct CA certificate on the machine or add the no-check-certificate switch to wget to avoid checking the certificate:

Once you have the Java archive downloaded you’ll need to create a target folder and extract the downloaded archive with tar:

The last couple of steps are to tell your OS to use the Java binaries you’ve just moved into place.

Running anything in Java, or using the -version switch should now use your newly installed binaries.




  • 0

Bash Command to Check Container Disk Space in Proxmox/ OpenVZ

Get Social!

proxmox logo gradKeeping an eye on all of your containers disk space can be time consuming if done one by one. Luckily, the vzlist command gives us access to many of the data and counters associated with each container.

Running vzlist on it’s own will give a list of the currently running containers and a few extra columns of information such as IP address and hostname.

You might be thinking that the above command doesn’t show anything about containers which are currently turned off, or about disk space. You’d be right!

Adding the –all switch will include all containers, regardless of their running state.

To add the disk space information we add the –output switch followed by the column names we want to display. For disk space, the column name is helpfully named diskspace so the command will look like this:

We now see the disk space of all of our containers, but with a problem. We have no idea (although in this example we do because we only have one container) which container the disk space output is for. We need to add a few more columns to the –output switch such as ctid and hostname.  (see below for a complete list of output columns)

The last trick here is to add a sort using the –sort switch and the column name

Let’s put all that together, plus a spot of awk magic to get a nice disk full percentage that we can work with:


Complete list of vzlist column headings

You can get a complete list of vzlist column headings with the following command:


  • 1

Installing the OpenVZ Web Panel

Get Social!

There are many web front ends to the OpenVZ virtualisation server which offer varying functionality and are at different stages of development.

Take a look at the OpenVZ Control Panels wiki page for a list and a brief description of what each one does.

One that I have found to be very stable, easy to use and the most feature rich is the OpenVZ Web Panel (OWP). It allows you to create and destroy new OpenVZ containers, manage networking, download new OS templates and a few other things all from a clean web based front end.

Installing the OpenVZ Web Panel

Installing the OpenVZ Web Portal couldn’t be easier – simply run a one-line command on the terminal and let the script do the rest. The script will download all the required dependencies, such as Ruby, and set everything up so that you have a working web address which you can use to administer your OpenVZ server.

Run the below command on your OpenVZ server.

Once the script completes, the web server will be available on your servers IP or hostname and port 3000. The default username and password, which are required for login are:

  • Username: admin
  • Password: admin


If you have iptables installed you will need to add a new rule for the default port 3000.

You can also change the port number by editing the config file of OWP.

And change the PORT attribute to the new port number. Remember to update your iptables configuration to the new port number. See my iptables cheat sheet for more information.

Once you have logged in you will need to change the default admin password. Click on My Profile on the left hand side and fill in the information as requested.


The next time you log in you will be able to log in with your new password.

  • 0

Test Internet Speed from the Command Line

Get Social!

speedtest-netMatt Martez has kindly created and shared a Python script for interacting with for testing bandwidth to the internet from the command line. This is a great script which only has the dependency of Python – something which is available on most Linux distributions.

Grab the script with wget to the server you wish to test. Remember, this is to test the bandwidth to servers which are publically available on the internet – this does not test your internal server to server communication. See Iperf for details on testing LAN bandwidth.

Add the execute permission:

And that’s all you need to start your first speed test! Run the speedtest-cli with the –simple switch to start your first basic speed test. The script will automatically choose the best server based on your location.

You can use the –help switch to see all the options you have with the tool.

  • 0

Create a permanent virtual IP address in Linux

Category : How-to

Get Social!

In a previous post, we saw how to create a virtual IP address, based on an existing network interface. The trouble with this method is that the virtual IP address will vanish when you reboot your machine.

On option is to attach the script to the network up and down scripts however there is a much easier way!

In Debian/ Ubuntu you simply create a new, virtual interface in the interfaces file.

And add a network interface, based on an existing interface. The below example is a virtual IP based on eth0 – note if this is your second virtual IP you would use eth0:2, and so on.

You will need to change the IP addresses to match your network. Notice there is no gateway – usually you can only have one gateway per machine.

Restart networking for the changes to take effect.

Visit our advertisers


Visit our advertisers