[MOD][XPOSED] Music2SD (v1.8) - Make Google Play Music save music where you want

Search This thread

Cloudane

Senior Member
May 8, 2012
188
29
EDIT: RESOLVED
First question, I guess FakeJap came with a hacked Music app which was un-hacked on update, as it's only meant to support SD from 4.4 onwards. Though I still have no idea where it keeps the cache files if it's done on internal storage.
Second question, I forgot step 5 (enable module)



I am rather confused.

I have a Note II with a 4.3 ROM on it (FakeJap) and I could swear that when I first installed this, Google Play Music already had the external storage option built-in in its own settings.

Now it's disappeared, so I tried Music2SD. Installed the requirements, rebooted, changed the location, and... nothing happens? Music2SD shows the SD card as the storage location, but Google Music still downloads it... somewhere else. I don't even know where, I've tried and tried and can't find where it stores it?? (no, it's not in /Android/data/com.android.google.play.music in the internal storage). But if I look at the free space, it's the internal space that drops when downloading to the cache...?
 
Last edited:

NovaChild

Member
Jul 30, 2011
8
1
EDIT: RESOLVED
First question, I guess FakeJap came with a hacked Music app which was un-hacked on update, as it's only meant to support SD from 4.4 onwards. Though I still have no idea where it keeps the cache files if it's done on internal storage.
Second question, I forgot step 5 (enable module)

I don't know if your rom actually had a hacked Music app or not, but my Note II has had the external storage option since release on both 4.3 and 4.4 AOSP and 4.1.2 TW Roms. I recently installed a 4.3 TW Rom for the first time, and the option was still there and still worked. Then I changed the DPI on my phone to 240 and the option disappeared. Played around with Xposed App Settings and was able to confirm that Google Play Music will now allow me to use External storage if and only if "Android System" is set to 320 dpi. Weirdest bug ever. However, doing that makes the notification screen (IMO) unusable, so I am temporarily at least back to using this module.
 

Maxr1998

Senior Member
Apr 15, 2013
2,148
3,209
22
Augsburg
maxr1998.de
Been sick at home this week with the Flu. Seeing as I had some time to kill I spent it digging through the source code of Google Play Music to fix Music2SD. I have just uploaded Version 1.8 of Music2SD on to the Google Play Store and to the main post of this thread. Enjoy! ;)

After the update, Google Play Music redownloads music after every reboot...
If there's no fix, I'll have to uninstall the module...

Sent using my nexus⁴ running Stock 4.4.2 with Xposed, GravityBox, XThemes and hells-Core B44 KK
 
  • Like
Reactions: ccristal

ccristal

Senior Member
Sep 28, 2009
527
60
After the update, Google Play Music redownloads music after every reboot...
If there's no fix, I'll have to uninstall the module...

Sent using my nexus⁴ running Stock 4.4.2 with Xposed, GravityBox, XThemes and hells-Core B44 KK

Same here.


Sent from my GT-N7000 using Tapatalk
 

Maxr1998

Senior Member
Apr 15, 2013
2,148
3,209
22
Augsburg
maxr1998.de
Same here.


Sent from my GT-N7000 using Tapatalk

After I uninstalled module, cleared data of PlayMusic, reinstalled v1.7.1, enabled in xposed, rebooted, configured, rebooted and then reconfigured PlayMusic it works again...

Sent using my nexus⁴ running Stock 4.4.2 with Xposed, GravityBox, XThemes and hells-Core B44 KK
 

Spikestrip

Senior Member
Apr 14, 2012
140
26
Google Music is now working as expected for me without music2sd, storing music on external sd.

Sent from my GT-N7100 using XDA Premium 4 mobile app

You're probably on KitKat. That's a thing now.

I've had horrible luck with this. Like many other people, Google Play Music doesn't recognize my music after a reboot or whenever it feels like it. I've discovered that my phone keeps recreating the .nomedia file in that folder, and when I delete it (force close Play music first), the music is seen again in Google Play music. Since I updated Music2D, the whole thing is borked. I can't tell where it is downloading music, changing the setting for location using Music2SD doesn't seem to make any difference at all, and I can't manually create links for this folder. Highly frustrating and I can't even tell how to fix it. Removing Music2SD now.

EDITED: I found the music. This is the second time I've had to hunt for it. Music2SD is deleted and gone, but the links it made are still around. I found the folder it was downloading to and moved all the stuff it had previously downloaded into there. I'll just stick with doing this manually in the future. Thanks for the tool though, and I can see why Google phased out SD card support in the first place.

