In this tutorial, we’ll look at the commands you can use on your Beaglebone Black just after installing Linux.
Expand your storage partition
As you may have noticed, the space available on Linux probably doesn’t correspond to the size of your microSD. This is because when Linux is installed, it creates a partition just big enough for its own files. So let’s see how to enlarge this partition to use your entire microSD card.
To do this, type the following command:
sudo /opt/scripts/tools/grow_partition.sh
How do I update my Beaglebone Black?
To install the latest version of your packages, here are the commands you will need:
sudo apt-get update
sudo apt-get upgrade
To install updates, you need an Internet connection via ethernet cable or a wifi key.
How do I change the keyboard language?
As you may have noticed, the keyboard defaults to English when the Beaglebone Black card is booted for the first time:
dpkg-reconfigure locales
Once you’ve typed the command, uncheck the US language with the star by pressing the space bar, then add a star in front of the FR language:
Select the new French language here:
Now restart your Beaglebone card to see the language change.
Format your USB key
The first step in formatting your USB flash drive on Beaglebone Black is to list the USB flash drives on the card:
lsblk
Once you’ve identified your USB flash drive, type the following command, replacing Ubuntu with the name of your flash drive and sda with the location of your flash drive:
sudo mkfs.vfat -n 'Ubuntu' -I /dev/sda
Mounting your USB key
To mount your USB flash drive and read its contents, the first step is to list all the peripherals connected to the Beaglebone Black in order to identify your USB flash drive:
lsblk
The second step is to create a mount point on your card so that you can mount your USB flash drive in this folder:
mkdir /mnt/usb
The last step is to mount your key in the mounting point:
mount /dev/sda /mnt/usb
Now all you have to do is check that your key is correctly mounted: