Hello, I am using vmware with fedora 38 installed and mounted my galaxy s8 android to the vm. I am making a backup of the android phone. I changed directory to the root of the android phone using
cd “/run/user/1000/gvfs/mtp:host=SAMSUNG_SAMSUNG_Android_98897a48334d553957” which is the root of the galaxy s8. Then, I entered this command
I restarted the vmware again and ran the code once more, and it gave me the same message but nonetheless it started zipping althought it too hours and hours so I left my PC on overnight. This time the size comparison of the two phones is alot different. Is there something wrong with this? See screenshot below
zip archives are compressed by default. But, it’s impossible for anyone to say if your zip archive is ok just by looking at the size. You’ll have to verify the contents yourself. An unverified backup is as good as no backup.
I’ve found out that when connecting the android phone and running the find command above, doesn’t zip hidden files and folders. But I am still receiving buffer error. Is the problem not enough ram to handle a large set of data ? Because it says buffer overflow detected, does that mean that data is too large to zip ? Also, how do I zip specific folders or subfolders within parent folders while excluding everything else?
Since we have little info about the phone or the data it contains it seems difficult to speculate about the cause of that buffer overflow error. Is the error on the source (the phone) or on your pc?
One workaround may be to simply copy the desired data from the phone to a subdirectory on your pc then zip the content of that subdirectory. You may even need to copy (or zip) smaller subsets of the full data content as individual units.
As far as the comment about excluding some data while zipping other parts I suggest you read up on how ‘find’ and the zip utility in use select what is being included or excluded. It is somewhat flexible but one needs to be familiar with its features as well.
It’s a samsung galaxy s8 with about 1500 pictures and about 100 videos in the DCIM/Camera folder and its on android 9. Total space is 64 GB and I have used 63.8/64 GB of storage.
That’s what I’m not sure about. How can I check which is giving the problem and what logs can I check ?
This is a long process because the data on the s8 is over 30 GB.
How can I do this via command line maybe making zips in smaller chunks avoids the I/O error ? I’m not sure…
If so then I suggest strongly that you first remove the sdcard from the phone and copy or archive the data from the DCIM directory off the card using a card reader on your pc. Once that is done and the data is deleted from the card then insert the card back into the phone and move the data from the phone DCIM directory to the card DCIM directory.
Repeat the above until all the necessary data is off the phone and you have additional space available to continue using the phone.
That tells me the phone has no space to assist in relocating the data.
All the more reason to do this process regularly and maintain free space on the phone.
I have always stored photos & videos only on the sd card to make it easy to transfer them to my PC and keep the phone memory open. You could if you wished use a 64GB sd card to allow more room for data.
This is not a actual micro sdcard. The android’s internal storage is just called sdcard. It isn’t an actual micro sd card. I dont have a micro sd card inserted into my galaxy s8
even then I’m using a webdav app it isn’t making temporary files on the phone and rewriting it back into fedora
Since the device is connected to the pc one could simply use the file manager to move the files. It only would need the phone to read the files and allow the transfer. Once the file is written to the pc it could be removed from the phone.
This could also be done from the command line very easily with the mv command, or a combination of cp & rm.
I’m trying to understand why it doesn’t work with a simple webdav app. I could’ve done this easily if I had some space but knowing that I barely have anything, even making a small zip containing one file is not possible because it would first need to be saved on the phone
Having only a tiny remaining space on the phone causes a problem since many apps require the use of ram or temporary file space to function. Clearing out some of that space with a tool that requires minimal extra space is mandatory and the webdav app seems to require more than would be necessary with the command line tools.
Start with the command line, then after some space is freed up it may be that your preferred app could manage the rest…
Tools that do not require space on the already full file system seem best for the task.
I am somewhat surprised that android allows the file system to fill up that much (99.6%) since linux normally reserves 5% to avoid those issues you are seeing.
I guess so…knowing that my pixel 7 has about 50 GB of storage remaining (while using the find and zip command works with the pixel 7) vs. 200 MB (fine and zip command doesn’t work here) or less on my galaxy s8…I’m not sure if that would be as big as a problem but let’s try to free up some space anyway