EDITED again: The previous trick of moving the downloaded music into the folder Google Play Music is using worked for me before, but not this time. This time Google Play Music deleted 6.5 GB of music I had just copied into that folder and promptly began downloading all the same files again. This has been nothing short of a nightmare. Most mornings when I want my music, it's gone, again. And I can't just dump music from my computer on here, it has to come from Google. So I spent most afternoons watching my music download again with my phone on the corner of my desk, I get to listen to the music on the way home, and the process starts again the next day. I can't wait for Sony to finally give us KitKat on the Xperia Z1. At least I can be pretty confident I'll get that from them eventually on this device.

Thank you to StevenMaterra for even trying to deal with this. I barely have the patience to bootleg a setup like this myself, let alone try to do it for a bunch of strangers. Hats off to you.
 
Last edited:

ccristal

Senior Member
Sep 28, 2009
527
60
Apologies for the off-topic, but this is driving me crazy: does anyone know why, despite being on KitKat and having the latest Google Play Music installed (5.4.1409N), I can't see the option to keep the downloaded music on the SD card?
(Yes, I do have a SD card...)

Thanks!

Sent from my GT-N7000 using Tapatalk
 
  • Like
Reactions: Capt4Chris

debernardis

Senior Member
Jun 30, 2011
532
149
Acireale, Sicily
www.debernardis.it
I am not in Kit Kat, I am still on 4.1.2 and play music is v5.4.1409N.1014766.
Music2sd is uninstalled.
I didn't move any file.
Actually my music files seem to live in [extSdCard]/Android/data/com.google.android.music/files/music

I don't know how stable is that all and hope it doesn't get erased and downloaded again.


Sent from my GT-N7100 using XDA Premium 4 mobile app
 
Last edited:

Capt4Chris

Senior Member
Mar 9, 2011
75
16
Nashville, TN
Apologies for the off-topic, but this is driving me crazy: does anyone know why, despite being on KitKat and having the latest Google Play Music installed (5.4.1409N), I can't see the option to keep the downloaded music on the SD card?
(Yes, I do have a SD card...)

Thanks!

Sent from my GT-N7000 using Tapatalk

I don't have this option either. Running CM11 on my HTC Evo 4G LTE.
 
  • Like
Reactions: ccristal

Tomdroid

Senior Member
Mar 4, 2010
151
13
I don't have this option either. Running CM11 on my HTC Evo 4G LTE.

Neither do I: Galaxy Note, 4.4.3, SlimKat Build3

Also, this module didn't work, then messed up:

I followed the instructions to the point. 3 times. Third time I made sure to a) erase all data from GPMusic, b) launch GPMusic with autocache disabled, c) force close GPM, d) activate Music2SD, reboot, e) launch GPM. That was the ONLY way I could get GPM to store music to the external SD card.
...
Yes, GPM DID store music where I wanted it to BUT: it refused to play cached music once I went offline! The music was where it was supposed to be (checked with root explorer), the pin in GPM was orange, GPM indicated the music being offline available when going offline, yet when I tried to play any of those tracks, it simply stated "Can't play selected track". I tried 2 more times, it just didn't work.
...
And at the third attempt, GPM started locking up while dl'ing tracks. From that point forward I couldn't launch GPM, nor delete its data / cache, nor uninstall it (if I tried, phone would reboot after a while), even after rebooting the phone. Luckily all I had to do was disable Music2SD to get GPM to work again. Alas, I'm no single step further getting my cached music to the SD card. Stupid Google.

@StevenMattera: Thanks for trying!
 
  • Like
Reactions: Capt4Chris

qtmod

Member
Dec 6, 2013
8
0
Hello. I have been using Music2SD for some time now and it has worked great.

Since 1.7.1 or 1.8 it doesn't seem to be working properly. After installing 1.8, I went to go listen to some music and my device's library was empty. I checked the folder on my SD and it was full of music files. I tried uninstalling Play Music and Music2SD, clearing out any old folders and started from scratch. After reinstalling and following the directions, doing reboots and such, I tried to download a music file, and it was not saving to my external SD.
I wiped again and tried the same with 1.7.1, which worked until I rebooted my phone, then Play Music was empty again.

I tried installing 1.7, which crashes whenever I try to open it.

Not sure why or what caused these issues. As I said I had been using Music2SD since shortly after it was released and it worked great.

I'm running a Samsung Galaxy S2 T989 with Android 4.1.2

Please let me know if you have any other questions or if I can help test/send logs, etc.

