Unix and Linux network configuration. Multiple network interfaces. Bridged NICs. High-availability network configurations.


Reviews of latest Unix and Linux software. Helpful tips for application support admins. Automating application support.


Disk partitioning, filesystems, directories, and files. Volume management, logical volumes, HA filesystems. Backups and disaster recovery.


Distributed server monitoring. Server performance and capacity planning. Monitoring applications, network status and user activity.

Commands & Shells

Cool Unix shell commands and options. Command-line tools and application. Things every Unix sysadmin needs to know.

Home » Commands & Shells

Quickly Grow tmpfs filesystem

Submitted by on August 6, 2018 – 4:13 pm

Just a quick command to double the size of the /tmp filesystem that uses tmpfs. This is  for those situations when you can’t be bothered to think.

df -hlP /tmp && (( s = `df -lP /tmp | grep ^tmpfs | awk '{print $2}'` * 2 *1024 )) && mount -o remount,size=${s} tmpfs /tmp && df -hlP /tmp

One thing to keep in mind, however, is that tmpfs is stored in volatile memory – sort of like a RAM disk – so it can pretend to be as big as you want it, but it can’t really hold more data than the available RAM.

Print Friendly, PDF & Email

Leave a Reply