Tuesday, April 19, 2011

This is for me.

copy mysql db to cloud

- dump your db
- mv to www server
- go to amazon aws server
- run this

sudo scp username@www.mediu.edu.my: ./


wait untuil it finish

Thursday, April 7, 2011

SNMPD on freebsd

I'm using FreeBSD 8.2 and here's the basics for getting snmp working:

cd /usr/ports/net-mgmnt/net-snmp
make
make install
make clean

edit /etc/rc.conf
add snmpd_enable="YES"

cd /usr/local/share/snmp
edit snmpd.conf (you may have to create it)
add the following
syslocation home (replace home with whatever you'd like)
syscontact me@here.com (put in your e-mail or whatever)
rocommunity private (replace with whatever read only name you'd like)
rwcommunity public (again, change this to whatever you'd like)
master yes
now save and exit

cd /usr/local/etc/rc.d
./snmpd.sh start

This will get you up and running with a very basic snmp configuration. There's a handy utility called 'snmpconf' that can be run to help you generate the snmp.conf (optional) and snmpd.conf files. This will give you more options and help tighten up security.

at this point you should be able to snmpwalk your host
snmpwalk -v1 -c public 127.0.0.1

Wednesday, April 6, 2011

format HDD on Ubuntu 10.10

After add HDD on your ubuntu box
check your hdd either its already present or not by using

fdisk -l

on your screen you will see

Disk /dev/cciss/c0d1: 1499.8 GB, 1499832039424 bytes
Disk /dev/cciss/c0d1 doesn't contain a valid partition table

after you know your OS HDD first hdd must be c0d0 and the number will increse on d example c0d0,c0d1,c0d2 etc

run this command to format your hdd, for this tutorial i will format ext3 for my HDD


mkfs.ext3 /dev/cciss/c0d1

wait for few minutes
now you done!