matthew@seymour:~$ mysql -h shuttle2 -u foobar -p animals
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 43 to server version: 3.23.58
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql>
NOTE
See the section “The MySQL Command-Line Client” for additional
command-line options.
Later, if you need to revoke privileges from foobar, you can use the
REVOKE statement. For example, the following statement revokes all
privileges from the user foobar:
Click here to view code image
REVOKE ALL ON animals FROM foobar;
Advanced database administration, privileges, and security are complex
topics that are beyond the scope of this book. See the “References” section at
the end of this chapter for links to online documentation. You can also check
out Luke Welling’s and Laura Thompson’s book PHP and MySQL Web
Development.
Configuring PostgreSQL
If you want to use PostgreSQL but do not want to use the version bundled
with Ubuntu, you can find the latest PostgreSQL binary files and source at
[http://www.postgresql.org. The PostgreSQL packages are distributed as several](http://www.postgresql.org. The PostgreSQL packages are distributed as several)
files. At a minimum, you want the postgresql package. You should see
the README file in the FTP directory ftp://ftp.postgresql.org/pub/ to
determine whether you need any other packages.
If you are installing from the Ubuntu package files, a necessary postgres
user account (that is, an account with the name of the user running the server
on your system) is created for you automatically:
Click here to view code image
matthew@seymour:~$ fgrep postgres /etc/passwd
postgres:x:26:26:PostgreSQL Server:/var/lib/postgresql:/bin/bash
Otherwise, you need to create a user called postgres during the
installation. This user should not have login privileges because only root