User Manual Orange Pi Zero 3

  Features   |  Use   |    Linux     |  Linux SDK   |  Android   |  Android SRC   |

RU          EN  

Chapt 3. Instructions for use of Debian/Ubuntu Server and Xfce desktop system
Страница:   25    26    27    28    29    30    31    32    33    34    35    36    37    38    39    40    41    42    43    44    45    46    47    48    49    50    51    52    53    54    55    56    57    58    59    60    61    62    63    64    65    66    67    68    69    70    71    72    73    74    75    76    77    78    79    80    81    82    83    84    85    86    87    88    89    90    91    92    93    94    95    96    97    98    99    100    101    102    103    104    105    106    107    108    109    110    111    112    113    114    115    116    117    118    119    120    121    122  


3.6.1. The first startup will automatically expand the capacity of the rootfs partition in the TF card

  • 1) After burning the Linux image of the development board into the TF card, you can check the capacity usage of the TF card on the Ubuntu computer, the steps are as follows:

    Note that this step does not affect the automatic expansion of the Linux system

    a. First install the gparted software on the Ubuntu computer

    test@test:~$ sudo apt install -y gparted

    b. Then open gparted test@test:~$ sudo gparted

    c. After opening gparted, you can select the TF card in the upper right corner, and then you can see the usage of the TF card capacity



    Img 3.12

    d. The figure above shows the situation of the TF card after burning the Linux desktop version system. It can be seen that although the total capacity of the TF card is 16GB (displayed as 14.84GiB in GParted), the rootfs partition (/dev/ sdc1) actually allocated only 4.05GiB, leaving 10.79GiB unallocated

  • 2) Then you can insert the TF card that has burned the Linux system into the development board to start. When the TF card starts the Linux system for the first time, it will call the orangepi-resize-filesystem script automatically through the systemd service orangepi-resize-filesystem.service. The expansion of the rootfs partition, so there is no need to manually expand the capacity.

  • 3) After logging in to the system, you can use the df -h command to check the size of the rootfs. If it is consistent with the actual capacity of the TF card, it means that the automatic expansion is running correctly.

    orangepi@orangepi:~$ df -h
    Filesystem Size Used Avail Use% Mounted on
    udev 430M 0 430M 0% /dev
    tmpfs 100M 5.6M 95M 6% /run

    /dev/mmcblk0p1 15G 915M 14G 7% / tmpfs 500M 0 500M 0% /dev/shm

  • 4) After starting the Linux system for the first time, we can also remove the TF card from the development board and reinsert it into the Ubuntu computer, and then use gparted to check the status of the TF card again,as shown in the figure below, the rootfs partition (/dev/ The capacity of sdc1) has been expanded to 14.69 GiB


    Img 3.13

    It should be noted that the Linux system has only one partition in ext4 format, and does not use a separate BOOT partition to store files such as the kernel image, so there is no problem of expanding the BOOT partition.


     <         > 


  • Страница:   25    26    27    28    29    30    31    32    33    34    35    36    37    38    39    40    41    42    43    44    45    46    47    48    49    50    51    52    53    54    55    56    57    58    59    60    61    62    63    64    65    66    67    68    69    70    71    72    73    74    75    76    77    78    79    80    81    82    83    84    85    86    87    88    89    90    91    92    93    94    95    96    97    98    99    100    101    102    103    104    105    106    107    108    109    110    111    112    113    114    115    116    117    118    119    120    121    122