Build your own Linux router

Things you need: 1. A Linux box 2. Two network adapters that connect to different networks that you wish to route. How: Enable IP Forwarding By default all modern Linux distributions will have IP Forwarding disabled. Use the following methods to enable and configure IP Forwarding. Check if IP Forwarding is enabled: We have to query the sysctl kernel value net.ipv4.ip_forward to see if forwarding is enabled or not: Using sysctl:...

May 12, 2014 · 2 min · Jahnin Rajamoni

Throttle SCP file transfers

Afraid that the scp transfer will eat up all available Bandwidth? To throttle scp file transfers, use the ‘-l’ parameter: For e.g.: To set the file transfer limit to 1Mbps scp -v -l 1024 useraccount@destinationhost:/path scp -v -l 1024 vmware.log root@10.10.10.101:/tmp

May 12, 2014 · 1 min · Jahnin Rajamoni

Finding files in Linux?

Find all .txt files with find: find / -name \\\*\.txt Find all files with pattern: find /path/to/files -type f -exec grep "pattern" {} /dev/null \\; Finding Files Less than 5MB… find / -name '\*' -size -5000k Finding Files Greater than 1 GB… find / -size +1000000k Finding Files modified in the last 10 Minutes… find / -amin -10 -name '\*' Finding Files modified in the last 10 hours… find / -atime -2 -name '*' Finding Files excluding the Mounted filesystems…...

October 25, 2013 · 1 min · Jahnin Rajamoni

Multiple ways to list directories in Linux

ls -ld */ find * -prune -type d -exec ls -ld {} \; ls -l |grep ^d ls -al -d \* | egrep "^d" ls -p | grep "/" tree -d -L 1 find . -type d find . -type d -exec ls -d {} \; ls -d .*"/" *"/"

October 25, 2013 · 1 min · Jahnin Rajamoni

Customizing the logon screens in ESXi

In order to post a message before the user logs in, edit the /etc/issue file and insert your custom text! To post a message after login, edit the message of the day file, i.e. /etc/motd and insert your custom text! To output custom text on the DCUI, from the vSphere Client, navigate to: Host -> Configuration -> Software -> Advanced Settings -> Annotations ->Add text to Annotations.WelcomeMessage

October 10, 2012 · 1 min · Jahnin Rajamoni