What is adb update. What is ADB? Adb commands for Android. Consecutive actions with the team

Most Android users don't know anything about ADB... Full title - Android Debug Bridge, stands for "Android Debug Bridge". ADB is part of the Android SDK . With the help of ADB, you can perform various actions on your Android tablet or smartphone, such as: flashing, copying files from computer to Android and vice versa, system restore and others.

ADB for Android - what is it?

As you probably know, the Android operating system is based on a modified Linux kernel. Therefore, it becomes necessary to use the command line with it. It is the program adb helps to establish communication between computer and Android. It is part of the Android SDK development environment, so to install the Android Debug Bridge, you need to download the Android SDK from the official website. There are versions for all popular operating systems: Windows, Mac OS and Linux. That is, to put it simply, adb allows using a computer to control a phone or tablet.

I also recommend the following instructions:

Basic adb commands for Android

Connect your device to PC via USB. Make sure all drivers are installed and USB debugging is enabled.

To Work with Android Debug Bridge best through the Windows command line. To do this, in Windows XP, click "Start" and in the "Find programs and files" input field enter "cmd", then press "Enter". If you have Windows 7 or higher, click "Start" and in the "Run" box type "cmd" and press the "Enter" key again.

adb devices

The most common adb command. With it, you can determine if your PC sees the connected device. If you did everything ok, the following line will appear: "List of devices attached". After that you will see the serial number of your smartphone or tablet and its status: "online" or "offline".

If it says "offline", it means that the device is in sleep mode, if it is "online", then the device is ready to execute your commands.

Thanks to this command, you can install applications on your smartphone or tablet. To do this, you need to register the path where the APK file is located:

adb intsall D: \\ papka_s_faylom \\ nazvanie_prilogeniya.apk

To avoid writing long paths, copy the file to the android-tools directory. Then the path will become like this:

adb intsall nazvanie_prilogeniya.apk

adb uninstall

You need to enter in the same way as the previous command. This will remove the application.

This team has an interesting feature. If you add a key -k, then when you delete a game or program, their data and cache will not be deleted, but will remain on the Android device.

Thanks to this command, you can transfer files from computer to Android. To do this, you need to know the full path where the file is stored and where to move it.

adb push D: \\ papka_s_faylom \\ nazvanie_fayla / sdcard / Android

To avoid writing long paths, copy the file to the android-tools directory. Then you need to enter:

adb push nazvanie_fayla / sdcard / Android

This command copies files from Android to computer. You need to know the path where the file is located on your smartphone or tablet and specify the location where you want to save the file. If you do not specify the latter, the file will be saved in the android-tools directory.

adb pull / sdcard / nazvanie_fayla \\ D: \\ papka_gde_sohranity

This command will restart your Android phone or tablet.

Thanks to this command, you can directly boot into bootloader mode.

adb reboot recovery

Not all devices support this command. With it, you can get into recovery mode.

adb connect

Using this command, you can connect the device to a Wi-Fi network. To do this, you need to know the ip address and port of the device.

adb connect ip: port

With this command, you get full access to all files on your device.

The second way to use the adb shell is to execute a single Android shell command using this construction:

adb shell<команда>

If you put your Android phone or tablet into bootloader mode, then the commands adb will no longer work. Here you need to use the fastboot commands.

To check if PC and Android can see each other, use the command:

After entering it, the serial number of your device should appear.

By entering this command, you can unlock the bootloader of Asus and HTC phones and tablets. When your device is in bootloader mode, enter:

Also, all your installed programs and personal data will be lost.

Using this command, you can display the contents of the log file: changes, errors, etc. The data will scroll too fast, so it is a good idea to save it to a single TXT file. To do this, enter:

adb logcat\u003e filename.txt

adb sideload

The team will come in handy for owners of Google Nexus devices. With it, you can update the firmware of the device. Download it to your computer, connect your Nexus to it, go to Recovery mode, select "Apply update from ADB" and then enter the command.

Detailed instructions on how to manually install an OTA update via ADB Sideload on LG Nexus 5 (Hammerhead) without having to unlock the bootloader, get superuser rights or install custom recovery.

Attention!

