Here an easy way to set up an email sandbox in Linux. All email sent from the server will be forwarded to an external email address.
1. Install postfix with pcre support.
apt-get install postfix postfix-pcre
2. Create the file /etc/postfix/virtual with the following line it (replace firstname.lastname@example.org with the email address that should receive all email).
3. edit /etc/postfix/main.cf and add the following line at the end
virtual_alias_maps = pcre:/etc/postfix/virtual
4. Restart postfix.
Unlike MySQL there is no default user name and password. To connect to a freshly installed PostgreSQL server on Linux you will need to change to the postgres user:
sudo su – postgres
After that you can connect to the server by simply typing
A more detailed explanation can be found at www.liquidweb.com/kb/what-is-the-default-password-for-postgresql/
Often when you start implementing something new you want to test your playbook on a single instance. If your Ansible hosts file looks like this
and you only want to run your playbook on host1, add the –limit paramter:
ansible-playbook –limit host1 playbook.yml
When you receive an error message like
scp: writing /tmp/mkinitramfs_Y2BgCE/ [..] : No space left on device
check how big your tmp folder is. If it looks like
overflow 1.0M 1.0M 0 100% /tmp
your volume was probably full at a time. After you allocated new disk space umount your volume with
If you receive the error “umount: /tmp: device is busy.” run “lsof /tmp/” to see what is using it.
After umounting /tmp your system should work fine again. You can prevent /tmp from reappearing after a restart with
echo 'MINTMPKB=0' > /etc/default/mountoverflowtmp
Having just downloaded Kali Linux I was wondering how to convert its VMware image to VirtualBox, thankfully I quickly found a page that just recommended to create a new virtual machine and add the VMware image as a disk: http://opendirective.net/blog/2014/07/on-converting-a-vm-from-vmware-to-virtualbox/
So if you want to run Kali Linux in Virtualbox, just
a) Create a new virtual machine in VirtualBox
b) Slect ‘Use an existing virtual hard drive file’ and select the Kali-Linux image (e.g. Kali-Linux-1.1.0-vm-amd64, the one without -s00x in the name)
By they way, the default login for Kali Linux is root / toor
Asus routers like the RT-N66U have support for SNMP in the latest firmware. Here is how to enable and test it (here using the awesome Asuswrt-merlin alternative firmware ).
Go To Administration and click on SNMP. Enable SNMP, enter a system name, system location, SNMP Get Community (just any text, this acts like a password). Click on Apply to activate the changes.
To test if SNMP is working you can use the snmpwalk command. If your router IP address is 192.168.1.1 and your SNMP Get Community string is ‘public’, run
snmpwalk -Os -c public -v2c 192.168.1.1 iso.184.108.40.206.1.1.1
The output should look like “iso.220.127.116.11.18.104.22.168 = STRING: “Linux RT-N66U 22.214.171.124 #1 Thu Nov 20 13:57:15 EST 2014 mips” if SNMP is working. If it is not working you will receive a message like “Timeout: No Response from 192.168.1.1”.
To get more data from SNMP run ‘snmpwalk -Os -c public -v2c 192.168.1.1’