Publishing web pages using Unix

If possible use Samba

The easiest way to publish your web pages is to map your web filestore using the Samba utility. However, there maybe reasons for doing it using a Unix interface (e.g. you are not using the University network, you are logged onto a Unix machine, etc). Please note: Unix commands are terse and if you are not familiar with the operating system you might find it a struggle. You will also need to setup the file and directory permissions. This is unnecessary if you are using Samba as the utility does it automatically. Many users find getting file and directory permissions set correctly to be the most problematic aspect of setting up web pages on Unix services.

Login and transfer files to your Unix account

The first step is to login into your Unix account on the University Gateway server. You can access this via the hostname "ssh.soton.ac.uk". Secure Shell (SSH) is the recommended network protocol for connecting to iSolutions Unix servers, and is available from all iSolutions Workstations. If you need to install it on your own PC, a SSH client for Windows is available from our software download server. Open SSH using:

Start->Programs->SSH Secure Shell->Secure Shell Client

You must connect using your iSolutions username and password and the hostname "ssh.soton.ac.uk".

Once logged in you will see the Unix prompt (the Unix prompt will look something like [username@gateway ~]$ with username being the username you logged on with).

Use secure File Transfer Protocol (sFTP) in SSH to transfer your files. The sFTP icon is the second icon in the fourth set in the tool bar (a file folder with a quarter circle of blue dots over it). Click it to open an sFTP session to the remote host.

Change access permissions of your directories and files

Your web filestore will already have appropriate permissions for the webserver to serve out content. If you are getting "403 permission denied" errors, there may be a problem with the access permissions for the file or directory in question.

Directories require the "read" and "execute" permissions switched on for everyone. Files only require the "read" permission switched on. To set these permissions use the chmod command:

chmod a+rx the_directory

chmod a+r the_file

If you have a lot of files, you can use wild cards to speed up the process. So, to change the permissions on all your .html files, you could type:

chmod a+rx *.html

Every time you add a new web page via sFTP, you will have to give it the correct permissions.