We can increase the “/tmp” partition on Linux without reformatting the file system.
Use following steps to re-size tmp partition:
- Change “count=2” field as per your requirement.
- Create “/home/tmp-dir” directory in the partition with sufficient available space.
- Change “/tmp” in last command to original path give in /etc/fstab
dd if=/dev/zero of=/home/tmpDir bs=1024M count=2
mke2fs -j /home/tmpDir
mount -t ext3 -o loop /home/tmpDir /tmp
/home/tmpDir /tmp ext3 defaults,loop 0 0
- Set permission to 1777 for “/tmp” once it’s created.
Hope this will make your job easy for resizing /tmp partition.