1

I'm running Ubuntu 16.04.3 LTS with LXDE desktop environment. I'm running it off a thumbdrive as a live boot, using a startup script to install my programs and configurations into the RAM disk. I used UNetBootin to install the .ISO on the thumbdrive. There is no swap partition in use to my knowledge, nor do I want one. There is no persistent storage on the thumbdrive, nor do I want any. For persistent storage, I use a single partition hard drive that shows up in my /media/ubuntu/ area. This is on a high end laptop with 16 GB of RAM.

The problem I'm encountering is the system becomes slow/lagged, particularly the external keyboard I'm trying to use.

When I run df -m I see:

$ df -m
Filesystem     1M-blocks   Used Available Use% Mounted on   
udev                7850      0      7850   0% /dev
tmpfs               1573     42      1532   3% /run
/dev/sdb1           7535   1516      6020  21% /cdrom
/dev/loop0          1429   1429         0 100% /rofs
aufs                7865   7589       277  97% /
tmpfs               7865     28      7838   1% /dev/shm
tmpfs                  5      1         5   1% /run/lock
tmpfs               7865      0      7865   0% /sys/fs/cgroup
tmpfs               7865      1      7865   1% /tmp
tmpfs               1573      1      1573   1% /run/user/999
/dev/dm-0         469324 424657     20805  96% /media/ubuntu/harddrive

I believe that 97% in use for aufs is what's causing the external keyboard lag and other system performance problems. After all, when I first boot up and prior to installing programs, the aufs in use percentage is way smaller and the external keyboard doesn't lag.

It looks like only 8 GB of RAM is being allocated to aufs. Meanwhile, look at those five tmpfs rows. The 78xx available makes it seem that 8 GB of RAM is being pointlessly dedicated to the tmpfs.

What are those tmpfs rows? Are they the same thing as a swap partition?

How can I make more of the total RAM (16 gb) available to aufs?

Sometimes I run

$ sudo su
root@ubuntu:/# sync; echo 1 > /proc/sys/vm/drop_caches
root@ubuntu:/# sync; echo 2 > /proc/sys/vm/drop_caches
root@ubuntu:/# sync; echo 3 > /proc/sys/vm/drop_caches
root@ubuntu:/# sync

And this seems to help a tiny bit. Running 'free -m' before and after running the above confirms that running the commands increases available memory. But I'm not sure what the above commands are actually doing or if/how they relate to the 'df -m' and aufs stuff.

Thanks (and in case it's relevant, I'm switching to Lubuntu soon)!

  • 1
    I'm not exactly sure how your aufs behaves, but tmpfs only use up as much memory as needed, so e.g. your /dev/shm only takes up those 28 MB RAM, the 7865 MB is the maximum size to which it is allowed to grow(half of your RAM by default), if enough free RAM is available, not its actual size. Don't worry about these tmpfs. Probably the aufs has the same default size limit of half your RAM. I don't see how dropping caches would give any speed benefit though, these are automatically dropped if the RAM is needed for applications. – Byte Commander Jan 31 '18 at 23:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.