Monthly Archives: November 2005

ubuntu sources.list generator

Site to generate an ubuntu sources.list for your preferred set of repositories. Just tick all repositories you want; the default set is selected automatically.

source-o-matic

using kpkg to build kernels

Using kpkg to Build Kernels

See also How To Compile A Kernel – The Ubuntu Way

Preparation

  • make backup floppy
 mkboot /boot/kernel...
  • add myself to src group (logout & login) (more…)

guest and public

  • guest = valid login but no account
  • guest is created (but disabled) by default; to enable run GRANT CONNECT TO GUEST
  • guest gets the permissions of the public role (as does everyone)
  • by default public has no permissions
  • Northwind: permissions are granted to public
  • pubs: permissions are granted to guest

Backup multiple MySQL databases into separate files

#!/bin/bash
# sonia 16-nov-05
# backup each mysql db into a different file, rather than one big file
# as with --all-databases - will make restores easier

USER="root"
PASSWORD="secret"
OUTPUTDIR="/var/lib/bacula"
MYSQLDUMP="/usr/bin/mysqldump"
MYSQL="/usr/bin/mysql"

# clean up any old backups - save space
rm "$OUTPUTDIR/*bak" > /dev/null 2>&1

# get a list of databases
databases=`$MYSQL --user=$USER --password=$PASSWORD \
 -e "SHOW DATABASES;" | tr -d "| " | grep -v Database`

# dump each database in turn
for db in $databases; do
    echo $db
    $MYSQLDUMP --force --opt --user=$USER --password=$PASSWORD \
    --databases $db > "$OUTPUTDIR/$db.bak"
done

Connect to MySQL across network using MS Access

  • comment out line in /etc/mysql/my.cnf that reads:
     bind-address = 127.0.0.1
     mysql> use mysql;
     mysql> select Host, User, Password from user;
     mysql> update user set host='%' where user = 'root';
     mysql> q
    • restart

    (more…)

Next Page »