Mengubah Blogspot atau blogger menjadi SEO Friendly - Postingan kali ini membahas tentang Tips SEO (Search engine optimization). Postingan ini adalah kumpulan cara untuk men-SEO-kan template blogger / blogspot kita. Tutorial step by step mengedit template blogger / blogspot agar SEO Friendly ini adalah hanya salah satu cara untuk meningkatkan SERP. Lebih detail, berikut adalah langkah-langkah SEO Guide untuk blogger templates :
1. Page Title
Biasanya format page title dari blogger kan seperti ini : JUDUL BLOG : JUDUL POSTING, nah agar blog kita lebih disukai oleh google sehingga ujung-ujungnya blog kita jadi rame, kita harus merubah format page title standart itu menjadi seperti ini : JUDUL POSTING | JUDUL BLOG. Caranya cari kode berikut :
<title><data:blog.pageTitle/> | Kata kunci sobat | Kata kunci sobat </title>
</b:if>
2. Meta keyword dan deskripsi
Mesin pencari seperti google sangat menyukai sebuah website / blog yang jelas tema dan isi content-nya. Oleh karena itu harus menambahkan suatu tag yang namanya meta tag. Caranya adalah dengan menambahkan kode berikut ini sebelum kode <b:skin><![CDATA[/*.
<meta name="description" content="Deskripsi Blog anda" />
<meta name="keywords" content="Kata kunci , kata kunci, kata kunci, kata kunci , kata kunci" />
</b:if>
3. memasang Breadcrumbs. Breadcrumbs adalah menu navigasi yang ada diatas sebuah posting atau artikel. Cara pasangnya juga sudah banyak dibahas di blog-blog guru blogging. Silahkan sobat cari di google dengan kata kunci “ cara membuat menu breadcrumbs”.
4. memasang Related Post. Related post sangat bagus untuk SEO maupun buat pengunjung. Caranya sudah banyak dibahas di blog-blog para guru blogging. Silahkan sobat cari di google dengan kata kunci “ cara membuat related post di blogger”.
5. Disable setting archive Google tidak suka dengan duplicate content. Jadi ketika kita mengaktifkan opsi arsip, misalnya kejadiannya seperti ini : Sebuah blog di blogger.com. dimuat 3 posting. Maka di halaman utama atau homepage akan ada 3 posting dan sebuah link arsip. Halaman arsip tersebut akan memunculkan 3 posting yang sama dengan yang di munculkan oleh homepage. Bagi search engine seperti google ini adalah masalah serius. Oleh karena itu kita sebaiknya me-non-aktifkan opsi arsip, caranya : setelah login klik tab setting >> Archiving >> pada bagian Archiving frequency ubah menjadi no archive. >> selesai simpan setting. Atau jika tidak ingin menonaktifkan fungsi arsip, silahkan letakkan kode berikut dibawah kode :
6. Menambahkan kode ‘rel=canonical’ Gunanya kita menambahkan ‘rel=canonical’ adalah untuk menghindari konten ganda, karena seperti para master of SEO bilang bahwa google sangat tidak dapat mentolerir sebuah duplicate content. Cara nya di edit html tambahkan kode berikut setelah kode <head>
Dengan menggunakan Fitur Replikasi di MySQL dapat membuat duplikasi database master ke slave secara realtime. Database slave ini juga nantinya dapat digunakan sebagai standby server untuk master jika DB master shutdown (in case: terjadi error di master) dengan melakukan perubahan pada aplikasi supaya merujuk ke DB slave.
Dalam membuat replikasi DB Server ini dapat menggunakan operating system Linux maupun Windows.
Langkah-langkahnya adalah sebagai berikut:
1.Master MySQL Database
Lakukan perubahan pada file konfigurasi mysql yang ada di Server Master. Biasanya nama file : mysql.cnf atau my.cnf yang terletak di /etc/mysql (Sesuai dengan Distro yang digunakan).
Lakukan perubahan atau penambahan seperti baris dibawah ini:
To get the most consistent results with a raw data snapshot you should shut down the server during the process, as below:
Acquire a read lock and get the master's status.
In a separate session, shut down the MySQL server:
shell> mysqladmin shutdown
Make a copy of the MySQL data files. Examples are shown below for common ways to do this - you need to choose only one of them:
shell> tar cf /tmp/db.tar./data shell> zip -r /tmp/db.zip./data shell> rsync --recursive ./data/tmp/dbdata
Start up the MySQL instance on the master.
If you are not using InnoDB tables, you can get a snapshot of the system from a master without shutting down the server as described in the following steps:
Acquire a read lock and get the master's status.
Take a copy of the MySQL data files. Examples are shown below for common solutions - you need to choose only one of these solutions:
shell> tar cf /tmp/db.tar./data shell> zip -r /tmp/db.zip./data shell> rsync --recursive ./data/tmp/dbdata
In the client where you acquired the read lock, free the lock:
mysql> UNLOCK TABLES;
Once you have created the archive or copy of the database, you will need to copy the files to each slave before starting the slave replication process.
cron is a unix, solaris utility that allows tasks to be automatically run in the background at regular intervals by the cron daemon. These tasks are often termed as cron jobs in unix , solaris. Crontab (CRON TABle) is a file which contains the schedule of cron entries to be run and at specified times.
Following points sum up the crontab functionality :
1. CrontabRestrictions ____________ You can execute crontab if your name appears in the file /usr/lib/cron/cron.allow. If that file does not exist, you can use crontab if your name does not appear in the file /usr/lib/cron/cron.deny. If only cron.deny exists and is empty, all users can use crontab. If neither file exists, only the root user can use crontab. The allow/deny files consist of one user name per line.
2.CrontabCommands __________ export EDITOR=vi ;to specify a editor to open crontab file.
crontab -e Edit your crontab file, or create one if it doesn't already exist. crontab -l Display your crontab file. crontab -r Remove your crontab file. crontab -v Display the last time you edited your crontab file. (This option is only available on a few systems.)
3. Crontab file ___________ Crontabsyntax :- A crontab file has five fields for specifying day , date and time followed by the command to be run at that interval.
* * * * * command to be executed - - - - - | | | | | | | | | +----- day of week (0 - 6) (Sunday=0) | | | +------- month (1 - 12) | | +--------- day of month (1 - 31) | +----------- hour (0 - 23) +------------- min (0 - 59)
* in the value field above means all legal values as in braces for that column. The value column can have a * or a list of elements separated by commas. An element is either a number in the ranges shown above or two numbers in the range separated by a hyphen (meaning an inclusive range).
Note: The specification of days can be made in two fields: month day and weekday. If both are specified in an entry, they are cumulative meaning both of the entries will get executed .
4. CrontabExample _______ A line in crontab file like below removes the tmp files from /home/someuser/tmp each day at 6:30 PM.
30 18 * * * rm /home/someuser/tmp/*
Changing the parameter values as below will cause this command to run at different time schedule below :
min
hour
day/month
month
day/week
Execution time
30
0
1
1,6,12
*
-- 00:30 Hrs on 1st of Jan, June & Dec.
:
0
20
*
10
1-5
--8.00 PM every weekday (Mon-Fri) only in Oct.
:
0
0
1,10,15
*
*
-- midnight on 1st ,10th & 15th of month
:
5,10
0
10
*
1
-- At 12.05,12.10 every Monday & on 10th of every month
:
Note : If you inadvertently enter the crontab command with no argument(s), do not attempt to get out with Control-d. This removes all entries in your crontab file. Instead, exit with Control-c.
5. CrontabEnvironment ___________ cron invokes the command from the user's HOME directory with the shell, (/usr/bin/sh). cron supplies a default environment for every shell, defining: HOME=user's-home-directory LOGNAME=user's-login-id PATH=/usr/bin:/usr/sbin:. SHELL=/usr/bin/sh
Users who desire to have their .profile executed must explicitly do so in the crontab entry or in a script called by the entry.
By default cron jobs sends a email to the user account executing the cronjob. If this is not needed put the following command At the end of the cron job line .
This article covered a significant aspect of system administration of setting up cronjobs . Unix administration involves lots of different tasks and some of these tasks are covered in this website but still there are many areas not covered here .
If you site relies on MySQL and stores its sensitive data in a MySQL database, you will most definitely want to backup that information so that it can be restored in case of any disaster (manual mistake to delete some data, software errors, hardware errors, server compromise, etc.).
With mysqldump anyone can write a small shell script and running it from cron, it will achieve an automatic backup solution. There are many such scripts already available freely and also many commercial solutions also (I assume as I have not tested any really ;)). The script that I liked the most is AutoMySQLBackup, because it doesn’t have any real requirements (mysqldump of course is needed - in any mysql client package - and gzip or bzip2 to compress the resulting file) and has all the features I was looking for in such a script.
AutoMySQLBackuphas all the features I needed: it can backup a single database, multiple databases, or all the databases on the server; each database is saved in a separate file that can be compressed (with gzip or bzip2); it will rotate the backups and not keep them filling your hard drive (as normal in the daily backup you will have only the last 7 days of backups, the weekly if enabled will have one for each week, etc.). It has also some other features (check the project homepage for full details), that I am not using myself (like email logs for example), but other peoples might find interesting.
The installation is very simple: just download the one file bash script and save it somewhere, customize it to fit your setup (only some basic changes are needed: like the MySQL user and password, backup location), make it executable and activate it in cron as needed (daily for example).
Here are the variables that I usually setup:
# Username to access the MySQL server e.g. dbuser USERNAME=dbuser # Username to access the MySQL server e.g. password PASSWORD=password # Host name (or IP address) of MySQL server e.g localhost DBHOST=localhost # List of DBNAMES for Daily/Weekly Backup e.g. "DB1 DB2 DB3" DBNAMES="all" # Backup directory location e.g /backups BACKUPDIR="/var/backup/mysql" # Mail setup MAILCONTENT="quiet"
You can also run the script manually:
./automysqlbackup.sh.2.5
but probably you will want to enable it in cron and run daily. You can just dump it in the /etc/cron.daily/ folder and you should be done. :). Myself I like to place it in /opt and create a symlink to the file (to help with future updates of the script):
ln -s automysqlbackup.sh.2.5 automysqlbackup.sh
and run it from cron by placing in /etc/crontab something like:
If needed, after the script is finished, you can save the backup folder where you placed the databases to a remote location (ftp, nfs, smb, or whatever) or another local medium (like tape for ex.). Saving to remote locations is not supported in the script itself so you will have to either mount the remote space locally (if it is possible… for nfs, smb, for ex.) and save directly onto it, or you will have to use another method to upload the files remotely (maybe you just have to include the backup folder used above in your regular backup script).
Are you using a different scrip to backup your databases? I would like to hear of it… Why did you like it? What features were you looking for? Or you had to write your own script because you have not found your needed features in any existing script available freely? Let me know…