Thanks
 

Capt4Chris

Senior Member
Mar 9, 2011
75
16
Nashville, TN
GPM.updated today. It's now allowing me to use External SD card for storage. Running 4.3 on Note 2.

After updating Google Play Music app, I still don't see the setting in the app to download music to my SD Card BUT it does seem to allow Music2SD (with Xposed Framework) to work properly!

It's still a little weird though. If I put my phone on airplane mode after downloading, if I set the little drop-down on the upper left to "On Device", the pinned music I downloaded after activating Music2SD DOES NOT show up. If I set it to "All Music" it DOES show (and can play while offline). That ends up being confusing however because, as it says, it shows ALL music, even if it's not pinned/downloaded to the device.

Maybe it'll work itself out if I let it sit for a while. I know the system sometimes needs time to process the fact that new music (pictures, video) has been saved to the device.

UPDATE: Well, I waited a while and restarted my phone but this behavior still persists... Oh well, at least it still works for the most part!

UPDATE2: In the end, this method stopped working again. More details are included in my 3/11 post.
 
Last edited:
  • Like
Reactions: Super_Luddite

Super_Luddite

Senior Member
Jun 21, 2013
370
93
Baltimore, MD
After updating Google Play Music app, I still don't see the setting in the app to download music to my SD Card BUT it does seem to allow Music2SD (with Xposed Framework) to work properly!

It's still a little weird though. If I put my phone on airplane mode after downloading, if I set the little drop-down on the upper left to "On Device", the pinned music I downloaded after activating Music2SD DOES NOT show up. If I set it to "All Music" it DOES show (and can play while offline). That ends up being confusing however because, as it says, it shows ALL music, even if it's not pinned/downloaded to the device.

Maybe it'll work itself out if I let it sit for a while. I know the system sometimes needs time to process the fact that new music (pictures, video) has been saved to the device.

UPDATE: Well, I waited a while and restarted my phone but this behavior still persists... Oh well, at least it still works for the most part!

So in tl;dr, the songs are stored on your SD, but you can't see them pinned?

Sent from my DROID RAZR using Tapatalk
 

