1

When installation ends (different Android API's) there message that installation finished with errors. I tried to use default location (.../Android/Sdk) and change it - no difference. Logs:

It seems that it thinks that no space left on device:

2018-06-20 22:33:05,075 [d thread 2]   WARN - ectedPackagesStep$CustomLogger - An error occurred while preparing SDK package Google APIs: No space left on device. 

/tmp dir is only 4GB, problem in this.

I tried to use TMPDIR=/home/rs/Downloads ./studio.sh but I saw nothing in Downloads and /tmp was 100% used.

I'm able to download small (4.0.3 for instance) images one by one and after reboot.

But last time I didn't see /tmp:

$ df -h
Filesystem      Size  Used Avail Use% Mounted on
udev            3,6G     0  3,6G   0% /dev
tmpfs           743M  9,5M  734M   2% /run
/dev/sda3        14G  7,2G  6,1G  55% /
tmpfs           3,7G   55M  3,6G   2% /dev/shm
tmpfs           5,0M  4,0K  5,0M   1% /run/lock
tmpfs           3,7G     0  3,7G   0% /sys/fs/cgroup
/dev/sda4       279G   11G  254G   4% /home
/dev/sda1       188M  3,4M  184M   2% /boot/efi
tmpfs           743M   48K  743M   1% /run/user/1000

$ mount | grep tmp
udev on /dev type devtmpfs (rw,nosuid,relatime,size=3742072k,nr_inodes=935518,mode=755)
tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=760336k,mode=755)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=760336k,mode=700,uid=1000,gid=1000)

$ cat /etc/fstab
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda3 during installation
UUID=7733e159-e4e2-405b-b75b-52a4cca7c90c /               ext4    errors=remount-ro 0       1
# /boot/efi was on /dev/sda1 during installation
UUID=902E-7BE8  /boot/efi       vfat    umask=0077      0       1
# /home was on /dev/sda4 during installation
UUID=edd2b68c-8e92-45d7-9261-9ca3ddf2f7de /home           ext4    defaults        0       2
# swap was on /dev/sda2 during installation
UUID=0d00f89e-3af0-4b46-ae0c-dcdbb82fcedb none            swap    sw              0       0
10
  • sudo apt autoremove ?
    – damadam
    Jun 19, 2018 at 9:33
  • @damadam didn't help.
    – R S
    Jun 19, 2018 at 9:45
  • @damadam question updated
    – R S
    Jun 20, 2018 at 19:47
  • Welcome to Ask Ubuntu! It appears you tried to edit this question while not logged in. Please log into your user account when you want to edit your posts so they don’t have to go through review and it becomes clear that you, the original author, intends these changes. Thanks. Jun 20, 2018 at 20:06
  • Could you please add a little more detail? What exactly did you do, what did you expect to happen and what happened instead? Did you encounter any warning or error messages? Please reproduce them in their entirety in your question. You can select, copy and paste terminal content and most dialogue messages in Ubuntu. Please edit your post to add information instead of posting a comment. (see How do I ask a good question?) Jun 20, 2018 at 20:12

1 Answer 1

1

If as you say the only problem that you are having is overfilling /tmp and you have plenty of space on your storage device as indicated by the output of df -h it's logical to assume that /tmp is not using your hard drive for storage but instead is probably using RAM which can seem like a great idea at some point but can later impose restrictions such as you are now experiencing.

On my 16.04 system I get

$ df -h /tmp
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda2       106G   11G   90G  11% /

But even this is too restrictive so even the 90GB I show available here is insufficient. According to https://source.android.com/setup/build/requirements you need

At least 100GB of free disk space to checkout the code and an extra 150GB to build it. If you conduct multiple builds, you will need even more space.

While your system has plenty of space on the /home partition it's definitely a bit restricted on the / (/dev/sda3) partition.

/dev/sda3 14G 7,2G 6,1G 55% /

If you had a larger capacity hard drive you would likely benefit from resizing your partitions. In effect shrinking /dev/sda4 where your home directory is and growing /dev/sda3 where everything under /which isn't mounted elsewhere is. Another option would be to mount /tmp to a specific location with more space in which case this related post would be useful. In your specific case however you are unlikely to get very far with the limited space you have available. I would do the following.

1) Make sure my system meets all the requirements

2) Obtain a new much higher capacity storage device.

3) Clone my existing system from the old drive to the new drive

4) Adjust partitions as necessary to take advantage of the new space.

4
  • question updated
    – R S
    Jun 21, 2018 at 15:45
  • @RS answer updated.
    – Elder Geek
    Jun 21, 2018 at 16:23
  • Thank you very much. I shrinked home partiton and extended root partition to 20Gb and it works fine now. I booted from live usb-stick and did it through GParted.
    – R S
    Jun 21, 2018 at 20:07
  • 1
    @RS I'm glad you were able to get through your current project, however if you often do things that require a lot of /tmp storage you may find yourself in the same situation again. If that happens you may wish to increase your storage capacity more substantially. If you are working an a laptop the steps I outlined are a good approach. If you have a desktop you can simply add a drive and mount it at /tmp. Cheers!
    – Elder Geek
    Jun 21, 2018 at 20:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .