1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

provisioning profilesが読み込めない時の解決策(物理)

Last updated at Posted at 2021-08-07

問題

Apple Developerからprovisioning profilesをDLして、ダブルクリックでXcodeに読み込ませようとすると、下記エラーによって読み込めない。

Failed to install one or more provisioning profiles on the device.

Please ensure the provisioning profile is configured for this device. If not, please try to generate a new profile.

スクリーンショット 2021-08-07 15.27.57.png

解決策

DLしたprovisioning profilesのファイル名を適切に書き換えて、provisioning profilesを保存するディレクトリに直接ぶちこめばOK。

  1. provisioning profilesをエディタなどで開く
  2. 開いたファイルの下の方にprovisioning profilesのUUIDが記載されているので、それをコピーして、ファイル名をfc033375-dde5-413f-9077-2fbcda719d7e.mobileprovisionのように書き換える
  3. /Users/ユーザ名/Library/MobileDevice/Provisioning Profilesの中に名前を書き換えたprovisioning profilesを保存する。
  4. Xcodeを再起動すればprovisioning profilesが新しいものに変わっているはず。

UUIDの場所

<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>AppIDName</key>

        ・・・省略
	
	<key>TimeToLive</key>
	<integer>365</integer>
	<key>UUID</key>
	<string>fc033375-dde5-413f-9077-2fbcda719d7e</string>←これ!!!
	<key>Version</key>
	<integer>1</integer>
</dict>

後書き

こちらの記事では上書きができないのが原因だから、同じファイル名のprovisioning profilesを削除すればOKとあるが、自分の場合はそもそも同じファイル名のprovisioning profilesは存在していなかった。
なんとなく想像される原因は、Xcodeのバージョンを複数使うためにXcodeの名前を変えて複数インストールしているとかかもしれない。
今回の手法は根本的な解決策ではないので、provisioning profilesの更新のたびのこの作業を行うのはめんどくさい。

1
1
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?