Installation instructions

    Create in the root of the C: \\ drive a folder named " Android».

    Open the command line and go to the created Android folder with the command “ cd c: \\ Android \\»(Commands are written without quotes).

    Connect your phone to your computer using a USB cable.

    Make sure the computer finds the device via ADB.
    To do this, enter “ adb devices"To the command line. On the request that appears on the phone for permission to debug via ADB on this computer, you must click " Ok", While selecting the item" Always allow from this computer". If the device is visible, the text “ List of devices attachedxxxxxxx device). If instead of “device” it says “offline” or the list turns out to be empty, then you need to update ADB, check the drivers / cable, change the USB port / computer.

    Reboot the phone to bootloader mode.
    To do this, turn off the device, turn it on while holding down the Volume Down key and the Power button, or enter “ adb reboot bootloader". If everything is done correctly, the inscription will be displayed on the smartphone screen Start and an Android lying on its back with the lid open.

    The first time you connect to a computer in Fastboot mode, the system may ask for drivers. To install them, you must specify the path to the folder with the downloaded drivers. If this did not happen and the device is not detected, you need to go to " device Manager", Expand the drop-down menu" Other devices"And double-click on the item" Unknown device"(Or" Android 1.0») With an exclamation point in a yellow triangle. In the tab “ General"Click on the button" Update driver", Refuse to search the network and indicate the path to the folder with drivers, while activating the item" Including subfolders". You may receive a warning that the publisher could not be verified, but you still need to ignore this message and continue with the installation. After a while, the drivers will be installed.

    Check the availability of the device in bootloader mode by entering the command “ fastboot devices". If the device is connected correctly, then the device identifier with the word "fastboot" will be displayed (for example, " xxxxxxx fastboot"). If nothing is displayed or "waiting for devices ...", then you need to update the drivers, change the USB port, or try to do these actions on another computer.

    Transfer the phone to recovery mode.
    To do this, use the volume buttons to select the item Recovery Mode and confirm the selection with the power key. When a small recumbent robot appears with a triangle and the text “ No command», Hold down the power button and press the volume up key once, then immediately release them at the same time. The phone will be loaded into stock recovery.

    Select the item " apply update from ADB».

    Check connection with smartphone via ADB Sideload.
    To do this, enter “ adb devices"To the command line. If the device is connected correctly, the text “ List of devices attached»And a list of all devices (for example, xxxxxxx sideload). If instead of "sideload" is written "host" or the list is empty, then you need to reboot the device and try again.

    Enter the command " adb sideload ota.zip". This will start copying the file to the phone and installing it further.

    Wait until the end of the operation and select the item " reboot system now».

When a user wants to update the firmware of his Android device, he is faced with the "Apply update from adb" option in the Recovery menu. We will tell you what it is and what ADB is responsible for on Android.

Many Android users are interested in the question - how can you modify the existing firmware and thereby get a newer one? Debug bridge from Android, which has an abbreviation, can help in such a situation. ADB... Using this option, you can control any device with the Android operating system, if the manufacturer has not closed access to this functionality. It should be said that the principle of operation of ADB has a client-server basis.

Apply update from ADB (translated as - Apply Android Debug Bridge Updates) is a phone control function used when updating, restoring, or custom flashing the system.

Apply update from ADB function in the phone's Recovery menu

Updating with ADB Sideload

There is an excellent command in the arsenal of the debug bridge - this is ADB Sideload, which allows you to update outdated firmware or restore the device (if it does not boot).

Updating an Android device comes within your means ZIP archive and menu Recovery (in the absence of it, you can use the bootloader). It is worth noting that there is a command similar to ADB Sideload - this is fastboot -w update... However, it does not work in all cases.

  1. A PC (personal computer) or laptop is required (there may be problems with Windows 8 / 8.1 operating systems).
  2. An Android driver is required.
  3. Software ADB RUN.
  4. Availability of original and working USB cable.
  5. The device must be charged more than 40 percent.
  6. A ZIP archive with the required update is required.

You need to enable USB debugging on your device.


Algorithm for downloading updates

  1. The first step is to download ZIP archive with an update for your gadget to a personal computer.
  2. The second step is connecting USB cable to connect a smartphone or tablet with a computer.
  3. At this step, on an Android device, you need to boot into recovery mode (the English name is recovery mode).
  4. After switching to recovery mode, select the "Apply update from ADB" command.
  5. The last action is to go to the command line and execute the ADB Sideload ( adb sideload<путь к файлу, название_файла>.zip).

I hope you figured out what the Apply update from ADB function means in the Recovery menu and apply the described algorithms when updating or restoring Android.

What is ADB? Adb commands for Android. In this article, you will learn what ADB is for what users need it, as well as how to manage it using commands in the Android terminal. Well, let's start learning the adb android commands ...

Introducing ADB

ADB (android debug bridge) is a tool for debugging, detecting errors in applications, unlocking devices on Android OS and much more. You can read the official documentation in English on this site.

Instructions for using ADB Sideload

But, of course, people like us did not wait that long. Note. Again, you will probably need re-stocking. Hope this guide will help you. Without it, you won't have access to the development teams that are included in most of our latest tutorials.

Add this line to your file with the required information. How it works and what you should look for you can see here. The beginning of the gallery. The most embarrassing auto-correction ever fails.

  • The update is now installed, which may take a few minutes.
  • Do not disconnect the computer from the computer until the operation is complete.
What messenger are you using?

Download ADB

You can download ADB from the official supplied Android SDK development environment or download small ADB installer, Installation takes place at the root of the disk FROM:\\

One or the other may also use a different service, depending on the contact, to communicate digitally with a friend. If we have forgotten your messenger, let us know! It can take a long time to wait for the firmware update, but you can always manually download and install the update over the air. The update is always distributed over the air.

The downloaded file can also be downloaded manually. Below are the steps for those who have a normal recovery or users who haven't changed their device. This is usually done by simultaneously pressing the power and volume down buttons to start the device. If this process is complete, restart your device. Since it's minimal, there is no need to install or download a bunch of files. It happens the same way, we will have to enter the correct commands for this. ... To use this tool, you must have the correct drivers for your device.

Make sure that the drivers are installed on the PC and USB debugging is enabled on Android.

Android and Linux adb commands

Adb commands can be divided into 3 types, directly for Adb command, FastBoot () and Android command.

Step 1 - Turn off your device. Step 5 - Now enter the following command at the command prompt. Step 6 - Enter the command to reboot. Your device will now reboot and it will start normally. That's all about this tutorial. Also check out our cool rooted app list.

Warning: never select or override the volume, just don't. Then select "recovery" as you can see on the screen to select the volume and enter the volume. As you can see, there are 12 options to choose from, the current firmware version of the device is displayed there.

Adb Teams

1. Checking for a connected Android, checks if the PC "sees" your smartphone or tablet.

To make sure everything works fine and the computer recognizes Android, you need to enter the adb command:

Adb devices

this screenshot shows that Android is connected

If you have did not appear a similar message, then it may be necessary to check the presence of drivers on the PC, the integrity of the cable, the operability of the USB port.

Only process for about a minute or less and the device will revert to its original settings and apps. Select a reboot system. To flush caching partitions, the system cache partition stores temporary system data. It should allow the system to access applications faster and more efficiently, but sometimes things get cluttered and outdated, so periodically flushing the cache can help make the system run smoother. It's the same process above, just select "wipe cache partitions" and it only takes a few minutes or less.

5. Receive file from Android to PC

Introducing ADB

If we don't have drivers for our phone, we have to search for them and install them. If we get the serial number, everything is correct. If, on the contrary, it does not work out, we will have to make sure that everything is correct. To move a file, we need to know the route of the phone where we want to place it.

If, for example, we want to move any video file, we have to place it in the folder we talked about earlier. Quite the opposite. This is almost the same as what we did before. He just does what he says. Reboot your device using the console.

In order to receive absolutely any file from an Android device to a computer, there is a command:

Adb pull

How to use and example:

In order to use the Adb command to receive a file from Android to PC, you need to. Write:

adb pull / sdcard / xxx / Sex_s_Pameloy_Anderson C: papka_gde_budet_hranitsya_file

That is, write the adb command, the path to the file that is located on Android, the name of the file and the place where to save this file on the PC.

We can not only reboot the device, but also access the bootloader. It is one of the more beneficial tools so sometimes the button combinations get tedious and we want to keep things simpler. Bootloader access can be useful for many things. We only need to print and we will be inside.

Android Terminal Commands

In case of "reboot" it will be used to enter recovery mode. This may be one of the most powerful commands available. Keep in mind that many devices are not included, and if so, we need to be sure that both devices are communicating.

In order to reboot Android after any operations performed, or reboot into a special mode, there is a command:

Adb reboot

Usage example:

Commands will restart Android

Adb reboot adb reboot normal

bootloader downloads

Adb reboot bootloader

The command will reboot Android into Recovery mode

If we have a phone from a different manufacturer, we will have a different method in each case. In the latter case, this command is useless. Then touch the terminal, read carefully and choose your options wisely. There are two ways to use it, one where the command is sent to the device to execute the command line in its own shell, and the other where we will actually be inside the command shell from the terminal. In the image above, the user is inside the device shell, browsing through files and folders.

Adb reboot recovery touch

For example, let's create a file 666.txt in the / sdcrad directory

Touch /sdcard/666.txt

13. Creating a Backup from a partition and restoring

An example of creating a Backup to an Sd card

dd if \u003d dev / block / mmcblk0p1 of \u003d sdcard / efs.img

Example of restoring a partition from a backup from an Sd card

dd if \u003d / sdcard / efs.img of \u003d / dev / block / mmcblk0p1

14. View the space occupied by a file

In order to understand how much something takes:

Du du systcode

Setting permission, rights to files and directories

To find out what permissions files and directories have, you need to write the following command

Access rights (permission)

They write them down in this form - RWX (letter) or 777 (digital)

Access rights share

1. Access to files
2.Access to directory

Access rights literal attributes

r - reading data files and directories (read)
w - changing the contents of files and directories or writing to them, but not deleting (write)
x - execution of the file or permission to enter the directory

There are three groups of users

« user"- file owner or directors
« group»Is a member of the group to which the owner belongs
« world"- the rest, not belonging to the 2nd groups

The order of recording access rights looks like this
first, the access rights for the owner are set - " u»
after the group - " g»
and at the end for the rest - “ o»

for instance

The owner of the file has the right to read (r), write (w) to it and execute (x), the rest only read.

Numeric access rights attributes

r - read 4
w - record 2
x - run 1
"-" no rights 0


The sum of their values \u200b\u200bmeans the final rights for the user and groups.

7 (rwx) \u003d 4 + 2 +1 full rights
5 (r-x) \u003d 4 + 0 + 1 read and execute
6 (rw-) \u003d 4 + 2 + 0 read and write
4 (r-) \u003d 4 + 0 + 0 read only


For beginners, an online calculator may be useful - link.

You need to set the rights with the command

for instance

chmod 777 * - will set read and write and execute permissions for all files and folders

chmod 755 file.avi

Hard and symbolic links

In Linux, including Android, there is such a thing as links - which sounds like a "shortcut" in normal familiar language. There are two types of links:

  • Hard links
  • Symbolic links or symlinks

What are the differences between hard and symbolic links?

Symbolic links - create a shortcut that points to the exact location of a file or folder where the shortcut refers. If a file or folder is moved, the symbolic link will be broken. To clearly understand what a symbolic link is - in Windows XP or Windows 7 there are program shortcuts on the desktop that link to the program folder, or rather exe-file.

How to create hard and symbolic links

ln ln -s

Today we will talk about two unfamiliar functions that a user encounters when flashing his Android device in the Recovery menu. We will tell you what Apply update from cache and Apply update from ADB are and briefly describe the process of working with these options when installing updates or flashing the device.

Apply update from cache Is a special feature of Android phones used when updating the operating system. Contained in the Recovery menu. Can be used to apply an update file from the cache folder of your mobile phone or other Android device.

Installing firmware via cache

The firmware from the Apply update from cache (cache) is not distributed among users. But its application remains one of the only methods in the absence of a computer at hand. Using Wi-Fi networks, you can download data for the OS to your phone. The regular Internet can also help, but the process will be pretty long.

The bottom line is placing program files (firmware or updates) in the cache directory. Access to Root rights the user must be open.

Option in the Recovery menu Apply update from ADB - can be used to install software updates using a computer - a bridge is created between the PC and Android via a USB cable. It is used most often and is very convenient.

All actions with the OS go through the ADB debug bridge. It is thanks to him that you can make various modifications to Android. Very often, access to such a possibility is hidden from the consumer by the settings of the manufacturer itself. Will consider both ways of flashing.


Firmware via ADB tool

The firmware would not have been possible without the SIDELOAD helper command. It is capable of extracting files from ZIP format archives. As you know, it is in them that program data is stored. You can replace this action only with the bootloader, all the same by performing the actions from the Recovery menu. Such a solution as fastboot -w update for Android devices is not relevant at all.

What the user needs to have
  1. Laptop or regular computer. There may be minor issues with some versions of Windows. Especially if it's Vista or Windows 8.
  2. Android drivers with the latest patches.
  3. Software for actions with OS - ADB RUN.
  4. Connect via USB.
  5. We check the correctness of the connection system in the phone.
  6. Archiver ZIP with updates.
Consecutive actions with the team
  1. Establish connections between the smartphone and the computer.
  2. You enter the downloaded ADB RUN program. On the menu Reboot Device we are looking for the already familiar Reboot Bootloader or Reboot Recovery.
  3. On the smartphone, select the item SIDELOAD.
  4. We return to the very beginning. Go to the menu and go to Move -\u003e Sideload
  5. Moving the archive itself with updates zIP format... To do this, open the item Copy ZIP to Directory - put it here.
  6. Click Install ZIP... Find the moved files. We activate.
  7. The firmware should start.

If a crash occurs, be sure to activate the sideload command. Restarting the device and re-doing all the steps can also help. And finally, a detailed video instruction for flashing Android devices and working with the menu Recovery.

The adb sideload command is awesome and can be used to easily perform a firmware update or restore Android if it won't load!

Once again about what the ADB SIDELOAD command is for - this command is needed in order to flash ZIP archives from the recovery menu or if there is no bootloader. This command has an analogue of fastboot -w update, but the fastboot utility does not work for many Android devices, so adb sideload is a universal tool.

How ADB Sideload works

ZIP archive-update is located in the folder with the adb utility, the smartphone or tablet is switched to recovery or bootloader mode. The adb utility is launched and the adb sideload command is written<название_файла>.zip, after which the archive is copied to Android and then flashed.

Required for ADB Sideload

  1. Computer or laptop
  2. Download and after it
  3. Download the program - ADB RUN or ADB
  4. Android device is at least 40% charged or more
  5. Original, undamaged MicroUSB cable
  6. Enable on Android
  7. ZIP archive update

Instructions for using ADB Sideload

This article will offer two options for how you can use adb sideload, the first method is a demonstration of how everything works from start to finish, the second method is automated, without unnecessary actions and scribbling by hand.

Method number 1

1. Connect your Android device to your computer
2. Move the ZIP file archive-update to the path C: / adb / progbin
3. Run the ADB RUN program or go to the menu Manual Command -> ADB

adb devices

And they should receive the following response:

C: / adb / adb / progbin\u003e adb devices List of devices attached NA36XWxxxххххх

If we get an answer (error):

C: / adb / adb / progbin\u003e adb devices List of devices attached NA36XWxxxххххх offline

If we get an answer (error):

C: / adb / adb / progbin\u003e adb devices List of devices attached

That is, there is nothing, after attached, the device is not visible (reinstalling the drivers, changing the USB port, changing the USB cable)

5. We transfer the device to Recovery mode or mode Bootloader

6. Depending on Recovery, in some cases it is necessary to enable forcibly enable the transfer mode and Sideload settings on the device:

If you have a standard or CWM Recovery, it may be called

  • install zip from sileload
  • apply update from ADB
  • ADB Sideload

and this menu can be found in the main section of Recovery, section Advanced or Install ZIP.

If you have TWRP Recovery

To activate sideload, go to Advanced -\u003e ADB Sideload and drag the bottom slider to the right:

7.In ADB RUN we write the following command:

adb sideload XXXXXXXX.zip

Where XXXXXXXX - the exact name of the flashed ZIP update (given the CAPITAL or STRING, as written, otherwise you will get an error)

Then the update (firmware) will be moved to Android and updated.

  • If you get an error error: closed - did not activate sideload on Android
  • If you get an error error: device not found - does not see Android, change the kernel, recovery, restart Android and switch to mode again.

Method number 2

1. Connect your Android device to your computer
2. Run the ADB RUN program and go to the menu Reboot Device -\u003e select Reboot Recovery or Reboot Bootloader (if not on the Recovery device)
3. Istall ZIP after which, select the file to be flashed, after which the firmware will start.

  • If you get an error error: closed - have not activated sideload on Android;
  • If you get an error error: device not found - does not see Android, change the kernel, recovery, restart Android and switch to mode again.