May
5

You can recover MySQL database server password with following five easy steps.

Stop services:

# /etc/init.d/mysql stop
# mysqld_safe --skip-grant-tables &

Login:

#mysql -u root

Output:

Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1 to server version: 4.1.15-Debian_1-log

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql>

Type:

mysql> use mysql;
mysql> update user set password=PASSWORD("NEW-ROOT-PASSWORD") where User='root';
mysql> flush privileges;
mysql> quit

Done!

Just make sure you stop mysql then start normal:

/etc/init.d/mysql stop
/etc/init.d/mysql start

Give a try login with root then type your new password:

mysql -u root -p

Have fun!



©Web design Costa del Sol | SEO Marbella
0
November
9

Setup Rsync

Posted In: Debian, Fedora, Ubuntu, server by IT-Design

#apt-get install rsync
# ssh-keygen -t rsa

press ENTER for all questions.

# cd /root/.ssh
# cp id_rsa.pub myserver

send SPC to the remote server:
# scp /root/.ssh/myserver 192.168.1.2:/var/tmp/

send SPC on different port
# scp ‘-P 2848′ /root/.ssh/myserver 192.168.1.2:/var/tmp/

if you receive an error use the following command to clean the old value on the local and online server:
sed -ie 1d ~/.ssh/known_hosts

Edit /etc/ssh/sshd_config
RSAAuthentication yes
PubkeyAuthentication yes

reload ssh server:
# /etc/init.d/ssh reload

open the remote server and change permition:

# cd /var/tmp/
# cat myserver && ~/.ssh/authorized_keys

run test on the local server: # rlogin 192.168.0.1

COPY FILES OVER SERVERS
# rsync -avz 192.168.1.2:/var/scripts/ /var/scripts/

USING DIFFERENT SSH PORT
# rsync -avz –rsh=’ssh -p2848′ 192.168.0.1:/var/scripts/ /var/scripts/



©Web design Costa del Sol | SEO Marbella
0
November
9

Install Spamassassin

Posted In: Debian, Fedora, Ubuntu, server by IT-Design

# apt-get install spamassassin spamc

<br># groupadd spamd
<br># useradd -g spamd -s /bin/false -m -d /home/spamassassin spamd

<br>#  /etc/init.d/spamassassin stop
<br>#  /etc/init.d/spamassassin start



©Web design Costa del Sol | SEO Marbella
0
November
9

Install webmin

Posted In: Debian, Fedora, Ubuntu by IT-Design

#install dependencies
apt-get install libnet-ssleay-perl openssl libauthen-pam-perl libio-pty-perl libmd5-perl

#download webmin:
wget http://garr.dl.sourceforge.net/sourceforge/webadmin/webmin_1.480_all.deb

#install webmin
dpkg -i webmin_1.470_all.deb

You can now access using the url https://your_ip:10000/



©Web design Costa del Sol | SEO Marbella
0
October
7

This is a simple copy and paste guide for Debian, Ubuntu users to easy install Yahoo domain keys, working for pop and HTML emails with Sendmail installation. Just copy and paste the commands after #

Install DK Milter:

# wget http://switch.dl.sourceforge.net/sourceforge/dk-milter/dk-milter-1.0.1.tar.gz
decompress:
#
tar xvzf dk-milter-1.0.1.tar.gz
install libraries:
# apt-get install openldap-utils gcc
Compiling:
# cd dk-milter-1.0.1
# cp site.config.m4.dist devtools/Site/site.config.m4
# sh Build
# sh Build install

Generate public key:

# cd /root/.ssh/
# openssl genrsa -out rsa.private 768
# openssl rsa -in rsa.private -out rsa.public -pubout -outform PEM
Move your private key to the domainkeys directory:
# cd /var/db
# mkdir dkim
# mv /root/.ssh/rsa.public /var/db/dkim/default.key.pem

YOUR RSA PUBLIC KEY VALUE:
You can find your public RSA key value in /var/db/dkim/default.key.pem between:
—–BEGIN RSA PRIVATE KEY—–

—–END RSA PRIVATE KEY—–

without break lines and spaces.

configure sendmail:

copy the line below under LOCAL_DOMAIN on /etc/mail/sendmail.mc:
INPUT_MAIL_FILTER(`dk-filter’, `S=inet:8891@localhost’)

rebuild sendmail:
# sendmailconfig

libs:

download the libs from the rar file and follow the instructions inside: http://www.it-design.es/libs/dk-filter.rar

start domain key-milter:

#/usr/bin/dk-filter -l -p inet:8891@localhost -d domain1.com, domain2.com -s /var/db dkim/default.key.pem -S default

Note: To add a new domain you must kill the dk-filter process and run the above comand again:

Example:
ps aux | grep dk-filter
Kill pid_number

restart sendmail:
# /etc/init.d/sendmail restart

In your domain provider control panel create the 3 following TXT records:

SPF record for Gmail:
@ v=spf1 ip4:YOUR_SERVER_IP/24 include:blackberry.com ptr:blackberry.com ~all

DOMAIN KEYS:
mail._domainkey k=rsa; t=y; p=YOUR_RSA_PUBLIC_KEY_VALUE

_domainkey o=~; r=your_email

THAT’S ALL!!!

If you find any problem is because you don’t know how to copy and paste…

OTHER GUIDES
Resize existing Ubuntu Partition



©Web design Costa del Sol | SEO Marbella
0