Category: linux

Hard link and soft link?

I would like to give some examples to describe practical meaning of hard links,soft links and cache in memory in a linux system. I will start creating two ramdisk partitions: # mkdir /ramdisk1 [root@tux ~]# mkdir /ramdisk2 [root@tux ~]# mount none -t tmpfs -o size=256m /ramdisk1 [root@tux ~]# mount none -t tmpfs -o size=256m /ramdisk2
Read More »

How to use ulimit utility to restrict users?

You can use ulimit command to prevent users from abusing system resources. Below I will touch two of the options; root@deb1:~# ulimit -a core file size (blocks, -c) 0 data seg size (kbytes, -d) unlimited scheduling priority (-e) 0 file size (blocks, -f) unlimited pending signals (-i) 15957 max locked memory (kbytes, -l) 64 max
Read More »

Reverse SSH connection

Imagine that you have a host (named A) somewhere that has no publicly reachable IP address but you would like to connect it via SSH. If this host A can reach outside, then you can reverse SSH into it. Here is the scenario; Host A (192.168.1.1) —  INTERNET —- Host C (10.10.10.1) On host A,
Read More »

Traffic shaping with TC in Linux

Traffic shaping is a method to control the rate at which packets are sent and Linux does a pretty good job in doing this. I am currently developing a shell-like interface for TC in python and the following script is the framework for the application. I will update this post as I have more experience
Read More »

Generic/TCP Segmentation Offload and Wireshark

Before reading this post you may have a look at the link http://en.wikipedia.org/wiki/Large_segment_offload which is the main motive of this post. While I was trying to troubleshoot some TCP communication, I wanted to investigate something which I have ignored so far. Maybe one screenshot is more than many words; Have a look at total length field of
Read More »