linux

Running cron from cli in drupal will result in.

PHP Warning:  include_once(): Failed opening './includes/bootstrap.inc'

Running cron from cli is useful when your behind external authentication and crontab is not available over http. Because normaly you would put something like:

0 * * * * wget --spider http://yoursite/cron.php

In terminal:

First install libevent:

cd /usr/local/src/
wget http://monkey.org/~provos/libevent-1.3e.tar.gz
tar zxpfv libevent*
cd libevent*
./configure
make install

Download and install memcached:

cd /usr/local/src/
wget http://www.danga.com/memcached/dist/memcached-1.2.4.tar.gz
tar zxpfv memcached*
cd memcached*
./configure
make install

In the command line type

crontab -e

Press your insert key.
Insert a line, run every five minutes for example (more on syntax http://unixhelp.ed.ac.uk/CGI/man-cgi?crontab+5)
5 * * * * /usr/bin/lynx -source http://yoursite.com/cron.php

And now exit: press escape and type ":exit"
By exiting you are saving and you wont be prompted.

We have two sites a dutch site and a french site and we want to host it under one url.
Setup your folders in de sites folders. Create a directory for the french site and create a directory for the dutch site. Both will have their own settings file.
In the root of your drupal installation create two symlinks. The two symlinks will point back to the root of your site.

ln -s /var/www/yoursite/ nl 
ln -s /var/www/yoursite/ fr

In the sites folder create the following symlinks.
ln -s /var/www/yoursite/sites/yoursite-dutch yoursite.ext.nl

Goto the location on your server where your file is using cd command

cd /var/www 

To see your location in the server directory tree use pwd command
pwd

For a list of all your databases:
$ mysql -u root -h localhost -p -Bse 'show databases'

To dump your database:

$ mysqldump -u root -h localhost -pmypassword faqs | database_name -9 > database_name.sql

To import your database:

mysql -u user -ppassword --default-character-set=utf8 database < "database_name.sql"

Syndicate content