How to install fluxbox + vnc on debian/ubuntu server / vps

Tutorial to install fluxbox  (window manager for X (light resource use) ) + VNC on debian server / vps


Comands in bold are the commands which you type into Putty (SSH Client)

 

Log in to your server / vps using SSH Client such as putty and issue the commands below in bold, none bold text is the guide.

 

apt-get update
apt-get upgrade



Install the Desktop enviroment & software. In the terminal window (putty) type :-

apt-get install tightvncserver xterm fluxbox iceweasel
update-menus
apt-get install xfonts-base xfonts-75dpi xfonts-100dpi


You may have to substitute iceweasel for firefox & vncserver for tightvncserver on some distro(s)

If running on a xen vps and you see an error like /dev/mem: mmap: Bad address;

There is no real reason for concern, this message is an error output of dmidecode which is called from within one of the scripts for a package you just installed or upgraded. dmidecode is trying to access low-level hardware information in order to pick some suitable default configuration. It will never work under Xen but it can be safely ignored.



The next step is most important!. You have to create a user with normal privileges. To do this issue the following command from putty (ssh):

useradd -m sboxuser1
passwd F43wr29KNw23


(For this example we have used the username sboxuser1 with the password    F43wr29KNw23 you will want to replace these values with more secure )

Next you will be prompted for a new password and then to verify the password, enter your password when asked.

(for example)
New Password: F43wr29KNw23
Verify: F43wr29KNw23

We have to add the user we just created to /etc/sudoers list, this will enable the user to use superuser commands without needing to login with the root user.

visudo

Locate the following line -

root ALL=(ALL) ALL


Insert your created user underneath by unserting the following line (replacing sboxuser1 with your username)  

 

sboxuser1 ALL=(ALL) ALL

save then exit

If you get an error when issuing the command visudo then you will need to install sudo. You can do this by typing the following in putty :-

apt-get install sudo



Load up another Putty terminal by right clicking on the left side of the Putty title bar and select Duplicate Session or you can load up putty like you normally do.

Once you have your new putty session open you need to login with your new username and password. If you are successful then you can close the root session window by typing :-

logout

You may have noticed that at this point the prompt changes from # to a $ symbol. This shows that you are logged in as a normal user and not a root user.

Now that you are logged in as the new user we want to make sure that you are in the home directory for this user. This is done by issuing this command:

cd /
cd /home/sboxuser1/



The next thing we should do is to configure VNC so you can connect to your new Fluxbox Desktop

mkdir .vnc
nano .vnc/xstartup


This file will be empty, just add the line "fluxbox" without quotes,  then save and exit (Ctrl O then Ctrl X)

What this step does is to make sure that Fluxbox starts up when the VNC session is started. (You can use other editors if you prefer such as vi, here we prefer to use nano as its simple and easy to use.)

We need to make the xstartup file executable, we can do this by typing in putty the following command :-

chmod +x .vnc/xstartup

We must start the vncserver by typing the following command in putty:-

vncserver :1


(The first time you run the vncserver it it will ask you to create a password no longer then 8 characters in length)

You will be prompted to enter your password and then to verify it, we have used the password   F43wr29K   in this tutorial.

You will then be asked to input a view only password, you can choose any password for this.  We have used in this tutorial the password sf4w5WY

You will then see something similar to this (your username will replace all instances of sboxuser1 in the following example) :-

    xauth:  creating new authority file /home/sboxuser1/.Xauthority

    New 'X' desktop is rutest:1

    Starting applications specified in /home/sboxuser1/.vnc/xstartup
    Log file is /home/sboxuser1/.vnc/rutest:1.log



SOME HELPFUL STUFF

Remember! Never run VNC as a root user

To kill the VNC process all u have to do is use this command via putty

vncserver -kill :1

The above command will terminate the vnc process.

If you need to change your VNC password then you can do this also in putty by typing

vncpasswd


The Desktop Enviroment is now installed, all you need to do now is to open a VNC viewer client on your home pc and type in the IP address of your server/vps and press connect, make sure you put the :1 on the end of your IP  (example   223.232.333.13:1 ).

You should be prompted for a password, type in your password and you should see your Fluxbox GUI (see www.fluxbox.org for more information).

Thats it for the basic installation of fluxbox and vnc server on a  Debian / Ubuntu Linux Dedicated Server or VPS

  • 147 Users Found This Useful
Was this answer helpful?

Related Articles

How can i show my cpu info (linux)?

How can i show my cpu info? Log in to your server via SSH then typ;e the following command...

How Can i tell if my server is being DoS/DDoS'd (denial of service ) ?

You can use this command to see the number of connections per IP. It's a bit easier on the eye...

How do i fix - 4gb seg fixup on debian (lenny)?

Some clients have had problems when upgrading their vps from Debian Etch to Debian Lenny.  After...

How do i fix - There is no public key available for the following key IDs: 9AA38DCD55BE302B

When i run apt-get update on my debian system i get the following error :- Thereisnopublic key...