Refresh devices in team provisioning profile managed by Xcode 7?

57,501

Solution 1

After adding the UDID in the member center I had the same issue. I have to say that I have a XCode managed iOS team development profile.

eventually what's worked is deleting the provisioning profile from the member center.

in xcode preferences, delete the team provisioning profile for the relevant app

go to your target, you'll see a "Fix Issue" button. click it, it will generate a new provisioning profile with the relevant devices.

Hope it helps.

Solution 2

Here's what worked for me on Xcode 8 & 9.

  1. Add your device to developer.apple.com.
  2. Go to your target's General tab and tap the (i) next to "Xcode Managed Profile", then drag the profile file icon in that popover to your desktop to get the filename of the provisioning profile. enter image description here
  3. Go to ~/Library/MobileDevice/Provisioning Profiles and delete the provisioning profile with the same filename that you got in #2.
  4. Xcode should regenerate the profile for your app with the device added in #1.

My account on developer.apple.com was not showing any Xcode managed profiles so this was the only way to make it work.

Solution 3

Simplest way:

Remove the mobileprovision file using terminal

rm + drag the file path from xcode

enter image description here

Solution 4

I also had this problem. I am using Xcode 7.2. Then its worked with following steps:

  1. Add you new device UDID in the Member Center
  2. Take Xcode -> Preference...
  3. Select account and press 'View Details...'
  4. Press 'Download All' button in bottom-left corner. New set of Team Provisioning Profiles will be downloaded.
  5. Now you can delete the old Team Provisioning Profiles from the list. (Right click -> Move to Trash)
  6. Update Provisioning Profile in 'Build Settings' Tab
  7. Press 'Fix Issue' button in 'General' Tab

Now you can run the app in your new device.

Solution 5

Spent a lot of time trying to fix the same issue on Xcode 7 i.e. refreshing the Xcode managed provisioning profiles.

After adding the UDID in the member center, what worked for me was just removing the account from preferences -> account and adding it back again. It updated all the provisioning profiles.

Share:
57,501
Will Larche
Author by

Will Larche

Software Engineer on Material Components

Updated on July 05, 2022

