by
Peter on
29 May 2007 in
Tips & Tutorials
In this multi-part article, I’m going to be showing you how to install the popular LAMP stack - that’s Linux, Apache, the MySQL database system and PHP (in this example, although you can have Perl, Python etc. instead) for running your own website or web development server.
The LAMP stack is a very popular setup and many websites run on it (including FOSSwire!). Best of all, all four of the tools in the stack are free and open source and really easy to get started with. For this tutorial, I’m going to be showing you how to install LAMP on Ubuntu 7.04 Feisty Fawn, but the process is very similar for other Linux distributions too. By the way, if you have a Windows machine that you want to do this on, check out this tutorial on our sister site GizBuzz instead for a nice easy WAMP setup.
Step One - get the software
All the stuff you need is pre-loaded into Ubuntu’s software repositories, and it’s really simple to install everything you need. If you’re doing a new install, you may want to take a look at the server edition of Ubuntu as it allows for a pre-configured profile that you can pick at install time.
For this tutorial, I’m going to assume you’ve already got your Ubuntu desktop up and running, though.
Read the rest of Installing and configuring LAMP on Ubuntu - Part 1
by
Peter on
28 May 2007 in
Tips & Tutorials
Occasionally if you’re working with binary files (maybe you’re doing software development for example), you might sometimes need to take a look through a binary file to find the strings that it contains.
Instead of trying to trawl through the rubbish and binary data that isn’t a lot of use to you, you can use the strings command to search through the file for the intelligible information it contains.
For example, you could do this on a critical system program like ls.
$ strings /bin/ls
With GNU ls, you’ll find a fair few strings in there, including:
This is free software. You may redistribute copies of it under the terms of the GNU General Public License .
There is NO WARRANTY, to the extent permitted by law.
Which is exactly the text you’ll see if you run:
ls --version
Just a quick example to prove that it works!
by
Peter on
27 May 2007 in
Tips & Tutorials
On your system, it is perfectly possible that you might have more than one version of a particular application installed. If you’ve custom compiled an application or have concurrent versions of one bit of software, this might be an issue for you.
Now when a program is in your PATH (in one directory of a list of special directories on your system), you can execute it just by typing its name and not the full path (e.g. ls and not /bin/ls).
But what happens when you’ve got two programs in PATH directories called the same thing? Well, usually the order of the directories in PATH will decide which one gets executed. A really easy and quick way to work out which one will get executed, though, is to use the built-in command which.
This command is also extremely useful if you want a quick way to discover where a command is located on the filesystem, for example if you can’t remember whether something is in /bin or /usr/bin.
Simply type which followed by the desired command name.
$ which ls
/bin/ls
Easy, simple and pretty memorable too. Next time you’re hunting for that program’s exact location or are confused about which program is which, use which.