"After a quick look I found out the issue. Ubuntu had created
another partition with /tmp being its mount point and its max size
was set to 1 MB.
"A search told me that this occurs if you happen to run out of
disk space on your root partition some time, so Ubuntu
automatically limits the size of /tmp to squeeze as much out of the
remaining space as it can. Ideally, original behaviour of /tmp
should be restored once you recover some space but it doesn't