Comments

  • Will Larche
    Will Larche almost 2 years

    It used to be that hitting the refresh arrow/loop button in preferences -> account would pull down a new provisioning profile with all ur new devices.

    Now it just downloads the ones you already have. But if the one you need updated is managed by Xcode, theres's no way I can find to add a device to it!

  • Will Larche
    Will Larche over 8 years
    Yeah. This does indeed work. 2 steps forward, 1 step back :)
  • Eric Chen
    Eric Chen over 8 years
    Thanks! Out of all the solutions online this is the real one.
  • Matheus Guimaraes
    Matheus Guimaraes over 8 years
    an update to this answer: this could be a new thing with the latest update to XCode 7 (version 7.0.1 (7A1001) ) but there isn't an option to delete provisioning profiles anymore. If you right-click on them nothing happens. The way I finally managed to get it to add my device to a provisioning profile was by deploying a test project to it. XCode then prompted me saying the device doesn't belong to any provisioning profiles and gave me the "Fix Issue" option. By the way, it wasn't enough to just hit fix issue, I had to actually let it finish deploy the test application on it
  • Youval Vaknin
    Youval Vaknin over 8 years
    @MatheusGuimaraes - I can still send the profiles to trash on build 7A1001. maybe it's an admin account issue on you mac?
  • Dave Nottage
    Dave Nottage over 8 years
    Yeah, it wasn't "automagic" for me, either. I ended up deleting the profile from the developer site, re-add one (including the new device), then go to Xcode preferences Accounts page, re-download, show it in Finder, copy it to another location. go to the Devices window and install it on the new device.
  • Zapko
    Zapko over 8 years
    Thanks, it works! This way seems to be better than deleting a profile by hands.
  • Mike Lambert
    Mike Lambert over 8 years
    This is the one that worked for me, as of XCode 7.1.1! Didn't need to add a never-seen-before device (I don't have an extra one), and didn't need to deploy a new test project to the device (wanted to try other answers first). But th
  • Mark A. Durham
    Mark A. Durham about 8 years
    As an alternative to downloading all the profiles and then deleting old profiles one-at-a-time with a right click, you can right-click any old provisioning profile and select "Show in Finder", (quit Xcode), shift-select all of the profiles in Finder and drag them into Trash (or right-click and select "Move to Trash"), (restart Xcode), and then download just the profiles you want/need. (Not certain if quitting/restarting Xcode is necessary, but better safe than sorry.)
  • Mike Taverne
    Mike Taverne almost 8 years
    For me, steps 1-4 were sufficient to refresh the provisioning profile to include the new device.
  • Gerrit Horeis
    Gerrit Horeis almost 8 years
    How can I achieve this when I'm only having the free developer account? In my member center I can't manage my provisioning profiles...
  • Tony Adams
    Tony Adams over 7 years
    In Xcode 8.1 there is an Preferences->Accounts->[Account name]->View Details button which shows Signing Identities and Provisioning Profiles for that account. A right click on a profile offers the ability to delete. Deleting the Team Provisioning profile for the account refreshed mine and the new UUID worked fine. (This was for a dev deployment via Fabric).
  • Alireza Mirian
    Alireza Mirian about 7 years
    sorry but where is "Build Settings" tab mentioned in step 6?
  • Alireza Mirian
    Alireza Mirian about 7 years
    Found it. You need to know that double clicking the project name in project manager opens a very important project settings section. I hate x-code!
  • Rob
    Rob almost 7 years
    This worked for me. I decided to try this answer before any other answers because it seemed like one of the least risky suggestions on this thread. My app is provisioned for APNS, for example. So the risks felt high. In fact, I only deleted the specific profile that I needed to automagically update (step. 5) so that I didn't have to touch the other profiles. @anusha-k saved my life. I've seen Xcode spiral into a freefall when you mess up provisioning, and I was really relieved this worked perfectly.
  • marsbear
    marsbear almost 7 years
    This does not work for refreshing an existing profile (e.g. when adding more devices). You still have to delete the profile on the disk.
  • Eugene
    Eugene almost 7 years
    This finally did it for me after adding devices for Fabric/Crashlytics Beta distribution. It's a shame their "Beta Walkthrough" documentation page still doesn't reflect this difference in Xcode 8. Thank you.
  • greaterKing
    greaterKing almost 7 years
    1. yup just added the device developer.apple.com 2. download the profile 3. re-import it in the General tab (click on the dropdown under Signing Debug and choose import profile) ...that should include the newly added device.
  • Kevin Machado
    Kevin Machado over 6 years
    Love you @yood, I was struggling me with that hidden provisioning profile :)
  • Michele Dall'Agata
    Michele Dall'Agata over 6 years
    That works. But how do I refresh the 7 days whenever I want? It's a pain to wait for the certificates to expire, I'd like to automate it running a script daily (it's for Kodi on Apple TV 4K).
  • Mihai Erős
    Mihai Erős about 6 years
    It works! I thought since Xcode 8 I can't do this anymore, thanks a lot.
  • Admin
    Admin over 5 years
    Worked for Fabric/Crashlytics/Beta on XCode 9. Thanks
  • Jonathan Cabrera
    Jonathan Cabrera over 5 years
    This is the fastest way to do it. After removing, just go back to Xcode and it will re-create the profile with the new devices.
  • Jackson
    Jackson over 5 years
    I got this to work in Xcode 10 / Mojave by just deleting everything in ~/Library/MobileDevice/Provisioning Profiles. None of them had recognizable names. But by deleting all, Xcode fixed it and it works now. 2 hours of my day wasted.
  • balazs630
    balazs630 over 5 years
    Somehow Xcode 10 was not creating the ~ iOS Team Provisioning Profile: com.xyz.appname for one of our project. Your solution worked fine! Thank you :)
  • Ilya Ilin
    Ilya Ilin almost 5 years
    You can just move this file to Safari in URL field and it will open it for you in Finder
  • Danny
    Danny almost 4 years
    This seems to be the only reliable way to do this even as of XCode 11, and it's just maddening that it's so hacky. Why on earth doesn't XCode give you a way to just refresh the automatic profiles? It seems like such an obvious need