Top Liked Posts

  • There are no posts matching your filters.
  • 30
    NOTE: You do not need this app if you do not have external storage or if you are on KitKat or above.

    This application requires root and the Xposed Framework - http://forum.xda-developers.com/showthread.php?t=1574401

    Do you not have enough room on your Internal Storage or Device Storage for your music, but have plenty of space on your SD Card? No more with Music2SD! You can now force Google Play Music to store your music where you want it.

    How To Get Started:
    1. Install Xposed Framework Installer.- http://forum.xda-developers.com/showthread.php?t=1574401
    2. Install Xposed Framework.
    3. Install Music2SD
    4. Open Music2SD and Select a Download Storage Location.
    5. Open Xposed Framework and Enable the Music2SD Module.
    6. Restart your phone/tablet.
    7. Start downloading music!

    Currently Tested on:
    • Galaxy S4 (Running CyanogenMod 10.2)
    • Galaxy Note 2 (Running CyanogenMod 10.1)
    • Galaxy Note 10.1 (Running CyanogenMod 10.1)
    • Galaxy Note (Running CyanogenMod 10.1)
    • Infuse 4G (Running Beanstalk)
    • Nexus S 4G (Running CyanogenMod 10.2)
    • Motorola Droid (Running CyanogenMod 9)

    Google Play Store
    Source Code
    3
    I have not been able to get it to work on a verizon s3. Music is still downloading to internal storage. Do I need to delete any folders on internal storage for it to work?

    Same thing here on Sprint S3, acted as if it worked. Started re downloading but still went to internal. Any suggestions on this?

    No folders have moved at all. Should I create the parent folders then just cut and paste the files into the created folders?

    I have found an issue with Music2SD. You must create the parent folders in your SD Card first. I will release an update to fix this most likely tonight. To get it working right now simply create the following folders in the root of your SD Card: /Android/data/com.google.android.music/

    will it save from the point of the mod and you need to manually move the old folder or does the folder get moved by the app?

    The folders don't get moved I will try to add this in the next update.

    Installed this on my Samsung Galaxy S4 and am not seeing the "SD Card" option as shown within your video. My internal is at /storage/emulated/0/ ( /mnt/sdcard/ ) and my external is at /storage/extSdCard/ ( /mnt/extSdCard/ ).

    What file system are you using on your SD Card. Because Android does not have a built-in API for getting the location of the SD Card I'm left to parsing out the "mount" command and parsing out mount points that are using a FAT file system. On top of that the location for an SD Card is different per Manufacturer per rom. (If anyone know a better way of getting this information, please feel free to let me know.) :)
    2
    Change Log:
    Version 1.8
    • Fixed Method overwriting for newer version of Google Play Music.
    Version 1.7.1
    • German Localization added.
    • Added exception handling for StatFS.
    Version 1.7
    • Localization Update (Support for English, French, Italian, Japanese, Korean, Portuguese, Russian, and Spanish)
    • German Support coming soon. (Waiting on translation.)
    • Free disk space fixed. Now using StatFs built in API.
    Version 1.6.1
    • Major Bug Fix
    • SD Card Support now sends "df" command.
    Version 1.6
    • Storage Location Selector now shows path and free disk space.
    • Storage Locations that would show up as "Device" will now show up as "External"
    • Will now display removable mounts with read/write permissions that do no show up under the environment variables as "Unknown Storage". Use caution when using these.
    • Tested and works with Meenova Mini MicroSD Card Reader.
    Version 1.5.2
    • Fixes support for "mount" commands with "on" and "type" verbiage. For real this time.
    • Fixed reported NullPointer Exceptions.
    • Added additional information "SD Card Support" to help pin point device/rom specific issues.
    Version 1.5.1
    • Fixed support for "mount" commands with "on" and "type" verbiage.
    Version 1.5
    • Fixed Force Close issue.
    Version 1.4
    • Improved SD Card detection. Now doesn't look at File System, but instead looks at Environment Variables and compares them to what is mounted and has read/write access.
    • Music2SD Debugger built-in.
    • Added Admod Ads.
    Version 1.3
    • Fixed an issue with older devices that emulates a SD Card. For example the Nexus S 4G was showing Device Storage and External Storage.
    • Now checks for root access and Xposed Framework on app start.
    • Now uses root access to automatically create the necessary directories on your SD Card.
    Version 1.2
    • Code clean up.
    • Support for multiple external storage locations.
    • Tablets now work in Landscape.
    Version 1.1
    • Fixed NullPointerException while searching for SD Card on non-rooted device. (You must be rooted to use this application!)
    Version 1.0
    • Initial Release

    License:
    Code:
    Copyright (c) 2014, Lepidus Development LLC
    All rights reserved.
    
    Redistribution and use in source and binary forms, with or without modification,
    are permitted provided that the following conditions are met:
    
      Redistributions of source code must retain the above copyright notice, this
      list of conditions and the following disclaimer.
    
      Redistributions in binary form must reproduce the above copyright notice, this
      list of conditions and the following disclaimer in the documentation and/or
      other materials provided with the distribution.
    
    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
    ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
    WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
    DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
    ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
    (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
    LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
    ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
    SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    2
    Version 1.3 is now on the Google Play Store and on the main post. The source code has also been updated on GitHub.
    • Fixed an issue with older devices that emulates a SD Card. For example the Nexus S 4G was showing Device Storage and External Storage.
    • Now checks for root access and Xposed Framework on app start.
    • Now uses root access to automatically create the necessary directories on your SD Card.


    I actually had code in there to create the subdirectories. However apparently the WRITE_EXTERNAL_STORAGE permission only gives you permission to write on the device storage and not the actual SD Card. After doing some research the only way to write to the SD card is to be a system app with WRITE_MEDIA_STORAGE permission or to do it through root. Seeing as I can't sign my app as a system app, I went with doing it through root. (This is why Music2SD asks for root when you open the app now.)


    I also created a video showing how to setup Music2SD, it's on the Google Play Store listing and below:


    IMPORTANT: If you have an issue where your external storage is not showing up there will be a new application in the main post called Music2SD-Debugger.apk. Please install and run this application. It's a simple app that gets the output of the "mount" command and puts it into an email. All you have to do is send the email and then I will analyze it and improve the SD Card detection. Android does not come with a built in method for detecting and getting the path of external storage devices, which is why I'm left to these weird and hacky methods of getting the SD Card path.
    1
    Seem to have found a problem with the Music2SD app. At first the application did what it did , changing the location of Google music data to my exsd card. After updating the new version of Google Music v5.2.1233L it's seem that the Music2SD is not working and Google Music is now redownload all my music that was in my sd crad into my internal memory (5 Gb of music T_T )

    Sent from my SPH-L710 using Tapatalk

    Seems fine on my device. Both with caching new songs and downloading albums for offline play.

    Sent from my GT-N7100 using Tapatalk
Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone