Skip to main content
Question

Can't upload custom configuration file


Forum|alt.badge.img+3

Hi!

We're just starting with Jamf and we wanted to set a company webpage as a homepage in Safari. I read a little about it, found code for custom profile and wanted to have a go.

The code I found is this (replaced the site name with facebook):

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>HomePage</key>
    <string>https://www.facebook.com</string>
    <key>NewWindowBehavior</key>
    <integer>0</integer>
</dict>
</plist>

When I try to upload it, I get a message "Unable to create object from file". Weird thing is, last week I tried to make a configuration file to enable TeamViewer (the same extension and stuff) and it works perfectly, each time I'd try to do it.

What may be wrong with the file?

Forum|alt.badge.img+16
  • Honored Contributor
  • July 8, 2019

When I get the "Unable to create object from file" error.. it's usually because a profile already in Jamf has the same name or same uuid.

C


Forum|alt.badge.img+15
  • Valued Contributor
  • July 8, 2019

I would try creating a Safari profile using ProfileCreator, and then uploading a custom mobileconfig vs pasting in the plist data under the custom profile payload in Jamf.


Forum|alt.badge.img+3
  • New Contributor
  • July 19, 2019

@gachowski How exactly should I cope with this? I've change the name, what about uuid?


Forum|alt.badge.img+5
  • New Contributor
  • July 19, 2019

@kjubus Be sure both the UUID and name are different from any other profiles in the jss. We had a conflict recently and tracked it down to a duplicate profile name, even though the uuid was different. I’d always assumed that jamf only used the uuid, but no. Once i changed both items, it uploaded successfully.


Forum|alt.badge.img+16
  • Honored Contributor
  • July 19, 2019

Usually when I edit the profile in Xcode the uuid is there and I just change the last number...but I am starting to think you might not have a uuid...

Did you try with the ProfileCreator? That is what most everyone uses...

C


Forum|alt.badge.img+8
  • Valued Contributor
  • July 22, 2019

Silly question, but did you use defaults to write the plist or did you type it manually and save as a plist?

Can you try the following with any success?

Note: com.domain.plist should be replaced with com.apple.Safari.plist (if Safari are the preferences you are trying to manage)

#!/bin/bash
/usr/bin/defaults write ~/Desktop/com.domain.plist HomePage -string https://www.facebook.com
/usr/bin/defaults write ~/Desktop/com.domain.plist NewWindowBehavior -bool FALSE
/usr/bin/plutil -convert xml1 ~/Desktop/com.domain.plist

Forum|alt.badge.img+21
  • Esteemed Contributor
  • December 6, 2019

I was editing an existing mobileconfig file with ProfileCreator and tried to upload that to replace the older revision of it when I got that error. I was able to resolve my issue by running uuidgen and replacing the existing UUID with the one that was generated. it uploaded just fine after that.


Forum|alt.badge.img+6
  • Contributor
  • April 16, 2021
I was editing an existing mobileconfig file with ProfileCreator and tried to upload that to replace the older revision of it when I got that error. I was able to resolve my issue by running uuidgen and replacing the existing UUID with the one that was generated. it uploaded just fine after that.

@AVmcclint Did you change the UUID using ProfileCreator? I don't see a way to do it in the application.


Forum|alt.badge.img+21
  • Esteemed Contributor
  • April 16, 2021

I just ran the uuidgen command in Terminal. It’s been so long since I did it, I don’t know what the actual process is, but I think it just generates a new UUID and you copy/paste that into JSS.


pbenware1
Forum|alt.badge.img+12
  • Valued Contributor
  • January 13, 2022
AVmcclint wrote:

I just ran the uuidgen command in Terminal. It’s been so long since I did it, I don’t know what the actual process is, but I think it just generates a new UUID and you copy/paste that into JSS.


Just used uuidgen on a crowdstrike config profile that 2 different uuid's in it, and was apparently preventing upload.  Worked great.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings