title: How to push files to sbin folder on the Android device?
body: <p>I'm not able to turn on recovery mode, just the factory mode.</p>
  
  <p>Communication between PC (Windows) and Android phone works fine over ADB, but the phone is not storing files after reboot.</p>
  
  <p>Script in which I'm trying to transfer certain files ((sd)parted) to /sbin directory:</p>
  
  <pre><code>adb -d shell stop
  
  adb -d shell su -c "mount -o rw,remount rootfs /"
  
  adb -d shell su -c "chmod 0777 /sbin"
  
  echo Copying files
  adb push e2fsck /sbin/
  adb push mke2fs /sbin/
  adb push parted /sbin/
  adb push resize2fs /sbin/
  adb push sdparted /sbin/
  adb push tune2fs /sbin/
  
  echo Rebooting
  adb reboot
  </code></pre>
  
  <p>Why files aren't stored on the device. What went wrong?</p>
  
  <p>I need to repartition the file system, so that's the reason why I need these files.</p>
  
  <pre><code>adb root
  </code></pre>
  
  <p>... does not work, it get's stuck.</p>
  
  <p>Please help.</p>