11 Replies Latest reply: Feb 17, 2013 11:17 PM by abstert
type11 Level 1 (0 points)

I'm setting up a new Mac Mini Server with OS 10.7.3. I've run through the Profile Manager configuration and it appears to be running. When I go to https://server.domain/mydevices I get the login screen, but when I try to login I receive the following  redirect error.


The webpage at https://server.domain/auth?redirect=https://server.domain/devicemanagement/api/a uthentication/device_callback has resulted in too many redirects.


Any suggestions?

Mac mini, Mac OS X (10.7.3)
  • abstert Level 1 (5 points)

    I had the same issue and did some research, but couldn't find any answers.  I simply turned Profile Manager Off then turned it back On and that seemed to resolve the problem.  Hope that works for you.

  • kginger_consulting Level 1 (0 points)

    I have 10.7.3 with the same redirect problem when authenticating to any part of the web server (including Profile Manager) on 4S iPhones running iOS 5.0.1 -  happenes 3G and wifi.


    OSX and iPads (v.1&2) running iOS 5.0.1 don't have this problem.


    Restarting apache and Profile Manager and the whole server had no effect.

  • Mark23 Level 3 (975 points)
  • abstert Level 1 (5 points)

    Seems to be a server hostname issue.  Try this:

    Open a Terminal window and issue the commands

         scutil --get HostName

         scutil --get ComputerName

          scutil --get LocalHostName


    What do these names say?  Based on what you have in your post, they should be:

         HostName = server.domain

         ComputerName = server

         LocalHostName = server


    Let me know if this is the case and if not what else we can do to resolve this problem.

  • Twistan Level 1 (5 points)


    I just read you reply.I am having a similar problem.

    I have no problems logging into Profile Manager/My Devices on the LAN but when someone wants to connect to Profile Manager and MyDevices from the Internet they see the the Profile M.'s title window "Admin" , then the re-direct happens and Safari says it can't connect to the server.

    I checked the host names and I see HostName= server.domain and LocalHostName=server, but the Computer Name is different (=Mac Mini Server).

    BTW, clients can connect to Wiki pages from the Internet with no problems.

    All connections from the Internet use DDNS address from DynDNS to connect.


    Can this problem be caused by an incompatibility of Safari 4.1.x ?

    Or is this a SSL issue ?


    Thank you very much for help in advance.



  • abstert Level 1 (5 points)

    In your case Twistan, it sounds like it most definitely is a SSL issue.  Your wiki page works fine because the SSL is setup correctly for that service.  However, the profile manager so how or another has the incorrect information deep in the config files that is causing this issue.


    The solution might be different for you, but for me, I issued the command:

    scutil --set HostName "whatever.mydomain.is"  #No quotes of course

    scutil --set ComputerName "MacMiniServer"

    scutil --set LocalHostName "MacMiniServer"


    I then turned off Profile Manager, deleted the SSL certs, recreated the SSL certs, and restarted Profile Manager.  Everything worked fine for me then.

  • Twistan Level 1 (5 points)

    Hi abstert,

    thank you very much for your response.

    I can't take any risks today, because the server is running a few important tasks, but I will try tomorrow on a clone.

    Did you mean to set the hostname to the private hostname, i.e. 'server.name.private' or to the public hostname 'name.dyndns.org' ?

    Which host name must I use in the "Common Name" field when I create  a self-signed certicate ? The public name 'name.dyndns.org'  or the private  name 'server.name.private'  ?

    Besides, do I have to switch on the Web Server in the Server App ? The Wikis work fine without the Apache web server.

    Thanks again !


  • kb8wfh Level 1 (5 points)

    Hi. I am having a similar problem. Did you ever find a solution to this issue? Thanks.

  • Twistan Level 1 (5 points)

    Well, I meanwhile managed to get most services up and running, all in all quite a time consuming process though.

    Did you set up your server with a public dynamic DNS hostname such as name.dyndns,org or as a private server ?

    If I remember well I set up the server as a public server (which makes sense if you want to use Profile and Device Manager) and I re-created the Open Direcory database and the server SSL's as described in one of my recent posts:




    If you follow these steps religiously you should be able to get all services up and running.


    Of course, DNS should also be working properly.


    I did not mention in that post that if applicable all server databases should be be backed-up (dumped) as described for example in an article by Jason Bosket (Sep 2011 on Sourcenetworks, sorry, I could not find the URL anymore).


    Hope that helps to give you an idea.





    NB. I am not an expert, just an experienced Mac user.

  • kb8wfh Level 1 (5 points)

    I finally solved this just a day ro so ago. Now my server crashed from something else and its being restored, but at least I think I know what the issue was.


    I had my server name as server.servername.private and had one of those dynamic IP services point to it with an external domain name. I emailed a very helpful and friendly fellow on YouTube by the name of Todd Olthoff who has some great videos on OS X Server. He told me to consider changing my server name to my external domain name. I was worried about doing that because everything else was working and didn't want to mess it up. But I tried anyway and it worked like a charm. The only other thing I had to do was change the certificate my system used to the new one the server crated once I changed its name. Like I said, everything worked fine now, and no redirects to a server name that didn't work. Give that a try.

  • abstert Level 1 (5 points)

    I can confirm that changing the name of the server to that of the external domain name will make profile manager work properly. 


    For example, if your external DDNS domain name is something like "mymacmini.dlinkddns.com" and your computer's fully qualified domain name is something like "JohnSmithsMac.local" this will not work.  The fix is to rename your mac something like this to match your DDNS domain "JohnSmithsMac.mymacmini.dlinkddns.com".  You then configure your router to forward the specified ports for Profile Manager to that server.


    I hope this is the method you used as it has been working for me now for over a year.  Let me know if you have any questions.